From ef3aa060f064f59a01e993ed5a1bc44a38a731b6 Mon Sep 17 00:00:00 2001
From: Stanislava Nedyalkova <stanislava@present-technologies.com>
Date: Fri, 19 Feb 2016 19:18:16 +0000
Subject: [PATCH 01/50] Fix issue #480

https://github.com/json-schema-form/angular-schema-form/issues/480
---
 src/default.html | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/default.html b/src/default.html
index b2b2184..a7a2546 100644
--- a/src/default.html
+++ b/src/default.html
@@ -1,5 +1,5 @@
-<div class="form-group schema-form-{{form.type}} {{form.htmlClass}}"
-     ng-class="{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }">
+<div class="form-group {{form.htmlClass}}"
+     ng-class="{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }">
   <label class="control-label {{form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>
 
   <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"

From 63cab9f54723d8b1a32ce40bc0337a72fa1a016e Mon Sep 17 00:00:00 2001
From: Stanislava Nedyalkova <stanislava@present-technologies.com>
Date: Fri, 19 Feb 2016 19:25:38 +0000
Subject: [PATCH 02/50] Add missing validation feedback flags

---
 src/default.html | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/default.html b/src/default.html
index a7a2546..86b20ad 100644
--- a/src/default.html
+++ b/src/default.html
@@ -41,7 +41,7 @@
 
   <span ng-if="form.feedback !== false"
         class="form-control-feedback"
-        ng-class="evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': hasSuccess(), 'glyphicon-remove': hasError() }"
+        ng-class="evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }"
         aria-hidden="true"></span>
 
   <span ng-if="hasError() || hasSuccess()"

From ccfe62627cc0911e9ff27bcf4087226a90d5c852 Mon Sep 17 00:00:00 2001
From: Marcel J Bennett <iamanthropic@gmail.com>
Date: Thu, 3 Mar 2016 18:12:19 +1100
Subject: [PATCH 03/50] Update default.html

Accept pull changes from @Schinkentanz pull request (https://github.com/json-schema-form/angular-schema-form/pull/434)
---
 src/default.html | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/default.html b/src/default.html
index b2b2184..4415195 100644
--- a/src/default.html
+++ b/src/default.html
@@ -41,7 +41,7 @@
 
   <span ng-if="form.feedback !== false"
         class="form-control-feedback"
-        ng-class="evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': hasSuccess(), 'glyphicon-remove': hasError() }"
+        ng-class="evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }"
         aria-hidden="true"></span>
 
   <span ng-if="hasError() || hasSuccess()"

From 468a58013554a5c658563cc1080c475dd5fb69e8 Mon Sep 17 00:00:00 2001
From: kornosaurus <simon.korn@textalk.se>
Date: Fri, 18 Mar 2016 09:41:53 +0100
Subject: [PATCH 04/50] Support for placeholder key on select type

---
 examples/data/titlemaps.json |  2 ++
 src/bootstrap-decorator.js   | 26 +++++++++++++++++++++++++-
 2 files changed, 27 insertions(+), 1 deletion(-)

diff --git a/examples/data/titlemaps.json b/examples/data/titlemaps.json
index e56cc5f..cd99411 100644
--- a/examples/data/titlemaps.json
+++ b/examples/data/titlemaps.json
@@ -51,6 +51,7 @@
     {
       "key": "select2",
       "type": "select",
+      "placeholder": "Please choose",
       "titleMap": {
         "a": "A",
         "b": "B",
@@ -60,6 +61,7 @@
     {
       "key": "noenum",
       "type": "select",
+      "placeholder": "Please choose",
       "titleMap": [
         { "value":"a", "name": "A" },
         { "value":"b", "name":"B" },
diff --git a/src/bootstrap-decorator.js b/src/bootstrap-decorator.js
index 8c20653..37ae763 100644
--- a/src/bootstrap-decorator.js
+++ b/src/bootstrap-decorator.js
@@ -28,6 +28,30 @@ function(decoratorsProvider, sfBuilderProvider, sfPathProvider) {
     }
   };
 
+  var selectPlaceholder = function(args) {
+    if (args.form.placeholder) {
+      var selectBox = args.fieldFrag.querySelector('select');
+      var option = document.createElement('option');
+      option.setAttribute('value', '');
+
+      // We only want the placeholder to show when we do not have a value on the model.
+      // We make ngModel builder replace all so we can use $$value$$.
+      option.setAttribute('sf-field-model', 'replaceAll');
+
+      // https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
+      // emptyOption.attr('selected', true) does not like the ng-if comment.
+      if (angular.version.major === 1 && angular.version.minor < 4) {
+        option.setAttribute('ng-if', '!$$value$$');
+      } else {
+        option.setAttribute('ng-show', '!$$value$$');
+      }
+
+      option.textContent = args.form.placeholder;
+
+      selectBox.appendChild(option);
+    }
+  };
+
   var defaults = [sfField, ngModel, ngModelOptions, condition];
   decoratorsProvider.defineDecorator('bootstrapDecorator', {
     textarea: {template: base + 'textarea.html', builder: defaults},
@@ -38,7 +62,7 @@ function(decoratorsProvider, sfBuilderProvider, sfPathProvider) {
     section: {template: base + 'section.html', builder: [sfField, simpleTransclusion, condition]},
     conditional: {template: base + 'section.html', builder: [sfField, simpleTransclusion, condition]},
     actions: {template: base + 'actions.html', builder: defaults},
-    select: {template: base + 'select.html', builder: defaults},
+    select: {template: base + 'select.html', builder: [selectPlaceholder, sfField, ngModel, ngModelOptions, condition]},
     checkbox: {template: base + 'checkbox.html', builder: defaults},
     checkboxes: {template: base + 'checkboxes.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
     number: {template: base + 'default.html', builder: defaults},

From 496932ff751ed26e52b207e9ac09f9a3da00c556 Mon Sep 17 00:00:00 2001
From: kornosaurus <simon.korn@textalk.se>
Date: Fri, 18 Mar 2016 09:50:04 +0100
Subject: [PATCH 05/50] Better comments inside selectPlaceholder builder

---
 src/bootstrap-decorator.js | 11 +++++++----
 1 file changed, 7 insertions(+), 4 deletions(-)

diff --git a/src/bootstrap-decorator.js b/src/bootstrap-decorator.js
index 37ae763..564458c 100644
--- a/src/bootstrap-decorator.js
+++ b/src/bootstrap-decorator.js
@@ -34,12 +34,15 @@ function(decoratorsProvider, sfBuilderProvider, sfPathProvider) {
       var option = document.createElement('option');
       option.setAttribute('value', '');
 
-      // We only want the placeholder to show when we do not have a value on the model.
-      // We make ngModel builder replace all so we can use $$value$$.
+      /* We only want the placeholder to show when we do not have a value on the model.
+       * We make ngModel builder replace all so we can use $$value$$.
+       */
       option.setAttribute('sf-field-model', 'replaceAll');
 
-      // https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
-      // emptyOption.attr('selected', true) does not like the ng-if comment.
+      /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
+       * angular > 1.4 does a emptyOption.attr('selected', true)
+       * which does not like the ng-if comment.
+       */
       if (angular.version.major === 1 && angular.version.minor < 4) {
         option.setAttribute('ng-if', '!$$value$$');
       } else {

From 7c8e25dae859117b0fddfaa7ed5a27ddeb7d389d Mon Sep 17 00:00:00 2001
From: kornosaurus <simon.korn@textalk.se>
Date: Mon, 21 Mar 2016 13:20:09 +0100
Subject: [PATCH 06/50] $$value$$ could be something other than a string, like
 a boolean.. so we need to check if $$value$$ is undefined instead

---
 src/bootstrap-decorator.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/bootstrap-decorator.js b/src/bootstrap-decorator.js
index 564458c..4f9ee32 100644
--- a/src/bootstrap-decorator.js
+++ b/src/bootstrap-decorator.js
@@ -44,9 +44,9 @@ function(decoratorsProvider, sfBuilderProvider, sfPathProvider) {
        * which does not like the ng-if comment.
        */
       if (angular.version.major === 1 && angular.version.minor < 4) {
-        option.setAttribute('ng-if', '!$$value$$');
+        option.setAttribute('ng-if', '$$value$$ === undefined');
       } else {
-        option.setAttribute('ng-show', '!$$value$$');
+        option.setAttribute('ng-show', '$$value$$ === undefined');
       }
 
       option.textContent = args.form.placeholder;

From 11aee56916c71648d80ee066030f46f172485015 Mon Sep 17 00:00:00 2001
From: Joel Kent <joel.kent@thomsonreuters.com>
Date: Sat, 16 Apr 2016 23:57:52 +0100
Subject: [PATCH 07/50] Sortable tab array

---
 src/tabarray.html | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/src/tabarray.html b/src/tabarray.html
index e7a5b8a..e6e3c02 100644
--- a/src/tabarray.html
+++ b/src/tabarray.html
@@ -6,8 +6,9 @@
      class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{form.htmlClass}}">
   <div ng-if="!form.tabType || form.tabType !== 'right'"
        ng-class="{'col-xs-3': !form.tabType || form.tabType === 'left'}">
-    <ul class="nav nav-tabs"
-        ng-class="{ 'tabs-left': !form.tabType || form.tabType === 'left'}">
+    <ol class="nav nav-tabs"
+        ng-class="{ 'tabs-left': !form.tabType || form.tabType === 'left'}"
+        sf-field-model ui-sortable="{items: 'li:not(:last-child)'}">
       <li sf-field-model="ng-repeat"
           ng-repeat="item in $$value$$ track by $index"
           ng-click="$event.preventDefault() || (selected.tab = $index)"
@@ -22,7 +23,7 @@
           {{ form.add || 'Add'}}
           </a>
       </li>
-    </ul>
+    </ol>
   </div>
 
   <div ng-class="{'col-xs-9': !form.tabType || form.tabType === 'left' || form.tabType === 'right'}">

From 0a8858615954f242e333bdcdb12e81b919a2a439 Mon Sep 17 00:00:00 2001
From: Joel Kent <joel.kent@thomsonreuters.com>
Date: Mon, 18 Apr 2016 10:20:36 +0100
Subject: [PATCH 08/50] Support for sortOptions

The ui-sortable directive is now passed sortOptions.
sortOptions.items defaults to ignore the last list item.
---
 src/bootstrap-decorator.js | 13 ++++++++++++-
 src/tabarray.html          |  2 +-
 2 files changed, 13 insertions(+), 2 deletions(-)

diff --git a/src/bootstrap-decorator.js b/src/bootstrap-decorator.js
index 8c20653..1deb784 100644
--- a/src/bootstrap-decorator.js
+++ b/src/bootstrap-decorator.js
@@ -27,13 +27,24 @@ function(decoratorsProvider, sfBuilderProvider, sfPathProvider) {
       });
     }
   };
+  
+  // Set tabArray sortOptions.items default.
+  var tabArray = function(args) {
+    if(args.form.hasOwnProperty('sortOptions')) {
+      if(!args.form.sortOptions.hasOwnProperty('items')) {
+        args.form.sortOptions['items'] = 'li:not(:last-child)';
+      }
+    } else {
+      args.form['sortOptions'] = {items: 'li:not(:last-child)'};
+    }
+  }
 
   var defaults = [sfField, ngModel, ngModelOptions, condition];
   decoratorsProvider.defineDecorator('bootstrapDecorator', {
     textarea: {template: base + 'textarea.html', builder: defaults},
     fieldset: {template: base + 'fieldset.html', builder: [sfField, simpleTransclusion, condition]},
     array: {template: base + 'array.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    tabarray: {template: base + 'tabarray.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    tabarray: {template: base + 'tabarray.html', builder: [sfField, ngModelOptions, ngModel, array, condition, tabArray]},
     tabs: {template: base + 'tabs.html', builder: [sfField, ngModelOptions, tabs, condition]},
     section: {template: base + 'section.html', builder: [sfField, simpleTransclusion, condition]},
     conditional: {template: base + 'section.html', builder: [sfField, simpleTransclusion, condition]},
diff --git a/src/tabarray.html b/src/tabarray.html
index e6e3c02..45bfbb9 100644
--- a/src/tabarray.html
+++ b/src/tabarray.html
@@ -8,7 +8,7 @@
        ng-class="{'col-xs-3': !form.tabType || form.tabType === 'left'}">
     <ol class="nav nav-tabs"
         ng-class="{ 'tabs-left': !form.tabType || form.tabType === 'left'}"
-        sf-field-model ui-sortable="{items: 'li:not(:last-child)'}">
+        sf-field-model ui-sortable="form.sortOptions">
       <li sf-field-model="ng-repeat"
           ng-repeat="item in $$value$$ track by $index"
           ng-click="$event.preventDefault() || (selected.tab = $index)"

From 52c64ffd53cd19eec9b72c28b5607d2c7bfecce1 Mon Sep 17 00:00:00 2001
From: Joel Kent <joel.kent@thomsonreuters.com>
Date: Mon, 25 Apr 2016 21:32:35 +0100
Subject: [PATCH 09/50] Example and protractor test for sortable tab arrays

---
 examples/sortable-tabarray.html            | 68 ++++++++++++++++++++++
 gulp/tasks/protractor.js                   |  2 +-
 test/protractor/specs/sortable-tabarray.js | 63 ++++++++++++++++++++
 3 files changed, 132 insertions(+), 1 deletion(-)
 create mode 100644 examples/sortable-tabarray.html
 create mode 100644 test/protractor/specs/sortable-tabarray.js

diff --git a/examples/sortable-tabarray.html b/examples/sortable-tabarray.html
new file mode 100644
index 0000000..50db452
--- /dev/null
+++ b/examples/sortable-tabarray.html
@@ -0,0 +1,68 @@
+<!doctype html>
+    <head>
+        <meta charset="utf-8">
+        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+        <title>Sortable tabArray</title>
+        <meta name="description" content="">
+        <meta name="viewport" content="width=device-width, initial-scale=1">
+        <link rel="apple-touch-icon" href="apple-touch-icon.png">
+
+        <link rel="stylesheet" href="../bower_components/bootstrap/dist/css/bootstrap.min.css">
+        <link rel="stylesheet" href="../bower_components/bootstrap/dist/css/bootstrap-theme.min.css">
+        <link rel="stylesheet" href="../bower_components/bootstrap-vertical-tabs/bootstrap.vertical-tabs.min.css">
+        
+        <script type="text/javascript" src="../bower_components/jquery/dist/jquery.min.js"></script>
+        <script type="text/javascript" src="../bower_components/angular/angular.min.js"></script>
+        <script type="text/javascript" src="../bower_components/angular-sanitize/angular-sanitize.min.js"></script>
+        <script type="text/javascript" src="../bower_components/tv4/tv4.js"></script>
+        <script type="text/javascript" src="../bower_components/objectpath/lib/ObjectPath.js"></script>
+        <script type="text/javascript" src="../bower_components/angular-schema-form/dist/schema-form.js"></script>
+        <script type="text/javascript" src="../bootstrap-decorator.js"></script>
+        <script type="text/javascript" src="../bower_components/angular-ui-sortable/sortable.min.js"></script>
+        <script type="text/javascript" src="../bower_components/jquery-ui/jquery-ui.min.js"></script>
+        
+        <script type="text/javascript">
+          var exampleApp = angular.module('exampleApp',['schemaForm', 'ui.sortable']);
+          
+          exampleApp.controller('exampleCtrl', ['$scope', function($scope) {
+            
+            $scope.model = {};
+            
+            $scope.schema = {
+              "type": "object",
+              "properties": {
+                "sortable-tabarray": {
+                  "type": "array",
+                  "items": { 
+                    "type": "object", 
+                    "properties": { 
+                      "name": { "type": "string" }, 
+                      "nick": { "type": "string" }
+                    }
+                  }
+                }
+              }
+            };
+
+            $scope.form = [
+              {
+                "key": "sortable-tabarray",
+                "type": "tabarray",
+                "title": "My name is: {{ value.name }}",
+                "items" : [
+                  {"key": "sortable-tabarray[].name", "htmlClass": "nameField"},
+                  {"key": "sortable-tabarray[].nick", "htmlClass": "nickField"}
+                ]
+              }
+            ];
+          }]);
+        </script>
+    </head>
+    <body ng-app="exampleApp" class="container">
+      <h3>Sortable Tab Array</h3>
+      <p>Drag and drop tabs to order the elements in the array</p>
+      <div class="container" ng-controller="exampleCtrl" style="margin: 0 auto;width: 100%;">
+        <form sf-schema="schema" sf-form="form" sf-model="model"></form>
+      </div>
+    </body>
+</html>
diff --git a/gulp/tasks/protractor.js b/gulp/tasks/protractor.js
index 9a3bb18..aaee0c6 100644
--- a/gulp/tasks/protractor.js
+++ b/gulp/tasks/protractor.js
@@ -27,7 +27,7 @@ gulp.task('protractor', ['webdriver-update'], function(cb) {
   }).on('end', cb);
 });
 
-['validation-messages', 'custom-validation'].forEach(function(name) {
+['validation-messages', 'custom-validation', 'sortable-tabarray'].forEach(function(name) {
   gulp.task('protractor:' + name, ['webdriver-update'], function(cb) {
     gulp.src(['test/protractor/specs/' + name + '.js']).pipe(protractor.protractor({
       configFile: 'test/protractor/conf.js',
diff --git a/test/protractor/specs/sortable-tabarray.js b/test/protractor/specs/sortable-tabarray.js
new file mode 100644
index 0000000..a18611c
--- /dev/null
+++ b/test/protractor/specs/sortable-tabarray.js
@@ -0,0 +1,63 @@
+describe('sortable tabarray', function () {
+    function checkDragDrop(i) {
+      browser.driver.wait(protractor.until.elementLocated(by.xpath("//ol/li[1]/a[text()='My name is: Name " + (i + 1) +"']")), 10000);
+      expect(element.all(by.css('.nav-tabs li a')).get(0).getText()).toBe('My name is: Name ' + (i + 1));
+    }
+    
+    function populateTab(i) {
+      browser.driver.wait(protractor.until.elementLocated(by.css('.tab-pane.active.index' + i)), 5000);
+      
+      browser.driver.wait(protractor.until.elementLocated(by.css('.tab-pane.index' + i + ' div.nickField > input')), 5000);
+      input = element.all(by.css('.tab-pane.index' + i + '  div.nickField > input')).first();
+      input.sendKeys('Nickname ' + i);
+      
+      browser.driver.wait(protractor.until.elementLocated(by.css('.tab-pane.index' + i + ' div.nameField > input')), 5000);
+      input = element.all(by.css('.tab-pane.index' + i + ' div.nameField > input')).first();
+      input.sendKeys('Name ' + i);
+      
+      browser.driver.wait(protractor.until.elementLocated(by.linkText('My name is: Name ' + i)), 10000); 
+    }
+    
+    it('form should exist', function () {
+        browser.get('http://localhost:8080/examples/sortable-tabarray.html');
+
+        expect(element(by.css('form')).getInnerHtml()).not.toEqual('');
+    });
+    
+    it('should be able order elements in array by dragging the tabs', function () {
+        browser.get('http://localhost:8080/examples/sortable-tabarray.html');
+        
+        var i;
+        var elementsToAdd = 9;
+
+        /* the array starts with 1 element, populate the first element */
+        populateTab(0);
+        
+        /* add elements and populate */
+        for (i = 1; i <= elementsToAdd; i++) {
+            var tabLink = element.all(by.css('.glyphicon-plus'));
+            tabLink.click().then(populateTab(i));
+        }
+
+        /* continue when all tabs have been populated*/
+        browser.driver.wait(protractor.until.elementLocated(by.linkText('My name is: Name ' + elementsToAdd)), 10000);
+        
+        /* check the number of tabs */
+        var tabs = element.all(by.css('.nav-tabs li'));
+        expect(tabs.count()).toBe(elementsToAdd + 2); //Extra 1 for the "+ Add" link
+
+        /* drag the tabs into reverse order (descending) */
+        for (i = 0; i < elementsToAdd; i++) {
+            var draggable_element = element.all(by.css('.nav-tabs li')).get(0);
+            var target_element = element.all(by.css('.nav-tabs li')).get(elementsToAdd - i);
+            expect(draggable_element.isPresent()).toEqual(true);
+            expect(target_element.isPresent()).toEqual(true);
+            browser.actions().dragAndDrop(draggable_element, target_element).perform().then(checkDragDrop(i));
+        }
+        
+        /* final check of the reverse ordered tabs */
+        for (i = 0; i <= elementsToAdd; i++) {
+            expect(element.all(by.css('.nav-tabs li a')).get(i).getText()).toBe('My name is: Name ' + (elementsToAdd - i));
+        }
+    });
+});
\ No newline at end of file

From 857b5f88c7059085e49c1b346059cf7fa136ec87 Mon Sep 17 00:00:00 2001
From: Joel Kent <joel.kent@thomsonreuters.com>
Date: Tue, 26 Apr 2016 16:59:21 +0100
Subject: [PATCH 10/50] Hide the Add link and Remove button if set to null

Tab array updated to behave the same as arrays where the Add link and
Remove button are hidden if set to null
---
 src/tabarray.html | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/tabarray.html b/src/tabarray.html
index 45bfbb9..1e8de1b 100644
--- a/src/tabarray.html
+++ b/src/tabarray.html
@@ -15,7 +15,7 @@
           ng-class="{active: selected.tab === $index}">
           <a href="#">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>
       </li>
-      <li ng-hide="form.readonly"
+      <li ng-hide="form.readonly || form.add === null"
           ng-disabled="form.schema.maxItems <= modelArray.length"
           ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">
         <a href="#">
@@ -36,7 +36,7 @@
 
            <div schema-form-array-items></div>
 
-           <button ng-hide="form.readonly"
+           <button ng-hide="form.readonly || form.remove === null"
                    ng-click="selected.tab = deleteFromArray($index).length - 1"
                    ng-disabled="form.schema.minItems >= modelArray.length"
                    type="button"
@@ -60,7 +60,7 @@
           ng-class="{active: selected.tab === $index}">
           <a href="#">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>
       </li>
-      <li ng-hide="form.readonly"
+      <li ng-hide="form.readonly || form.add === null"
           ng-disabled="form.schema.maxItems <= modelArray.length"
           ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">
         <a href="#">

From a24eebc44dc5f8dad3e933da7d1b26f1d76e7d6c Mon Sep 17 00:00:00 2001
From: Joel Kent <joel.kent@thomsonreuters.com>
Date: Wed, 27 Apr 2016 16:36:03 +0100
Subject: [PATCH 11/50] Example and tests include hiding Add and Remove

The example has been extended to include 4 tab array demos:
standard, add link disabled, remove button disabled and
drag and drop sortable. The protractor tests have been extended to
test add link disabled and remove button disabled.
---
 examples/sortable-tabarray.html            |  68 -------
 examples/tabarray.html                     | 202 +++++++++++++++++++++
 gulp/tasks/protractor.js                   |   2 +-
 test/protractor/specs/sortable-tabarray.js |  63 -------
 test/protractor/specs/tabarray.js          | 109 +++++++++++
 5 files changed, 312 insertions(+), 132 deletions(-)
 delete mode 100644 examples/sortable-tabarray.html
 create mode 100644 examples/tabarray.html
 delete mode 100644 test/protractor/specs/sortable-tabarray.js
 create mode 100644 test/protractor/specs/tabarray.js

diff --git a/examples/sortable-tabarray.html b/examples/sortable-tabarray.html
deleted file mode 100644
index 50db452..0000000
--- a/examples/sortable-tabarray.html
+++ /dev/null
@@ -1,68 +0,0 @@
-<!doctype html>
-    <head>
-        <meta charset="utf-8">
-        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
-        <title>Sortable tabArray</title>
-        <meta name="description" content="">
-        <meta name="viewport" content="width=device-width, initial-scale=1">
-        <link rel="apple-touch-icon" href="apple-touch-icon.png">
-
-        <link rel="stylesheet" href="../bower_components/bootstrap/dist/css/bootstrap.min.css">
-        <link rel="stylesheet" href="../bower_components/bootstrap/dist/css/bootstrap-theme.min.css">
-        <link rel="stylesheet" href="../bower_components/bootstrap-vertical-tabs/bootstrap.vertical-tabs.min.css">
-        
-        <script type="text/javascript" src="../bower_components/jquery/dist/jquery.min.js"></script>
-        <script type="text/javascript" src="../bower_components/angular/angular.min.js"></script>
-        <script type="text/javascript" src="../bower_components/angular-sanitize/angular-sanitize.min.js"></script>
-        <script type="text/javascript" src="../bower_components/tv4/tv4.js"></script>
-        <script type="text/javascript" src="../bower_components/objectpath/lib/ObjectPath.js"></script>
-        <script type="text/javascript" src="../bower_components/angular-schema-form/dist/schema-form.js"></script>
-        <script type="text/javascript" src="../bootstrap-decorator.js"></script>
-        <script type="text/javascript" src="../bower_components/angular-ui-sortable/sortable.min.js"></script>
-        <script type="text/javascript" src="../bower_components/jquery-ui/jquery-ui.min.js"></script>
-        
-        <script type="text/javascript">
-          var exampleApp = angular.module('exampleApp',['schemaForm', 'ui.sortable']);
-          
-          exampleApp.controller('exampleCtrl', ['$scope', function($scope) {
-            
-            $scope.model = {};
-            
-            $scope.schema = {
-              "type": "object",
-              "properties": {
-                "sortable-tabarray": {
-                  "type": "array",
-                  "items": { 
-                    "type": "object", 
-                    "properties": { 
-                      "name": { "type": "string" }, 
-                      "nick": { "type": "string" }
-                    }
-                  }
-                }
-              }
-            };
-
-            $scope.form = [
-              {
-                "key": "sortable-tabarray",
-                "type": "tabarray",
-                "title": "My name is: {{ value.name }}",
-                "items" : [
-                  {"key": "sortable-tabarray[].name", "htmlClass": "nameField"},
-                  {"key": "sortable-tabarray[].nick", "htmlClass": "nickField"}
-                ]
-              }
-            ];
-          }]);
-        </script>
-    </head>
-    <body ng-app="exampleApp" class="container">
-      <h3>Sortable Tab Array</h3>
-      <p>Drag and drop tabs to order the elements in the array</p>
-      <div class="container" ng-controller="exampleCtrl" style="margin: 0 auto;width: 100%;">
-        <form sf-schema="schema" sf-form="form" sf-model="model"></form>
-      </div>
-    </body>
-</html>
diff --git a/examples/tabarray.html b/examples/tabarray.html
new file mode 100644
index 0000000..52cb8dc
--- /dev/null
+++ b/examples/tabarray.html
@@ -0,0 +1,202 @@
+<!doctype html>
+    <head>
+        <meta charset="utf-8">
+        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+        <title>Tab Array Demo</title>
+        <meta name="description" content="">
+        <meta name="viewport" content="width=device-width, initial-scale=1">
+        <link rel="apple-touch-icon" href="apple-touch-icon.png">
+
+        <link rel="stylesheet" href="../bower_components/bootstrap/dist/css/bootstrap.min.css">
+        <link rel="stylesheet" href="../bower_components/bootstrap/dist/css/bootstrap-theme.min.css">
+        <link rel="stylesheet" href="../bower_components/bootstrap-vertical-tabs/bootstrap.vertical-tabs.min.css">
+        
+        <script type="text/javascript" src="../bower_components/jquery/dist/jquery.min.js"></script>
+        <script type="text/javascript" src="../bower_components/angular/angular.min.js"></script>
+        <script type="text/javascript" src="../bower_components/angular-sanitize/angular-sanitize.min.js"></script>
+        <script type="text/javascript" src="../bower_components/tv4/tv4.js"></script>
+        <script type="text/javascript" src="../bower_components/objectpath/lib/ObjectPath.js"></script>
+        <script type="text/javascript" src="../bower_components/angular-schema-form/dist/schema-form.js"></script>
+        <script type="text/javascript" src="../bootstrap-decorator.js"></script>
+        <script type="text/javascript" src="../bower_components/angular-ui-sortable/sortable.min.js"></script>
+        <script type="text/javascript" src="../bower_components/jquery-ui/jquery-ui.min.js"></script>
+        
+        <script type="text/javascript">
+          var exampleApp = angular.module('exampleApp',['schemaForm', 'ui.sortable']);
+          
+          exampleApp.controller('exampleCtrl', ['$scope', function($scope) {
+            
+            $scope.model = {
+              "exampleSelector": "standard"
+            };
+            
+            $scope.schema = {
+              "type": "object",
+              "properties": {
+                "exampleSelector": {
+                  "type": "string",
+                  "title": "Tab Array Example Selector",
+                  "enum": [
+                    "standard",
+                    "addDisabled",
+                    "removeDisabled",
+                    "sortable"
+                  ]
+                },
+                "standardTabArray": {
+                  "type": "array",
+                  "items": { 
+                    "type": "object", 
+                    "properties": { 
+                      "name": { "type": "string" }, 
+                      "nick": { "type": "string" }
+                    }
+                  }
+                },
+                "addDisabledTabArray": {
+                  "type": "array",
+                  "items": { 
+                    "type": "object", 
+                    "properties": { 
+                      "name": { "type": "string" }, 
+                      "nick": { "type": "string" }
+                    }
+                  }
+                },
+                "removeDisabledTabArray": {
+                  "type": "array",
+                  "items": { 
+                    "type": "object", 
+                    "properties": { 
+                      "name": { "type": "string" }, 
+                      "nick": { "type": "string" }
+                    }
+                  }
+                },
+                "sortableTabArray": {
+                  "type": "array",
+                  "items": { 
+                    "type": "object", 
+                    "properties": { 
+                      "name": { "type": "string" }, 
+                      "nick": { "type": "string" }
+                    }
+                  }
+                }
+              }
+            };
+
+            $scope.form = [
+              {
+                "key": "exampleSelector",
+                "titleMap": [
+                  {"value": "standard", "name": "Standard"},
+                  {"value": "addDisabled", "name": "Add Disabled"},
+                  {"value": "removeDisabled", "name": "Remove Disabled"},
+                  {"value": "sortable", "name": "Sortable"}
+                ]
+              },
+              {
+                "type": "section",
+                "condition": "model.exampleSelector == 'standard'",
+                "title": "",
+                "htmlCss": "row",
+                "items": [
+                  {
+                    "type": "help",
+                    "helpvalue": "<h4>Standard tab array</h4>"
+                  },
+                  {
+                    "key": "standardTabArray",
+                    "type": "tabarray",
+                    "title": "My name is: {{ value.name }}",
+                    "sortOptions": {
+                      "disabled": true
+                    },
+                    "items" : [
+                      {"key": "standardTabArray[].name", "htmlClass": "nameField"},
+                      {"key": "standardTabArray[].nick", "htmlClass": "nickField"}
+                    ]
+                  },
+                ]
+              },
+              {
+                "type": "section",
+                "condition": "model.exampleSelector == 'addDisabled'",
+                "htmlCss": "row",
+                "items": [
+                  {
+                    "type": "help",
+                    "helpvalue": "<h4>Tab array with add link hidden</h4>"
+                  },
+                  {
+                    "key": "addDisabledTabArray",
+                    "type": "tabarray",
+                    "add": null,
+                    "title": "My name is: {{ value.name }}",
+                    "sortOptions": {
+                      "disabled": true
+                    },
+                    "items" : [
+                      {"key": "addDisabledTabArray[].name", "htmlClass": "nameField"},
+                      {"key": "addDisabledTabArray[].nick", "htmlClass": "nickField"}
+                    ]
+                  }
+                ]
+              },
+              {
+                "type": "section",
+                "condition": "model.exampleSelector == 'removeDisabled'",
+                "htmlCss": "row",
+                "items": [
+                  {
+                    "type": "help",
+                    "helpvalue": "<h4>Tab array with remove button hidden</h4>"
+                  },
+                  {
+                    "key": "removeDisabledTabArray",
+                    "type": "tabarray",
+                    "remove": null,
+                    "title": "My name is: {{ value.name }}",
+                    "sortOptions": {
+                      "disabled": true
+                    },
+                    "items" : [
+                      {"key": "removeDisabledTabArray[].name", "htmlClass": "nameField"},
+                      {"key": "removeDisabledTabArray[].nick", "htmlClass": "nickField"}
+                    ]
+                  }
+                ]
+              },
+              {
+                "type": "section",
+                "condition": "model.exampleSelector == 'sortable'",
+                "htmlCss": "row",
+                "items": [
+                  {
+                    "type": "help",
+                    "helpvalue": "<h4>Drag and drop sortable tab array</h4>"
+                  },
+                  {
+                    "key": "sortableTabArray",
+                    "type": "tabarray",
+                    "title": "My name is: {{ value.name }}",
+                    "items" : [
+                      {"key": "sortableTabArray[].name", "htmlClass": "nameField"},
+                      {"key": "sortableTabArray[].nick", "htmlClass": "nickField"}
+                    ]
+                  }
+                ]
+              }
+            ];
+          }]);
+        </script>
+    </head>
+    <body ng-app="exampleApp" class="container">
+      <h3>Tab Array Demo</h3>
+      <p>Drag and drop tabs to order the elements in the array</p>
+      <div class="container" ng-controller="exampleCtrl" style="margin: 0 auto;width: 100%;">
+        <form sf-schema="schema" sf-form="form" sf-model="model"></form>
+      </div>
+    </body>
+</html>
diff --git a/gulp/tasks/protractor.js b/gulp/tasks/protractor.js
index aaee0c6..9c410e8 100644
--- a/gulp/tasks/protractor.js
+++ b/gulp/tasks/protractor.js
@@ -27,7 +27,7 @@ gulp.task('protractor', ['webdriver-update'], function(cb) {
   }).on('end', cb);
 });
 
-['validation-messages', 'custom-validation', 'sortable-tabarray'].forEach(function(name) {
+['validation-messages', 'custom-validation', 'tabarray'].forEach(function(name) {
   gulp.task('protractor:' + name, ['webdriver-update'], function(cb) {
     gulp.src(['test/protractor/specs/' + name + '.js']).pipe(protractor.protractor({
       configFile: 'test/protractor/conf.js',
diff --git a/test/protractor/specs/sortable-tabarray.js b/test/protractor/specs/sortable-tabarray.js
deleted file mode 100644
index a18611c..0000000
--- a/test/protractor/specs/sortable-tabarray.js
+++ /dev/null
@@ -1,63 +0,0 @@
-describe('sortable tabarray', function () {
-    function checkDragDrop(i) {
-      browser.driver.wait(protractor.until.elementLocated(by.xpath("//ol/li[1]/a[text()='My name is: Name " + (i + 1) +"']")), 10000);
-      expect(element.all(by.css('.nav-tabs li a')).get(0).getText()).toBe('My name is: Name ' + (i + 1));
-    }
-    
-    function populateTab(i) {
-      browser.driver.wait(protractor.until.elementLocated(by.css('.tab-pane.active.index' + i)), 5000);
-      
-      browser.driver.wait(protractor.until.elementLocated(by.css('.tab-pane.index' + i + ' div.nickField > input')), 5000);
-      input = element.all(by.css('.tab-pane.index' + i + '  div.nickField > input')).first();
-      input.sendKeys('Nickname ' + i);
-      
-      browser.driver.wait(protractor.until.elementLocated(by.css('.tab-pane.index' + i + ' div.nameField > input')), 5000);
-      input = element.all(by.css('.tab-pane.index' + i + ' div.nameField > input')).first();
-      input.sendKeys('Name ' + i);
-      
-      browser.driver.wait(protractor.until.elementLocated(by.linkText('My name is: Name ' + i)), 10000); 
-    }
-    
-    it('form should exist', function () {
-        browser.get('http://localhost:8080/examples/sortable-tabarray.html');
-
-        expect(element(by.css('form')).getInnerHtml()).not.toEqual('');
-    });
-    
-    it('should be able order elements in array by dragging the tabs', function () {
-        browser.get('http://localhost:8080/examples/sortable-tabarray.html');
-        
-        var i;
-        var elementsToAdd = 9;
-
-        /* the array starts with 1 element, populate the first element */
-        populateTab(0);
-        
-        /* add elements and populate */
-        for (i = 1; i <= elementsToAdd; i++) {
-            var tabLink = element.all(by.css('.glyphicon-plus'));
-            tabLink.click().then(populateTab(i));
-        }
-
-        /* continue when all tabs have been populated*/
-        browser.driver.wait(protractor.until.elementLocated(by.linkText('My name is: Name ' + elementsToAdd)), 10000);
-        
-        /* check the number of tabs */
-        var tabs = element.all(by.css('.nav-tabs li'));
-        expect(tabs.count()).toBe(elementsToAdd + 2); //Extra 1 for the "+ Add" link
-
-        /* drag the tabs into reverse order (descending) */
-        for (i = 0; i < elementsToAdd; i++) {
-            var draggable_element = element.all(by.css('.nav-tabs li')).get(0);
-            var target_element = element.all(by.css('.nav-tabs li')).get(elementsToAdd - i);
-            expect(draggable_element.isPresent()).toEqual(true);
-            expect(target_element.isPresent()).toEqual(true);
-            browser.actions().dragAndDrop(draggable_element, target_element).perform().then(checkDragDrop(i));
-        }
-        
-        /* final check of the reverse ordered tabs */
-        for (i = 0; i <= elementsToAdd; i++) {
-            expect(element.all(by.css('.nav-tabs li a')).get(i).getText()).toBe('My name is: Name ' + (elementsToAdd - i));
-        }
-    });
-});
\ No newline at end of file
diff --git a/test/protractor/specs/tabarray.js b/test/protractor/specs/tabarray.js
new file mode 100644
index 0000000..656e057
--- /dev/null
+++ b/test/protractor/specs/tabarray.js
@@ -0,0 +1,109 @@
+describe('tab array', function () {
+  it('form should exist', function () {
+    browser.get('http://localhost:8080/examples/tabarray.html');
+
+    expect(element(by.css('form')).getInnerHtml()).not.toEqual('');
+  });
+
+  it('add link should be hidden', function () {
+    browser.get('http://localhost:8080/examples/tabarray.html');
+
+    /* select the add disabled example */
+    element(by.css('[name="exampleSelector"]')).element(by.cssContainingText('option', 'Add Disabled')).click().then(function() {
+
+      /* Add link should not be displayed */
+      var tabs = element.all(by.css('.nav-tabs li'));
+      expect(tabs.get(0).isDisplayed()).toBeTruthy();
+      expect(tabs.get(1).isDisplayed()).toBeFalsy();
+      
+      var addLink = element.all(by.partialLinkText('Add'));
+      expect(addLink.count()).toBe(0);
+      
+      /*** control tests ***/
+      /* Remove button should be displayed */
+      var removeButton = element.all(by.partialButtonText('Remove')).get(0);
+      expect(removeButton.isDisplayed()).toBeTruthy();
+    });
+  });
+
+  it('remove button should be hidden', function () {
+    browser.get('http://localhost:8080/examples/tabarray.html');
+
+    /* select the remove disabled example */
+    element(by.css('[name="exampleSelector"]')).element(by.cssContainingText('option', 'Remove Disabled')).click().then(function() {
+      
+      /* Remove button should not be displayed */
+      var removeButton = element.all(by.partialButtonText('Remove')).get(0);
+      expect(removeButton.isDisplayed()).toBeFalsy();
+      
+      /*** control tests ***/
+      /* Add link should not be displayed */
+      var tabs = element.all(by.css('.nav-tabs li'));
+      expect(tabs.get(0).isDisplayed()).toBeTruthy();
+      expect(tabs.get(1).isDisplayed()).toBeTruthy();
+      
+      var addLink = element.all(by.partialLinkText('Add'));
+      expect(addLink.count()).toBe(1);
+    });
+  });
+
+  it('should be able order elements in array by dragging the tabs', function () {
+    browser.get('http://localhost:8080/examples/tabarray.html');
+    
+    function checkDragDrop(i) {
+      browser.driver.wait(protractor.until.elementLocated(by.xpath("//ol/li[1]/a[text()='My name is: Name " + (i + 1) +"']")), 10000);
+      expect(element.all(by.css('.nav-tabs li a')).get(0).getText()).toBe('My name is: Name ' + (i + 1));
+    }
+    
+    function populateTab(i) {
+      browser.driver.wait(protractor.until.elementLocated(by.css('.tab-pane.active.index' + i)), 5000);
+      
+      browser.driver.wait(protractor.until.elementLocated(by.css('.tab-pane.index' + i + ' div.nickField > input')), 5000);
+      input = element.all(by.css('.tab-pane.index' + i + '  div.nickField > input')).first();
+      input.sendKeys('Nickname ' + i);
+      
+      browser.driver.wait(protractor.until.elementLocated(by.css('.tab-pane.index' + i + ' div.nameField > input')), 5000);
+      input = element.all(by.css('.tab-pane.index' + i + ' div.nameField > input')).first();
+      input.sendKeys('Name ' + i);
+      
+      browser.driver.wait(protractor.until.elementLocated(by.linkText('My name is: Name ' + i)), 10000); 
+    }
+    
+    /* select the sortable example */
+    element(by.css('[name="exampleSelector"]')).element(by.cssContainingText('option', 'Sortable')).click().then(function() {
+    
+      var i;
+      var elementsToAdd = 9;
+
+      /* the array starts with 1 element, populate the first element */
+      populateTab(0);
+      
+      /* add elements and populate */
+      for (i = 1; i <= elementsToAdd; i++) {
+          var tabLink = element.all(by.css('.glyphicon-plus'));
+          tabLink.click().then(populateTab(i));
+      }
+
+      /* continue when all tabs have been populated*/
+      browser.driver.wait(protractor.until.elementLocated(by.linkText('My name is: Name ' + elementsToAdd)), 10000);
+      
+      /* check the number of tabs */
+      var tabs = element.all(by.css('.nav-tabs li'));
+      expect(tabs.count()).toBe(elementsToAdd + 2); //Extra 1 for the "+ Add" link
+
+      /* drag the tabs into reverse order (descending) */
+      for (i = 0; i < elementsToAdd; i++) {
+          var draggable_element = element.all(by.css('.nav-tabs li')).get(0);
+          var target_element = element.all(by.css('.nav-tabs li')).get(elementsToAdd - i);
+          expect(draggable_element.isPresent()).toEqual(true);
+          expect(target_element.isPresent()).toEqual(true);
+          browser.actions().dragAndDrop(draggable_element, target_element).perform().then(checkDragDrop(i));
+      }
+      
+      /* final check of the reverse ordered tabs */
+      for (i = 0; i <= elementsToAdd; i++) {
+          expect(element.all(by.css('.nav-tabs li a')).get(i).getText()).toBe('My name is: Name ' + (elementsToAdd - i));
+      }
+    });
+  });
+});

From 2308fe5b5b006a4c119bd20184bfa775319116a0 Mon Sep 17 00:00:00 2001
From: Joel Kent <joel.kent@thomsonreuters.com>
Date: Mon, 23 May 2016 21:29:42 +0100
Subject: [PATCH 12/50] Move tab array examples to the existing bootstrap
 example

---
 examples/bootstrap-example.html             |   9 +-
 examples/data/tabarray-add-disabled.json    |  44 +++++
 examples/data/tabarray-remove-disabled.json |  44 +++++
 examples/data/tabarray-sortable.json        |  40 ++++
 examples/tabarray.html                      | 202 --------------------
 test/protractor/specs/tabarray.js           |  20 +-
 6 files changed, 145 insertions(+), 214 deletions(-)
 create mode 100644 examples/data/tabarray-add-disabled.json
 create mode 100644 examples/data/tabarray-remove-disabled.json
 create mode 100644 examples/data/tabarray-sortable.json
 delete mode 100644 examples/tabarray.html

diff --git a/examples/bootstrap-example.html b/examples/bootstrap-example.html
index 5bef56a..c7908b2 100644
--- a/examples/bootstrap-example.html
+++ b/examples/bootstrap-example.html
@@ -214,9 +214,9 @@ <h3>Schema</h3>
 <!-- <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.21/angular-sanitize.min.js"></script> -->
 
 
-<!--
-<script type="text/javascript" src="../bower_components/angular-ui-sortable/sortable.js"></script>
--->
+<script type="text/javascript" src="../bower_components/angular-ui-sortable/sortable.min.js"></script>
+<script type="text/javascript" src="../bower_components/jquery-ui/jquery-ui.min.js"></script>
+
 <script type="text/javascript" src="../bower_components/angular-ui-ace/ui-ace.js"></script>
 <script type="text/javascript" src="../bower_components/objectpath/lib/ObjectPath.js"></script>
 <script type="text/javascript" src="../bower_components/pickadate/lib/picker.js"></script>
@@ -254,6 +254,9 @@ <h3>Schema</h3>
     { name: "TitleMap Examples", data: 'data/titlemaps.json' },
     { name: "Kitchen Sink", data: 'data/sink.json' },
     { name: "Hack: Conditional required", data: 'data/conditional-required.json' },
+    { name: "Tab Array: Add Disabled", data: 'data/tabarray-add-disabled.json' },
+    { name: "Tab Array: Remove Disabled", data: 'data/tabarray-remove-disabled.json' },
+    { name: "Tab Array: Sortable (Drag and Drop)", data: 'data/tabarray-sortable.json' }
   ];
 
   $scope.navbarMode = 'default';
diff --git a/examples/data/tabarray-add-disabled.json b/examples/data/tabarray-add-disabled.json
new file mode 100644
index 0000000..b604e22
--- /dev/null
+++ b/examples/data/tabarray-add-disabled.json
@@ -0,0 +1,44 @@
+{
+  "schema": {
+    "type": "object",
+    "title": "Tab Array: Add Disabled",
+    "properties": {
+      "addDisabledTabArray": {
+        "type": "array",
+        "items": { 
+          "type": "object", 
+          "properties": { 
+            "name": { "type": "string" }, 
+            "nick": { "type": "string" }
+          }
+        }
+      }
+    }
+  },
+  "form": [
+    {
+      "type": "section",
+      "htmlCss": "row",
+      "items": [
+        {
+          "type": "help",
+          "helpvalue": "<h4>Tab array with add link hidden</h4>"
+        },
+        {
+          "key": "addDisabledTabArray",
+          "type": "tabarray",
+          "add": null,
+          "title": "My name is: {{ value.name }}",
+          "sortOptions": {
+            "disabled": true
+          },
+          "items" : [
+            {"key": "addDisabledTabArray[].name", "htmlClass": "nameField"},
+            {"key": "addDisabledTabArray[].nick", "htmlClass": "nickField"}
+          ]
+        }
+      ]
+    }
+  ],
+  "model": {}
+}
diff --git a/examples/data/tabarray-remove-disabled.json b/examples/data/tabarray-remove-disabled.json
new file mode 100644
index 0000000..74e818e
--- /dev/null
+++ b/examples/data/tabarray-remove-disabled.json
@@ -0,0 +1,44 @@
+{
+  "schema": {
+    "type": "object",
+    "title": "Tab Array: Remove Disabled",
+    "properties": {
+      "removeDisabledTabArray": {
+        "type": "array",
+        "items": { 
+          "type": "object", 
+          "properties": { 
+            "name": { "type": "string" }, 
+            "nick": { "type": "string" }
+          }
+        }
+      }
+    }
+  },
+  "form": [
+    {
+      "type": "section",
+      "htmlCss": "row",
+      "items": [
+        {
+          "type": "help",
+          "helpvalue": "<h4>Tab array with remove button hidden</h4>"
+        },
+        {
+          "key": "removeDisabledTabArray",
+          "type": "tabarray",
+          "remove": null,
+          "title": "My name is: {{ value.name }}",
+          "sortOptions": {
+            "disabled": true
+          },
+          "items" : [
+            {"key": "removeDisabledTabArray[].name", "htmlClass": "nameField"},
+            {"key": "removeDisabledTabArray[].nick", "htmlClass": "nickField"}
+          ]
+        }
+      ]
+    }
+  ],
+  "model": {}
+}
diff --git a/examples/data/tabarray-sortable.json b/examples/data/tabarray-sortable.json
new file mode 100644
index 0000000..3eda316
--- /dev/null
+++ b/examples/data/tabarray-sortable.json
@@ -0,0 +1,40 @@
+{
+  "schema": {
+    "type": "object",
+    "title": "Tab Array: Sortable (Drag and Drop)",
+    "properties": {
+      "sortableTabArray": {
+        "type": "array",
+        "items": { 
+          "type": "object", 
+          "properties": { 
+            "name": { "type": "string" }, 
+            "nick": { "type": "string" }
+          }
+        }
+      }
+    }
+  },
+  "form": [
+    {
+      "type": "section",
+      "htmlCss": "row",
+      "items": [
+        {
+          "type": "help",
+          "helpvalue": "<h4>Drag and drop sortable tab array</h4>"
+        },
+        {
+          "key": "sortableTabArray",
+          "type": "tabarray",
+          "title": "My name is: {{ value.name }}",
+          "items" : [
+            {"key": "sortableTabArray[].name", "htmlClass": "nameField"},
+            {"key": "sortableTabArray[].nick", "htmlClass": "nickField"}
+          ]
+        }
+      ]
+    }
+  ],
+  "model": {}
+}
diff --git a/examples/tabarray.html b/examples/tabarray.html
deleted file mode 100644
index 52cb8dc..0000000
--- a/examples/tabarray.html
+++ /dev/null
@@ -1,202 +0,0 @@
-<!doctype html>
-    <head>
-        <meta charset="utf-8">
-        <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
-        <title>Tab Array Demo</title>
-        <meta name="description" content="">
-        <meta name="viewport" content="width=device-width, initial-scale=1">
-        <link rel="apple-touch-icon" href="apple-touch-icon.png">
-
-        <link rel="stylesheet" href="../bower_components/bootstrap/dist/css/bootstrap.min.css">
-        <link rel="stylesheet" href="../bower_components/bootstrap/dist/css/bootstrap-theme.min.css">
-        <link rel="stylesheet" href="../bower_components/bootstrap-vertical-tabs/bootstrap.vertical-tabs.min.css">
-        
-        <script type="text/javascript" src="../bower_components/jquery/dist/jquery.min.js"></script>
-        <script type="text/javascript" src="../bower_components/angular/angular.min.js"></script>
-        <script type="text/javascript" src="../bower_components/angular-sanitize/angular-sanitize.min.js"></script>
-        <script type="text/javascript" src="../bower_components/tv4/tv4.js"></script>
-        <script type="text/javascript" src="../bower_components/objectpath/lib/ObjectPath.js"></script>
-        <script type="text/javascript" src="../bower_components/angular-schema-form/dist/schema-form.js"></script>
-        <script type="text/javascript" src="../bootstrap-decorator.js"></script>
-        <script type="text/javascript" src="../bower_components/angular-ui-sortable/sortable.min.js"></script>
-        <script type="text/javascript" src="../bower_components/jquery-ui/jquery-ui.min.js"></script>
-        
-        <script type="text/javascript">
-          var exampleApp = angular.module('exampleApp',['schemaForm', 'ui.sortable']);
-          
-          exampleApp.controller('exampleCtrl', ['$scope', function($scope) {
-            
-            $scope.model = {
-              "exampleSelector": "standard"
-            };
-            
-            $scope.schema = {
-              "type": "object",
-              "properties": {
-                "exampleSelector": {
-                  "type": "string",
-                  "title": "Tab Array Example Selector",
-                  "enum": [
-                    "standard",
-                    "addDisabled",
-                    "removeDisabled",
-                    "sortable"
-                  ]
-                },
-                "standardTabArray": {
-                  "type": "array",
-                  "items": { 
-                    "type": "object", 
-                    "properties": { 
-                      "name": { "type": "string" }, 
-                      "nick": { "type": "string" }
-                    }
-                  }
-                },
-                "addDisabledTabArray": {
-                  "type": "array",
-                  "items": { 
-                    "type": "object", 
-                    "properties": { 
-                      "name": { "type": "string" }, 
-                      "nick": { "type": "string" }
-                    }
-                  }
-                },
-                "removeDisabledTabArray": {
-                  "type": "array",
-                  "items": { 
-                    "type": "object", 
-                    "properties": { 
-                      "name": { "type": "string" }, 
-                      "nick": { "type": "string" }
-                    }
-                  }
-                },
-                "sortableTabArray": {
-                  "type": "array",
-                  "items": { 
-                    "type": "object", 
-                    "properties": { 
-                      "name": { "type": "string" }, 
-                      "nick": { "type": "string" }
-                    }
-                  }
-                }
-              }
-            };
-
-            $scope.form = [
-              {
-                "key": "exampleSelector",
-                "titleMap": [
-                  {"value": "standard", "name": "Standard"},
-                  {"value": "addDisabled", "name": "Add Disabled"},
-                  {"value": "removeDisabled", "name": "Remove Disabled"},
-                  {"value": "sortable", "name": "Sortable"}
-                ]
-              },
-              {
-                "type": "section",
-                "condition": "model.exampleSelector == 'standard'",
-                "title": "",
-                "htmlCss": "row",
-                "items": [
-                  {
-                    "type": "help",
-                    "helpvalue": "<h4>Standard tab array</h4>"
-                  },
-                  {
-                    "key": "standardTabArray",
-                    "type": "tabarray",
-                    "title": "My name is: {{ value.name }}",
-                    "sortOptions": {
-                      "disabled": true
-                    },
-                    "items" : [
-                      {"key": "standardTabArray[].name", "htmlClass": "nameField"},
-                      {"key": "standardTabArray[].nick", "htmlClass": "nickField"}
-                    ]
-                  },
-                ]
-              },
-              {
-                "type": "section",
-                "condition": "model.exampleSelector == 'addDisabled'",
-                "htmlCss": "row",
-                "items": [
-                  {
-                    "type": "help",
-                    "helpvalue": "<h4>Tab array with add link hidden</h4>"
-                  },
-                  {
-                    "key": "addDisabledTabArray",
-                    "type": "tabarray",
-                    "add": null,
-                    "title": "My name is: {{ value.name }}",
-                    "sortOptions": {
-                      "disabled": true
-                    },
-                    "items" : [
-                      {"key": "addDisabledTabArray[].name", "htmlClass": "nameField"},
-                      {"key": "addDisabledTabArray[].nick", "htmlClass": "nickField"}
-                    ]
-                  }
-                ]
-              },
-              {
-                "type": "section",
-                "condition": "model.exampleSelector == 'removeDisabled'",
-                "htmlCss": "row",
-                "items": [
-                  {
-                    "type": "help",
-                    "helpvalue": "<h4>Tab array with remove button hidden</h4>"
-                  },
-                  {
-                    "key": "removeDisabledTabArray",
-                    "type": "tabarray",
-                    "remove": null,
-                    "title": "My name is: {{ value.name }}",
-                    "sortOptions": {
-                      "disabled": true
-                    },
-                    "items" : [
-                      {"key": "removeDisabledTabArray[].name", "htmlClass": "nameField"},
-                      {"key": "removeDisabledTabArray[].nick", "htmlClass": "nickField"}
-                    ]
-                  }
-                ]
-              },
-              {
-                "type": "section",
-                "condition": "model.exampleSelector == 'sortable'",
-                "htmlCss": "row",
-                "items": [
-                  {
-                    "type": "help",
-                    "helpvalue": "<h4>Drag and drop sortable tab array</h4>"
-                  },
-                  {
-                    "key": "sortableTabArray",
-                    "type": "tabarray",
-                    "title": "My name is: {{ value.name }}",
-                    "items" : [
-                      {"key": "sortableTabArray[].name", "htmlClass": "nameField"},
-                      {"key": "sortableTabArray[].nick", "htmlClass": "nickField"}
-                    ]
-                  }
-                ]
-              }
-            ];
-          }]);
-        </script>
-    </head>
-    <body ng-app="exampleApp" class="container">
-      <h3>Tab Array Demo</h3>
-      <p>Drag and drop tabs to order the elements in the array</p>
-      <div class="container" ng-controller="exampleCtrl" style="margin: 0 auto;width: 100%;">
-        <form sf-schema="schema" sf-form="form" sf-model="model"></form>
-      </div>
-    </body>
-</html>
diff --git a/test/protractor/specs/tabarray.js b/test/protractor/specs/tabarray.js
index 656e057..03f5e3f 100644
--- a/test/protractor/specs/tabarray.js
+++ b/test/protractor/specs/tabarray.js
@@ -1,15 +1,17 @@
 describe('tab array', function () {
   it('form should exist', function () {
-    browser.get('http://localhost:8080/examples/tabarray.html');
-
-    expect(element(by.css('form')).getInnerHtml()).not.toEqual('');
+    browser.get('http://localhost:8080/examples/bootstrap-example.html');
+    
+    element(by.css('#selectTest')).all(by.cssContainingText('option', 'Tab Array')).first().click().then(function() {
+      expect(element(by.css('form.ng-valid-schema-form')).getInnerHtml()).not.toEqual('');
+    });
   });
 
   it('add link should be hidden', function () {
-    browser.get('http://localhost:8080/examples/tabarray.html');
+    browser.get('http://localhost:8080/examples/bootstrap-example.html');
 
     /* select the add disabled example */
-    element(by.css('[name="exampleSelector"]')).element(by.cssContainingText('option', 'Add Disabled')).click().then(function() {
+    element(by.css('#selectTest')).element(by.cssContainingText('option', 'Tab Array: Add Disabled')).click().then(function() {
 
       /* Add link should not be displayed */
       var tabs = element.all(by.css('.nav-tabs li'));
@@ -27,10 +29,10 @@ describe('tab array', function () {
   });
 
   it('remove button should be hidden', function () {
-    browser.get('http://localhost:8080/examples/tabarray.html');
+    browser.get('http://localhost:8080/examples/bootstrap-example.html');
 
     /* select the remove disabled example */
-    element(by.css('[name="exampleSelector"]')).element(by.cssContainingText('option', 'Remove Disabled')).click().then(function() {
+    element(by.css('#selectTest')).element(by.cssContainingText('option', 'Tab Array: Remove Disabled')).click().then(function() {
       
       /* Remove button should not be displayed */
       var removeButton = element.all(by.partialButtonText('Remove')).get(0);
@@ -48,7 +50,7 @@ describe('tab array', function () {
   });
 
   it('should be able order elements in array by dragging the tabs', function () {
-    browser.get('http://localhost:8080/examples/tabarray.html');
+    browser.get('http://localhost:8080/examples/bootstrap-example.html');
     
     function checkDragDrop(i) {
       browser.driver.wait(protractor.until.elementLocated(by.xpath("//ol/li[1]/a[text()='My name is: Name " + (i + 1) +"']")), 10000);
@@ -70,7 +72,7 @@ describe('tab array', function () {
     }
     
     /* select the sortable example */
-    element(by.css('[name="exampleSelector"]')).element(by.cssContainingText('option', 'Sortable')).click().then(function() {
+    element(by.css('#selectTest')).element(by.cssContainingText('option', 'Tab Array: Sortable')).click().then(function() {
     
       var i;
       var elementsToAdd = 9;

From c8f3e3f28578fac915615ce63c48e3f146b3a823 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Wed, 25 May 2016 22:44:04 +1000
Subject: [PATCH 13/50] Update bower to use un-minified version

---
 bower.json | 7 +++++--
 1 file changed, 5 insertions(+), 2 deletions(-)

diff --git a/bower.json b/bower.json
index a2de370..7c6b086 100644
--- a/bower.json
+++ b/bower.json
@@ -4,9 +4,12 @@
     "David Jensen (Textalk) <david.lgj@gmail.com>"
   ],
   "description": "Bootstrap 3 decorator for Angular Schema Form",
-  "main": "bootstrap-decorator.min.js",
+  "main": "bootstrap-decorator.js",
   "keywords": [
-    "angular-schema-form-decorator"
+    "angular-schema-form-decorator",
+    "json-schema",
+    "json-schema-form",
+    "angular-schema-form"
   ],
   "license": "MIT",
   "homepage": "schemaform.io",

From 158ba0d5a2dbfae7f6c54e207846cc1e0336a99a Mon Sep 17 00:00:00 2001
From: Jozef Izso <jozef.izso@gmail.com>
Date: Thu, 23 Jun 2016 10:44:37 +0200
Subject: [PATCH 14/50] Update links with json-schema-form team addresses

---
 README.md                       | 2 +-
 examples/bootstrap-example.html | 2 +-
 examples/data/complex-keys.json | 2 +-
 3 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/README.md b/README.md
index a45ba9a..b28d190 100644
--- a/README.md
+++ b/README.md
@@ -1,7 +1,7 @@
 Angular Bootstrap Decorator
 ==========================
 
-For https://github.com/Textalk/angular-schema-form
+For https://github.com/json-schema-form/angular-schema-form
 
 This is the new Bootstrap Decorator! That means a Bootstrap 3 frontend for the Angular Schema Form
 project. The former Bootstrap decorator used to be included in the main repo, but has now moved
diff --git a/examples/bootstrap-example.html b/examples/bootstrap-example.html
index c7908b2..8aa312a 100644
--- a/examples/bootstrap-example.html
+++ b/examples/bootstrap-example.html
@@ -353,7 +353,7 @@ <h3>Schema</h3>
     $scope.navbarMode = 'saved';
 
     var gist = {
-      "description": "A saved configuration for a schema form example, http://textalk.github.io/angular-schema-form/examples/bootstrap-example.html",
+      "description": "A saved configuration for a schema form example, http://schemaform.io/examples/bootstrap-example.html",
       "public": true,
       "files": {
         "schema.json": {
diff --git a/examples/data/complex-keys.json b/examples/data/complex-keys.json
index cccac77..b618e2c 100644
--- a/examples/data/complex-keys.json
+++ b/examples/data/complex-keys.json
@@ -39,7 +39,7 @@
   "form": [
     {
       "type": "help",
-      "helpvalue": "Complex keys are only supported with AngularJS version 1.3.x, see <a href=\"https://github.com/Textalk/angular-schema-form/blob/master/docs/knownlimitations.md\">known limitations</a> in the docs."
+      "helpvalue": "Complex keys are only supported with AngularJS version 1.3.x, see <a href=\"https://github.com/json-schema-form/angular-schema-form/blob/master/docs/knownlimitations.md\">known limitations</a> in the docs."
     },
     "['a[\"b\"].c']",
     {

From 6c425ed8f212cd7ea0929486a1d423e8040f086e Mon Sep 17 00:00:00 2001
From: Paul Morris-Hill <paulmorrishill@googlemail.com>
Date: Tue, 19 Jul 2016 17:10:50 +0100
Subject: [PATCH 15/50] Fixed exception with placeholder interpolation on IE10+

---
 src/textarea.html | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/textarea.html b/src/textarea.html
index a87745e..29176c3 100644
--- a/src/textarea.html
+++ b/src/textarea.html
@@ -5,7 +5,7 @@
             class="form-control {{form.fieldHtmlClass}}"
             id="{{form.key.slice(-1)[0]}}"
             sf-changed="form"
-            placeholder="{{form.placeholder}}"
+            ng-attr-placeholder="{{form.placeholder}}"
             ng-disabled="form.readonly"
             sf-field-model
             schema-validate="form"
@@ -19,7 +19,7 @@
     <textarea class="form-control {{form.fieldHtmlClass}}"
               id="{{form.key.slice(-1)[0]}}"
               sf-changed="form"
-              placeholder="{{form.placeholder}}"
+              ng-attr-placeholder="{{form.placeholder}}"
               ng-disabled="form.readonly"
               sf-field-model
               schema-validate="form"

From d473cd6391690d5464262e4dc986cd0b1dce48ab Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Wed, 21 Sep 2016 00:30:48 +1000
Subject: [PATCH 16/50] Added initial version

pulling in json-schema-form-core and angular-schema-form
---
 bower.json                                    |    8 +-
 dist/angular-schema-form-bootstrap.js         | 3819 +++++++++++++++++
 examples/bootstrap-example.html               |    5 +-
 gulp/tasks/minify.js                          |    8 +-
 gulp/tasks/templates.js                       |   31 +
 npm-debug.log                                 |   48 +
 package.json                                  |   52 +-
 ...angular-schema-form-bootstrap-templates.js |   17 +
 ...lar-schema-form-bootstrap-templates.min.js |    1 +
 src/bootstrap-decorator.js                    |  178 +-
 src/module.js                                 |    4 +
 webpack.config.js                             |   38 +
 12 files changed, 4109 insertions(+), 100 deletions(-)
 create mode 100644 dist/angular-schema-form-bootstrap.js
 create mode 100644 gulp/tasks/templates.js
 create mode 100644 npm-debug.log
 create mode 100644 src/angular-schema-form-bootstrap-templates.js
 create mode 100644 src/angular-schema-form-bootstrap-templates.min.js
 create mode 100644 src/module.js
 create mode 100644 webpack.config.js

diff --git a/bower.json b/bower.json
index 7c6b086..ba87f10 100644
--- a/bower.json
+++ b/bower.json
@@ -1,10 +1,12 @@
 {
   "name": "angular-schema-form-bootstrap",
+  "version": "1.0.0-alpha.1",
   "authors": [
-    "David Jensen (Textalk) <david.lgj@gmail.com>"
+    "David Jensen (Textalk) <david.lgj@gmail.com>",
+    "Marcel Bennett <iamanthropic@gmail.com>"
   ],
   "description": "Bootstrap 3 decorator for Angular Schema Form",
-  "main": "bootstrap-decorator.js",
+  "main": "dist/bootstrap-decorator.js",
   "keywords": [
     "angular-schema-form-decorator",
     "json-schema",
@@ -21,7 +23,7 @@
     "tests"
   ],
   "dependencies": {
-    "angular-schema-form": ">= 0.8.7"
+    "angular-schema-form": ">=0.8.13"
   },
   "devDependencies": {
     "angular-ui-ace": "bower",
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
new file mode 100644
index 0000000..84f3ac4
--- /dev/null
+++ b/dist/angular-schema-form-bootstrap.js
@@ -0,0 +1,3819 @@
+/*!
+ * angular-schema-form-bootstrap
+ * @version 1.0.0-alpha.1
+ * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
+ * @license MIT
+ * Copyright (c) 2016 JSON Schema Form
+ */
+(function webpackUniversalModuleDefinition(root, factory) {
+	if(typeof exports === 'object' && typeof module === 'object')
+		module.exports = factory(require("angular"), require("tv4"));
+	else if(typeof define === 'function' && define.amd)
+		define(["angular", "tv4"], factory);
+	else {
+		var a = typeof exports === 'object' ? factory(require("angular"), require("tv4")) : factory(root["angular"], root["tv4"]);
+		for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
+	}
+})(this, function(__WEBPACK_EXTERNAL_MODULE_2__, __WEBPACK_EXTERNAL_MODULE_3__) {
+return /******/ (function(modules) { // webpackBootstrap
+/******/ 	// The module cache
+/******/ 	var installedModules = {};
+
+/******/ 	// The require function
+/******/ 	function __webpack_require__(moduleId) {
+
+/******/ 		// Check if module is in cache
+/******/ 		if(installedModules[moduleId])
+/******/ 			return installedModules[moduleId].exports;
+
+/******/ 		// Create a new module (and put it into the cache)
+/******/ 		var module = installedModules[moduleId] = {
+/******/ 			exports: {},
+/******/ 			id: moduleId,
+/******/ 			loaded: false
+/******/ 		};
+
+/******/ 		// Execute the module function
+/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
+
+/******/ 		// Flag the module as loaded
+/******/ 		module.loaded = true;
+
+/******/ 		// Return the exports of the module
+/******/ 		return module.exports;
+/******/ 	}
+
+
+/******/ 	// expose the modules object (__webpack_modules__)
+/******/ 	__webpack_require__.m = modules;
+
+/******/ 	// expose the module cache
+/******/ 	__webpack_require__.c = installedModules;
+
+/******/ 	// __webpack_public_path__
+/******/ 	__webpack_require__.p = "";
+
+/******/ 	// Load entry module and return exports
+/******/ 	return __webpack_require__(0);
+/******/ })
+/************************************************************************/
+/******/ ([
+/* 0 */
+/***/ function(module, exports, __webpack_require__) {
+
+	__webpack_require__(1);
+	__webpack_require__(4);
+	//require('./type-parser.js');
+	__webpack_require__(5);
+
+/***/ },
+/* 1 */
+/***/ function(module, exports, __webpack_require__) {
+
+	/*!
+	 * angular-schema-form
+	 * @version 1.0.0-alpha.2
+	 * @link https://github.com/json-schema-form/angular-schema-form
+	 * @license MIT
+	 * Copyright (c) 2016 JSON Schema Form
+	 */
+	(function webpackUniversalModuleDefinition(root, factory) {
+		if(true)
+			module.exports = factory(__webpack_require__(2), __webpack_require__(3));
+		else if(typeof define === 'function' && define.amd)
+			define(["angular", "tv4"], factory);
+		else {
+			var a = typeof exports === 'object' ? factory(require("angular"), require("tv4")) : factory(root["angular"], root["tv4"]);
+			for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
+		}
+	})(this, function(__WEBPACK_EXTERNAL_MODULE_2__, __WEBPACK_EXTERNAL_MODULE_8__) {
+	return /******/ (function(modules) { // webpackBootstrap
+	/******/ 	// The module cache
+	/******/ 	var installedModules = {};
+
+	/******/ 	// The require function
+	/******/ 	function __webpack_require__(moduleId) {
+
+	/******/ 		// Check if module is in cache
+	/******/ 		if(installedModules[moduleId])
+	/******/ 			return installedModules[moduleId].exports;
+
+	/******/ 		// Create a new module (and put it into the cache)
+	/******/ 		var module = installedModules[moduleId] = {
+	/******/ 			exports: {},
+	/******/ 			id: moduleId,
+	/******/ 			loaded: false
+	/******/ 		};
+
+	/******/ 		// Execute the module function
+	/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
+
+	/******/ 		// Flag the module as loaded
+	/******/ 		module.loaded = true;
+
+	/******/ 		// Return the exports of the module
+	/******/ 		return module.exports;
+	/******/ 	}
+
+
+	/******/ 	// expose the modules object (__webpack_modules__)
+	/******/ 	__webpack_require__.m = modules;
+
+	/******/ 	// expose the module cache
+	/******/ 	__webpack_require__.c = installedModules;
+
+	/******/ 	// __webpack_public_path__
+	/******/ 	__webpack_require__.p = "";
+
+	/******/ 	// Load entry module and return exports
+	/******/ 	return __webpack_require__(0);
+	/******/ })
+	/************************************************************************/
+	/******/ ([
+	/* 0 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		module.exports = __webpack_require__(1);
+
+
+	/***/ },
+	/* 1 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		var _builder = __webpack_require__(3);
+
+		var _builder2 = _interopRequireDefault(_builder);
+
+		var _decorators = __webpack_require__(4);
+
+		var _decorators2 = _interopRequireDefault(_decorators);
+
+		var _schemaForm = __webpack_require__(5);
+
+		var _schemaForm2 = _interopRequireDefault(_schemaForm);
+
+		var _jsonSchemaFormCore = __webpack_require__(6);
+
+		var _validator = __webpack_require__(7);
+
+		var _validator2 = _interopRequireDefault(_validator);
+
+		var _errors = __webpack_require__(9);
+
+		var _errors2 = _interopRequireDefault(_errors);
+
+		var _sfPath = __webpack_require__(10);
+
+		var _sfPath2 = _interopRequireDefault(_sfPath);
+
+		var _array = __webpack_require__(11);
+
+		var _array2 = _interopRequireDefault(_array);
+
+		var _changed = __webpack_require__(12);
+
+		var _changed2 = _interopRequireDefault(_changed);
+
+		var _field = __webpack_require__(13);
+
+		var _field2 = _interopRequireDefault(_field);
+
+		var _message = __webpack_require__(14);
+
+		var _message2 = _interopRequireDefault(_message);
+
+		var _newArray = __webpack_require__(15);
+
+		var _newArray2 = _interopRequireDefault(_newArray);
+
+		var _schemaForm3 = __webpack_require__(16);
+
+		var _schemaForm4 = _interopRequireDefault(_schemaForm3);
+
+		var _schemaValidate = __webpack_require__(17);
+
+		var _schemaValidate2 = _interopRequireDefault(_schemaValidate);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+		// Deps is sort of a problem for us, maybe in the future we will ask the user to depend
+		// on modules for add-ons
+
+		var deps = [];
+		try {
+		  //This throws an expection if module does not exist.
+		  _angular2.default.module('ngSanitize');
+		  deps.push('ngSanitize');
+		} catch (e) {}
+
+		try {
+		  //This throws an expection if module does not exist.
+		  _angular2.default.module('ui.sortable');
+		  deps.push('ui.sortable');
+		} catch (e) {}
+
+		try {
+		  //This throws an expection if module does not exist.
+		  _angular2.default.module('angularSpectrumColorpicker');
+		  deps.push('angularSpectrumColorpicker');
+		} catch (e) {}
+
+		_angular2.default.module('schemaForm', deps)
+		// Providers and services
+		.provider('sfPath', _sfPath2.default).provider('sfBuilder', ['sfPathProvider', _builder2.default]).provider('schemaFormDecorators', ['$compileProvider', 'sfPathProvider', _decorators2.default]).provider('sfErrorMessage', _errors2.default).provider('schemaForm', ['sfPathProvider', _schemaForm2.default]).factory('sfSelect', function () {
+		  return _jsonSchemaFormCore.select;
+		}).factory('sfValidator', _validator2.default)
+
+		// Directives
+		.directive('sfArray', ['sfSelect', 'schemaForm', 'sfValidator', 'sfPath', _array2.default]).directive('sfChanged', _changed2.default).directive('sfField', ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', _field2.default]).directive('sfMessage', ['$injector', 'sfErrorMessage', _message2.default]).directive('sfNewArray', ['sfSelect', 'sfPath', 'schemaForm', _newArray2.default]).directive('sfSchema', ['$compile', '$http', '$templateCache', '$q', 'schemaForm', 'schemaFormDecorators', 'sfSelect', 'sfPath', 'sfBuilder', _schemaForm4.default]).directive('schemaValidate', ['sfValidator', '$parse', 'sfSelect', _schemaValidate2.default]);
+
+	/***/ },
+	/* 2 */
+	/***/ function(module, exports) {
+
+		module.exports = angular;
+
+	/***/ },
+	/* 3 */
+	/***/ function(module, exports) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function (sfPathProvider) {
+
+		  var SNAKE_CASE_REGEXP = /[A-Z]/g;
+		  var snakeCase = function snakeCase(name, separator) {
+		    separator = separator || '_';
+		    return name.replace(SNAKE_CASE_REGEXP, function (letter, pos) {
+		      return (pos ? separator : '') + letter.toLowerCase();
+		    });
+		  };
+		  var formId = 0;
+
+		  var builders = {
+		    sfField: function sfField(args) {
+		      args.fieldFrag.firstChild.setAttribute('sf-field', formId);
+
+		      // We use a lookup table for easy access to our form.
+		      args.lookup['f' + formId] = args.form;
+		      formId++;
+		    },
+		    ngModel: function ngModel(args) {
+		      if (!args.form.key) {
+		        return;
+		      }
+		      var key = args.form.key;
+
+		      // Redact part of the key, used in arrays
+		      // KISS keyRedaction is a number.
+		      if (args.state.keyRedaction) {
+		        key = key.slice(args.state.keyRedaction);
+		      }
+
+		      // Stringify key.
+		      var modelValue;
+		      if (!args.state.modelValue) {
+		        var strKey = sfPathProvider.stringify(key).replace(/"/g, '&quot;');
+		        modelValue = args.state.modelName || 'model';
+
+		        if (strKey) {
+		          // Sometimes, like with arrays directly in arrays strKey is nothing.
+		          modelValue += (strKey[0] !== '[' ? '.' : '') + strKey;
+		        }
+		      } else {
+		        // Another builder, i.e. array has overriden the modelValue
+		        modelValue = args.state.modelValue;
+		      }
+
+		      // Find all sf-field-value attributes.
+		      // No value means a add a ng-model.
+		      // sf-field-value="replaceAll", loop over attributes and replace $$value$$ in each.
+		      // sf-field-value="attrName", replace or set value of that attribute.
+		      var nodes = args.fieldFrag.querySelectorAll('[sf-field-model]');
+		      for (var i = 0; i < nodes.length; i++) {
+		        var n = nodes[i];
+		        var conf = n.getAttribute('sf-field-model');
+		        if (!conf || conf === '') {
+		          n.setAttribute('ng-model', modelValue);
+		        } else if (conf === 'replaceAll') {
+		          var attributes = n.attributes;
+		          for (var j = 0; j < attributes.length; j++) {
+		            if (attributes[j].value && attributes[j].value.indexOf('$$value') !== -1) {
+		              attributes[j].value = attributes[j].value.replace(/\$\$value\$\$/g, modelValue);
+		            }
+		          }
+		        } else {
+		          var val = n.getAttribute(conf);
+		          if (val && val.indexOf('$$value$$')) {
+		            n.setAttribute(conf, val.replace(/\$\$value\$\$/g, modelValue));
+		          } else {
+		            n.setAttribute(conf, modelValue);
+		          }
+		        }
+		      }
+		    },
+		    simpleTransclusion: function simpleTransclusion(args) {
+		      var children = args.build(args.form.items, args.path + '.items', args.state);
+		      args.fieldFrag.firstChild.appendChild(children);
+		    },
+
+		    // Patch on ngModelOptions, since it doesn't like waiting for its value.
+		    ngModelOptions: function ngModelOptions(args) {
+		      if (args.form.ngModelOptions && Object.keys(args.form.ngModelOptions).length > 0) {
+		        args.fieldFrag.firstChild.setAttribute('ng-model-options', JSON.stringify(args.form.ngModelOptions));
+		      }
+		    },
+		    transclusion: function transclusion(args) {
+		      var transclusions = args.fieldFrag.querySelectorAll('[sf-field-transclude]');
+
+		      if (transclusions.length) {
+		        for (var i = 0; i < transclusions.length; i++) {
+		          var n = transclusions[i];
+
+		          // The sf-transclude attribute is not a directive,
+		          // but has the name of what we're supposed to
+		          // traverse. Default to `items`
+		          var sub = n.getAttribute('sf-field-transclude') || 'items';
+		          var items = args.form[sub];
+
+		          if (items) {
+		            var childFrag = args.build(items, args.path + '.' + sub, args.state);
+		            n.appendChild(childFrag);
+		          }
+		        }
+		      }
+		    },
+		    condition: function condition(args) {
+		      // Do we have a condition? Then we slap on an ng-if on all children,
+		      // but be nice to existing ng-if.
+		      if (args.form.condition) {
+		        var evalExpr = 'evalExpr(' + args.path + '.condition, { model: model, "arrayIndex": $index})';
+		        if (args.form.key) {
+		          var strKey = sfPathProvider.stringify(args.form.key);
+		          evalExpr = 'evalExpr(' + args.path + '.condition,{ model: model, "arrayIndex": $index, ' + '"modelValue": model' + (strKey[0] === '[' ? '' : '.') + strKey + '})';
+		        };
+
+		        var children = args.fieldFrag.children || args.fieldFrag.childNodes;
+		        for (var i = 0; i < children.length; i++) {
+		          var child = children[i];
+		          var ngIf = child.getAttribute('ng-if');
+		          child.setAttribute('ng-if', ngIf ? '(' + ngIf + ') || (' + evalExpr + ')' : evalExpr);
+		        }
+		      }
+		    },
+		    array: function array(args) {
+		      var items = args.fieldFrag.querySelector('[schema-form-array-items]');
+		      if (items) {
+		        var state = angular.copy(args.state);
+		        state.keyRedaction = 0;
+		        state.keyRedaction += args.form.key.length + 1;
+
+		        // Special case, an array with just one item in it that is not an object.
+		        // So then we just override the modelValue
+		        if (args.form.schema && args.form.schema.items && args.form.schema.items.type && args.form.schema.items.type.indexOf('object') === -1 && args.form.schema.items.type.indexOf('array') === -1) {
+		          var strKey = sfPathProvider.stringify(args.form.key).replace(/"/g, '&quot;') + '[$index]';
+		          state.modelValue = 'modelArray[$index]';
+		        } else {
+		          state.modelName = 'item';
+		        }
+
+		        // Flag to the builder that where in an array.
+		        // This is needed for compatabiliy if a "old" add-on is used that
+		        // hasn't been transitioned to the new builder.
+		        state.arrayCompatFlag = true;
+
+		        var childFrag = args.build(args.form.items, args.path + '.items', state);
+		        items.appendChild(childFrag);
+		      }
+		    },
+		    numeric: function numeric(args) {
+		      var inputFrag = args.fieldFrag.querySelector('input');
+		      var maximum = args.form.maximum || false;
+		      var exclusiveMaximum = args.form.exclusiveMaximum || false;
+		      var minimum = args.form.minimum || false;
+		      var exclusiveMinimum = args.form.exclusiveMinimum || false;
+		      var multipleOf = args.form.multipleOf || false;
+		      if (inputFrag) {
+		        if (multipleOf !== false) {
+		          inputFrag.setAttribute('step', multipleOf);
+		        };
+
+		        if (maximum !== false) {
+		          if (exclusiveMaximum !== false && multipleOf !== false) {
+		            maximum = maximum - multipleOf;
+		          };
+		          inputFrag.setAttribute('max', maximum);
+		        };
+
+		        if (minimum !== false) {
+		          if (exclusiveMinimum !== false && multipleOf !== false) {
+		            minimum = minimum + multipleOf;
+		          };
+		          inputFrag.setAttribute('min', minimum);
+		        };
+		      };
+		    }
+		  };
+		  this.builders = builders;
+		  var stdBuilders = [builders.sfField, builders.ngModel, builders.ngModelOptions, builders.condition];
+		  this.stdBuilders = stdBuilders;
+
+		  this.$get = ['$templateCache', 'schemaFormDecorators', 'sfPath', function ($templateCache, schemaFormDecorators, sfPath) {
+		    var checkForSlot = function checkForSlot(form, slots) {
+		      // Finally append this field to the frag.
+		      // Check for slots
+		      if (form.key) {
+		        var slot = slots[sfPath.stringify(form.key)];
+		        if (slot) {
+		          while (slot.firstChild) {
+		            slot.removeChild(slot.firstChild);
+		          }
+		          return slot;
+		        }
+		      }
+		    };
+
+		    var _build = function _build(items, decorator, templateFn, slots, path, state, lookup) {
+		      state = state || {};
+		      lookup = lookup || Object.create(null);
+		      path = path || 'schemaForm.form';
+		      var container = document.createDocumentFragment();
+		      items.reduce(function (frag, f, index) {
+
+		        // Sanity check.
+		        if (!f.type) {
+		          return frag;
+		        }
+
+		        var field = decorator[f.type] || decorator['default'];
+		        if (!field.replace) {
+		          // Backwards compatability build
+		          var n = document.createElement(snakeCase(decorator.__name, '-'));
+		          if (state.arrayCompatFlag) {
+		            n.setAttribute('form', 'copyWithIndex($index)');
+		          } else {
+		            n.setAttribute('form', path + '[' + index + ']');
+		          }
+
+		          (checkForSlot(f, slots) || frag).appendChild(n);
+		        } else {
+		          var tmpl;
+
+		          // Reset arrayCompatFlag, it's only valid for direct children of the array.
+		          state.arrayCompatFlag = false;
+
+		          // TODO: Create a couple of testcases, small and large and
+		          //       measure optmization. A good start is probably a
+		          //       cache of DOM nodes for a particular template
+		          //       that can be cloned instead of using innerHTML
+		          var div = document.createElement('div');
+		          var template = templateFn(f, field) || templateFn(f, decorator['default']);
+		          div.innerHTML = template;
+
+		          // Move node to a document fragment, we don't want the div.
+		          tmpl = document.createDocumentFragment();
+		          while (div.childNodes.length > 0) {
+		            tmpl.appendChild(div.childNodes[0]);
+		          }
+
+		          // Possible builder, often a noop
+		          var args = {
+		            fieldFrag: tmpl,
+		            form: f,
+		            lookup: lookup,
+		            state: state,
+		            path: path + '[' + index + ']',
+
+		            // Recursive build fn
+		            build: function build(items, path, state) {
+		              return _build(items, decorator, templateFn, slots, path, state, lookup);
+		            }
+
+		          };
+
+		          // Let the form definiton override builders if it wants to.
+		          var builderFn = f.builder || field.builder;
+
+		          // Builders are either a function or a list of functions.
+		          if (typeof builderFn === 'function') {
+		            builderFn(args);
+		          } else {
+		            builderFn.forEach(function (fn) {
+		              fn(args);
+		            });
+		          }
+
+		          // Append
+		          (checkForSlot(f, slots) || frag).appendChild(tmpl);
+		        }
+		        return frag;
+		      }, container);
+
+		      return container;
+		    };
+
+		    return {
+		      /**
+		       * Builds a form from a canonical form definition
+		       */
+		      build: function build(form, decorator, slots, lookup) {
+		        return _build(form, decorator, function (form, field) {
+		          if (form.type === 'template') {
+		            return form.template;
+		          }
+		          return $templateCache.get(field.template);
+		        }, slots, undefined, undefined, lookup);
+		      },
+		      builder: builders,
+		      stdBuilders: stdBuilders,
+		      internalBuild: _build
+		    };
+		  }];
+		};
+
+	/***/ },
+	/* 4 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function ($compileProvider, sfPathProvider) {
+		  var defaultDecorator = '';
+		  var decorators = {};
+
+		  // Map template after decorator and type.
+		  var templateUrl = function templateUrl(name, form) {
+		    //schemaDecorator is alias for whatever is set as default
+		    if (name === 'sfDecorator') {
+		      name = defaultDecorator;
+		    }
+
+		    var decorator = decorators[name];
+		    if (decorator[form.type]) {
+		      return decorator[form.type].template;
+		    }
+
+		    //try default
+		    return decorator['default'].template;
+		  };
+
+		  /**************************************************
+		   * DEPRECATED                                     *
+		   * The new builder and sf-field is preferred, but *
+		   * we keep this in during a transitional period   *
+		   * so that add-ons that don't use the new builder *
+		   * works.                                         *
+		   **************************************************/
+		  //TODO: Move to a compatability extra script.
+		  var createDirective = function createDirective(name) {
+		    $compileProvider.directive(name, ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', function ($parse, $compile, $http, $templateCache, $interpolate, $q, sfErrorMessage, sfPath, sfSelect) {
+
+		      return {
+		        restrict: 'AE',
+		        replace: false,
+		        transclude: false,
+		        scope: true,
+		        require: '?^sfSchema',
+		        link: function link(scope, element, attrs, sfSchema) {
+
+		          //The ngModelController is used in some templates and
+		          //is needed for error messages,
+		          scope.$on('schemaFormPropagateNgModelController', function (event, ngModel) {
+		            event.stopPropagation();
+		            event.preventDefault();
+		            scope.ngModel = ngModel;
+		          });
+
+		          //Keep error prone logic from the template
+		          scope.showTitle = function () {
+		            return scope.form && scope.form.notitle !== true && scope.form.title;
+		          };
+
+		          scope.listToCheckboxValues = function (list) {
+		            var values = {};
+		            _angular2.default.forEach(list, function (v) {
+		              values[v] = true;
+		            });
+		            return values;
+		          };
+
+		          scope.checkboxValuesToList = function (values) {
+		            var lst = [];
+		            _angular2.default.forEach(values, function (v, k) {
+		              if (v) {
+		                lst.push(k);
+		              }
+		            });
+		            return lst;
+		          };
+
+		          scope.buttonClick = function ($event, form) {
+		            if (_angular2.default.isFunction(form.onClick)) {
+		              form.onClick($event, form);
+		            } else if (_angular2.default.isString(form.onClick)) {
+		              if (sfSchema) {
+		                //evaluating in scope outside of sfSchemas isolated scope
+		                sfSchema.evalInParentScope(form.onClick, { '$event': $event, form: form });
+		              } else {
+		                scope.$eval(form.onClick, { '$event': $event, form: form });
+		              };
+		            };
+		          };
+
+		          /**
+		           * Evaluate an expression, i.e. scope.$eval
+		           * but do it in sfSchemas parent scope sf-schema directive is used
+		           * @param {string} expression
+		           * @param {Object} locals (optional)
+		           * @return {Any} the result of the expression
+		           */
+		          scope.evalExpr = function (expression, locals) {
+		            if (sfSchema) {
+		              //evaluating in scope outside of sfSchemas isolated scope
+		              return sfSchema.evalInParentScope(expression, locals);
+		            }
+
+		            return scope.$eval(expression, locals);
+		          };
+
+		          /**
+		           * Evaluate an expression, i.e. scope.$eval
+		           * in this decorators scope
+		           * @param {string} expression
+		           * @param {Object} locals (optional)
+		           * @return {Any} the result of the expression
+		           */
+		          scope.evalInScope = function (expression, locals) {
+		            if (expression) {
+		              return scope.$eval(expression, locals);
+		            }
+		          };
+
+		          /**
+		           * Interpolate the expression.
+		           * Similar to `evalExpr()` and `evalInScope()`
+		           * but will not fail if the expression is
+		           * text that contains spaces.
+		           *
+		           * Use the Angular `{{ interpolation }}`
+		           * braces to access properties on `locals`.
+		           *
+		           * @param  {string} content The string to interpolate.
+		           * @param  {Object} locals (optional) Properties that may be accessed in the
+		           *                         `expression` string.
+		           * @return {Any} The result of the expression or `undefined`.
+		           */
+		          scope.interp = function (expression, locals) {
+		            return expression && $interpolate(expression)(locals);
+		          };
+
+		          //This works since we ot the ngModel from the array or the schema-validate directive.
+		          scope.hasSuccess = function () {
+		            if (!scope.ngModel) {
+		              return false;
+		            }
+		            return scope.ngModel.$valid && (!scope.ngModel.$pristine || !scope.ngModel.$isEmpty(scope.ngModel.$modelValue));
+		          };
+
+		          scope.hasError = function () {
+		            if (!scope.ngModel) {
+		              return false;
+		            }
+		            return scope.ngModel.$invalid && !scope.ngModel.$pristine;
+		          };
+
+		          /**
+		           * DEPRECATED: use sf-messages instead.
+		           * Error message handler
+		           * An error can either be a schema validation message or a angular js validtion
+		           * error (i.e. required)
+		           */
+		          scope.errorMessage = function (schemaError) {
+		            return sfErrorMessage.interpolate(schemaError && schemaError.code + '' || 'default', scope.ngModel && scope.ngModel.$modelValue || '', scope.ngModel && scope.ngModel.$viewValue || '', scope.form, scope.options && scope.options.validationMessage);
+		          };
+
+		          // Rebind our part of the form to the scope.
+		          var once = scope.$watch(attrs.form, function (form) {
+		            if (form) {
+		              // Workaround for 'updateOn' error from ngModelOptions
+		              // see https://github.com/Textalk/angular-schema-form/issues/255
+		              // and https://github.com/Textalk/angular-schema-form/issues/206
+		              form.ngModelOptions = form.ngModelOptions || {};
+		              scope.form = form;
+
+		              //ok let's replace that template!
+		              //We do this manually since we need to bind ng-model properly and also
+		              //for fieldsets to recurse properly.
+		              var templatePromise;
+
+		              // type: "template" is a special case. It can contain a template inline or an url.
+		              // otherwise we find out the url to the template and load them.
+		              if (form.type === 'template' && form.template) {
+		                templatePromise = $q.when(form.template);
+		              } else {
+		                var url = form.type === 'template' ? form.templateUrl : templateUrl(name, form);
+		                templatePromise = $http.get(url, { cache: $templateCache }).then(function (res) {
+		                  return res.data;
+		                });
+		              }
+
+		              templatePromise.then(function (template) {
+		                if (form.key) {
+		                  var key = form.key ? sfPathProvider.stringify(form.key).replace(/"/g, '&quot;') : '';
+		                  template = template.replace(/\$\$value\$\$/g, 'model' + (key[0] !== '[' ? '.' : '') + key);
+		                }
+		                element.html(template);
+
+		                // Do we have a condition? Then we slap on an ng-if on all children,
+		                // but be nice to existing ng-if.
+		                if (form.condition) {
+
+		                  var evalExpr = 'evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';
+		                  if (form.key) {
+		                    evalExpr = 'evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex, "modelValue": model' + sfPath.stringify(form.key) + '})';
+		                  }
+
+		                  _angular2.default.forEach(element.children(), function (child) {
+		                    var ngIf = child.getAttribute('ng-if');
+		                    child.setAttribute('ng-if', ngIf ? '(' + ngIf + ') || (' + evalExpr + ')' : evalExpr);
+		                  });
+		                }
+		                $compile(element.contents())(scope);
+		              });
+
+		              // Where there is a key there is probably a ngModel
+		              if (form.key) {
+		                // It looks better with dot notation.
+		                scope.$on('schemaForm.error.' + form.key.join('.'), function (event, error, validationMessage, validity, formName) {
+		                  // validationMessage and validity are mutually exclusive
+		                  formName = validity;
+		                  if (validationMessage === true || validationMessage === false) {
+		                    validity = validationMessage;
+		                    validationMessage = undefined;
+		                  };
+
+		                  // If we have specified a form name, and this model is not within
+		                  // that form, then leave things be.
+		                  if (formName != undefined && scope.ngModel.$$parentForm.$name !== formName) {
+		                    return;
+		                  };
+
+		                  if (scope.ngModel && error) {
+		                    if (scope.ngModel.$setDirty) {
+		                      scope.ngModel.$setDirty();
+		                    } else {
+		                      // FIXME: Check that this actually works on 1.2
+		                      scope.ngModel.$dirty = true;
+		                      scope.ngModel.$pristine = false;
+		                    };
+
+		                    // Set the new validation message if one is supplied
+		                    // Does not work when validationMessage is just a string.
+		                    if (validationMessage) {
+		                      if (!form.validationMessage) {
+		                        form.validationMessage = {};
+		                      }
+		                      form.validationMessage[error] = validationMessage;
+		                    }
+
+		                    scope.ngModel.$setValidity(error, validity === true);
+
+		                    if (validity === true) {
+		                      // Re-trigger model validator, that model itself would be re-validated
+		                      scope.ngModel.$validate();
+
+		                      // Setting or removing a validity can change the field to believe its valid
+		                      // but its not. So lets trigger its validation as well.
+		                      scope.$broadcast('schemaFormValidate');
+		                    }
+		                  }
+		                });
+
+		                // Clean up the model when the corresponding form field is $destroy-ed.
+		                // Default behavior can be supplied as a globalOption, and behavior can be overridden in the form definition.
+		                scope.$on('$destroy', function () {
+		                  // If the entire schema form is destroyed we don't touch the model
+		                  if (!scope.externalDestructionInProgress) {
+		                    var destroyStrategy = form.destroyStrategy || scope.options && scope.options.destroyStrategy || 'remove';
+		                    // No key no model, and we might have strategy 'retain'
+		                    if (form.key && destroyStrategy !== 'retain') {
+
+		                      // Get the object that has the property we wan't to clear.
+		                      var obj = scope.model;
+		                      if (form.key.length > 1) {
+		                        obj = sfSelect(form.key.slice(0, form.key.length - 1), obj);
+		                      }
+
+		                      // We can get undefined here if the form hasn't been filled out entirely
+		                      if (obj === undefined) {
+		                        return;
+		                      }
+
+		                      // Type can also be a list in JSON Schema
+		                      var type = form.schema && form.schema.type || '';
+
+		                      // Empty means '',{} and [] for appropriate types and undefined for the rest
+		                      if (destroyStrategy === 'empty' && type.indexOf('string') !== -1) {
+		                        obj[form.key.slice(-1)] = '';
+		                      } else if (destroyStrategy === 'empty' && type.indexOf('object') !== -1) {
+		                        obj[form.key.slice(-1)] = {};
+		                      } else if (destroyStrategy === 'empty' && type.indexOf('array') !== -1) {
+		                        obj[form.key.slice(-1)] = [];
+		                      } else if (destroyStrategy === 'null') {
+		                        obj[form.key.slice(-1)] = null;
+		                      } else {
+		                        delete obj[form.key.slice(-1)];
+		                      }
+		                    }
+		                  }
+		                });
+		              }
+
+		              once();
+		            }
+		          });
+		        }
+		      };
+		    }]);
+		  };
+
+		  var createManualDirective = function createManualDirective(type, templateUrl, transclude) {
+		    transclude = _angular2.default.isDefined(transclude) ? transclude : false;
+		    $compileProvider.directive('sf' + _angular2.default.uppercase(type[0]) + type.substr(1), function () {
+		      return {
+		        restrict: 'EAC',
+		        scope: true,
+		        replace: true,
+		        transclude: transclude,
+		        template: '<sf-decorator form="form"></sf-decorator>',
+		        link: function link(scope, element, attrs) {
+		          var watchThis = {
+		            'items': 'c',
+		            'titleMap': 'c',
+		            'schema': 'c'
+		          };
+		          var form = { type: type };
+		          var once = true;
+		          _angular2.default.forEach(attrs, function (value, name) {
+		            if (name[0] !== '$' && name.indexOf('ng') !== 0 && name !== 'sfField') {
+
+		              var updateForm = function updateForm(val) {
+		                if (_angular2.default.isDefined(val) && val !== form[name]) {
+		                  form[name] = val;
+
+		                  //when we have type, and if specified key we apply it on scope.
+		                  if (once && form.type && (form.key || _angular2.default.isUndefined(attrs.key))) {
+		                    scope.form = form;
+		                    once = false;
+		                  }
+		                }
+		              };
+
+		              if (name === 'model') {
+		                //"model" is bound to scope under the name "model" since this is what the decorators
+		                //know and love.
+		                scope.$watch(value, function (val) {
+		                  if (val && scope.model !== val) {
+		                    scope.model = val;
+		                  }
+		                });
+		              } else if (watchThis[name] === 'c') {
+		                //watch collection
+		                scope.$watchCollection(value, updateForm);
+		              } else {
+		                //$observe
+		                attrs.$observe(name, updateForm);
+		              }
+		            }
+		          });
+		        }
+		      };
+		    });
+		  };
+
+		  /**
+		   * DEPRECATED: use defineDecorator instead.
+		   * Create a decorator directive and its sibling "manual" use decorators.
+		   * The directive can be used to create form fields or other form entities.
+		   * It can be used in conjunction with <schema-form> directive in which case the decorator is
+		   * given it's configuration via a the "form" attribute.
+		   *
+		   * ex. Basic usage
+		   *   <sf-decorator form="myform"></sf-decorator>
+		   **
+		   * @param {string} name directive name (CamelCased)
+		   * @param {Object} templates, an object that maps "type" => "templateUrl"
+		   */
+		  this.createDecorator = function (name, templates) {
+		    //console.warn('schemaFormDecorators.createDecorator is DEPRECATED, use defineDecorator instead.');
+		    decorators[name] = { '__name': name };
+
+		    _angular2.default.forEach(templates, function (url, type) {
+		      decorators[name][type] = { template: url, replace: false, builder: [] };
+		    });
+
+		    if (!decorators[defaultDecorator]) {
+		      defaultDecorator = name;
+		    }
+		    createDirective(name);
+		  };
+
+		  /**
+		   * Define a decorator. A decorator is a set of form types with templates and builder functions
+		   * that help set up the form.
+		   *
+		   * @param {string} name directive name (CamelCased)
+		   * @param {Object} fields, an object that maps "type" => `{ template, builder, replace}`.
+		                     attributes `builder` and `replace` are optional, and replace defaults to true.
+		                       `template` should be the key of the template to load and it should be pre-loaded
+		                     in `$templateCache`.
+		                       `builder` can be a function or an array of functions. They will be called in
+		                     the order they are supplied.
+		                       `replace` (DEPRECATED) is for backwards compatability. If false the builder
+		                     will use the "old" way of building that form field using a <sf-decorator>
+		                     directive.
+		   */
+		  this.defineDecorator = function (name, fields) {
+		    decorators[name] = { '__name': name }; // TODO: this feels like a hack, come up with a better way.
+
+		    _angular2.default.forEach(fields, function (field, type) {
+		      field.builder = field.builder || [];
+		      field.replace = _angular2.default.isDefined(field.replace) ? field.replace : true;
+		      decorators[name][type] = field;
+		    });
+
+		    if (!decorators[defaultDecorator]) {
+		      defaultDecorator = name;
+		    }
+		    createDirective(name);
+		  };
+
+		  /**
+		   * DEPRECATED
+		   * Creates a directive of a decorator
+		   * Usable when you want to use the decorators without using <schema-form> directive.
+		   * Specifically when you need to reuse styling.
+		   *
+		   * ex. createDirective('text','...')
+		   *  <sf-text title="foobar" model="person" key="name" schema="schema"></sf-text>
+		   *
+		   * @param {string}  type The type of the directive, resulting directive will have sf- prefixed
+		   * @param {string}  templateUrl
+		   * @param {boolean} transclude (optional) sets transclude option of directive, defaults to false.
+		   */
+		  this.createDirective = createManualDirective;
+
+		  /**
+		   * DEPRECATED
+		   * Same as createDirective, but takes an object where key is 'type' and value is 'templateUrl'
+		   * Useful for batching.
+		   * @param {Object} templates
+		   */
+		  this.createDirectives = function (templates) {
+		    _angular2.default.forEach(templates, function (url, type) {
+		      createManualDirective(type, url);
+		    });
+		  };
+
+		  /**
+		   * Getter for decorator settings
+		   * @param {string} name (optional) defaults to defaultDecorator
+		   * @return {Object} rules and templates { rules: [],templates: {}}
+		   */
+		  this.decorator = function (name) {
+		    name = name || defaultDecorator;
+		    return decorators[name];
+		  };
+
+		  /**
+		   * DEPRECATED use defineAddOn() instead.
+		   * Adds a mapping to an existing decorator.
+		   * @param {String} name Decorator name
+		   * @param {String} type Form type for the mapping
+		   * @param {String} url  The template url
+		   * @param {Function} builder (optional) builder function
+		   * @param {boolean} replace (optional) defaults to false. Replace decorator directive with template.
+		   */
+		  this.addMapping = function (name, type, url, builder, replace) {
+		    if (decorators[name]) {
+		      decorators[name][type] = {
+		        template: url,
+		        builder: builder,
+		        replace: !!replace
+		      };
+		    }
+		  };
+
+		  /**
+		   * Adds an add-on to an existing decorator.
+		   * @param {String} name Decorator name
+		   * @param {String} type Form type for the mapping
+		   * @param {String} url  The template url
+		   * @param {Function|Array} builder (optional) builder function(s),
+		   */
+		  this.defineAddOn = function (name, type, url, builder) {
+		    if (decorators[name]) {
+		      decorators[name][type] = {
+		        template: url,
+		        builder: builder,
+		        replace: true
+		      };
+		    }
+		  };
+
+		  //Service is just a getter for directive templates and rules
+		  this.$get = function () {
+		    return {
+		      decorator: function decorator(name) {
+		        return decorators[name] || decorators[defaultDecorator];
+		      },
+		      defaultDecorator: defaultDecorator
+		    };
+		  };
+
+		  //Create a default directive
+		  createDirective('sfDecorator');
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 5 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function () {
+
+		  var postProcessFn = function postProcessFn(form) {
+		    return form;
+		  };
+		  var defaults = _jsonSchemaFormCore.schemaDefaults.createDefaults();
+
+		  /**
+		   * Provider API
+		   */
+		  this.defaults = defaults;
+		  this.stdFormObj = _jsonSchemaFormCore.schemaDefaults.stdFormObj;
+		  this.defaultFormDefinition = _jsonSchemaFormCore.schemaDefaults.defaultFormDefinition;
+
+		  /**
+		   * Register a post process function.
+		   * This function is called with the fully merged
+		   * form definition (i.e. after merging with schema)
+		   * and whatever it returns is used as form.
+		   */
+		  this.postProcess = function (fn) {
+		    postProcessFn = fn;
+		  };
+
+		  /**
+		   * Append default form rule
+		   *
+		   * @param {string}   type json schema type
+		   * @param {Function} rule a function(propertyName,propertySchema,options) that returns a form
+		   *                        definition or undefined
+		   */
+		  this.appendRule = function (type, rule) {
+		    if (!defaults[type]) {
+		      defaults[type] = [];
+		    }
+		    defaults[type].push(rule);
+		  };
+
+		  /**
+		   * Prepend default form rule
+		   *
+		   * @param {string}   type json schema type
+		   * @param {Function} rule a function(propertyName,propertySchema,options) that returns a form
+		   *                        definition or undefined
+		   */
+		  this.prependRule = function (type, rule) {
+		    if (!defaults[type]) {
+		      defaults[type] = [];
+		    }
+		    defaults[type].unshift(rule);
+		  };
+
+		  /**
+		   * Utility function to create a standard form object.
+		   * This does *not* set the type of the form but rather all shared attributes.
+		   * You probably want to start your rule with creating the form with this method
+		   * then setting type and any other values you need.
+		   * @param {Object} schema
+		   * @param {Object} options
+		   * @return {Object} a form field defintion
+		   */
+		  this.createStandardForm = _jsonSchemaFormCore.schemaDefaults.stdFormObj;
+		  /* End Provider API */
+
+		  this.$get = function () {
+
+		    var service = {};
+		    var typeDefault = this.defaults;
+
+		    service.merge = function (schema, form, ignore, options, readonly, asyncTemplates) {
+		      form = form || ['*'];
+		      options = options || {};
+
+		      // Get readonly from root object
+		      readonly = readonly || schema.readonly || schema.readOnly;
+
+		      var stdForm = _jsonSchemaFormCore.schemaDefaults.defaultForm(schema, typeDefault, ignore, options);
+
+		      //simple case, we have a "*", just put the stdForm there
+		      var idx = form.indexOf('*');
+		      if (idx !== -1) {
+		        form = form.slice(0, idx).concat(stdForm.form).concat(form.slice(idx + 1));
+		      }
+
+		      //ok let's merge!
+		      //We look at the supplied form and extend it with schema standards
+		      var canonical = (0, _jsonSchemaFormCore.merge)(stdForm.lookup, form, options, readonly, asyncTemplates);
+		      return postProcessFn(canonical);
+		    };
+
+		    /**
+		     * Create form defaults from schema
+		     */
+		    service.defaults = _jsonSchemaFormCore.schemaDefaults.defaultForm;
+
+		    //Utility functions
+		    /**
+		     * Form defaults for schema by type
+		     * As a form is generated from a schema these are the definitions of each json-schema type
+		     */
+		    service.typeDefault = typeDefault;
+
+		    /**
+		     * Traverse a schema, applying a function(schema,path) on every sub schema
+		     * i.e. every property of an object.
+		     */
+		    service.traverseSchema = _jsonSchemaFormCore.traverseSchema;
+
+		    service.traverseForm = _jsonSchemaFormCore.traverseForm;
+
+		    return service;
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		var _jsonSchemaFormCore = __webpack_require__(6);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 6 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		/*!
+		 * json-schema-form
+		 * @version 1.0.0-alpha.1
+		 * @link https://github.com/json-schema-form/json-schema-form-core
+		 * @license MIT
+		 * Copyright (c) 2016 JSON Schema Form
+		 */
+		(function webpackUniversalModuleDefinition(root, factory) {
+			if(true)
+				module.exports = factory();
+			else if(typeof define === 'function' && define.amd)
+				define([], factory);
+			else {
+				var a = factory();
+				for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
+			}
+		})(this, function() {
+		return /******/ (function(modules) { // webpackBootstrap
+		/******/ 	// The module cache
+		/******/ 	var installedModules = {};
+
+		/******/ 	// The require function
+		/******/ 	function __webpack_require__(moduleId) {
+
+		/******/ 		// Check if module is in cache
+		/******/ 		if(installedModules[moduleId])
+		/******/ 			return installedModules[moduleId].exports;
+
+		/******/ 		// Create a new module (and put it into the cache)
+		/******/ 		var module = installedModules[moduleId] = {
+		/******/ 			exports: {},
+		/******/ 			id: moduleId,
+		/******/ 			loaded: false
+		/******/ 		};
+
+		/******/ 		// Execute the module function
+		/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
+
+		/******/ 		// Flag the module as loaded
+		/******/ 		module.loaded = true;
+
+		/******/ 		// Return the exports of the module
+		/******/ 		return module.exports;
+		/******/ 	}
+
+
+		/******/ 	// expose the modules object (__webpack_modules__)
+		/******/ 	__webpack_require__.m = modules;
+
+		/******/ 	// expose the module cache
+		/******/ 	__webpack_require__.c = installedModules;
+
+		/******/ 	// __webpack_public_path__
+		/******/ 	__webpack_require__.p = "";
+
+		/******/ 	// Load entry module and return exports
+		/******/ 	return __webpack_require__(0);
+		/******/ })
+		/************************************************************************/
+		/******/ ([
+		/* 0 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			module.exports = __webpack_require__(1);
+
+
+		/***/ },
+		/* 1 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+			exports.canonicalTitleMap = exports.schemaDefaults = exports.sfPath = undefined;
+
+			var _merge = __webpack_require__(2);
+
+			Object.keys(_merge).forEach(function (key) {
+			  if (key === "default") return;
+			  Object.defineProperty(exports, key, {
+			    enumerable: true,
+			    get: function get() {
+			      return _merge[key];
+			    }
+			  });
+			});
+
+			var _select = __webpack_require__(7);
+
+			Object.keys(_select).forEach(function (key) {
+			  if (key === "default") return;
+			  Object.defineProperty(exports, key, {
+			    enumerable: true,
+			    get: function get() {
+			      return _select[key];
+			    }
+			  });
+			});
+
+			var _traverse = __webpack_require__(8);
+
+			Object.keys(_traverse).forEach(function (key) {
+			  if (key === "default") return;
+			  Object.defineProperty(exports, key, {
+			    enumerable: true,
+			    get: function get() {
+			      return _traverse[key];
+			    }
+			  });
+			});
+
+			var _schemaDefaults = __webpack_require__(9);
+
+			var schemaDefaultsImp = _interopRequireWildcard(_schemaDefaults);
+
+			var _sfPath = __webpack_require__(3);
+
+			var sfPathImp = _interopRequireWildcard(_sfPath);
+
+			var _canonicalTitleMap = __webpack_require__(6);
+
+			var _canonicalTitleMap2 = _interopRequireDefault(_canonicalTitleMap);
+
+			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+			function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
+
+			var sfPath = exports.sfPath = sfPathImp;
+			var schemaDefaults = exports.schemaDefaults = schemaDefaultsImp;
+			var canonicalTitleMap = exports.canonicalTitleMap = _canonicalTitleMap2.default;
+
+		/***/ },
+		/* 2 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+			exports.merge = merge;
+
+			var _sfPath = __webpack_require__(3);
+
+			var _canonicalTitleMap = __webpack_require__(6);
+
+			var _canonicalTitleMap2 = _interopRequireDefault(_canonicalTitleMap);
+
+			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+			//export function merge(schema, form, schemaDefaultTypes, ignore, options, readonly, asyncTemplates) {
+			function merge(lookup, form, options, readonly, asyncTemplates) {
+			  form = form || [];
+			  options = options || {};
+
+			  //ok let's merge!
+			  //We look at the supplied form and extend it with schema standards
+			  return form.map(function (obj) {
+
+			    //handle the shortcut with just a name
+			    if (typeof obj === 'string') {
+			      obj = { key: obj };
+			    }
+
+			    if (obj.key) {
+			      if (typeof obj.key === 'string') {
+			        obj.key = (0, _sfPath.parse)(obj.key);
+			      }
+			    }
+
+			    //If it has a titleMap make sure it's a list
+			    if (obj.titleMap) {
+			      obj.titleMap = (0, _canonicalTitleMap2.default)(obj.titleMap);
+			    }
+
+			    //extend with std form from schema.
+			    if (obj.key) {
+			      var strid = (0, _sfPath.stringify)(obj.key);
+			      if (lookup[strid]) {
+			        (function () {
+			          var schemaDefaults = lookup[strid];
+			          if (schemaDefaults) {
+			            Object.keys(schemaDefaults).forEach(function (attr) {
+			              if (obj[attr] === undefined) {
+			                obj[attr] = schemaDefaults[attr];
+			              }
+			            });
+			          }
+			        })();
+			      }
+			    }
+
+			    // Are we inheriting readonly?
+			    if (readonly === true) {
+			      // Inheriting false is not cool.
+			      obj.readonly = true;
+			    }
+
+			    //if it's a type with items, merge 'em!
+			    if (obj.items) {
+			      obj.items = merge(lookup, obj.items, options, obj.readonly, asyncTemplates);
+			    }
+
+			    //if its has tabs, merge them also!
+			    if (obj.tabs) {
+			      obj.tabs.forEach(function (tab) {
+			        if (tab.items) {
+			          tab.items = merge(lookup, tab.items, options, obj.readonly, asyncTemplates);
+			        }
+			      });
+			    }
+
+			    // Special case: checkbox
+			    // Since have to ternary state we need a default
+			    if (obj.type === 'checkbox' && obj.schema['default'] === undefined) {
+			      obj.schema['default'] = false;
+			    };
+
+			    // Special case: template type with tempplateUrl that's needs to be loaded before rendering
+			    // TODO: this is not a clean solution. Maybe something cleaner can be made when $ref support
+			    // is introduced since we need to go async then anyway
+			    if (asyncTemplates && obj.type === 'template' && !obj.template && obj.templateUrl) {
+			      asyncTemplates.push(obj);
+			    }
+
+			    return obj;
+			  });
+			}
+
+		/***/ },
+		/* 3 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+
+			var _objectpath = __webpack_require__(4);
+
+			Object.defineProperty(exports, 'parse', {
+			  enumerable: true,
+			  get: function get() {
+			    return _objectpath.parse;
+			  }
+			});
+			Object.defineProperty(exports, 'stringify', {
+			  enumerable: true,
+			  get: function get() {
+			    return _objectpath.stringify;
+			  }
+			});
+			Object.defineProperty(exports, 'normalize', {
+			  enumerable: true,
+			  get: function get() {
+			    return _objectpath.normalize;
+			  }
+			});
+
+		/***/ },
+		/* 4 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			module.exports = __webpack_require__(5).ObjectPath;
+
+		/***/ },
+		/* 5 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			var __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
+
+			var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; };
+
+			;!function (undefined) {
+
+				var ObjectPath = {
+					parse: function parse(str) {
+						if (typeof str !== 'string') {
+							throw new TypeError('ObjectPath.parse must be passed a string');
+						}
+
+						var i = 0;
+						var parts = [];
+						var d, b, q, c;
+						while (i < str.length) {
+							d = str.indexOf('.', i);
+							b = str.indexOf('[', i);
+
+							// we've reached the end
+							if (d === -1 && b === -1) {
+								parts.push(str.slice(i, str.length));
+								i = str.length;
+							}
+
+							// dots
+							else if (b === -1 || d !== -1 && d < b) {
+									parts.push(str.slice(i, d));
+									i = d + 1;
+								}
+
+								// brackets
+								else {
+										if (b > i) {
+											parts.push(str.slice(i, b));
+											i = b;
+										}
+										q = str.slice(b + 1, b + 2);
+										if (q !== '"' && q !== '\'') {
+											c = str.indexOf(']', b);
+											if (c === -1) c = str.length;
+											parts.push(str.slice(i + 1, c));
+											i = str.slice(c + 1, c + 2) === '.' ? c + 2 : c + 1;
+										} else {
+											c = str.indexOf(q + ']', b);
+											if (c === -1) c = str.length;
+											while (str.slice(c - 1, c) === '\\' && b < str.length) {
+												b++;
+												c = str.indexOf(q + ']', b);
+											}
+											parts.push(str.slice(i + 2, c).replace(new RegExp('\\' + q, 'g'), q));
+											i = str.slice(c + 2, c + 3) === '.' ? c + 3 : c + 2;
+										}
+									}
+						}
+						return parts;
+					},
+
+					// root === true : auto calculate root; must be dot-notation friendly
+					// root String : the string to use as root
+					stringify: function stringify(arr, quote) {
+
+						if (!Array.isArray(arr)) arr = [arr.toString()];
+
+						quote = quote === '"' ? '"' : '\'';
+
+						return arr.map(function (n) {
+							return '[' + quote + n.toString().replace(new RegExp(quote, 'g'), '\\' + quote) + quote + ']';
+						}).join('');
+					},
+
+					normalize: function normalize(data, quote) {
+						return ObjectPath.stringify(Array.isArray(data) ? data : ObjectPath.parse(data), quote);
+					},
+
+					// Angular
+					registerModule: function registerModule(angular) {
+						angular.module('ObjectPath', []).provider('ObjectPath', function () {
+							this.parse = ObjectPath.parse;
+							this.stringify = ObjectPath.stringify;
+							this.normalize = ObjectPath.normalize;
+							this.$get = function () {
+								return ObjectPath;
+							};
+						});
+					}
+				};
+
+				// AMD
+				if (true) {
+					!(__WEBPACK_AMD_DEFINE_RESULT__ = function () {
+						return { ObjectPath: ObjectPath };
+					}.call(exports, __webpack_require__, exports, module), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
+				}
+
+				// CommonJS
+				else if ((typeof exports === 'undefined' ? 'undefined' : _typeof(exports)) === 'object') {
+						exports.ObjectPath = ObjectPath;
+					}
+
+					// Browser global
+					else {
+							window.ObjectPath = ObjectPath;
+						}
+			}();
+
+		/***/ },
+		/* 6 */
+		/***/ function(module, exports) {
+
+			"use strict";
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+
+			var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; }; // Takes a titleMap in either object or list format and returns one in
+			// in the list format.
+
+
+			exports.default = function (titleMap, originalEnum) {
+			  if (!Array.isArray(titleMap)) {
+			    var _ret = function () {
+			      var canonical = [];
+			      if (originalEnum) {
+			        originalEnum.forEach(function (value) {
+			          canonical.push({ name: titleMap[value], value: value });
+			        });
+			      } else {
+			        Object.keys(titleMap).forEach(function (value) {
+			          canonical.push({ name: titleMap[value], value: value });
+			        });
+			      }
+			      return {
+			        v: canonical
+			      };
+			    }();
+
+			    if ((typeof _ret === "undefined" ? "undefined" : _typeof(_ret)) === "object") return _ret.v;
+			  }
+			  return titleMap;
+			};
+
+		/***/ },
+		/* 7 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+			exports.select = select;
+
+			var _sfPath = __webpack_require__(3);
+
+			var _sfPath2 = _interopRequireDefault(_sfPath);
+
+			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+			var numRe = /^\d+$/;
+
+			/**
+			  * @description
+			  * Utility method to access deep properties without
+			  * throwing errors when things are not defined.
+			  * Can also set a value in a deep structure, creating objects when missing
+			  * ex.
+			  * var foo = Select('address.contact.name',obj)
+			  * Select('address.contact.name',obj,'Leeroy')
+			  *
+			  * @param {string} projection A dot path to the property you want to get/set
+			  * @param {object} obj   (optional) The object to project on, defaults to 'this'
+			  * @param {Any}    valueToSet (opional)  The value to set, if parts of the path of
+			  *                 the projection is missing empty objects will be created.
+			  * @returns {Any|undefined} returns the value at the end of the projection path
+			  *                          or undefined if there is none.
+			  */
+			function select(projection, obj, valueToSet) {
+			  if (!obj) {
+			    obj = this;
+			  }
+			  //Support [] array syntax
+			  var parts = typeof projection === 'string' ? _sfPath2.default.parse(projection) : projection;
+
+			  if (typeof valueToSet !== 'undefined' && parts.length === 1) {
+			    //special case, just setting one variable
+			    obj[parts[0]] = valueToSet;
+			    return obj;
+			  }
+
+			  if (typeof valueToSet !== 'undefined' && typeof obj[parts[0]] === 'undefined') {
+			    // We need to look ahead to check if array is appropriate
+			    obj[parts[0]] = parts.length > 2 && numRe.test(parts[1]) ? [] : {};
+			  }
+
+			  var value = obj[parts[0]];
+			  for (var i = 1; i < parts.length; i++) {
+			    // Special case: We allow JSON Form syntax for arrays using empty brackets
+			    // These will of course not work here so we exit if they are found.
+			    if (parts[i] === '') {
+			      return undefined;
+			    }
+			    if (typeof valueToSet !== 'undefined') {
+			      if (i === parts.length - 1) {
+			        //last step. Let's set the value
+			        value[parts[i]] = valueToSet;
+			        return valueToSet;
+			      } else {
+			        // Make sure to create new objects on the way if they are not there.
+			        // We need to look ahead to check if array is appropriate
+			        var tmp = value[parts[i]];
+			        if (typeof tmp === 'undefined' || tmp === null) {
+			          tmp = numRe.test(parts[i + 1]) ? [] : {};
+			          value[parts[i]] = tmp;
+			        }
+			        value = tmp;
+			      }
+			    } else if (value) {
+			      //Just get nex value.
+			      value = value[parts[i]];
+			    }
+			  }
+			  return value;
+			}
+
+		/***/ },
+		/* 8 */
+		/***/ function(module, exports) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+			exports.traverseSchema = traverseSchema;
+			exports.traverseForm = traverseForm;
+			/**
+			 * Traverse a schema, applying a function(schema,path) on every sub schema
+			 * i.e. every property of an object.
+			 */
+			function traverseSchema(schema, fn, path, ignoreArrays) {
+			  ignoreArrays = ignoreArrays === undefined ? true : ignoreArrays;
+
+			  path = path || [];
+
+			  var traverse = function traverse(schema, fn, path) {
+			    fn(schema, path);
+			    if (schema.properties) {
+			      Object.keys(schema.properties).forEach(function (name) {
+			        var currentPath = path.slice();
+			        currentPath.push(name);
+			        traverse(schema.properties[name], fn, currentPath);
+			      });
+			    }
+
+			    //Only support type "array" which have a schema as "items".
+			    if (!ignoreArrays && schema.items) {
+			      var arrPath = path.slice();arrPath.push('');
+			      traverse(schema.items, fn, arrPath);
+			    }
+			  };
+
+			  traverse(schema, fn, path || []);
+			}
+
+			function traverseForm(form, fn) {
+			  fn(form);
+			  if (form.items) {
+			    form.items.forEach(function (f) {
+			      traverseForm(f, fn);
+			    });
+			  }
+
+			  if (form.tabs) {
+			    form.tabs.forEach(function (tab) {
+			      if (tab.items) {
+			        tab.items.forEach(function (f) {
+			          traverseForm(f, fn);
+			        });
+			      }
+			    });
+			  }
+			}
+
+		/***/ },
+		/* 9 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+
+			var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; };
+
+			exports.defaultFormDefinition = defaultFormDefinition;
+			exports.stdFormObj = stdFormObj;
+			exports.text = text;
+			exports.number = number;
+			exports.integer = integer;
+			exports.checkbox = checkbox;
+			exports.select = select;
+			exports.checkboxes = checkboxes;
+			exports.fieldset = fieldset;
+			exports.array = array;
+			exports.createDefaults = createDefaults;
+			exports.defaultForm = defaultForm;
+
+			var _sfPath = __webpack_require__(3);
+
+			var _canonicalTitleMap = __webpack_require__(6);
+
+			var _canonicalTitleMap2 = _interopRequireDefault(_canonicalTitleMap);
+
+			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+			/* Utils */
+			var stripNullType = function stripNullType(type) {
+			  if (Array.isArray(type) && type.length == 2) {
+			    if (type[0] === 'null') {
+			      return type[1];
+			    };
+			    if (type[1] === 'null') {
+			      return type[0];
+			    };
+			  };
+			  return type;
+			};
+
+			//Creates an default titleMap list from an enum, i.e. a list of strings.
+			var enumToTitleMap = function enumToTitleMap(enm) {
+			  var titleMap = []; //canonical titleMap format is a list.
+			  enm.forEach(function (name) {
+			    titleMap.push({ name: name, value: name });
+			  });
+			  return titleMap;
+			};
+
+			/**
+			 * Creates a default form definition from a schema.
+			 */
+			function defaultFormDefinition(schemaTypes, name, schema, options) {
+			  var rules = schemaTypes[stripNullType(schema.type)];
+			  if (rules) {
+			    var def = void 0;
+			    // We give each rule a possibility to recurse it's children.
+			    var innerDefaultFormDefinition = function innerDefaultFormDefinition(childName, childSchema, childOptions) {
+			      return defaultFormDefinition(schemaTypes, childName, childSchema, childOptions);
+			    };
+			    for (var i = 0; i < rules.length; i++) {
+			      def = rules[i](name, schema, options, innerDefaultFormDefinition);
+
+			      //first handler in list that actually returns something is our handler!
+			      if (def) {
+
+			        // Do we have form defaults in the schema under the x-schema-form-attribute?
+			        if (def.schema['x-schema-form']) {
+			          Object.assign(def, def.schema['x-schema-form']);
+			        }
+
+			        return def;
+			      }
+			    }
+			  }
+			}
+
+			/**
+			 * Creates a form object with all common properties
+			 */
+			function stdFormObj(name, schema, options) {
+			  options = options || {};
+
+			  // The Object.assign used to be a angular.copy. Should work though.
+			  var f = options.global && options.global.formDefaults ? Object.assign({}, options.global.formDefaults) : {};
+			  if (options.global && options.global.supressPropertyTitles === true) {
+			    f.title = schema.title;
+			  } else {
+			    f.title = schema.title || name;
+			  }
+
+			  if (schema.description) {
+			    f.description = schema.description;
+			  }
+			  if (options.required === true || schema.required === true) {
+			    f.required = true;
+			  }
+			  if (schema.maxLength) {
+			    f.maxlength = schema.maxLength;
+			  }
+			  if (schema.minLength) {
+			    f.minlength = schema.minLength;
+			  }
+			  if (schema.readOnly || schema.readonly) {
+			    f.readonly = true;
+			  }
+			  if (schema.minimum) {
+			    f.minimum = schema.minimum + (schema.exclusiveMinimum ? 1 : 0);
+			  }
+			  if (schema.maximum) {
+			    f.maximum = schema.maximum - (schema.exclusiveMaximum ? 1 : 0);
+			  }
+
+			  // Non standard attributes (DONT USE DEPRECATED)
+			  // If you must set stuff like this in the schema use the x-schema-form attribute
+			  if (schema.validationMessage) {
+			    f.validationMessage = schema.validationMessage;
+			  }
+			  if (schema.enumNames) {
+			    f.titleMap = (0, _canonicalTitleMap2.default)(schema.enumNames, schema['enum']);
+			  }
+			  f.schema = schema;
+
+			  // Ng model options doesn't play nice with undefined, might be defined
+			  // globally though
+			  f.ngModelOptions = f.ngModelOptions || {};
+
+			  return f;
+			};
+
+			/*** Schema types to form type mappings, with defaults ***/
+			function text(name, schema, options) {
+			  if (stripNullType(schema.type) === 'string' && !schema['enum']) {
+			    var f = stdFormObj(name, schema, options);
+			    f.key = options.path;
+			    f.type = 'text';
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+			    return f;
+			  }
+			}
+
+			//default in json form for number and integer is a text field
+			//input type="number" would be more suitable don't ya think?
+			function number(name, schema, options) {
+			  if (stripNullType(schema.type) === 'number') {
+			    var f = stdFormObj(name, schema, options);
+			    f.key = options.path;
+			    f.type = 'number';
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+			    return f;
+			  }
+			}
+
+			function integer(name, schema, options) {
+			  if (stripNullType(schema.type) === 'integer') {
+			    var f = stdFormObj(name, schema, options);
+			    f.key = options.path;
+			    f.type = 'number';
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+			    return f;
+			  }
+			}
+
+			function checkbox(name, schema, options) {
+			  if (stripNullType(schema.type) === 'boolean') {
+			    var f = stdFormObj(name, schema, options);
+			    f.key = options.path;
+			    f.type = 'checkbox';
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+			    return f;
+			  }
+			}
+
+			function select(name, schema, options) {
+			  if (stripNullType(schema.type) === 'string' && schema['enum']) {
+			    var f = stdFormObj(name, schema, options);
+			    f.key = options.path;
+			    f.type = 'select';
+			    if (!f.titleMap) {
+			      f.titleMap = enumToTitleMap(schema['enum']);
+			    }
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+			    return f;
+			  }
+			}
+
+			function checkboxes(name, schema, options) {
+			  if (stripNullType(schema.type) === 'array' && schema.items && schema.items['enum']) {
+			    var f = stdFormObj(name, schema, options);
+			    f.key = options.path;
+			    f.type = 'checkboxes';
+			    if (!f.titleMap) {
+			      f.titleMap = enumToTitleMap(schema.items['enum']);
+			    }
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+			    return f;
+			  }
+			}
+
+			function fieldset(name, schema, options, defaultFormDef) {
+			  if (stripNullType(schema.type) === 'object') {
+			    var _ret = function () {
+			      var f = stdFormObj(name, schema, options);
+			      f.type = 'fieldset';
+			      f.key = options.path;
+			      f.items = [];
+			      options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+
+			      //recurse down into properties
+			      if (schema.properties) {
+			        Object.keys(schema.properties).forEach(function (key) {
+			          var value = schema.properties[key];
+			          var path = options.path.slice();
+			          path.push(key);
+			          if (options.ignore[(0, _sfPath.stringify)(path)] !== true) {
+			            var required = schema.required && schema.required.indexOf(key) !== -1;
+
+			            var def = defaultFormDef(key, value, {
+			              path: path,
+			              required: required || false,
+			              lookup: options.lookup,
+			              ignore: options.ignore,
+			              global: options.global
+			            });
+			            if (def) {
+			              f.items.push(def);
+			            }
+			          }
+			        });
+			      }
+			      return {
+			        v: f
+			      };
+			    }();
+
+			    if ((typeof _ret === 'undefined' ? 'undefined' : _typeof(_ret)) === "object") return _ret.v;
+			  }
+			}
+
+			function array(name, schema, options, defaultFormDef) {
+			  if (stripNullType(schema.type) === 'array') {
+			    var f = stdFormObj(name, schema, options);
+			    f.type = 'array';
+			    f.key = options.path;
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+
+			    var required = schema.required && schema.required.indexOf(options.path[options.path.length - 1]) !== -1;
+
+			    // The default is to always just create one child. This works since if the
+			    // schemas items declaration is of type: "object" then we get a fieldset.
+			    // We also follow json form notatation, adding empty brackets "[]" to
+			    // signify arrays.
+
+			    var arrPath = options.path.slice();
+			    arrPath.push('');
+
+			    f.items = [defaultFormDef(name, schema.items, {
+			      path: arrPath,
+			      required: required || false,
+			      lookup: options.lookup,
+			      ignore: options.ignore,
+			      global: options.global
+			    })];
+
+			    return f;
+			  }
+			}
+
+			function createDefaults() {
+			  //First sorted by schema type then a list.
+			  //Order has importance. First handler returning an form snippet will be used.
+			  return {
+			    string: [select, text],
+			    object: [fieldset],
+			    number: [number],
+			    integer: [integer],
+			    boolean: [checkbox],
+			    array: [checkboxes, array]
+			  };
+			};
+
+			/**
+			 * Create form defaults from schema
+			 */
+			function defaultForm(schema, defaultSchemaTypes, ignore, globalOptions) {
+			  var form = [];
+			  var lookup = {}; //Map path => form obj for fast lookup in merging
+			  ignore = ignore || {};
+			  globalOptions = globalOptions || {};
+			  defaultSchemaTypes = defaultSchemaTypes || createDefaults();
+
+			  if (schema.properties) {
+			    Object.keys(schema.properties).forEach(function (key) {
+			      if (ignore[key] !== true) {
+			        var required = schema.required && schema.required.indexOf(key) !== -1;
+			        var def = defaultFormDefinition(defaultSchemaTypes, key, schema.properties[key], {
+			          path: [key], // Path to this property in bracket notation.
+			          lookup: lookup, // Extra map to register with. Optimization for merger.
+			          ignore: ignore, // The ignore list of paths (sans root level name)
+			          required: required, // Is it required? (v4 json schema style)
+			          global: globalOptions // Global options, including form defaults
+			        });
+			        if (def) {
+			          form.push(def);
+			        }
+			      }
+			    });
+			  } else {
+			    throw new Error('Not implemented. Only type "object" allowed at root level of schema.');
+			  }
+			  return { form: form, lookup: lookup };
+			}
+
+		/***/ }
+		/******/ ])
+		});
+		;
+
+	/***/ },
+	/* 7 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function () {
+
+		  var validator = {};
+
+		  /**
+		   * Validate a value against its form definition and schema.
+		   * The value should either be of proper type or a string, some type
+		   * coercion is applied.
+		   *
+		   * @param {Object} form A merged form definition, i.e. one with a schema.
+		   * @param {Any} value the value to validate.
+		   * @return a tv4js result object.
+		   */
+		  validator.validate = function (form, value) {
+		    if (!form) {
+		      return { valid: true };
+		    }
+		    var schema = form.schema;
+
+		    if (!schema) {
+		      return { valid: true };
+		    }
+
+		    // Input of type text and textareas will give us a viewValue of ''
+		    // when empty, this is a valid value in a schema and does not count as something
+		    // that breaks validation of 'required'. But for our own sanity an empty field should
+		    // not validate if it's required.
+		    if (value === '') {
+		      value = undefined;
+		    }
+
+		    // Numbers fields will give a null value, which also means empty field
+		    if (form.type === 'number' && value === null) {
+		      value = undefined;
+		    }
+
+		    // Version 4 of JSON Schema has the required property not on the
+		    // property itself but on the wrapping object. Since we like to test
+		    // only this property we wrap it in a fake object.
+		    var wrap = { type: 'object', 'properties': {} };
+		    var propName = form.key[form.key.length - 1];
+		    wrap.properties[propName] = schema;
+
+		    if (form.required) {
+		      wrap.required = [propName];
+		    }
+		    var valueWrap = {};
+		    if (_angular2.default.isDefined(value)) {
+		      valueWrap[propName] = value;
+		    }
+		    return _tv2.default.validateResult(valueWrap, wrap);
+		  };
+
+		  return validator;
+		};
+
+		var _tv = __webpack_require__(8);
+
+		var _tv2 = _interopRequireDefault(_tv);
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 8 */
+	/***/ function(module, exports) {
+
+		module.exports = tv4;
+
+	/***/ },
+	/* 9 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function () {
+
+		  // The codes are tv4 error codes.
+		  // Not all of these can actually happen in a field, but for
+		  // we never know when one might pop up so it's best to cover them all.
+
+		  // TODO: Humanize these.
+		  var defaultMessages = {
+		    'default': 'Field does not validate',
+		    0: 'Invalid type, expected {{schema.type}}',
+		    1: 'No enum match for: {{viewValue}}',
+		    10: 'Data does not match any schemas from "anyOf"',
+		    11: 'Data does not match any schemas from "oneOf"',
+		    12: 'Data is valid against more than one schema from "oneOf"',
+		    13: 'Data matches schema from "not"',
+		    // Numeric errors
+		    100: 'Value is not a multiple of {{schema.multipleOf}}',
+		    101: '{{viewValue}} is less than the allowed minimum of {{schema.minimum}}',
+		    102: '{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}',
+		    103: '{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}',
+		    104: '{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}',
+		    105: 'Value is not a valid number',
+		    // String errors
+		    200: 'String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}',
+		    201: 'String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}',
+		    202: 'String does not match pattern: {{schema.pattern}}',
+		    // Object errors
+		    300: 'Too few properties defined, minimum {{schema.minProperties}}',
+		    301: 'Too many properties defined, maximum {{schema.maxProperties}}',
+		    302: 'Required',
+		    303: 'Additional properties not allowed',
+		    304: 'Dependency failed - key must exist',
+		    // Array errors
+		    400: 'Array is too short ({{value.length}}), minimum {{schema.minItems}}',
+		    401: 'Array is too long ({{value.length}}), maximum {{schema.maxItems}}',
+		    402: 'Array items are not unique',
+		    403: 'Additional items not allowed',
+		    // Format errors
+		    500: 'Format validation failed',
+		    501: 'Keyword failed: "{{title}}"',
+		    // Schema structure
+		    600: 'Circular $refs',
+		    // Non-standard validation options
+		    1000: 'Unknown property (not in schema)'
+		  };
+
+		  // In some cases we get hit with an angular validation error
+		  defaultMessages.number = defaultMessages[105];
+		  defaultMessages.required = defaultMessages[302];
+		  defaultMessages.min = defaultMessages[101];
+		  defaultMessages.max = defaultMessages[103];
+		  defaultMessages.maxlength = defaultMessages[201];
+		  defaultMessages.minlength = defaultMessages[200];
+		  defaultMessages.pattern = defaultMessages[202];
+
+		  this.setDefaultMessages = function (messages) {
+		    defaultMessages = messages;
+		  };
+
+		  this.getDefaultMessages = function () {
+		    return defaultMessages;
+		  };
+
+		  this.setDefaultMessage = function (error, msg) {
+		    defaultMessages[error] = msg;
+		  };
+
+		  this.$get = ['$interpolate', function ($interpolate) {
+
+		    var service = {};
+		    service.defaultMessages = defaultMessages;
+
+		    /**
+		     * Interpolate and return proper error for an eror code.
+		     * Validation message on form trumps global error messages.
+		     * and if the message is a function instead of a string that function will be called instead.
+		     * @param {string} error the error code, i.e. tv4-xxx for tv4 errors, otherwise it's whats on
+		     *                       ngModel.$error for custom errors.
+		     * @param {Any} value the actual model value.
+		     * @param {Any} viewValue the viewValue
+		     * @param {Object} form a form definition object for this field
+		     * @param  {Object} global the global validation messages object (even though its called global
+		     *                         its actually just shared in one instance of sf-schema)
+		     * @return {string} The error message.
+		     */
+		    service.interpolate = function (error, value, viewValue, form, global) {
+		      global = global || {};
+		      var validationMessage = form.validationMessage || {};
+
+		      // Drop tv4 prefix so only the code is left.
+		      if (error.indexOf('tv4-') === 0) {
+		        error = error.substring(4);
+		      }
+
+		      // First find apropriate message or function
+		      var message = validationMessage['default'] || global['default'] || '';
+
+		      [validationMessage, global, defaultMessages].some(function (val) {
+		        if (_angular2.default.isString(val) || _angular2.default.isFunction(val)) {
+		          message = val;
+		          return true;
+		        }
+		        if (val && val[error]) {
+		          message = val[error];
+		          return true;
+		        }
+		      });
+
+		      var context = {
+		        error: error,
+		        value: value,
+		        viewValue: viewValue,
+		        form: form,
+		        schema: form.schema,
+		        title: form.title || form.schema && form.schema.title
+		      };
+		      if (_angular2.default.isFunction(message)) {
+		        return message(context);
+		      } else {
+		        return $interpolate(message)(context);
+		      }
+		    };
+
+		    return service;
+		  }];
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 10 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function () {
+
+		  // expose the methods in sfPathProvider
+		  this.parse = _jsonSchemaFormCore.sfPath.parse;
+		  this.stringify = _jsonSchemaFormCore.sfPath.stringify;
+		  this.normalize = _jsonSchemaFormCore.sfPath.normalize;
+
+		  this.$get = function () {
+		    return _jsonSchemaFormCore.sfPath;
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		var _jsonSchemaFormCore = __webpack_require__(6);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 11 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function (sfSelect, schemaForm, sfValidator, sfPath) {
+
+		  var setIndex = function setIndex(index) {
+		    return function (form) {
+		      if (form.key) {
+		        form.key[form.key.indexOf('')] = index;
+		      }
+		    };
+		  };
+
+		  return {
+		    restrict: 'A',
+		    scope: true,
+		    require: '?ngModel',
+		    link: function link(scope, element, attrs, ngModel) {
+		      var formDefCache = {};
+
+		      scope.validateArray = _angular2.default.noop;
+
+		      if (ngModel) {
+		        // We need the ngModelController on several places,
+		        // most notably for errors.
+		        // So we emit it up to the decorator directive so it can put it on scope.
+		        scope.$emit('schemaFormPropagateNgModelController', ngModel);
+		      }
+
+		      // Watch for the form definition and then rewrite it.
+		      // It's the (first) array part of the key, '[]' that needs a number
+		      // corresponding to an index of the form.
+		      var once = scope.$watch(attrs.sfArray, function (form) {
+		        if (!form) {
+		          return;
+		        }
+
+		        // An array model always needs a key so we know what part of the model
+		        // to look at. This makes us a bit incompatible with JSON Form, on the
+		        // other hand it enables two way binding.
+		        var list = sfSelect(form.key, scope.model);
+
+		        // We only modify the same array instance but someone might change the array from
+		        // the outside so let's watch for that. We use an ordinary watch since the only case
+		        // we're really interested in is if its a new instance.
+		        var key = sfPath.normalize(form.key);
+		        scope.$watch('model' + (key[0] !== '[' ? '.' : '') + key, function (value) {
+		          list = scope.modelArray = value;
+		        });
+
+		        // Since ng-model happily creates objects in a deep path when setting a
+		        // a value but not arrays we need to create the array.
+		        if (_angular2.default.isUndefined(list)) {
+		          list = [];
+		          sfSelect(form.key, scope.model, list);
+		        }
+		        scope.modelArray = list;
+
+		        // Arrays with titleMaps, i.e. checkboxes doesn't have items.
+		        if (form.items) {
+
+		          // To be more compatible with JSON Form we support an array of items
+		          // in the form definition of "array" (the schema just a value).
+		          // for the subforms code to work this means we wrap everything in a
+		          // section. Unless there is just one.
+		          var subForm = form.items[0];
+		          if (form.items.length > 1) {
+		            subForm = {
+		              type: 'section',
+		              items: form.items.map(function (item) {
+		                item.ngModelOptions = form.ngModelOptions;
+		                if (_angular2.default.isUndefined(item.readonly)) {
+		                  item.readonly = form.readonly;
+		                }
+		                return item;
+		              })
+		            };
+		          }
+		        }
+
+		        // We ceate copies of the form on demand, caching them for
+		        // later requests
+		        scope.copyWithIndex = function (index) {
+		          if (!formDefCache[index]) {
+		            if (subForm) {
+		              var copy = _angular2.default.copy(subForm);
+		              copy.arrayIndex = index;
+		              schemaForm.traverseForm(copy, setIndex(index));
+		              formDefCache[index] = copy;
+		            }
+		          }
+		          return formDefCache[index];
+		        };
+
+		        scope.appendToArray = function () {
+		          var len = list.length;
+		          var copy = scope.copyWithIndex(len);
+		          schemaForm.traverseForm(copy, function (part) {
+
+		            if (part.key) {
+		              var def;
+		              if (_angular2.default.isDefined(part['default'])) {
+		                def = part['default'];
+		              }
+		              if (_angular2.default.isDefined(part.schema) && _angular2.default.isDefined(part.schema['default'])) {
+		                def = part.schema['default'];
+		              }
+
+		              if (_angular2.default.isDefined(def)) {
+		                sfSelect(part.key, scope.model, def);
+		              }
+		            }
+		          });
+
+		          // If there are no defaults nothing is added so we need to initialize
+		          // the array. undefined for basic values, {} or [] for the others.
+		          if (len === list.length) {
+		            var type = sfSelect('schema.items.type', form);
+		            var dflt;
+		            if (type === 'object') {
+		              dflt = {};
+		            } else if (type === 'array') {
+		              dflt = [];
+		            }
+		            list.push(dflt);
+		          }
+
+		          // Trigger validation.
+		          scope.validateArray();
+		          return list;
+		        };
+
+		        scope.deleteFromArray = function (index) {
+		          list.splice(index, 1);
+
+		          // Trigger validation.
+		          scope.validateArray();
+
+		          // Angular 1.2 lacks setDirty
+		          if (ngModel && ngModel.$setDirty) {
+		            ngModel.$setDirty();
+		          }
+		          return list;
+		        };
+
+		        // Always start with one empty form unless configured otherwise.
+		        // Special case: don't do it if form has a titleMap
+		        if (!form.titleMap && form.startEmpty !== true && list.length === 0) {
+		          scope.appendToArray();
+		        }
+
+		        // Title Map handling
+		        // If form has a titleMap configured we'd like to enable looping over
+		        // titleMap instead of modelArray, this is used for intance in
+		        // checkboxes. So instead of variable number of things we like to create
+		        // a array value from a subset of values in the titleMap.
+		        // The problem here is that ng-model on a checkbox doesn't really map to
+		        // a list of values. This is here to fix that.
+		        if (form.titleMap && form.titleMap.length > 0) {
+		          scope.titleMapValues = [];
+
+		          // We watch the model for changes and the titleMapValues to reflect
+		          // the modelArray
+		          var updateTitleMapValues = function updateTitleMapValues(arr) {
+		            scope.titleMapValues = [];
+		            arr = arr || [];
+
+		            form.titleMap.forEach(function (item) {
+		              scope.titleMapValues.push(arr.indexOf(item.value) !== -1);
+		            });
+		          };
+		          //Catch default values
+		          updateTitleMapValues(scope.modelArray);
+		          scope.$watchCollection('modelArray', updateTitleMapValues);
+
+		          //To get two way binding we also watch our titleMapValues
+		          scope.$watchCollection('titleMapValues', function (vals, old) {
+		            if (vals && vals !== old) {
+		              var arr = scope.modelArray;
+
+		              // Apparently the fastest way to clear an array, readable too.
+		              // http://jsperf.com/array-destroy/32
+		              while (arr.length > 0) {
+		                arr.pop();
+		              }
+		              form.titleMap.forEach(function (item, index) {
+		                if (vals[index]) {
+		                  arr.push(item.value);
+		                }
+		              });
+
+		              // Time to validate the rebuilt array.
+		              scope.validateArray();
+		            }
+		          });
+		        }
+
+		        // If there is a ngModel present we need to validate when asked.
+		        if (ngModel) {
+		          var error;
+
+		          scope.validateArray = function () {
+		            // The actual content of the array is validated by each field
+		            // so we settle for checking validations specific to arrays
+
+		            // Since we prefill with empty arrays we can get the funny situation
+		            // where the array is required but empty in the gui but still validates.
+		            // Thats why we check the length.
+		            var result = sfValidator.validate(form, scope.modelArray.length > 0 ? scope.modelArray : undefined);
+
+		            // TODO: DRY this up, it has a lot of similarities with schema-validate
+		            // Since we might have different tv4 errors we must clear all
+		            // errors that start with tv4-
+		            Object.keys(ngModel.$error).filter(function (k) {
+		              return k.indexOf('tv4-') === 0;
+		            }).forEach(function (k) {
+		              ngModel.$setValidity(k, true);
+		            });
+
+		            if (result.valid === false && result.error && (result.error.dataPath === '' || result.error.dataPath === '/' + form.key[form.key.length - 1])) {
+
+		              // Set viewValue to trigger $dirty on field. If someone knows a
+		              // a better way to do it please tell.
+		              ngModel.$setViewValue(scope.modelArray);
+		              error = result.error;
+		              ngModel.$setValidity('tv4-' + result.error.code, false);
+		            }
+		          };
+
+		          scope.$on('schemaFormValidate', scope.validateArray);
+
+		          scope.hasSuccess = function () {
+		            if (scope.options && scope.options.pristine && scope.options.pristine.success === false) {
+		              return ngModel.$valid && !ngModel.$pristine && !ngModel.$isEmpty(ngModel.$modelValue);
+		            } else {
+		              return ngModel.$valid && (!ngModel.$pristine || !ngModel.$isEmpty(ngModel.$modelValue));
+		            }
+		          };
+
+		          scope.hasError = function () {
+		            if (!scope.options || !scope.options.pristine || scope.options.pristine.errors !== false) {
+		              // Show errors in pristine forms. The default.
+		              // Note that "validateOnRender" option defaults to *not* validate initial form.
+		              // so as a default there won't be any error anyway, but if the model is modified
+		              // from the outside the error will show even if the field is pristine.
+		              return ngModel.$invalid;
+		            } else {
+		              // Don't show errors in pristine forms.
+		              return ngModel.$invalid && !ngModel.$pristine;
+		            }
+		          };
+
+		          scope.schemaError = function () {
+		            return error;
+		          };
+		        }
+
+		        once();
+		      });
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 12 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function () {
+		  return {
+		    require: 'ngModel',
+		    restrict: 'AC',
+		    scope: false,
+		    link: function link(scope, element, attrs, ctrl) {
+		      var form = scope.$eval(attrs.sfChanged);
+		      //"form" is really guaranteed to be here since the decorator directive
+		      //waits for it. But best be sure.
+		      if (form && form.onChange) {
+		        ctrl.$viewChangeListeners.push(function () {
+		          if (_angular2.default.isFunction(form.onChange)) {
+		            form.onChange(ctrl.$modelValue, form);
+		          } else {
+		            scope.evalExpr(form.onChange, { 'modelValue': ctrl.$modelValue, form: form });
+		          }
+		        });
+		      }
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 13 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function ($parse, $compile, $http, $templateCache, $interpolate, $q, sfErrorMessage, sfPath, sfSelect) {
+
+		  return {
+		    restrict: 'AE',
+		    replace: false,
+		    transclude: false,
+		    scope: true,
+		    require: '^sfSchema',
+		    link: {
+		      pre: function pre(scope, element, attrs, sfSchema) {
+		        //The ngModelController is used in some templates and
+		        //is needed for error messages,
+		        scope.$on('schemaFormPropagateNgModelController', function (event, ngModel) {
+		          event.stopPropagation();
+		          event.preventDefault();
+		          scope.ngModel = ngModel;
+		        });
+
+		        // Fetch our form.
+		        scope.form = sfSchema.lookup['f' + attrs.sfField];
+		      },
+		      post: function post(scope, element, attrs, sfSchema) {
+		        //Keep error prone logic from the template
+		        scope.showTitle = function () {
+		          return scope.form && scope.form.notitle !== true && scope.form.title;
+		        };
+
+		        scope.listToCheckboxValues = function (list) {
+		          var values = {};
+		          _angular2.default.forEach(list, function (v) {
+		            values[v] = true;
+		          });
+		          return values;
+		        };
+
+		        scope.checkboxValuesToList = function (values) {
+		          var lst = [];
+		          _angular2.default.forEach(values, function (v, k) {
+		            if (v) {
+		              lst.push(k);
+		            }
+		          });
+		          return lst;
+		        };
+
+		        scope.buttonClick = function ($event, form) {
+		          if (_angular2.default.isFunction(form.onClick)) {
+		            form.onClick($event, form);
+		          } else if (_angular2.default.isString(form.onClick)) {
+		            if (sfSchema) {
+		              //evaluating in scope outside of sfSchemas isolated scope
+		              sfSchema.evalInParentScope(form.onClick, { '$event': $event, form: form });
+		            } else {
+		              scope.$eval(form.onClick, { '$event': $event, form: form });
+		            }
+		          }
+		        };
+
+		        /**
+		         * Evaluate an expression, i.e. scope.$eval
+		         * but do it in sfSchemas parent scope sf-schema directive is used
+		         *
+		         * @param {string} expression
+		         * @param {Object} locals (optional)
+		         * @return {Any} the result of the expression
+		         */
+		        scope.evalExpr = function (expression, locals) {
+		          if (sfSchema) {
+		            //evaluating in scope outside of sfSchemas isolated scope
+		            return sfSchema.evalInParentScope(expression, locals);
+		          }
+
+		          return scope.$eval(expression, locals);
+		        };
+
+		        /**
+		         * Evaluate an expression, i.e. scope.$eval
+		         * in this decorators scope
+		         * @param {string} expression
+		         * @param {Object} locals (optional)
+		         * @return {Any} the result of the expression
+		         */
+		        scope.evalInScope = function (expression, locals) {
+		          if (expression) {
+		            return scope.$eval(expression, locals);
+		          }
+		        };
+
+		        /**
+		         * Interpolate the expression.
+		         * Similar to `evalExpr()` and `evalInScope()`
+		         * but will not fail if the expression is
+		         * text that contains spaces.
+		         *
+		         * Use the Angular `{{ interpolation }}`
+		         * braces to access properties on `locals`.
+		         *
+		         * @param  {string} content The string to interpolate.
+		         * @param  {Object} locals (optional) Properties that may be accessed in the
+		         *                         `expression` string.
+		         * @return {Any} The result of the expression or `undefined`.
+		         */
+		        scope.interp = function (expression, locals) {
+		          return expression && $interpolate(expression)(locals);
+		        };
+
+		        //This works since we get the ngModel from the array or the schema-validate directive.
+		        scope.hasSuccess = function () {
+		          if (!scope.ngModel) {
+		            return false;
+		          }
+		          if (scope.options && scope.options.pristine && scope.options.pristine.success === false) {
+		            return scope.ngModel.$valid && !scope.ngModel.$pristine && !scope.ngModel.$isEmpty(scope.ngModel.$modelValue);
+		          } else {
+		            return scope.ngModel.$valid && (!scope.ngModel.$pristine || !scope.ngModel.$isEmpty(scope.ngModel.$modelValue));
+		          }
+		        };
+
+		        scope.hasError = function () {
+		          if (!scope.ngModel) {
+		            return false;
+		          }
+		          if (!scope.options || !scope.options.pristine || scope.options.pristine.errors !== false) {
+		            // Show errors in pristine forms. The default.
+		            // Note that "validateOnRender" option defaults to *not* validate initial form.
+		            // so as a default there won't be any error anyway, but if the model is modified
+		            // from the outside the error will show even if the field is pristine.
+		            return scope.ngModel.$invalid;
+		          } else {
+		            // Don't show errors in pristine forms.
+		            return scope.ngModel.$invalid && !scope.ngModel.$pristine;
+		          }
+		        };
+
+		        /**
+		         * DEPRECATED: use sf-messages instead.
+		         * Error message handler
+		         * An error can either be a schema validation message or a angular js validtion
+		         * error (i.e. required)
+		         */
+		        scope.errorMessage = function (schemaError) {
+		          return sfErrorMessage.interpolate(schemaError && schemaError.code + '' || 'default', scope.ngModel && scope.ngModel.$modelValue || '', scope.ngModel && scope.ngModel.$viewValue || '', scope.form, scope.options && scope.options.validationMessage);
+		        };
+
+		        var form = scope.form;
+
+		        // Where there is a key there is probably a ngModel
+		        if (form.key) {
+		          // It looks better with dot notation.
+		          scope.$on('schemaForm.error.' + form.key.join('.'), function (event, error, validationMessage, validity, formName) {
+		            // validationMessage and validity are mutually exclusive
+		            formName = validity;
+		            if (validationMessage === true || validationMessage === false) {
+		              validity = validationMessage;
+		              validationMessage = undefined;
+		            };
+
+		            // If we have specified a form name, and this model is not within
+		            // that form, then leave things be.
+		            if (formName != undefined && scope.ngModel.$$parentForm.$name !== formName) {
+		              return;
+		            };
+
+		            if (scope.ngModel && error) {
+		              if (scope.ngModel.$setDirty) {
+		                scope.ngModel.$setDirty();
+		              } else {
+		                // FIXME: Check that this actually works on 1.2
+		                scope.ngModel.$dirty = true;
+		                scope.ngModel.$pristine = false;
+		              }
+
+		              // Set the new validation message if one is supplied
+		              // Does not work when validationMessage is just a string.
+		              if (validationMessage) {
+		                if (!form.validationMessage) {
+		                  form.validationMessage = {};
+		                }
+		                form.validationMessage[error] = validationMessage;
+		              }
+
+		              scope.ngModel.$setValidity(error, validity === true);
+
+		              if (validity === true) {
+		                // Re-trigger model validator, that model itself would be re-validated
+		                scope.ngModel.$validate();
+
+		                // Setting or removing a validity can change the field to believe its valid
+		                // but its not. So lets trigger its validation as well.
+		                scope.$broadcast('schemaFormValidate');
+		              }
+		            }
+		          });
+
+		          // Clean up the model when the corresponding form field is $destroy-ed.
+		          // Default behavior can be supplied as a globalOption, and behavior can be overridden
+		          // in the form definition.
+		          scope.$on('$destroy', function () {
+		            // If the entire schema form is destroyed we don't touch the model
+		            if (!scope.externalDestructionInProgress) {
+		              var destroyStrategy = form.destroyStrategy || scope.options && scope.options.destroyStrategy || 'remove';
+		              // No key no model, and we might have strategy 'retain'
+		              if (form.key && destroyStrategy !== 'retain') {
+
+		                // Get the object that has the property we wan't to clear.
+		                var obj = scope.model;
+		                if (form.key.length > 1) {
+		                  obj = sfSelect(form.key.slice(0, form.key.length - 1), obj);
+		                }
+
+		                // We can get undefined here if the form hasn't been filled out entirely
+		                if (obj === undefined) {
+		                  return;
+		                }
+
+		                // Type can also be a list in JSON Schema
+		                var type = form.schema && form.schema.type || '';
+
+		                // Empty means '',{} and [] for appropriate types and undefined for the rest
+		                //console.log('destroy', destroyStrategy, form.key, type, obj);
+		                if (destroyStrategy === 'empty' && type.indexOf('string') !== -1) {
+		                  obj[form.key.slice(-1)] = '';
+		                } else if (destroyStrategy === 'empty' && type.indexOf('object') !== -1) {
+		                  obj[form.key.slice(-1)] = {};
+		                } else if (destroyStrategy === 'empty' && type.indexOf('array') !== -1) {
+		                  obj[form.key.slice(-1)] = [];
+		                } else if (destroyStrategy === 'null') {
+		                  obj[form.key.slice(-1)] = null;
+		                } else {
+		                  delete obj[form.key.slice(-1)];
+		                }
+		              }
+		            }
+		          });
+		        }
+		      }
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 14 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function ($injector, sfErrorMessage) {
+
+		  //Inject sanitizer if it exists
+		  var $sanitize = $injector.has('$sanitize') ? $injector.get('$sanitize') : function (html) {
+		    return html;
+		  };
+
+		  return {
+		    scope: false,
+		    restrict: 'EA',
+		    link: function link(scope, element, attrs) {
+
+		      var message = '';
+		      if (attrs.sfMessage) {
+		        scope.$watch(attrs.sfMessage, function (msg) {
+		          if (msg) {
+		            message = $sanitize(msg);
+		            update(!!scope.ngModel);
+		          }
+		        });
+		      }
+
+		      var currentMessage;
+		      // Only call html() if needed.
+		      var setMessage = function setMessage(msg) {
+		        if (msg !== currentMessage) {
+		          element.html(msg);
+		          currentMessage = msg;
+		        }
+		      };
+
+		      var update = function update(checkForErrors) {
+		        if (checkForErrors) {
+		          if (!scope.hasError()) {
+		            setMessage(message);
+		          } else {
+		            var errors = [];
+		            _angular2.default.forEach(scope.ngModel && scope.ngModel.$error, function (status, code) {
+		              if (status) {
+		                // if true then there is an error
+		                // Angular 1.3 removes properties, so we will always just have errors.
+		                // Angular 1.2 sets them to false.
+		                errors.push(code);
+		              }
+		            });
+
+		            // In Angular 1.3 we use one $validator to stop the model value from getting updated.
+		            // this means that we always end up with a 'schemaForm' error.
+		            errors = errors.filter(function (e) {
+		              return e !== 'schemaForm';
+		            });
+
+		            // We only show one error.
+		            // TODO: Make that optional
+		            var error = errors[0];
+
+		            if (error) {
+		              setMessage(sfErrorMessage.interpolate(error, scope.ngModel.$modelValue, scope.ngModel.$viewValue, scope.form, scope.options && scope.options.validationMessage));
+		            } else {
+		              setMessage(message);
+		            }
+		          }
+		        } else {
+		          setMessage(message);
+		        }
+		      };
+
+		      // Update once.
+		      update();
+
+		      var once = scope.$watch('ngModel', function (ngModel) {
+		        if (ngModel) {
+		          // We also listen to changes of the model via parsers and formatters.
+		          // This is since both the error message can change and given a pristine
+		          // option to not show errors the ngModel.$error might not have changed
+		          // but we're not pristine any more so we should change!
+		          ngModel.$parsers.push(function (val) {
+		            update(true);return val;
+		          });
+		          ngModel.$formatters.push(function (val) {
+		            update(true);return val;
+		          });
+		          once();
+		        }
+		      });
+
+		      // We watch for changes in $error
+		      scope.$watchCollection('ngModel.$error', function () {
+		        update(!!scope.ngModel);
+		      });
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 15 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function (sel, sfPath, schemaForm) {
+		  return {
+		    scope: false,
+		    link: function link(scope, element, attrs) {
+		      scope.min = 0;
+
+		      scope.modelArray = scope.$eval(attrs.sfNewArray);
+
+		      // We need to have a ngModel to hook into validation. It doesn't really play well with
+		      // arrays though so we both need to trigger validation and onChange.
+		      // So we watch the value as well. But watching an array can be tricky. We wan't to know
+		      // when it changes so we can validate,
+		      var watchFn = function watchFn() {
+		        //scope.modelArray = modelArray;
+		        scope.modelArray = scope.$eval(attrs.sfNewArray);
+		        // validateField method is exported by schema-validate
+		        if (scope.ngModel && scope.ngModel.$pristine && scope.firstDigest && (!scope.options || scope.options.validateOnRender !== true)) {
+		          return;
+		        } else if (scope.validateField) {
+		          scope.validateField();
+		        }
+		      };
+
+		      var onChangeFn = function onChangeFn() {
+		        if (scope.form && scope.form.onChange) {
+		          if (_angular2.default.isFunction(scope.form.onChange)) {
+		            scope.form.onChange(scope.modelArray, scope.form);
+		          } else {
+		            scope.evalExpr(scope.form.onChange, { 'modelValue': scope.modelArray, form: scope.form });
+		          }
+		        }
+		      };
+
+		      // If model is undefined make sure it gets set.
+		      var getOrCreateModel = function getOrCreateModel() {
+		        var model = scope.modelArray;
+		        if (!model) {
+		          var selection = sfPath.parse(attrs.sfNewArray);
+		          model = [];
+		          sel(selection, scope, model);
+		          scope.modelArray = model;
+		        }
+		        return model;
+		      };
+
+		      // We need the form definition to make a decision on how we should listen.
+		      var once = scope.$watch('form', function (form) {
+		        if (!form) {
+		          return;
+		        }
+
+		        // Always start with one empty form unless configured otherwise.
+		        // Special case: don't do it if form has a titleMap
+		        if (!form.titleMap && form.startEmpty !== true && (!scope.modelArray || scope.modelArray.length === 0)) {
+		          scope.appendToArray();
+		        }
+
+		        // If we have "uniqueItems" set to true, we must deep watch for changes.
+		        if (scope.form && scope.form.schema && scope.form.schema.uniqueItems === true) {
+		          scope.$watch(attrs.sfNewArray, watchFn, true);
+
+		          // We still need to trigger onChange though.
+		          scope.$watch([attrs.sfNewArray, attrs.sfNewArray + '.length'], onChangeFn);
+		        } else {
+		          // Otherwise we like to check if the instance of the array has changed, or if something
+		          // has been added/removed.
+		          if (scope.$watchGroup) {
+		            scope.$watchGroup([attrs.sfNewArray, attrs.sfNewArray + '.length'], function () {
+		              watchFn();
+		              onChangeFn();
+		            });
+		          } else {
+		            // Angular 1.2 support
+		            scope.$watch(attrs.sfNewArray, function () {
+		              watchFn();
+		              onChangeFn();
+		            });
+		            scope.$watch(attrs.sfNewArray + '.length', function () {
+		              watchFn();
+		              onChangeFn();
+		            });
+		          }
+		        }
+
+		        // Title Map handling
+		        // If form has a titleMap configured we'd like to enable looping over
+		        // titleMap instead of modelArray, this is used for intance in
+		        // checkboxes. So instead of variable number of things we like to create
+		        // a array value from a subset of values in the titleMap.
+		        // The problem here is that ng-model on a checkbox doesn't really map to
+		        // a list of values. This is here to fix that.
+		        if (form.titleMap && form.titleMap.length > 0) {
+		          scope.titleMapValues = [];
+
+		          // We watch the model for changes and the titleMapValues to reflect
+		          // the modelArray
+		          var updateTitleMapValues = function updateTitleMapValues(arr) {
+		            scope.titleMapValues = [];
+		            arr = arr || [];
+
+		            form.titleMap.forEach(function (item) {
+		              scope.titleMapValues.push(arr.indexOf(item.value) !== -1);
+		            });
+		          };
+		          //Catch default values
+		          updateTitleMapValues(scope.modelArray);
+
+		          // TODO: Refactor and see if we can get rid of this watch by piggy backing on the
+		          // validation watch.
+		          scope.$watchCollection('modelArray', updateTitleMapValues);
+
+		          //To get two way binding we also watch our titleMapValues
+		          scope.$watchCollection('titleMapValues', function (vals, old) {
+		            if (vals && vals !== old) {
+		              var arr = getOrCreateModel();
+
+		              form.titleMap.forEach(function (item, index) {
+		                var arrIndex = arr.indexOf(item.value);
+		                if (arrIndex === -1 && vals[index]) arr.push(item.value);
+		                if (arrIndex !== -1 && !vals[index]) arr.splice(arrIndex, 1);
+		              });
+		              // Time to validate the rebuilt array.
+		              // validateField method is exported by schema-validate
+		              if (scope.validateField) {
+		                scope.validateField();
+		              }
+		            }
+		          });
+		        }
+
+		        once();
+		      });
+
+		      scope.appendToArray = function () {
+		        var empty;
+
+		        // Create and set an array if needed.
+		        var model = getOrCreateModel();
+
+		        // Same old add empty things to the array hack :(
+		        if (scope.form && scope.form.schema && scope.form.schema.items) {
+
+		          var items = scope.form.schema.items;
+		          if (items.type && items.type.indexOf('object') !== -1) {
+		            empty = {};
+
+		            // Check for possible defaults
+		            if (!scope.options || scope.options.setSchemaDefaults !== false) {
+		              empty = _angular2.default.isDefined(items['default']) ? items['default'] : empty;
+
+		              // Check for defaults further down in the schema.
+		              // If the default instance sets the new array item to something falsy, i.e. null
+		              // then there is no need to go further down.
+		              if (empty) {
+		                schemaForm.traverseSchema(items, function (prop, path) {
+		                  if (_angular2.default.isDefined(prop['default'])) {
+		                    sel(path, empty, prop['default']);
+		                  }
+		                });
+		              }
+		            }
+		          } else if (items.type && items.type.indexOf('array') !== -1) {
+		            empty = [];
+		            if (!scope.options || scope.options.setSchemaDefaults !== false) {
+		              empty = items['default'] || empty;
+		            }
+		          } else {
+		            // No type? could still have defaults.
+		            if (!scope.options || scope.options.setSchemaDefaults !== false) {
+		              empty = items['default'] || empty;
+		            }
+		          }
+		        }
+		        model.push(empty);
+
+		        return model;
+		      };
+
+		      scope.deleteFromArray = function (index) {
+		        var model = scope.modelArray;
+		        if (model) {
+		          model.splice(index, 1);
+		        }
+		        return model;
+		      };
+
+		      // For backwards compatability, i.e. when a bootstrap-decorator tag is used
+		      // as child to the array.
+		      var setIndex = function setIndex(index) {
+		        return function (form) {
+		          if (form.key) {
+		            form.key[form.key.indexOf('')] = index;
+		          }
+		        };
+		      };
+		      var formDefCache = {};
+		      scope.copyWithIndex = function (index) {
+		        var form = scope.form;
+		        if (!formDefCache[index]) {
+
+		          // To be more compatible with JSON Form we support an array of items
+		          // in the form definition of "array" (the schema just a value).
+		          // for the subforms code to work this means we wrap everything in a
+		          // section. Unless there is just one.
+		          var subForm = form.items[0];
+		          if (form.items.length > 1) {
+		            subForm = {
+		              type: 'section',
+		              items: form.items.map(function (item) {
+		                item.ngModelOptions = form.ngModelOptions;
+		                if (_angular2.default.isUndefined(item.readonly)) {
+		                  item.readonly = form.readonly;
+		                }
+		                return item;
+		              })
+		            };
+		          }
+
+		          if (subForm) {
+		            var copy = _angular2.default.copy(subForm);
+		            copy.arrayIndex = index;
+		            schemaForm.traverseForm(copy, setIndex(index));
+		            formDefCache[index] = copy;
+		          }
+		        }
+		        return formDefCache[index];
+		      };
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 16 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function ($compile, $http, $templateCache, $q, schemaForm, schemaFormDecorators, sfSelect, sfPath, sfBuilder) {
+
+		  return {
+		    scope: {
+		      schema: '=sfSchema',
+		      initialForm: '=sfForm',
+		      model: '=sfModel',
+		      options: '=sfOptions'
+		    },
+		    controller: ['$scope', function ($scope) {
+		      this.evalInParentScope = function (expr, locals) {
+		        return $scope.$parent.$eval(expr, locals);
+		      };
+
+		      // Set up form lookup map
+		      var that = this;
+		      $scope.lookup = function (lookup) {
+		        if (lookup) {
+		          that.lookup = lookup;
+		        }
+		        return that.lookup;
+		      };
+		    }],
+		    replace: false,
+		    restrict: 'A',
+		    transclude: true,
+		    require: '?form',
+		    link: function link(scope, element, attrs, formCtrl, transclude) {
+
+		      //expose form controller on scope so that we don't force authors to use name on form
+		      scope.formCtrl = formCtrl;
+
+		      //We'd like to handle existing markup,
+		      //besides using it in our template we also
+		      //check for ng-model and add that to an ignore list
+		      //i.e. even if form has a definition for it or form is ["*"]
+		      //we don't generate it.
+		      var ignore = {};
+		      transclude(scope, function (clone) {
+		        clone.addClass('schema-form-ignore');
+		        element.prepend(clone);
+
+		        if (element[0].querySelectorAll) {
+		          var models = element[0].querySelectorAll('[ng-model]');
+		          if (models) {
+		            for (var i = 0; i < models.length; i++) {
+		              var key = models[i].getAttribute('ng-model');
+		              //skip first part before .
+		              ignore[key.substring(key.indexOf('.') + 1)] = true;
+		            }
+		          }
+		        }
+		      });
+
+		      var lastDigest = {};
+		      var childScope;
+
+		      // Common renderer function, can either be triggered by a watch or by an event.
+		      var render = function render(schema, form) {
+		        var asyncTemplates = [];
+		        var merged = schemaForm.merge(schema, form, ignore, scope.options, undefined, asyncTemplates);
+
+		        if (asyncTemplates.length > 0) {
+		          // Pre load all async templates and put them on the form for the builder to use.
+		          $q.all(asyncTemplates.map(function (form) {
+		            return $http.get(form.templateUrl, { cache: $templateCache }).then(function (res) {
+		              form.template = res.data;
+		            });
+		          })).then(function () {
+		            internalRender(schema, form, merged);
+		          });
+		        } else {
+		          internalRender(schema, form, merged);
+		        }
+		      };
+
+		      var internalRender = function internalRender(schema, form, merged) {
+		        // Create a new form and destroy the old one.
+		        // Not doing keeps old form elements hanging around after
+		        // they have been removed from the DOM
+		        // https://github.com/Textalk/angular-schema-form/issues/200
+		        if (childScope) {
+		          // Destroy strategy should not be acted upon
+		          scope.externalDestructionInProgress = true;
+		          childScope.$destroy();
+		          scope.externalDestructionInProgress = false;
+		        }
+		        childScope = scope.$new();
+
+		        //make the form available to decorators
+		        childScope.schemaForm = { form: merged, schema: schema };
+
+		        //clean all but pre existing html.
+		        element.children(':not(.schema-form-ignore)').remove();
+
+		        // Find all slots.
+		        var slots = {};
+		        var slotsFound = element[0].querySelectorAll('*[sf-insert-field]');
+
+		        for (var i = 0; i < slotsFound.length; i++) {
+		          slots[slotsFound[i].getAttribute('sf-insert-field')] = slotsFound[i];
+		        }
+
+		        // if sfUseDecorator is undefined the default decorator is used.
+		        var decorator = schemaFormDecorators.decorator(attrs.sfUseDecorator);
+		        // Use the builder to build it and append the result
+		        var lookup = Object.create(null);
+		        scope.lookup(lookup); // give the new lookup to the controller.
+		        element[0].appendChild(sfBuilder.build(merged, decorator, slots, lookup));
+
+		        // We need to know if we're in the first digest looping
+		        // I.e. just rendered the form so we know not to validate
+		        // empty fields.
+		        childScope.firstDigest = true;
+		        // We use a ordinary timeout since we don't need a digest after this.
+		        setTimeout(function () {
+		          childScope.firstDigest = false;
+		        }, 0);
+
+		        //compile only children
+		        $compile(element.children())(childScope);
+
+		        //ok, now that that is done let's set any defaults
+		        if (!scope.options || scope.options.setSchemaDefaults !== false) {
+		          schemaForm.traverseSchema(schema, function (prop, path) {
+		            if (_angular2.default.isDefined(prop['default'])) {
+		              var val = sfSelect(path, scope.model);
+		              if (_angular2.default.isUndefined(val)) {
+		                sfSelect(path, scope.model, prop['default']);
+		              }
+		            }
+		          });
+		        }
+
+		        scope.$emit('sf-render-finished', element);
+		      };
+
+		      var defaultForm = ['*'];
+
+		      //Since we are dependant on up to three
+		      //attributes we'll do a common watch
+		      scope.$watch(function () {
+
+		        var schema = scope.schema;
+		        var form = scope.initialForm || defaultForm;
+
+		        //The check for schema.type is to ensure that schema is not {}
+		        if (form && schema && schema.type && (lastDigest.form !== form || lastDigest.schema !== schema) && Object.keys(schema.properties).length > 0) {
+		          lastDigest.schema = schema;
+		          lastDigest.form = form;
+
+		          render(schema, form);
+		        }
+		      });
+
+		      // We also listen to the event schemaFormRedraw so you can manually trigger a change if
+		      // part of the form or schema is chnaged without it being a new instance.
+		      scope.$on('schemaFormRedraw', function () {
+		        var schema = scope.schema;
+		        var form = scope.initialForm ? _angular2.default.copy(scope.initialForm) : ['*'];
+		        if (schema) {
+		          render(schema, form);
+		        }
+		      });
+
+		      scope.$on('$destroy', function () {
+		        // Each field listens to the $destroy event so that it can remove any value
+		        // from the model if that field is removed from the form. This is the default
+		        // destroy strategy. But if the entire form (or at least the part we're on)
+		        // gets removed, like when routing away to another page, then we definetly want to
+		        // keep the model intact. So therefore we set a flag to tell the others it's time to just
+		        // let it be.
+		        scope.externalDestructionInProgress = true;
+		      });
+
+		      /**
+		       * Evaluate an expression, i.e. scope.$eval
+		       * but do it in parent scope
+		       *
+		       * @param {String} expression
+		       * @param {Object} locals (optional)
+		       * @return {Any} the result of the expression
+		       */
+		      scope.evalExpr = function (expression, locals) {
+		        return scope.$parent.$eval(expression, locals);
+		      };
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 17 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function (sfValidator, $parse, sfSelect) {
+
+		  return {
+		    restrict: 'A',
+		    scope: false,
+		    // We want the link function to be *after* the input directives link function so we get access
+		    // the parsed value, ex. a number instead of a string
+		    priority: 500,
+		    require: 'ngModel',
+		    link: function link(scope, element, attrs, ngModel) {
+		      // We need the ngModelController on several places,
+		      // most notably for errors.
+		      // So we emit it up to the decorator directive so it can put it on scope.
+		      scope.$emit('schemaFormPropagateNgModelController', ngModel);
+
+		      var error = null;
+		      var form = scope.$eval(attrs.schemaValidate);
+
+		      if (form.copyValueTo) {
+		        ngModel.$viewChangeListeners.push(function () {
+		          var paths = form.copyValueTo;
+		          _angular2.default.forEach(paths, function (path) {
+		            sfSelect(path, scope.model, ngModel.$modelValue);
+		          });
+		        });
+		      };
+
+		      // Validate against the schema.
+
+		      var validate = function validate(viewValue) {
+		        //console.log('validate called', viewValue)
+		        //Still might be undefined
+		        if (!form) {
+		          return viewValue;
+		        }
+
+		        // Omit TV4 validation
+		        if (scope.options && scope.options.tv4Validation === false) {
+		          return viewValue;
+		        }
+
+		        var result = sfValidator.validate(form, viewValue);
+		        //console.log('result is', result)
+		        // Since we might have different tv4 errors we must clear all
+		        // errors that start with tv4-
+		        Object.keys(ngModel.$error).filter(function (k) {
+		          return k.indexOf('tv4-') === 0;
+		        }).forEach(function (k) {
+		          ngModel.$setValidity(k, true);
+		        });
+
+		        if (!result.valid) {
+		          // it is invalid, return undefined (no model update)
+		          ngModel.$setValidity('tv4-' + result.error.code, false);
+		          error = result.error;
+
+		          // In Angular 1.3+ return the viewValue, otherwise we inadvertenly
+		          // will trigger a 'parse' error.
+		          // we will stop the model value from updating with our own $validator
+		          // later.
+		          if (ngModel.$validators) {
+		            return viewValue;
+		          }
+		          // Angular 1.2 on the other hand lacks $validators and don't add a 'parse' error.
+		          return undefined;
+		        }
+		        return viewValue;
+		      };
+
+		      // Custom validators, parsers, formatters etc
+		      if (typeof form.ngModel === 'function') {
+		        form.ngModel(ngModel);
+		      }
+
+		      ['$parsers', '$viewChangeListeners', '$formatters'].forEach(function (attr) {
+		        if (form[attr] && ngModel[attr]) {
+		          form[attr].forEach(function (fn) {
+		            ngModel[attr].push(fn);
+		          });
+		        }
+		      });
+
+		      ['$validators', '$asyncValidators'].forEach(function (attr) {
+		        // Check if our version of angular has validators, i.e. 1.3+
+		        if (form[attr] && ngModel[attr]) {
+		          _angular2.default.forEach(form[attr], function (fn, name) {
+		            ngModel[attr][name] = fn;
+		          });
+		        }
+		      });
+
+		      // Get in last of the parses so the parsed value has the correct type.
+		      // We don't use $validators since we like to set different errors depending tv4 error codes
+		      ngModel.$parsers.push(validate);
+
+		      // But we do use one custom validator in the case of Angular 1.3 to stop the model from
+		      // updating if we've found an error.
+		      if (ngModel.$validators) {
+		        ngModel.$validators.schemaForm = function () {
+		          //console.log('validators called.')
+		          // Any error and we're out of here!
+		          return !Object.keys(ngModel.$error).some(function (e) {
+		            return e !== 'schemaForm';
+		          });
+		        };
+		      }
+
+		      var schema = form.schema;
+
+		      // A bit ugly but useful.
+		      scope.validateField = function (formName) {
+		        // If we have specified a form name, and this model is not within
+		        // that form, then leave things be.
+		        if (formName != undefined && ngModel.$$parentForm.$name !== formName) {
+		          return;
+		        }
+
+		        // Special case: arrays
+		        // TODO: Can this be generalized in a way that works consistently?
+		        // Just setting the viewValue isn't enough to trigger validation
+		        // since it's the same value. This will be better when we drop
+		        // 1.2 support.
+		        if (schema && schema.type.indexOf('array') !== -1) {
+		          validate(ngModel.$modelValue);
+		        }
+
+		        // We set the viewValue to trigger parsers,
+		        // since modelValue might be empty and validating just that
+		        // might change an existing error to a "required" error message.
+		        if (ngModel.$setDirty) {
+
+		          // Angular 1.3+
+		          ngModel.$setDirty();
+		          ngModel.$setViewValue(ngModel.$viewValue);
+		          ngModel.$commitViewValue();
+
+		          // In Angular 1.3 setting undefined as a viewValue does not trigger parsers
+		          // so we need to do a special required check.
+
+		          // angulars checkbox directive isEmpty does not do the check we want.
+		          if (form.type === 'checkbox') {
+		            if (form.required && ngModel.$modelValue === undefined) {
+		              ngModel.$setValidity('tv4-302', false);
+		            }
+		          } else if (form.required && ngModel.$isEmpty(ngModel.$modelValue)) {
+		            ngModel.$setValidity('tv4-302', false);
+		          }
+		        } else {
+		          // Angular 1.2
+		          // In angular 1.2 setting a viewValue of undefined will trigger the parser.
+		          // hence required works.
+		          ngModel.$setViewValue(ngModel.$viewValue);
+		        }
+		      };
+
+		      var first = true;
+		      ngModel.$formatters.push(function (val) {
+		        // When a form first loads this will be called for each field.
+		        // we usually don't want that.
+		        if (ngModel.$pristine && first && (!scope.options || scope.options.validateOnRender !== true)) {
+		          first = false;
+		          return val;
+		        }
+		        validate(ngModel.$modelValue);
+		        return val;
+		      });
+
+		      // Listen to an event so we can validate the input on request
+		      scope.$on('schemaFormValidate', function (event, formName) {
+		        scope.validateField(formName);
+		      });
+
+		      scope.schemaError = function () {
+		        return error;
+		      };
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ }
+	/******/ ])
+	});
+	;
+
+/***/ },
+/* 2 */
+/***/ function(module, exports) {
+
+	module.exports = angular;
+
+/***/ },
+/* 3 */
+/***/ function(module, exports) {
+
+	module.exports = tv4;
+
+/***/ },
+/* 4 */
+/***/ function(module, exports) {
+
+	angular.module("schemaForm").run(["$templateCache", function ($templateCache) {
+	  $templateCache.put("decorators/bootstrap/actions-trcl.html", "<div class=\"btn-group schema-form-actions {{form.htmlClass}}\" ng-transclude=\"\"></div>");
+	  $templateCache.put("decorators/bootstrap/actions.html", "<div class=\"btn-group schema-form-actions {{form.htmlClass}}\"><input ng-repeat-start=\"item in form.items\" type=\"submit\" class=\"btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}\" value=\"{{item.title}}\" ng-if=\"item.type === \'submit\'\"> <button ng-repeat-end=\"\" class=\"btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}\" type=\"button\" ng-disabled=\"form.readonly\" ng-if=\"item.type !== \'submit\'\" ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button></div>");
+	  $templateCache.put("decorators/bootstrap/array.html", "<div class=\"schema-form-array {{form.htmlClass}}\" sf-field-model=\"sf-new-array\" sf-new-array=\"\"><label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label><ol class=\"list-group\" sf-field-model=\"\" ui-sortable=\"form.sortOptions\"><li class=\"list-group-item {{form.fieldHtmlClass}}\" schema-form-array-items=\"\" sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\"><button ng-hide=\"form.readonly || form.remove === null\" ng-click=\"deleteFromArray($index)\" ng-disabled=\"form.schema.minItems >= modelArray.length\" style=\"position: relative; z-index: 20;\" type=\"button\" class=\"close pull-right\"><span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span></button></li></ol><div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\"><div class=\"help-block\" ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\" ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div><button ng-hide=\"form.readonly || form.add === null\" ng-click=\"appendToArray()\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" type=\"button\" class=\"btn {{ form.style.add || \'btn-default\' }} pull-right\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</button></div></div>");
+	  $templateCache.put("decorators/bootstrap/checkbox.html", "<div class=\"checkbox schema-form-checkbox {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"{{form.labelHtmlClass}}\"><input type=\"checkbox\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" class=\"{{form.fieldHtmlClass}}\" name=\"{{form.key.slice(-1)[0]}}\"> <span ng-bind-html=\"form.title\"></span></label><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+	  $templateCache.put("decorators/bootstrap/checkboxes.html", "<div sf-field-model=\"sf-new-array\" sf-new-array=\"\" class=\"form-group schema-form-checkboxes {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" sf-field-model=\"\" schema-validate=\"form\" ng-show=\"showTitle()\">{{form.title}}</label><div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\"><label><input type=\"checkbox\" ng-disabled=\"form.readonly\" sf-changed=\"form\" class=\"{{form.fieldHtmlClass}}\" ng-model=\"titleMapValues[$index]\" name=\"{{form.key.slice(-1)[0]}}\"> <span ng-bind-html=\"form.titleMap[$index].name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+	  $templateCache.put("decorators/bootstrap/default.html", "<div class=\"form-group {{form.htmlClass}}\" ng-class=\"{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{\'sr-only\': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label> <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\" ng-show=\"form.key\" type=\"{{form.type}}\" step=\"any\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-field-model=\"\" ng-disabled=\"form.readonly\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\" aria-describedby=\"{{form.key.slice(-1)[0] + \'Status\'}}\"><div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\" ng-class=\"{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}\"><span ng-if=\"form.fieldAddonLeft\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonLeft\"></span> <input ng-show=\"form.key\" type=\"{{form.type}}\" step=\"any\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-field-model=\"\" ng-disabled=\"form.readonly\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\" aria-describedby=\"{{form.key.slice(-1)[0] + \'Status\'}}\"> <span ng-if=\"form.fieldAddonRight\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonRight\"></span></div><span ng-if=\"form.feedback !== false\" class=\"form-control-feedback\" ng-class=\"evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }\" aria-hidden=\"true\"></span> <span ng-if=\"hasError() || hasSuccess()\" id=\"{{form.key.slice(-1)[0] + \'Status\'}}\" class=\"sr-only\">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+	  $templateCache.put("decorators/bootstrap/fieldset.html", "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{form.htmlClass}}\"><legend ng-class=\"{\'sr-only\': !showTitle() }\">{{ form.title }}</legend><div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div></fieldset>");
+	  $templateCache.put("decorators/bootstrap/help.html", "<div class=\"helpvalue schema-form-helpvalue {{form.htmlClass}}\" ng-bind-html=\"form.helpvalue\"></div>");
+	  $templateCache.put("decorators/bootstrap/radio-buttons.html", "<div class=\"form-group schema-form-radiobuttons {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><div><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label></div><div class=\"btn-group\"><label sf-field-model=\"replaceAll\" class=\"btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}\" ng-class=\"{ active: item.value === $$value$$ }\" ng-repeat=\"item in form.titleMap\"><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" style=\"display: none;\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+	  $templateCache.put("decorators/bootstrap/radios-inline.html", "<div class=\"form-group schema-form-radios-inline {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\" sf-field-model=\"\" schema-validate=\"form\">{{form.title}}</label><div><label class=\"radio-inline\" ng-repeat=\"item in form.titleMap\"><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+	  $templateCache.put("decorators/bootstrap/radios.html", "<div class=\"form-group schema-form-radios {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" sf-field-model=\"\" schema-validate=\"form\" ng-show=\"showTitle()\">{{form.title}}</label><div class=\"radio\" ng-repeat=\"item in form.titleMap\"><label><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+	  $templateCache.put("decorators/bootstrap/section.html", "<div class=\"schema-form-section {{form.htmlClass}}\"></div>");
+	  $templateCache.put("decorators/bootstrap/select.html", "<div class=\"form-group {{form.htmlClass}} schema-form-select\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label><select sf-field-model=\"\" ng-disabled=\"form.readonly\" sf-changed=\"form\" class=\"form-control {{form.fieldHtmlClass}}\" schema-validate=\"form\" ng-options=\"item.value as item.name group by item.group for item in form.titleMap\" name=\"{{form.key.slice(-1)[0]}}\"></select><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+	  $templateCache.put("decorators/bootstrap/submit.html", "<div class=\"form-group schema-form-submit {{form.htmlClass}}\"><input type=\"submit\" class=\"btn {{ form.style || \'btn-primary\' }} {{form.fieldHtmlClass}}\" value=\"{{form.title}}\" ng-disabled=\"form.readonly\" ng-if=\"form.type === \'submit\'\"> <button class=\"btn {{ form.style || \'btn-default\' }}\" type=\"button\" ng-click=\"buttonClick($event,form)\" ng-disabled=\"form.readonly\" ng-if=\"form.type !== \'submit\'\"><span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span> {{form.title}}</button></div>");
+	  $templateCache.put("decorators/bootstrap/tabarray.html", "<div ng-init=\"selected = { tab: 0 }\" ng-model=\"modelArray\" schema-validate=\"form\" sf-field-model=\"sf-new-array\" sf-new-array=\"\" class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{form.htmlClass}}\"><div ng-if=\"!form.tabType || form.tabType !== \'right\'\" ng-class=\"{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}\"><ol class=\"nav nav-tabs\" ng-class=\"{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}\" sf-field-model=\"\" ui-sortable=\"form.sortOptions\"><li sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide=\"form.readonly || form.add === null\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\"><a href=\"#\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</a></li></ol></div><div ng-class=\"{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}\"><div class=\"tab-content {{form.fieldHtmlClass}}\"><div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\" sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-show=\"selected.tab === $index\" ng-class=\"{active: selected.tab === $index}\"><div schema-form-array-items=\"\"></div><button ng-hide=\"form.readonly || form.remove === null\" ng-click=\"selected.tab = deleteFromArray($index).length - 1\" ng-disabled=\"form.schema.minItems >= modelArray.length\" type=\"button\" class=\"btn {{ form.style.remove || \'btn-default\' }} pull-right\"><i class=\"glyphicon glyphicon-trash\"></i> {{ form.remove || \'Remove\'}}</button></div><div class=\"help-block\" ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\" ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div></div></div></div><div ng-if=\"form.tabType === \'right\'\" class=\"col-xs-3\"><ul class=\"nav nav-tabs tabs-right\"><li sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide=\"form.readonly || form.add === null\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\"><a href=\"#\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</a></li></ul></div>");
+	  $templateCache.put("decorators/bootstrap/tabs.html", "<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{form.htmlClass}}\"><ul class=\"nav nav-tabs\"><li ng-repeat=\"tab in form.tabs\" ng-disabled=\"form.readonly\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{ tab.title }}</a></li></ul><div class=\"tab-content {{form.fieldHtmlClass}}\"></div></div>");
+	  $templateCache.put("decorators/bootstrap/textarea.html", "<div class=\"form-group has-feedback {{form.htmlClass}} schema-form-textarea\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{\'sr-only\': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label> <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\"></textarea><div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\" ng-class=\"{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}\"><span ng-if=\"form.fieldAddonLeft\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonLeft\"></span> <textarea class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\"></textarea> <span ng-if=\"form.fieldAddonRight\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonRight\"></span></div><span class=\"help-block\" sf-message=\"form.description\"></span></div>");
+	}]);
+
+/***/ },
+/* 5 */
+/***/ function(module, exports) {
+
+	(function (angular, undefined) {
+	  'use strict';
+
+	  angular.module('schemaForm').config(bootstrapDecoratorConfig).filter('sfCamelKey', sfCamelKeyFilter);
+
+	  bootstrapDecoratorConfig.$inject = ['schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'];
+
+	  function bootstrapDecoratorConfig(schemaFormProvider, decoratorsProvider, sfBuilderProvider, sfPathProvider, $injector) {
+	    var base = 'decorators/bootstrap/';
+
+	    var simpleTransclusion = sfBuilderProvider.builders.simpleTransclusion;
+	    var ngModelOptions = sfBuilderProvider.builders.ngModelOptions;
+	    var ngModel = sfBuilderProvider.builders.ngModel;
+	    var sfField = sfBuilderProvider.builders.sfField;
+	    var condition = sfBuilderProvider.builders.condition;
+	    var array = sfBuilderProvider.builders.array;
+	    var numeric = sfBuilderProvider.builders.numeric;
+
+	    // Tabs is so bootstrap specific that it stays here.
+	    var tabs = function (args) {
+	      if (args.form.tabs && args.form.tabs.length > 0) {
+	        var tabContent = args.fieldFrag.querySelector('.tab-content');
+
+	        args.form.tabs.forEach(function (tab, index) {
+	          var div = document.createElement('div');
+	          div.className = 'tab-pane';
+	          div.setAttribute('ng-disabled', 'form.readonly');
+	          div.setAttribute('ng-show', 'selected.tab === ' + index);
+	          div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
+
+	          var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
+	          div.appendChild(childFrag);
+	          tabContent.appendChild(div);
+	        });
+	      }
+	    };
+
+	    var selectPlaceholder = function (args) {
+	      if (args.form.placeholder) {
+	        var selectBox = args.fieldFrag.querySelector('select');
+	        var option = document.createElement('option');
+	        option.setAttribute('value', '');
+
+	        /* We only want the placeholder to show when we do not have a value on the model.
+	         * We make ngModel builder replace all so we can use $$value$$.
+	         */
+	        option.setAttribute('sf-field-model', 'replaceAll');
+
+	        /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
+	         * angular > 1.4 does a emptyOption.attr('selected', true)
+	         * which does not like the ng-if comment.
+	         */
+	        if (angular.version.major === 1 && angular.version.minor < 4) {
+	          option.setAttribute('ng-if', '$$value$$ === undefined');
+	        } else {
+	          option.setAttribute('ng-show', '$$value$$ === undefined');
+	        }
+
+	        option.textContent = args.form.placeholder;
+
+	        selectBox.appendChild(option);
+	      }
+	    };
+
+	    var defaults = [sfField, ngModel, ngModelOptions, condition];
+	    decoratorsProvider.defineDecorator('bootstrapDecorator', {
+	      textarea: { template: base + 'textarea.html', builder: defaults },
+	      fieldset: { template: base + 'fieldset.html', builder: [sfField, simpleTransclusion, condition] },
+	      array: { template: base + 'array.html', builder: [sfField, ngModelOptions, ngModel, array, condition] },
+	      tabarray: { template: base + 'tabarray.html', builder: [sfField, ngModelOptions, ngModel, array, condition] },
+	      tabs: { template: base + 'tabs.html', builder: [sfField, ngModelOptions, tabs, condition] },
+	      section: { template: base + 'section.html', builder: [sfField, simpleTransclusion, condition] },
+	      conditional: { template: base + 'section.html', builder: [sfField, simpleTransclusion, condition] },
+	      actions: { template: base + 'actions.html', builder: defaults },
+	      select: { template: base + 'select.html', builder: defaults.concat(selectPlaceholder) },
+	      checkbox: { template: base + 'checkbox.html', builder: defaults },
+	      checkboxes: { template: base + 'checkboxes.html', builder: [sfField, ngModelOptions, ngModel, array, condition] },
+	      number: { template: base + 'default.html', builder: defaults.concat(numeric) },
+	      password: { template: base + 'default.html', builder: defaults },
+	      submit: { template: base + 'submit.html', builder: defaults },
+	      button: { template: base + 'submit.html', builder: defaults },
+	      radios: { template: base + 'radios.html', builder: defaults },
+	      'radios-inline': { template: base + 'radios-inline.html', builder: defaults },
+	      radiobuttons: { template: base + 'radio-buttons.html', builder: defaults },
+	      help: { template: base + 'help.html', builder: defaults },
+	      'default': { template: base + 'default.html', builder: defaults }
+	    }, []);
+	  };
+
+	  /**
+	   * sfCamelKey Filter
+	   */
+	  function sfCamelKeyFilter() {
+	    return function (formKey) {
+	      if (!formKey) {
+	        return '';
+	      };
+	      var part, i, key;
+	      key = formKey.slice();
+	      for (i = 0; i < key.length; i++) {
+	        part = key[i].toLowerCase().split('');
+	        if (i && part.length) {
+	          part[0] = part[0].toUpperCase();
+	        };
+	        key[i] = part.join('');
+	      };
+	      return key.join('');
+	    };
+	  };
+	})(angular, undefined);
+
+/***/ }
+/******/ ])
+});
+;
\ No newline at end of file
diff --git a/examples/bootstrap-example.html b/examples/bootstrap-example.html
index c7908b2..4a6c577 100644
--- a/examples/bootstrap-example.html
+++ b/examples/bootstrap-example.html
@@ -218,7 +218,6 @@ <h3>Schema</h3>
 <script type="text/javascript" src="../bower_components/jquery-ui/jquery-ui.min.js"></script>
 
 <script type="text/javascript" src="../bower_components/angular-ui-ace/ui-ace.js"></script>
-<script type="text/javascript" src="../bower_components/objectpath/lib/ObjectPath.js"></script>
 <script type="text/javascript" src="../bower_components/pickadate/lib/picker.js"></script>
 <script type="text/javascript" src="../bower_components/pickadate/lib/picker.date.js"></script>
 <script type="text/javascript" src="../bower_components/pickadate/lib/translations/nl_NL.js"></script>
@@ -227,9 +226,7 @@ <h3>Schema</h3>
 <script type="text/javascript" src="../bower_components/spectrum/i18n/jquery.spectrum-sv.js"></script>
 <script type="text/javascript" src="../bower_components/angular-spectrum-colorpicker/dist/angular-spectrum-colorpicker.min.js"></script>
 
-
-<script type="text/javascript" src="../bower_components/angular-schema-form/dist/schema-form.js"></script>
-<script type="text/javascript" src="../bootstrap-decorator.js"></script>
+<script type="text/javascript" src="../dist/angular-schema-form-bootstrap.js"></script>
 <script type="text/javascript" src="../bower_components/angular-schema-form-datepicker/bootstrap-datepicker.min.js"></script>
 <script type="text/javascript" src="../bower_components/angular-schema-form-colorpicker/bootstrap-colorpicker.min.js"></script>
 
diff --git a/gulp/tasks/minify.js b/gulp/tasks/minify.js
index dd8577d..70dbac9 100644
--- a/gulp/tasks/minify.js
+++ b/gulp/tasks/minify.js
@@ -23,10 +23,10 @@ gulp.task('minify', function() {
   stream.queue(gulp.src('./src/**/*.js'));
 
   stream.done()
-  .pipe(concat('bootstrap-decorator.js'))
-  .pipe(gulp.dest('./'))
+  .pipe(rename('angular-schema-form-bootstrap-templates.js'))
+  .pipe(gulp.dest('./src'))
   .pipe(uglify())
-  .pipe(rename('bootstrap-decorator.min.js'))
-  .pipe(gulp.dest('./'));
+  .pipe(rename('angular-schema-form-bootstrap-templates.min.js'))
+  .pipe(gulp.dest('./src'));
 
 });
diff --git a/gulp/tasks/templates.js b/gulp/tasks/templates.js
new file mode 100644
index 0000000..e533f3f
--- /dev/null
+++ b/gulp/tasks/templates.js
@@ -0,0 +1,31 @@
+var gulp = require('gulp'),
+  streamqueue = require('streamqueue'),
+  minifyHtml = require('gulp-minify-html'),
+  templateCache = require('gulp-angular-templatecache'),
+  concat = require('gulp-concat'),
+  rename = require('gulp-rename'),
+  uglify = require('gulp-uglify');
+
+gulp.task('templates', function() {
+  var stream = streamqueue({objectMode: true});
+  stream.queue(
+    gulp.src('./src/**/*.html')
+    .pipe(minifyHtml({
+      empty: true,
+      spare: true,
+      quotes: true
+    }))
+    .pipe(templateCache({
+      module: 'schemaForm',
+      root: 'decorators/bootstrap/'
+    }))
+    );
+
+  stream.done()
+  .pipe(rename('angular-schema-form-bootstrap-templates.js'))
+  .pipe(gulp.dest('./src'))
+  .pipe(uglify())
+  .pipe(rename('angular-schema-form-bootstrap-templates.min.js'))
+  .pipe(gulp.dest('./src'));
+
+});
diff --git a/npm-debug.log b/npm-debug.log
new file mode 100644
index 0000000..b1668bc
--- /dev/null
+++ b/npm-debug.log
@@ -0,0 +1,48 @@
+0 info it worked if it ends with ok
+1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',
+1 verbose cli   'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
+1 verbose cli   'run',
+1 verbose cli   'dist' ]
+2 info using npm@3.8.3
+3 info using node@v5.10.1
+4 verbose run-script [ 'predist', 'dist', 'postdist' ]
+5 info lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~predist: angular-schema-form-bootstrap@1.0.0-alpha.1
+6 silly lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~predist: no script for predist, continuing
+7 info lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: angular-schema-form-bootstrap@1.0.0-alpha.1
+8 verbose lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: unsafe-perm in lifecycle true
+9 verbose lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: PATH: C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin;C:\Users\Marcel\Documents\SERIOUS\git\angular-schema-form-bootstrap\node_modules\.bin;C:\Program Files\nodejs;C:\Program Files\ConEmu\ConEmu\Scripts;C:\Program Files\ConEmu\ConEmu\Scripts;C:\Program Files\ConEmu;C:\Program Files\ConEmu\ConEmu;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;c:\Program Files (x86)\Intel\iCLS Client\;c:\Program Files\Intel\iCLS Client\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Windows Live\Shared;C:\Program Files\NpackdCL-1;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\MSysGit\bin;C:\Program Files\TortoiseGit_64_bit\bin;C:\Program Files\TortoiseHg_64_bit\;C:\Program Files\Microsoft\Web Platform Installer\;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommon\;C:\Program Files\nodejs\;C:\Users\Marcel\AppData\Local\atom\bin;C:\Users\Marcel\AppData\Roaming\npm
+10 verbose lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: CWD: C:\Users\Marcel\Documents\SERIOUS\git\angular-schema-form-bootstrap
+11 silly lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: Args: [ '/d /s /c', 'npm run build && npm run minify' ]
+12 silly lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: Returned: code: 1  signal: null
+13 info lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: Failed to exec dist script
+14 verbose stack Error: angular-schema-form-bootstrap@1.0.0-alpha.1 dist: `npm run build && npm run minify`
+14 verbose stack Exit status 1
+14 verbose stack     at EventEmitter.<anonymous> (C:\Program Files\nodejs\node_modules\npm\lib\utils\lifecycle.js:239:16)
+14 verbose stack     at emitTwo (events.js:100:13)
+14 verbose stack     at EventEmitter.emit (events.js:185:7)
+14 verbose stack     at ChildProcess.<anonymous> (C:\Program Files\nodejs\node_modules\npm\lib\utils\spawn.js:24:14)
+14 verbose stack     at emitTwo (events.js:100:13)
+14 verbose stack     at ChildProcess.emit (events.js:185:7)
+14 verbose stack     at maybeClose (internal/child_process.js:850:16)
+14 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:215:5)
+15 verbose pkgid angular-schema-form-bootstrap@1.0.0-alpha.1
+16 verbose cwd C:\Users\Marcel\Documents\SERIOUS\git\angular-schema-form-bootstrap
+17 error Windows_NT 10.0.10586
+18 error argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "dist"
+19 error node v5.10.1
+20 error npm  v3.8.3
+21 error code ELIFECYCLE
+22 error angular-schema-form-bootstrap@1.0.0-alpha.1 dist: `npm run build && npm run minify`
+22 error Exit status 1
+23 error Failed at the angular-schema-form-bootstrap@1.0.0-alpha.1 dist script 'npm run build && npm run minify'.
+23 error Make sure you have the latest version of node.js and npm installed.
+23 error If you do, this is most likely a problem with the angular-schema-form-bootstrap package,
+23 error not with npm itself.
+23 error Tell the author that this fails on your system:
+23 error     npm run build && npm run minify
+23 error You can get information on how to open an issue for this project with:
+23 error     npm bugs angular-schema-form-bootstrap
+23 error Or if that isn't available, you can get their info via:
+23 error     npm owner ls angular-schema-form-bootstrap
+23 error There is likely additional logging output above.
+24 verbose exit [ 1, true ]
diff --git a/package.json b/package.json
index 1c531ff..fddc613 100644
--- a/package.json
+++ b/package.json
@@ -1,28 +1,62 @@
 {
   "name": "angular-schema-form-bootstrap",
-  "version": "0.2.0",
+  "version": "1.0.0-alpha.1",
   "description": "Bootstrap 3 decorator for Angular Schema Form",
-  "main": "bootstrap-decorator.js",
+  "main": "dist/bootstrap-decorator.js",
   "scripts": {
-    "test": "echo \"Error: no test specified\" && exit 1"
+    "templates": "gulp templates",
+    "dist": "npm run build && npm run minify",
+    "build": "webpack",
+    "watch": "webpack --watch",
+    "minify": "uglifyjs dist/angular-schema-form-material.js --comments --output=dist/angular-schema-form-material.min.js",
+    "test": "echo \"Error: no test specified\" && exit 1",
+    "test-not-yet-done": "karma start --single-run --browsers PhantomJS karma.conf.js --log-level info"
   },
   "keywords": [
     "angular-schema-form-decorator"
   ],
-  "author": "David Jensen <david.lgj@gmail.com>",
+  "author": "json-schema-form",
+  "contributors": [
+    "David Jensen <david.lgj@gmail.com> (https://github.com/davidlgj)",
+    "Marcel J Bennett <iamanthropic@gmail.com> (https://github.com/Anthropic)"
+  ],
   "license": "MIT",
+  "dependencies": {
+    "angular-schema-form": "git://github.com/json-schema-form/angular-schema-form.git#feature/webpack-babel"
+  },
   "devDependencies": {
-    "gulp": "^3.8.11",
+    "babel-core": "^6.10.4",
+    "babel-loader": "^6.2.4",
+    "babel-polyfill": "^6.9.1",
+    "babel-preset-es2015": "^6.9.0",
+    "chai": "^3.5.0",
+    "coveralls": "^2.11.0",
+    "gulp": "^3.9.0",
     "gulp-angular-templatecache": "^1.6.0",
     "gulp-concat": "^2.5.2",
-    "gulp-jscs": "^2.0.0",
+    "gulp-jscs": "^3.0.2",
     "gulp-minify-html": "^1.0.2",
-    "gulp-protractor": "^1.0.0",
+    "gulp-protractor": "^3.0.0",
     "gulp-rename": "^1.2.2",
     "gulp-uglify": "^1.2.0",
-    "gulp-umd": "^0.2.0",
     "gulp-watch": "^4.2.4",
     "gulp-webserver": "^0.9.1",
-    "streamqueue": "^0.1.3"
+    "karma": "^0.13.22",
+    "karma-chai-sinon": "^0.1.5",
+    "karma-coverage": "^1.0.0",
+    "karma-growler-reporter": "0.0.1",
+    "karma-mocha": "^1.0.1",
+    "karma-phantomjs-launcher": "^0.1.4",
+    "karma-webpack": "^1.7.0",
+    "mocha": "^2.5.3",
+    "mocha-lcov-reporter": "0.0.1",
+    "ng-cache-loader": "0.0.16",
+    "protractor": "^2.5.1",
+    "sinon": "^1.17.4",
+    "sinon-chai": "^2.8.0",
+    "streamqueue": "^0.1.3",
+    "uglify-js": "^2.6.2",
+    "webpack": "^1.13.1",
+    "webpack-dev-server": "^1.14.1"
   }
 }
diff --git a/src/angular-schema-form-bootstrap-templates.js b/src/angular-schema-form-bootstrap-templates.js
new file mode 100644
index 0000000..836efee
--- /dev/null
+++ b/src/angular-schema-form-bootstrap-templates.js
@@ -0,0 +1,17 @@
+angular.module("schemaForm").run(["$templateCache", function($templateCache) {$templateCache.put("decorators/bootstrap/actions-trcl.html","<div class=\"btn-group schema-form-actions {{form.htmlClass}}\" ng-transclude=\"\"></div>");
+$templateCache.put("decorators/bootstrap/actions.html","<div class=\"btn-group schema-form-actions {{form.htmlClass}}\"><input ng-repeat-start=\"item in form.items\" type=\"submit\" class=\"btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}\" value=\"{{item.title}}\" ng-if=\"item.type === \'submit\'\"> <button ng-repeat-end=\"\" class=\"btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}\" type=\"button\" ng-disabled=\"form.readonly\" ng-if=\"item.type !== \'submit\'\" ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button></div>");
+$templateCache.put("decorators/bootstrap/array.html","<div class=\"schema-form-array {{form.htmlClass}}\" sf-field-model=\"sf-new-array\" sf-new-array=\"\"><label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label><ol class=\"list-group\" sf-field-model=\"\" ui-sortable=\"form.sortOptions\"><li class=\"list-group-item {{form.fieldHtmlClass}}\" schema-form-array-items=\"\" sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\"><button ng-hide=\"form.readonly || form.remove === null\" ng-click=\"deleteFromArray($index)\" ng-disabled=\"form.schema.minItems >= modelArray.length\" style=\"position: relative; z-index: 20;\" type=\"button\" class=\"close pull-right\"><span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span></button></li></ol><div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\"><div class=\"help-block\" ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\" ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div><button ng-hide=\"form.readonly || form.add === null\" ng-click=\"appendToArray()\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" type=\"button\" class=\"btn {{ form.style.add || \'btn-default\' }} pull-right\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</button></div></div>");
+$templateCache.put("decorators/bootstrap/checkbox.html","<div class=\"checkbox schema-form-checkbox {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"{{form.labelHtmlClass}}\"><input type=\"checkbox\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" class=\"{{form.fieldHtmlClass}}\" name=\"{{form.key.slice(-1)[0]}}\"> <span ng-bind-html=\"form.title\"></span></label><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+$templateCache.put("decorators/bootstrap/checkboxes.html","<div sf-field-model=\"sf-new-array\" sf-new-array=\"\" class=\"form-group schema-form-checkboxes {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" sf-field-model=\"\" schema-validate=\"form\" ng-show=\"showTitle()\">{{form.title}}</label><div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\"><label><input type=\"checkbox\" ng-disabled=\"form.readonly\" sf-changed=\"form\" class=\"{{form.fieldHtmlClass}}\" ng-model=\"titleMapValues[$index]\" name=\"{{form.key.slice(-1)[0]}}\"> <span ng-bind-html=\"form.titleMap[$index].name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+$templateCache.put("decorators/bootstrap/default.html","<div class=\"form-group {{form.htmlClass}}\" ng-class=\"{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{\'sr-only\': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label> <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\" ng-show=\"form.key\" type=\"{{form.type}}\" step=\"any\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-field-model=\"\" ng-disabled=\"form.readonly\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\" aria-describedby=\"{{form.key.slice(-1)[0] + \'Status\'}}\"><div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\" ng-class=\"{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}\"><span ng-if=\"form.fieldAddonLeft\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonLeft\"></span> <input ng-show=\"form.key\" type=\"{{form.type}}\" step=\"any\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-field-model=\"\" ng-disabled=\"form.readonly\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\" aria-describedby=\"{{form.key.slice(-1)[0] + \'Status\'}}\"> <span ng-if=\"form.fieldAddonRight\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonRight\"></span></div><span ng-if=\"form.feedback !== false\" class=\"form-control-feedback\" ng-class=\"evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }\" aria-hidden=\"true\"></span> <span ng-if=\"hasError() || hasSuccess()\" id=\"{{form.key.slice(-1)[0] + \'Status\'}}\" class=\"sr-only\">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+$templateCache.put("decorators/bootstrap/fieldset.html","<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{form.htmlClass}}\"><legend ng-class=\"{\'sr-only\': !showTitle() }\">{{ form.title }}</legend><div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div></fieldset>");
+$templateCache.put("decorators/bootstrap/help.html","<div class=\"helpvalue schema-form-helpvalue {{form.htmlClass}}\" ng-bind-html=\"form.helpvalue\"></div>");
+$templateCache.put("decorators/bootstrap/radio-buttons.html","<div class=\"form-group schema-form-radiobuttons {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><div><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label></div><div class=\"btn-group\"><label sf-field-model=\"replaceAll\" class=\"btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}\" ng-class=\"{ active: item.value === $$value$$ }\" ng-repeat=\"item in form.titleMap\"><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" style=\"display: none;\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+$templateCache.put("decorators/bootstrap/radios-inline.html","<div class=\"form-group schema-form-radios-inline {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\" sf-field-model=\"\" schema-validate=\"form\">{{form.title}}</label><div><label class=\"radio-inline\" ng-repeat=\"item in form.titleMap\"><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+$templateCache.put("decorators/bootstrap/radios.html","<div class=\"form-group schema-form-radios {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" sf-field-model=\"\" schema-validate=\"form\" ng-show=\"showTitle()\">{{form.title}}</label><div class=\"radio\" ng-repeat=\"item in form.titleMap\"><label><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+$templateCache.put("decorators/bootstrap/section.html","<div class=\"schema-form-section {{form.htmlClass}}\"></div>");
+$templateCache.put("decorators/bootstrap/select.html","<div class=\"form-group {{form.htmlClass}} schema-form-select\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label><select sf-field-model=\"\" ng-disabled=\"form.readonly\" sf-changed=\"form\" class=\"form-control {{form.fieldHtmlClass}}\" schema-validate=\"form\" ng-options=\"item.value as item.name group by item.group for item in form.titleMap\" name=\"{{form.key.slice(-1)[0]}}\"></select><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
+$templateCache.put("decorators/bootstrap/submit.html","<div class=\"form-group schema-form-submit {{form.htmlClass}}\"><input type=\"submit\" class=\"btn {{ form.style || \'btn-primary\' }} {{form.fieldHtmlClass}}\" value=\"{{form.title}}\" ng-disabled=\"form.readonly\" ng-if=\"form.type === \'submit\'\"> <button class=\"btn {{ form.style || \'btn-default\' }}\" type=\"button\" ng-click=\"buttonClick($event,form)\" ng-disabled=\"form.readonly\" ng-if=\"form.type !== \'submit\'\"><span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span> {{form.title}}</button></div>");
+$templateCache.put("decorators/bootstrap/tabarray.html","<div ng-init=\"selected = { tab: 0 }\" ng-model=\"modelArray\" schema-validate=\"form\" sf-field-model=\"sf-new-array\" sf-new-array=\"\" class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{form.htmlClass}}\"><div ng-if=\"!form.tabType || form.tabType !== \'right\'\" ng-class=\"{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}\"><ol class=\"nav nav-tabs\" ng-class=\"{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}\" sf-field-model=\"\" ui-sortable=\"form.sortOptions\"><li sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide=\"form.readonly || form.add === null\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\"><a href=\"#\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</a></li></ol></div><div ng-class=\"{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}\"><div class=\"tab-content {{form.fieldHtmlClass}}\"><div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\" sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-show=\"selected.tab === $index\" ng-class=\"{active: selected.tab === $index}\"><div schema-form-array-items=\"\"></div><button ng-hide=\"form.readonly || form.remove === null\" ng-click=\"selected.tab = deleteFromArray($index).length - 1\" ng-disabled=\"form.schema.minItems >= modelArray.length\" type=\"button\" class=\"btn {{ form.style.remove || \'btn-default\' }} pull-right\"><i class=\"glyphicon glyphicon-trash\"></i> {{ form.remove || \'Remove\'}}</button></div><div class=\"help-block\" ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\" ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div></div></div></div><div ng-if=\"form.tabType === \'right\'\" class=\"col-xs-3\"><ul class=\"nav nav-tabs tabs-right\"><li sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide=\"form.readonly || form.add === null\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\"><a href=\"#\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</a></li></ul></div>");
+$templateCache.put("decorators/bootstrap/tabs.html","<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{form.htmlClass}}\"><ul class=\"nav nav-tabs\"><li ng-repeat=\"tab in form.tabs\" ng-disabled=\"form.readonly\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{ tab.title }}</a></li></ul><div class=\"tab-content {{form.fieldHtmlClass}}\"></div></div>");
+$templateCache.put("decorators/bootstrap/textarea.html","<div class=\"form-group has-feedback {{form.htmlClass}} schema-form-textarea\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{\'sr-only\': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label> <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\"></textarea><div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\" ng-class=\"{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}\"><span ng-if=\"form.fieldAddonLeft\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonLeft\"></span> <textarea class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\"></textarea> <span ng-if=\"form.fieldAddonRight\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonRight\"></span></div><span class=\"help-block\" sf-message=\"form.description\"></span></div>");}]);
\ No newline at end of file
diff --git a/src/angular-schema-form-bootstrap-templates.min.js b/src/angular-schema-form-bootstrap-templates.min.js
new file mode 100644
index 0000000..aa8b5a2
--- /dev/null
+++ b/src/angular-schema-form-bootstrap-templates.min.js
@@ -0,0 +1 @@
+angular.module("schemaForm").run(["$templateCache",function(e){e.put("decorators/bootstrap/actions-trcl.html",'<div class="btn-group schema-form-actions {{form.htmlClass}}" ng-transclude=""></div>'),e.put("decorators/bootstrap/actions.html",'<div class="btn-group schema-form-actions {{form.htmlClass}}"><input ng-repeat-start="item in form.items" type="submit" class="btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}" value="{{item.title}}" ng-if="item.type === \'submit\'"> <button ng-repeat-end="" class="btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}" type="button" ng-disabled="form.readonly" ng-if="item.type !== \'submit\'" ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button></div>'),e.put("decorators/bootstrap/array.html",'<div class="schema-form-array {{form.htmlClass}}" sf-field-model="sf-new-array" sf-new-array=""><label class="control-label" ng-show="showTitle()">{{ form.title }}</label><ol class="list-group" sf-field-model="" ui-sortable="form.sortOptions"><li class="list-group-item {{form.fieldHtmlClass}}" schema-form-array-items="" sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index"><button ng-hide="form.readonly || form.remove === null" ng-click="deleteFromArray($index)" ng-disabled="form.schema.minItems >= modelArray.length" style="position: relative; z-index: 20;" type="button" class="close pull-right"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button></li></ol><div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form"><div class="help-block" ng-show="(hasError() && errorMessage(schemaError())) || form.description" ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div><button ng-hide="form.readonly || form.add === null" ng-click="appendToArray()" ng-disabled="form.schema.maxItems <= modelArray.length" type="button" class="btn {{ form.style.add || \'btn-default\' }} pull-right"><i class="glyphicon glyphicon-plus"></i> {{ form.add || \'Add\'}}</button></div></div>'),e.put("decorators/bootstrap/checkbox.html",'<div class="checkbox schema-form-checkbox {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="{{form.labelHtmlClass}}"><input type="checkbox" sf-changed="form" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" class="{{form.fieldHtmlClass}}" name="{{form.key.slice(-1)[0]}}"> <span ng-bind-html="form.title"></span></label><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/checkboxes.html",'<div sf-field-model="sf-new-array" sf-new-array="" class="form-group schema-form-checkboxes {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" sf-field-model="" schema-validate="form" ng-show="showTitle()">{{form.title}}</label><div class="checkbox" ng-repeat="val in titleMapValues track by $index"><label><input type="checkbox" ng-disabled="form.readonly" sf-changed="form" class="{{form.fieldHtmlClass}}" ng-model="titleMapValues[$index]" name="{{form.key.slice(-1)[0]}}"> <span ng-bind-html="form.titleMap[$index].name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/default.html",'<div class="form-group {{form.htmlClass}}" ng-class="{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }"><label class="control-label {{form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label> <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight" ng-show="form.key" type="{{form.type}}" step="any" sf-changed="form" placeholder="{{form.placeholder}}" class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-field-model="" ng-disabled="form.readonly" schema-validate="form" name="{{form.key.slice(-1)[0]}}" aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}"><div ng-if="form.fieldAddonLeft || form.fieldAddonRight" ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}"><span ng-if="form.fieldAddonLeft" class="input-group-addon" ng-bind-html="form.fieldAddonLeft"></span> <input ng-show="form.key" type="{{form.type}}" step="any" sf-changed="form" placeholder="{{form.placeholder}}" class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-field-model="" ng-disabled="form.readonly" schema-validate="form" name="{{form.key.slice(-1)[0]}}" aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}"> <span ng-if="form.fieldAddonRight" class="input-group-addon" ng-bind-html="form.fieldAddonRight"></span></div><span ng-if="form.feedback !== false" class="form-control-feedback" ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }" aria-hidden="true"></span> <span ng-if="hasError() || hasSuccess()" id="{{form.key.slice(-1)[0] + \'Status\'}}" class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/fieldset.html",'<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{form.htmlClass}}"><legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend><div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div></fieldset>'),e.put("decorators/bootstrap/help.html",'<div class="helpvalue schema-form-helpvalue {{form.htmlClass}}" ng-bind-html="form.helpvalue"></div>'),e.put("decorators/bootstrap/radio-buttons.html",'<div class="form-group schema-form-radiobuttons {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><div><label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label></div><div class="btn-group"><label sf-field-model="replaceAll" class="btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}" ng-class="{ active: item.value === $$value$$ }" ng-repeat="item in form.titleMap"><input type="radio" class="{{form.fieldHtmlClass}}" sf-changed="form" style="display: none;" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" ng-value="item.value" name="{{form.key.join(\'.\')}}"> <span ng-bind-html="item.name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/radios-inline.html",'<div class="form-group schema-form-radios-inline {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()" sf-field-model="" schema-validate="form">{{form.title}}</label><div><label class="radio-inline" ng-repeat="item in form.titleMap"><input type="radio" class="{{form.fieldHtmlClass}}" sf-changed="form" ng-disabled="form.readonly" sf-field-model="" ng-value="item.value" name="{{form.key.join(\'.\')}}"> <span ng-bind-html="item.name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/radios.html",'<div class="form-group schema-form-radios {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" sf-field-model="" schema-validate="form" ng-show="showTitle()">{{form.title}}</label><div class="radio" ng-repeat="item in form.titleMap"><label><input type="radio" class="{{form.fieldHtmlClass}}" sf-changed="form" ng-disabled="form.readonly" sf-field-model="" ng-value="item.value" name="{{form.key.join(\'.\')}}"> <span ng-bind-html="item.name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/section.html",'<div class="schema-form-section {{form.htmlClass}}"></div>'),e.put("decorators/bootstrap/select.html",'<div class="form-group {{form.htmlClass}} schema-form-select" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}"><label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label><select sf-field-model="" ng-disabled="form.readonly" sf-changed="form" class="form-control {{form.fieldHtmlClass}}" schema-validate="form" ng-options="item.value as item.name group by item.group for item in form.titleMap" name="{{form.key.slice(-1)[0]}}"></select><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/submit.html",'<div class="form-group schema-form-submit {{form.htmlClass}}"><input type="submit" class="btn {{ form.style || \'btn-primary\' }} {{form.fieldHtmlClass}}" value="{{form.title}}" ng-disabled="form.readonly" ng-if="form.type === \'submit\'"> <button class="btn {{ form.style || \'btn-default\' }}" type="button" ng-click="buttonClick($event,form)" ng-disabled="form.readonly" ng-if="form.type !== \'submit\'"><span ng-if="form.icon" class="{{form.icon}}"></span> {{form.title}}</button></div>'),e.put("decorators/bootstrap/tabarray.html",'<div ng-init="selected = { tab: 0 }" ng-model="modelArray" schema-validate="form" sf-field-model="sf-new-array" sf-new-array="" class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{form.htmlClass}}"><div ng-if="!form.tabType || form.tabType !== \'right\'" ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}"><ol class="nav nav-tabs" ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}" sf-field-model="" ui-sortable="form.sortOptions"><li sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index" ng-click="$event.preventDefault() || (selected.tab = $index)" ng-class="{active: selected.tab === $index}"><a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide="form.readonly || form.add === null" ng-disabled="form.schema.maxItems <= modelArray.length" ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)"><a href="#"><i class="glyphicon glyphicon-plus"></i> {{ form.add || \'Add\'}}</a></li></ol></div><div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}"><div class="tab-content {{form.fieldHtmlClass}}"><div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}" sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index" ng-show="selected.tab === $index" ng-class="{active: selected.tab === $index}"><div schema-form-array-items=""></div><button ng-hide="form.readonly || form.remove === null" ng-click="selected.tab = deleteFromArray($index).length - 1" ng-disabled="form.schema.minItems >= modelArray.length" type="button" class="btn {{ form.style.remove || \'btn-default\' }} pull-right"><i class="glyphicon glyphicon-trash"></i> {{ form.remove || \'Remove\'}}</button></div><div class="help-block" ng-show="(hasError() && errorMessage(schemaError())) || form.description" ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div></div></div></div><div ng-if="form.tabType === \'right\'" class="col-xs-3"><ul class="nav nav-tabs tabs-right"><li sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index" ng-click="$event.preventDefault() || (selected.tab = $index)" ng-class="{active: selected.tab === $index}"><a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide="form.readonly || form.add === null" ng-disabled="form.schema.maxItems <= modelArray.length" ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)"><a href="#"><i class="glyphicon glyphicon-plus"></i> {{ form.add || \'Add\'}}</a></li></ul></div>'),e.put("decorators/bootstrap/tabs.html",'<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{form.htmlClass}}"><ul class="nav nav-tabs"><li ng-repeat="tab in form.tabs" ng-disabled="form.readonly" ng-click="$event.preventDefault() || (selected.tab = $index)" ng-class="{active: selected.tab === $index}"><a href="#">{{ tab.title }}</a></li></ul><div class="tab-content {{form.fieldHtmlClass}}"></div></div>'),e.put("decorators/bootstrap/textarea.html",'<div class="form-group has-feedback {{form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label> <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight" class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-changed="form" placeholder="{{form.placeholder}}" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" name="{{form.key.slice(-1)[0]}}"></textarea><div ng-if="form.fieldAddonLeft || form.fieldAddonRight" ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}"><span ng-if="form.fieldAddonLeft" class="input-group-addon" ng-bind-html="form.fieldAddonLeft"></span> <textarea class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-changed="form" placeholder="{{form.placeholder}}" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" name="{{form.key.slice(-1)[0]}}"></textarea> <span ng-if="form.fieldAddonRight" class="input-group-addon" ng-bind-html="form.fieldAddonRight"></span></div><span class="help-block" sf-message="form.description"></span></div>')}]);
\ No newline at end of file
diff --git a/src/bootstrap-decorator.js b/src/bootstrap-decorator.js
index 885ead9..7fa6e2d 100644
--- a/src/bootstrap-decorator.js
+++ b/src/bootstrap-decorator.js
@@ -1,93 +1,111 @@
-angular.module('schemaForm').config(['schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider',
-function(decoratorsProvider, sfBuilderProvider, sfPathProvider) {
-  var base = 'decorators/bootstrap/';
+(function(angular, undefined) {'use strict';
+  angular
+    .module('schemaForm')
+    .config(bootstrapDecoratorConfig)
+    .filter('sfCamelKey', sfCamelKeyFilter);
 
-  var simpleTransclusion  = sfBuilderProvider.builders.simpleTransclusion;
-  var ngModelOptions      = sfBuilderProvider.builders.ngModelOptions;
-  var ngModel             = sfBuilderProvider.builders.ngModel;
-  var sfField             = sfBuilderProvider.builders.sfField;
-  var condition           = sfBuilderProvider.builders.condition;
-  var array               = sfBuilderProvider.builders.array;
+  bootstrapDecoratorConfig.$inject = [
+    'schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'
+  ];
 
-  // Tabs is so bootstrap specific that it stays here.
-  var tabs = function(args) {
-    if (args.form.tabs && args.form.tabs.length > 0) {
-      var tabContent = args.fieldFrag.querySelector('.tab-content');
+  function bootstrapDecoratorConfig(
+      schemaFormProvider, decoratorsProvider, sfBuilderProvider, sfPathProvider, $injector) {
+    var base = 'decorators/bootstrap/';
 
-      args.form.tabs.forEach(function(tab, index) {
-        var div = document.createElement('div');
-        div.className = 'tab-pane';
-        div.setAttribute('ng-disabled', 'form.readonly');
-        div.setAttribute('ng-show', 'selected.tab === ' + index);
-        div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
+    var simpleTransclusion  = sfBuilderProvider.builders.simpleTransclusion;
+    var ngModelOptions      = sfBuilderProvider.builders.ngModelOptions;
+    var ngModel             = sfBuilderProvider.builders.ngModel;
+    var sfField             = sfBuilderProvider.builders.sfField;
+    var condition           = sfBuilderProvider.builders.condition;
+    var array               = sfBuilderProvider.builders.array;
+    var numeric             = sfBuilderProvider.builders.numeric;
 
-        var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
-        div.appendChild(childFrag);
-        tabContent.appendChild(div);
-      });
-    }
-  };
-  
-  // Set tabArray sortOptions.items default.
-  var tabArray = function(args) {
-    if(args.form.hasOwnProperty('sortOptions')) {
-      if(!args.form.sortOptions.hasOwnProperty('items')) {
-        args.form.sortOptions['items'] = 'li:not(:last-child)';
+    // Tabs is so bootstrap specific that it stays here.
+    var tabs = function(args) {
+      if (args.form.tabs && args.form.tabs.length > 0) {
+        var tabContent = args.fieldFrag.querySelector('.tab-content');
+
+        args.form.tabs.forEach(function(tab, index) {
+          var div = document.createElement('div');
+          div.className = 'tab-pane';
+          div.setAttribute('ng-disabled', 'form.readonly');
+          div.setAttribute('ng-show', 'selected.tab === ' + index);
+          div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
+
+          var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
+          div.appendChild(childFrag);
+          tabContent.appendChild(div);
+        });
       }
-    } else {
-      args.form['sortOptions'] = {items: 'li:not(:last-child)'};
-    }
-  }
+    };
 
-  var selectPlaceholder = function(args) {
-    if (args.form.placeholder) {
-      var selectBox = args.fieldFrag.querySelector('select');
-      var option = document.createElement('option');
-      option.setAttribute('value', '');
+    var selectPlaceholder = function(args) {
+      if (args.form.placeholder) {
+        var selectBox = args.fieldFrag.querySelector('select');
+        var option = document.createElement('option');
+        option.setAttribute('value', '');
 
-      /* We only want the placeholder to show when we do not have a value on the model.
-       * We make ngModel builder replace all so we can use $$value$$.
-       */
-      option.setAttribute('sf-field-model', 'replaceAll');
+        /* We only want the placeholder to show when we do not have a value on the model.
+         * We make ngModel builder replace all so we can use $$value$$.
+         */
+        option.setAttribute('sf-field-model', 'replaceAll');
 
-      /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
-       * angular > 1.4 does a emptyOption.attr('selected', true)
-       * which does not like the ng-if comment.
-       */
-      if (angular.version.major === 1 && angular.version.minor < 4) {
-        option.setAttribute('ng-if', '$$value$$ === undefined');
-      } else {
-        option.setAttribute('ng-show', '$$value$$ === undefined');
-      }
+        /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
+         * angular > 1.4 does a emptyOption.attr('selected', true)
+         * which does not like the ng-if comment.
+         */
+        if (angular.version.major === 1 && angular.version.minor < 4) {
+          option.setAttribute('ng-if', '$$value$$ === undefined');
+        } else {
+          option.setAttribute('ng-show', '$$value$$ === undefined');
+        }
 
-      option.textContent = args.form.placeholder;
+        option.textContent = args.form.placeholder;
 
-      selectBox.appendChild(option);
-    }
+        selectBox.appendChild(option);
+      }
+    };
+
+    var defaults = [sfField, ngModel, ngModelOptions, condition];
+    decoratorsProvider.defineDecorator('bootstrapDecorator', {
+      textarea: {template: base + 'textarea.html', builder: defaults},
+      fieldset: {template: base + 'fieldset.html', builder: [sfField, simpleTransclusion, condition]},
+      array: {template: base + 'array.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
+      tabarray: {template: base + 'tabarray.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
+      tabs: {template: base + 'tabs.html', builder: [sfField, ngModelOptions, tabs, condition]},
+      section: {template: base + 'section.html', builder: [sfField, simpleTransclusion, condition]},
+      conditional: {template: base + 'section.html', builder: [sfField, simpleTransclusion, condition]},
+      actions: {template: base + 'actions.html', builder: defaults},
+      select: {template: base + 'select.html', builder: defaults.concat(selectPlaceholder)},
+      checkbox: {template: base + 'checkbox.html', builder: defaults},
+      checkboxes: {template: base + 'checkboxes.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
+      number: {template: base + 'default.html', builder: defaults.concat(numeric)},
+      password: {template: base + 'default.html', builder: defaults},
+      submit: {template: base + 'submit.html', builder: defaults},
+      button: {template: base + 'submit.html', builder: defaults},
+      radios: {template: base + 'radios.html', builder: defaults},
+      'radios-inline': {template: base + 'radios-inline.html', builder: defaults},
+      radiobuttons: {template: base + 'radio-buttons.html', builder: defaults},
+      help: {template: base + 'help.html', builder: defaults},
+      'default': {template: base + 'default.html', builder: defaults}
+    }, []);
   };
 
-  var defaults = [sfField, ngModel, ngModelOptions, condition];
-  decoratorsProvider.defineDecorator('bootstrapDecorator', {
-    textarea: {template: base + 'textarea.html', builder: defaults},
-    fieldset: {template: base + 'fieldset.html', builder: [sfField, simpleTransclusion, condition]},
-    array: {template: base + 'array.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    tabarray: {template: base + 'tabarray.html', builder: [sfField, ngModelOptions, ngModel, array, condition, tabArray]},
-    tabs: {template: base + 'tabs.html', builder: [sfField, ngModelOptions, tabs, condition]},
-    section: {template: base + 'section.html', builder: [sfField, simpleTransclusion, condition]},
-    conditional: {template: base + 'section.html', builder: [sfField, simpleTransclusion, condition]},
-    actions: {template: base + 'actions.html', builder: defaults},
-    select: {template: base + 'select.html', builder: [selectPlaceholder, sfField, ngModel, ngModelOptions, condition]},
-    checkbox: {template: base + 'checkbox.html', builder: defaults},
-    checkboxes: {template: base + 'checkboxes.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    number: {template: base + 'default.html', builder: defaults},
-    password: {template: base + 'default.html', builder: defaults},
-    submit: {template: base + 'submit.html', builder: defaults},
-    button: {template: base + 'submit.html', builder: defaults},
-    radios: {template: base + 'radios.html', builder: defaults},
-    'radios-inline': {template: base + 'radios-inline.html', builder: defaults},
-    radiobuttons: {template: base + 'radio-buttons.html', builder: defaults},
-    help: {template: base + 'help.html', builder: defaults},
-    'default': {template: base + 'default.html', builder: defaults}
-  }, []);
+  /**
+   * sfCamelKey Filter
+   */
+  function sfCamelKeyFilter() {
+    return function(formKey) {
+      if (!formKey) { return ''; };
+      var part, i, key;
+      key = formKey.slice();
+      for (i = 0; i < key.length; i++) {
+        part = key[i].toLowerCase().split('');
+        if (i && part.length) { part[0] = part[0].toUpperCase(); };
+        key[i] = part.join('');
+      };
+      return key.join('');
+    };
+  };
 
-}]);
+})(angular, undefined);
diff --git a/src/module.js b/src/module.js
new file mode 100644
index 0000000..24f297a
--- /dev/null
+++ b/src/module.js
@@ -0,0 +1,4 @@
+require('../node_modules/angular-schema-form/dist/schema-form.js');
+require('./angular-schema-form-bootstrap-templates.js');
+//require('./type-parser.js');
+require('./bootstrap-decorator.js');
diff --git a/webpack.config.js b/webpack.config.js
new file mode 100644
index 0000000..d701a92
--- /dev/null
+++ b/webpack.config.js
@@ -0,0 +1,38 @@
+/* global __dirname */
+var webpack = require('webpack');
+var path = require('path');
+var pjson = require('./package.json');
+console.log('Angular Schema Form Bootstrap v' + pjson.version);
+
+module.exports = {
+  entry: './src/module.js',
+  output: {
+    path: path.join(__dirname, 'dist'),
+    filename: 'angular-schema-form-bootstrap.js',
+    libraryTarget: 'umd'
+  },
+  resolve: { extensions: [ '', '.js', '.html' ] },
+  module: {
+    loaders: [
+      {
+        test: /\.js$/,
+        include: [ path.join(__dirname, 'src') ],
+        loader: 'babel',
+      },
+      { test: /\.html$/, loader: "ng-cache?prefix=decorators/bootstrap" }
+    ]
+  },
+  externals: {
+    'angular': 'var angular',
+    'tv4': 'var tv4',
+  },
+  plugins: [
+    new webpack.BannerPlugin(
+      'angular-schema-form-bootstrap\n' +
+      '@version ' +
+      pjson.version + '\n' +
+      '@link https://github.com/json-schema-form/angular-schema-form-bootstrap\n' +
+      '@license MIT\n' +
+      'Copyright (c) 2016 JSON Schema Form')
+  ]
+};

From d95d8a207110f6797c5d91b4e36f6303a61222c6 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Wed, 21 Sep 2016 00:39:58 +1000
Subject: [PATCH 17/50] Update README

---
 README.md | 15 +++++++++++++--
 1 file changed, 13 insertions(+), 2 deletions(-)

diff --git a/README.md b/README.md
index a45ba9a..9593911 100644
--- a/README.md
+++ b/README.md
@@ -23,12 +23,23 @@ or
 ```sh
 npm install angular-schema-form-bootstrap
 ```
+And then include `angular-schema-form-bootstrap.min.js`. Note that angular-schema-form >= 1.0.0-alpha.1 is needed.
 
-And then include `bootstrap-decorator.min.js`. Note that angular-schema-form >= 0.8.7 is needed.
-
+You **DO NOT** need to include angular-schema-form with this version, it is now embedded within the above file.
 
 Future
 ------
 Using the new builder opens up for a lot of optimization. Primarily we can get rid of a lot of small
 watches by using build helpers. For instance, slapping on a `sf-changed` directive *only* if the
 form definition has an `onChange` option.
+
+We also intend to provide a version that can be added as just the decorator without including Angular Schema Form.
+
+Developer Install
+-----------------
+```sh
+bower install
+npm install
+```
+Then read package.json for the available scripts.
+**Note** templates are compiled so the templates script must be run after changes.

From 04685e91452ad5d3ca197838bb37d4d203309e42 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Mon, 3 Oct 2016 08:43:47 +1100
Subject: [PATCH 18/50] Remove templates needing compiling with gulp

Template dependencies are now loaded through webpack also
---
 dist/angular-schema-form-bootstrap.js  | 390 +++++++++++++++++--------
 examples/bootstrap-example.html        |   1 -
 package.json                           |   7 +-
 src/bootstrap-decorator.js             | 210 +++++++------
 src/{ => bootstrap}/actions-trcl.html  |   0
 src/{ => bootstrap}/actions.html       |   0
 src/{ => bootstrap}/array.html         |   0
 src/{ => bootstrap}/checkbox.html      |   0
 src/{ => bootstrap}/checkboxes.html    |   0
 src/{ => bootstrap}/default.html       |   0
 src/{ => bootstrap}/fieldset.html      |   0
 src/{ => bootstrap}/help.html          |   0
 src/{ => bootstrap}/radio-buttons.html |   0
 src/{ => bootstrap}/radios-inline.html |   0
 src/{ => bootstrap}/radios.html        |   0
 src/{ => bootstrap}/section.html       |   0
 src/{ => bootstrap}/select.html        |   0
 src/{ => bootstrap}/submit.html        |   0
 src/{ => bootstrap}/tabarray.html      |   0
 src/{ => bootstrap}/tabs.html          |   3 +-
 src/{ => bootstrap}/textarea.html      |   0
 src/module.js                          |   4 +-
 webpack.config.js                      |  42 ++-
 23 files changed, 424 insertions(+), 233 deletions(-)
 rename src/{ => bootstrap}/actions-trcl.html (100%)
 rename src/{ => bootstrap}/actions.html (100%)
 rename src/{ => bootstrap}/array.html (100%)
 rename src/{ => bootstrap}/checkbox.html (100%)
 rename src/{ => bootstrap}/checkboxes.html (100%)
 rename src/{ => bootstrap}/default.html (100%)
 rename src/{ => bootstrap}/fieldset.html (100%)
 rename src/{ => bootstrap}/help.html (100%)
 rename src/{ => bootstrap}/radio-buttons.html (100%)
 rename src/{ => bootstrap}/radios-inline.html (100%)
 rename src/{ => bootstrap}/radios.html (100%)
 rename src/{ => bootstrap}/section.html (100%)
 rename src/{ => bootstrap}/select.html (100%)
 rename src/{ => bootstrap}/submit.html (100%)
 rename src/{ => bootstrap}/tabarray.html (100%)
 rename src/{ => bootstrap}/tabs.html (71%)
 rename src/{ => bootstrap}/textarea.html (100%)

diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index 84f3ac4..17abfc8 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -14,7 +14,7 @@
 		var a = typeof exports === 'object' ? factory(require("angular"), require("tv4")) : factory(root["angular"], root["tv4"]);
 		for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
 	}
-})(this, function(__WEBPACK_EXTERNAL_MODULE_2__, __WEBPACK_EXTERNAL_MODULE_3__) {
+})(this, function(__WEBPACK_EXTERNAL_MODULE_19__, __WEBPACK_EXTERNAL_MODULE_20__) {
 return /******/ (function(modules) { // webpackBootstrap
 /******/ 	// The module cache
 /******/ 	var installedModules = {};
@@ -62,9 +62,9 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports, __webpack_require__) {
 
 	__webpack_require__(1);
-	__webpack_require__(4);
+	//require('./angular-schema-form-bootstrap-templates.js');
 	//require('./type-parser.js');
-	__webpack_require__(5);
+	__webpack_require__(2);
 
 /***/ },
 /* 1 */
@@ -79,7 +79,7 @@ return /******/ (function(modules) { // webpackBootstrap
 	 */
 	(function webpackUniversalModuleDefinition(root, factory) {
 		if(true)
-			module.exports = factory(__webpack_require__(2), __webpack_require__(3));
+			module.exports = factory(__webpack_require__(19), __webpack_require__(20));
 		else if(typeof define === 'function' && define.amd)
 			define(["angular", "tv4"], factory);
 		else {
@@ -3664,154 +3664,292 @@ return /******/ (function(modules) { // webpackBootstrap
 
 /***/ },
 /* 2 */
-/***/ function(module, exports) {
+/***/ function(module, exports, __webpack_require__) {
 
-	module.exports = angular;
+	// angular-templatecache-loader
+	let textareaTemplate = __webpack_require__(18);
+	let fieldsetTemplate = __webpack_require__(8);
+	let arrayTemplate = __webpack_require__(4);
+	let tabarrayTemplate = __webpack_require__(16);
+	let tabsTemplate = __webpack_require__(17);
+	let sectionTemplate = __webpack_require__(13);
+	let actionsTemplate = __webpack_require__(3);
+	let selectTemplate = __webpack_require__(14);
+	let checkboxTemplate = __webpack_require__(5);
+	let checkboxesTemplate = __webpack_require__(6);
+	let submitTemplate = __webpack_require__(15);
+	let radiosTemplate = __webpack_require__(12);
+	let radiosInlineTemplate = __webpack_require__(11);
+	let radiobuttonsTemplate = __webpack_require__(10);
+	let helpTemplate = __webpack_require__(9);
+	let defaultTemplate = __webpack_require__(7);
+
+	angular.module('schemaForm').config(bootstrapDecoratorConfig).filter('sfCamelKey', sfCamelKeyFilter);
+
+	bootstrapDecoratorConfig.$inject = ['schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'];
+
+	function bootstrapDecoratorConfig(schemaFormProvider, decoratorsProvider, sfBuilderProvider, sfPathProvider, $injector) {
+	  var base = 'decorators/bootstrap/';
+
+	  var simpleTransclusion = sfBuilderProvider.builders.simpleTransclusion;
+	  var ngModelOptions = sfBuilderProvider.builders.ngModelOptions;
+	  var ngModel = sfBuilderProvider.builders.ngModel;
+	  var sfField = sfBuilderProvider.builders.sfField;
+	  var condition = sfBuilderProvider.builders.condition;
+	  var array = sfBuilderProvider.builders.array;
+	  var numeric = sfBuilderProvider.builders.numeric;
+
+	  // Tabs is so bootstrap specific that it stays here.
+	  var tabs = function (args) {
+	    if (args.form.tabs && args.form.tabs.length > 0) {
+	      var tabContent = args.fieldFrag.querySelector('.tab-content');
+
+	      args.form.tabs.forEach(function (tab, index) {
+	        var evalExpr = '(evalExpr(' + args.path + '.tabs[' + index + ']' + '.condition, { model: model, "arrayIndex": $index}))';
+	        var div = document.createElement('div');
+	        div.className = 'tab-pane';
+	        div.setAttribute('ng-disabled', 'form.readonly');
+	        div.setAttribute('ng-show', 'selected.tab === ' + index);
+	        div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
+	        if (!!tab.condition) {
+	          div.setAttribute('ng-if', evalExpr);
+	        };
+
+	        var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
+	        div.appendChild(childFrag);
+	        tabContent.appendChild(div);
+	      });
+	    }
+	  };
+
+	  var selectPlaceholder = function (args) {
+	    if (args.form.placeholder) {
+	      var selectBox = args.fieldFrag.querySelector('select');
+	      var option = document.createElement('option');
+	      option.setAttribute('value', '');
+
+	      /* We only want the placeholder to show when we do not have a value on the model.
+	       * We make ngModel builder replace all so we can use $$value$$.
+	       */
+	      option.setAttribute('sf-field-model', 'replaceAll');
+
+	      /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
+	       * angular > 1.4 does a emptyOption.attr('selected', true)
+	       * which does not like the ng-if comment.
+	       */
+	      if (angular.version.major === 1 && angular.version.minor < 4) {
+	        option.setAttribute('ng-if', '$$value$$ === undefined');
+	      } else {
+	        option.setAttribute('ng-show', '$$value$$ === undefined');
+	      }
+
+	      option.textContent = args.form.placeholder;
+
+	      selectBox.appendChild(option);
+	    }
+	  };
+
+	  var defaults = [sfField, ngModel, ngModelOptions, condition];
+	  decoratorsProvider.defineDecorator('bootstrapDecorator', {
+	    textarea: { template: textareaTemplate, builder: defaults },
+	    fieldset: { template: fieldsetTemplate, builder: [sfField, simpleTransclusion, condition] },
+	    array: { template: arrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
+	    tabarray: { template: tabarrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
+	    tabs: { template: tabsTemplate, builder: [sfField, ngModelOptions, tabs, condition] },
+	    section: { template: sectionTemplate, builder: [sfField, simpleTransclusion, condition] },
+	    conditional: { template: sectionTemplate, builder: [sfField, simpleTransclusion, condition] },
+	    actions: { template: actionsTemplate, builder: defaults },
+	    select: { template: selectTemplate, builder: defaults.concat(selectPlaceholder) },
+	    checkbox: { template: checkboxTemplate, builder: defaults },
+	    checkboxes: { template: checkboxesTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
+	    number: { template: defaultTemplate, builder: defaults.concat(numeric) },
+	    password: { template: defaultTemplate, builder: defaults },
+	    submit: { template: submitTemplate, builder: defaults },
+	    button: { template: submitTemplate, builder: defaults },
+	    radios: { template: radiosTemplate, builder: defaults },
+	    'radios-inline': { template: radiosInlineTemplate, builder: defaults },
+	    radiobuttons: { template: radiobuttonsTemplate, builder: defaults },
+	    help: { template: helpTemplate, builder: defaults },
+	    'default': { template: defaultTemplate, builder: defaults }
+	  }, []);
+	};
+
+	/**
+	 * sfCamelKey Filter
+	 */
+	function sfCamelKeyFilter() {
+	  return function (formKey) {
+	    if (!formKey) {
+	      return '';
+	    };
+	    var part, i, key;
+	    key = formKey.slice();
+	    for (i = 0; i < key.length; i++) {
+	      part = key[i].toLowerCase().split('');
+	      if (i && part.length) {
+	        part[0] = part[0].toUpperCase();
+	      };
+	      key[i] = part.join('');
+	    };
+	    return key.join('');
+	  };
+	};
 
 /***/ },
 /* 3 */
 /***/ function(module, exports) {
 
-	module.exports = tv4;
+	var path = 'bootstrap/actions.html';
+	var html = "<div class=\"btn-group schema-form-actions {{form.htmlClass}}\">\r\n  <input ng-repeat-start=\"item in form.items\"\r\n         type=\"submit\"\r\n         class=\"btn {{ item.style || 'btn-default' }} {{form.fieldHtmlClass}}\"\r\n         value=\"{{item.title}}\"\r\n         ng-if=\"item.type === 'submit'\">\r\n  <button ng-repeat-end\r\n          class=\"btn {{ item.style || 'btn-default' }} {{form.fieldHtmlClass}}\"\r\n          type=\"button\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"item.type !== 'submit'\"\r\n          ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
 
 /***/ },
 /* 4 */
 /***/ function(module, exports) {
 
-	angular.module("schemaForm").run(["$templateCache", function ($templateCache) {
-	  $templateCache.put("decorators/bootstrap/actions-trcl.html", "<div class=\"btn-group schema-form-actions {{form.htmlClass}}\" ng-transclude=\"\"></div>");
-	  $templateCache.put("decorators/bootstrap/actions.html", "<div class=\"btn-group schema-form-actions {{form.htmlClass}}\"><input ng-repeat-start=\"item in form.items\" type=\"submit\" class=\"btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}\" value=\"{{item.title}}\" ng-if=\"item.type === \'submit\'\"> <button ng-repeat-end=\"\" class=\"btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}\" type=\"button\" ng-disabled=\"form.readonly\" ng-if=\"item.type !== \'submit\'\" ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button></div>");
-	  $templateCache.put("decorators/bootstrap/array.html", "<div class=\"schema-form-array {{form.htmlClass}}\" sf-field-model=\"sf-new-array\" sf-new-array=\"\"><label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label><ol class=\"list-group\" sf-field-model=\"\" ui-sortable=\"form.sortOptions\"><li class=\"list-group-item {{form.fieldHtmlClass}}\" schema-form-array-items=\"\" sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\"><button ng-hide=\"form.readonly || form.remove === null\" ng-click=\"deleteFromArray($index)\" ng-disabled=\"form.schema.minItems >= modelArray.length\" style=\"position: relative; z-index: 20;\" type=\"button\" class=\"close pull-right\"><span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span></button></li></ol><div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\"><div class=\"help-block\" ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\" ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div><button ng-hide=\"form.readonly || form.add === null\" ng-click=\"appendToArray()\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" type=\"button\" class=\"btn {{ form.style.add || \'btn-default\' }} pull-right\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</button></div></div>");
-	  $templateCache.put("decorators/bootstrap/checkbox.html", "<div class=\"checkbox schema-form-checkbox {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"{{form.labelHtmlClass}}\"><input type=\"checkbox\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" class=\"{{form.fieldHtmlClass}}\" name=\"{{form.key.slice(-1)[0]}}\"> <span ng-bind-html=\"form.title\"></span></label><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-	  $templateCache.put("decorators/bootstrap/checkboxes.html", "<div sf-field-model=\"sf-new-array\" sf-new-array=\"\" class=\"form-group schema-form-checkboxes {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" sf-field-model=\"\" schema-validate=\"form\" ng-show=\"showTitle()\">{{form.title}}</label><div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\"><label><input type=\"checkbox\" ng-disabled=\"form.readonly\" sf-changed=\"form\" class=\"{{form.fieldHtmlClass}}\" ng-model=\"titleMapValues[$index]\" name=\"{{form.key.slice(-1)[0]}}\"> <span ng-bind-html=\"form.titleMap[$index].name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-	  $templateCache.put("decorators/bootstrap/default.html", "<div class=\"form-group {{form.htmlClass}}\" ng-class=\"{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{\'sr-only\': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label> <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\" ng-show=\"form.key\" type=\"{{form.type}}\" step=\"any\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-field-model=\"\" ng-disabled=\"form.readonly\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\" aria-describedby=\"{{form.key.slice(-1)[0] + \'Status\'}}\"><div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\" ng-class=\"{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}\"><span ng-if=\"form.fieldAddonLeft\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonLeft\"></span> <input ng-show=\"form.key\" type=\"{{form.type}}\" step=\"any\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-field-model=\"\" ng-disabled=\"form.readonly\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\" aria-describedby=\"{{form.key.slice(-1)[0] + \'Status\'}}\"> <span ng-if=\"form.fieldAddonRight\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonRight\"></span></div><span ng-if=\"form.feedback !== false\" class=\"form-control-feedback\" ng-class=\"evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }\" aria-hidden=\"true\"></span> <span ng-if=\"hasError() || hasSuccess()\" id=\"{{form.key.slice(-1)[0] + \'Status\'}}\" class=\"sr-only\">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-	  $templateCache.put("decorators/bootstrap/fieldset.html", "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{form.htmlClass}}\"><legend ng-class=\"{\'sr-only\': !showTitle() }\">{{ form.title }}</legend><div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div></fieldset>");
-	  $templateCache.put("decorators/bootstrap/help.html", "<div class=\"helpvalue schema-form-helpvalue {{form.htmlClass}}\" ng-bind-html=\"form.helpvalue\"></div>");
-	  $templateCache.put("decorators/bootstrap/radio-buttons.html", "<div class=\"form-group schema-form-radiobuttons {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><div><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label></div><div class=\"btn-group\"><label sf-field-model=\"replaceAll\" class=\"btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}\" ng-class=\"{ active: item.value === $$value$$ }\" ng-repeat=\"item in form.titleMap\"><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" style=\"display: none;\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-	  $templateCache.put("decorators/bootstrap/radios-inline.html", "<div class=\"form-group schema-form-radios-inline {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\" sf-field-model=\"\" schema-validate=\"form\">{{form.title}}</label><div><label class=\"radio-inline\" ng-repeat=\"item in form.titleMap\"><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-	  $templateCache.put("decorators/bootstrap/radios.html", "<div class=\"form-group schema-form-radios {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" sf-field-model=\"\" schema-validate=\"form\" ng-show=\"showTitle()\">{{form.title}}</label><div class=\"radio\" ng-repeat=\"item in form.titleMap\"><label><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-	  $templateCache.put("decorators/bootstrap/section.html", "<div class=\"schema-form-section {{form.htmlClass}}\"></div>");
-	  $templateCache.put("decorators/bootstrap/select.html", "<div class=\"form-group {{form.htmlClass}} schema-form-select\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label><select sf-field-model=\"\" ng-disabled=\"form.readonly\" sf-changed=\"form\" class=\"form-control {{form.fieldHtmlClass}}\" schema-validate=\"form\" ng-options=\"item.value as item.name group by item.group for item in form.titleMap\" name=\"{{form.key.slice(-1)[0]}}\"></select><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-	  $templateCache.put("decorators/bootstrap/submit.html", "<div class=\"form-group schema-form-submit {{form.htmlClass}}\"><input type=\"submit\" class=\"btn {{ form.style || \'btn-primary\' }} {{form.fieldHtmlClass}}\" value=\"{{form.title}}\" ng-disabled=\"form.readonly\" ng-if=\"form.type === \'submit\'\"> <button class=\"btn {{ form.style || \'btn-default\' }}\" type=\"button\" ng-click=\"buttonClick($event,form)\" ng-disabled=\"form.readonly\" ng-if=\"form.type !== \'submit\'\"><span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span> {{form.title}}</button></div>");
-	  $templateCache.put("decorators/bootstrap/tabarray.html", "<div ng-init=\"selected = { tab: 0 }\" ng-model=\"modelArray\" schema-validate=\"form\" sf-field-model=\"sf-new-array\" sf-new-array=\"\" class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{form.htmlClass}}\"><div ng-if=\"!form.tabType || form.tabType !== \'right\'\" ng-class=\"{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}\"><ol class=\"nav nav-tabs\" ng-class=\"{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}\" sf-field-model=\"\" ui-sortable=\"form.sortOptions\"><li sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide=\"form.readonly || form.add === null\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\"><a href=\"#\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</a></li></ol></div><div ng-class=\"{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}\"><div class=\"tab-content {{form.fieldHtmlClass}}\"><div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\" sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-show=\"selected.tab === $index\" ng-class=\"{active: selected.tab === $index}\"><div schema-form-array-items=\"\"></div><button ng-hide=\"form.readonly || form.remove === null\" ng-click=\"selected.tab = deleteFromArray($index).length - 1\" ng-disabled=\"form.schema.minItems >= modelArray.length\" type=\"button\" class=\"btn {{ form.style.remove || \'btn-default\' }} pull-right\"><i class=\"glyphicon glyphicon-trash\"></i> {{ form.remove || \'Remove\'}}</button></div><div class=\"help-block\" ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\" ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div></div></div></div><div ng-if=\"form.tabType === \'right\'\" class=\"col-xs-3\"><ul class=\"nav nav-tabs tabs-right\"><li sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide=\"form.readonly || form.add === null\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\"><a href=\"#\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</a></li></ul></div>");
-	  $templateCache.put("decorators/bootstrap/tabs.html", "<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{form.htmlClass}}\"><ul class=\"nav nav-tabs\"><li ng-repeat=\"tab in form.tabs\" ng-disabled=\"form.readonly\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{ tab.title }}</a></li></ul><div class=\"tab-content {{form.fieldHtmlClass}}\"></div></div>");
-	  $templateCache.put("decorators/bootstrap/textarea.html", "<div class=\"form-group has-feedback {{form.htmlClass}} schema-form-textarea\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{\'sr-only\': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label> <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\"></textarea><div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\" ng-class=\"{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}\"><span ng-if=\"form.fieldAddonLeft\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonLeft\"></span> <textarea class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\"></textarea> <span ng-if=\"form.fieldAddonRight\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonRight\"></span></div><span class=\"help-block\" sf-message=\"form.description\"></span></div>");
-	}]);
+	var path = 'bootstrap/array.html';
+	var html = "<div  class=\"schema-form-array {{form.htmlClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{form.fieldHtmlClass}}\"\r\n        schema-form-array-items\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $index\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
 
 /***/ },
 /* 5 */
 /***/ function(module, exports) {
 
-	(function (angular, undefined) {
-	  'use strict';
+	var path = 'bootstrap/checkbox.html';
+	var html = "<div class=\"checkbox schema-form-checkbox {{form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{form.fieldHtmlClass}}\"\r\n           name=\"{{form.key.slice(-1)[0]}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 6 */
+/***/ function(module, exports) {
 
-	  angular.module('schemaForm').config(bootstrapDecoratorConfig).filter('sfCamelKey', sfCamelKeyFilter);
+	var path = 'bootstrap/checkboxes.html';
+	var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{form.key.slice(-1)[0]}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
 
-	  bootstrapDecoratorConfig.$inject = ['schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'];
+/***/ },
+/* 7 */
+/***/ function(module, exports) {
 
-	  function bootstrapDecoratorConfig(schemaFormProvider, decoratorsProvider, sfBuilderProvider, sfPathProvider, $injector) {
-	    var base = 'decorators/bootstrap/';
+	var path = 'bootstrap/default.html';
+	var html = "<div class=\"form-group {{form.htmlClass}}\"\r\n     ng-class=\"{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"form.key\"\r\n         type=\"{{form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{form.placeholder}}\"\r\n         class=\"form-control {{form.fieldHtmlClass}}\"\r\n         id=\"{{form.key.slice(-1)[0]}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{form.key.slice(-1)[0]}}\"\r\n         aria-describedby=\"{{form.key.slice(-1)[0] + 'Status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"form.key\"\r\n           type=\"{{form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{form.placeholder}}\"\r\n           class=\"form-control {{form.fieldHtmlClass}}\"\r\n           id=\"{{form.key.slice(-1)[0]}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{form.key.slice(-1)[0]}}\"\r\n           aria-describedby=\"{{form.key.slice(-1)[0] + 'Status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{form.key.slice(-1)[0] + 'Status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
 
-	    var simpleTransclusion = sfBuilderProvider.builders.simpleTransclusion;
-	    var ngModelOptions = sfBuilderProvider.builders.ngModelOptions;
-	    var ngModel = sfBuilderProvider.builders.ngModel;
-	    var sfField = sfBuilderProvider.builders.sfField;
-	    var condition = sfBuilderProvider.builders.condition;
-	    var array = sfBuilderProvider.builders.array;
-	    var numeric = sfBuilderProvider.builders.numeric;
+/***/ },
+/* 8 */
+/***/ function(module, exports) {
 
-	    // Tabs is so bootstrap specific that it stays here.
-	    var tabs = function (args) {
-	      if (args.form.tabs && args.form.tabs.length > 0) {
-	        var tabContent = args.fieldFrag.querySelector('.tab-content');
+	var path = 'bootstrap/fieldset.html';
+	var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{form.htmlClass}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
 
-	        args.form.tabs.forEach(function (tab, index) {
-	          var div = document.createElement('div');
-	          div.className = 'tab-pane';
-	          div.setAttribute('ng-disabled', 'form.readonly');
-	          div.setAttribute('ng-show', 'selected.tab === ' + index);
-	          div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
+/***/ },
+/* 9 */
+/***/ function(module, exports) {
 
-	          var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
-	          div.appendChild(childFrag);
-	          tabContent.appendChild(div);
-	        });
-	      }
-	    };
+	var path = 'bootstrap/help.html';
+	var html = "<div class=\"helpvalue schema-form-helpvalue {{form.htmlClass}}\" ng-bind-html=\"form.helpvalue\"></div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
 
-	    var selectPlaceholder = function (args) {
-	      if (args.form.placeholder) {
-	        var selectBox = args.fieldFrag.querySelector('select');
-	        var option = document.createElement('option');
-	        option.setAttribute('value', '');
-
-	        /* We only want the placeholder to show when we do not have a value on the model.
-	         * We make ngModel builder replace all so we can use $$value$$.
-	         */
-	        option.setAttribute('sf-field-model', 'replaceAll');
-
-	        /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
-	         * angular > 1.4 does a emptyOption.attr('selected', true)
-	         * which does not like the ng-if comment.
-	         */
-	        if (angular.version.major === 1 && angular.version.minor < 4) {
-	          option.setAttribute('ng-if', '$$value$$ === undefined');
-	        } else {
-	          option.setAttribute('ng-show', '$$value$$ === undefined');
-	        }
-
-	        option.textContent = args.form.placeholder;
-
-	        selectBox.appendChild(option);
-	      }
-	    };
+/***/ },
+/* 10 */
+/***/ function(module, exports) {
 
-	    var defaults = [sfField, ngModel, ngModelOptions, condition];
-	    decoratorsProvider.defineDecorator('bootstrapDecorator', {
-	      textarea: { template: base + 'textarea.html', builder: defaults },
-	      fieldset: { template: base + 'fieldset.html', builder: [sfField, simpleTransclusion, condition] },
-	      array: { template: base + 'array.html', builder: [sfField, ngModelOptions, ngModel, array, condition] },
-	      tabarray: { template: base + 'tabarray.html', builder: [sfField, ngModelOptions, ngModel, array, condition] },
-	      tabs: { template: base + 'tabs.html', builder: [sfField, ngModelOptions, tabs, condition] },
-	      section: { template: base + 'section.html', builder: [sfField, simpleTransclusion, condition] },
-	      conditional: { template: base + 'section.html', builder: [sfField, simpleTransclusion, condition] },
-	      actions: { template: base + 'actions.html', builder: defaults },
-	      select: { template: base + 'select.html', builder: defaults.concat(selectPlaceholder) },
-	      checkbox: { template: base + 'checkbox.html', builder: defaults },
-	      checkboxes: { template: base + 'checkboxes.html', builder: [sfField, ngModelOptions, ngModel, array, condition] },
-	      number: { template: base + 'default.html', builder: defaults.concat(numeric) },
-	      password: { template: base + 'default.html', builder: defaults },
-	      submit: { template: base + 'submit.html', builder: defaults },
-	      button: { template: base + 'submit.html', builder: defaults },
-	      radios: { template: base + 'radios.html', builder: defaults },
-	      'radios-inline': { template: base + 'radios-inline.html', builder: defaults },
-	      radiobuttons: { template: base + 'radio-buttons.html', builder: defaults },
-	      help: { template: base + 'help.html', builder: defaults },
-	      'default': { template: base + 'default.html', builder: defaults }
-	    }, []);
-	  };
+	var path = 'bootstrap/radio-buttons.html';
+	var html = "<div class=\"form-group schema-form-radiobuttons {{form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (item.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: item.value === $$value$$ }\"\r\n           ng-repeat=\"item in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
 
-	  /**
-	   * sfCamelKey Filter
-	   */
-	  function sfCamelKeyFilter() {
-	    return function (formKey) {
-	      if (!formKey) {
-	        return '';
-	      };
-	      var part, i, key;
-	      key = formKey.slice();
-	      for (i = 0; i < key.length; i++) {
-	        part = key[i].toLowerCase().split('');
-	        if (i && part.length) {
-	          part[0] = part[0].toUpperCase();
-	        };
-	        key[i] = part.join('');
-	      };
-	      return key.join('');
-	    };
-	  };
-	})(angular, undefined);
+/***/ },
+/* 11 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/radios-inline.html';
+	var html = "<div class=\"form-group schema-form-radios-inline {{form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"item in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 12 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/radios.html';
+	var html = "<div class=\"form-group schema-form-radios {{form.htmlClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"item in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 13 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/section.html';
+	var html = "<div class=\"schema-form-section {{form.htmlClass}}\"></div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 14 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/select.html';
+	var html = "<div class=\"form-group {{form.htmlClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{form.key.slice(-1)[0]}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 15 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/submit.html';
+	var html = "<div class=\"form-group schema-form-submit {{form.htmlClass}}\">\r\n  <input type=\"submit\"\r\n         class=\"btn {{ form.style || 'btn-primary' }} {{form.fieldHtmlClass}}\"\r\n         value=\"{{form.title}}\"\r\n         ng-disabled=\"form.readonly\"\r\n         ng-if=\"form.type === 'submit'\">\r\n  <button class=\"btn {{ form.style || 'btn-default' }}\"\r\n          type=\"button\"\r\n          ng-click=\"buttonClick($event,form)\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"form.type !== 'submit'\">\r\n      <span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 16 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/tabarray.html';
+	var html = "\r\n<div ng-init=\"selected = { tab: 0 }\"\r\n     ng-model=\"modelArray\" schema-validate=\"form\"\r\n     sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{form.htmlClass}}\">\r\n  <div ng-if=\"!form.tabType || form.tabType !== 'right'\"\r\n       ng-class=\"{'col-xs-3': !form.tabType || form.tabType === 'left'}\">\r\n    <ol class=\"nav nav-tabs\"\r\n        ng-class=\"{ 'tabs-left': !form.tabType || form.tabType === 'left'}\"\r\n        sf-field-model ui-sortable=\"form.sortOptions\">\r\n      <li sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class=\"{'col-xs-9': !form.tabType || form.tabType === 'left' || form.tabType === 'right'}\">\r\n    <div class=\"tab-content {{form.fieldHtmlClass}}\">\r\n      <div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\"\r\n           sf-field-model=\"ng-repeat\"\r\n           ng-repeat=\"item in $$value$$ track by $index\"\r\n           ng-show=\"selected.tab === $index\"\r\n           ng-class=\"{active: selected.tab === $index}\">\r\n\r\n           <div schema-form-array-items></div>\r\n\r\n           <button ng-hide=\"form.readonly || form.remove === null\"\r\n                   ng-click=\"selected.tab = deleteFromArray($index).length - 1\"\r\n                   ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n                   type=\"button\"\r\n                   class=\"btn {{ form.style.remove || 'btn-default' }} pull-right\">\r\n             <i class=\"glyphicon glyphicon-trash\"></i>\r\n             {{ form.remove || 'Remove'}}\r\n           </button>\r\n      </div>\r\n      <div class=\"help-block\"\r\n           ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n           ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if=\"form.tabType === 'right'\" class=\"col-xs-3\">\r\n    <ul class=\"nav nav-tabs tabs-right\">\r\n      <li  sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 17 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/tabs.html';
+	var html = "<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{form.htmlClass}}\">\r\n  <ul class=\"nav nav-tabs\">\r\n    <li ng-repeat=\"tab in form.tabs\"\r\n        ng-disabled=\"form.readonly\"\r\n        ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n        ng-class=\"{active: selected.tab === $index}\"\r\n        ng-if=\"(!tab.condition || evalExpr(tab.condition, { model: model, arrayIndex: $index}))\">\r\n        <a href=\"#\">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class=\"tab-content {{form.fieldHtmlClass}}\">\r\n  </div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 18 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/textarea.html';
+	var html = "<div class=\"form-group has-feedback {{form.htmlClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{form.fieldHtmlClass}}\"\r\n            id=\"{{form.key.slice(-1)[0]}}\"\r\n            sf-changed=\"form\"\r\n            placeholder=\"{{form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{form.key.slice(-1)[0]}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{form.fieldHtmlClass}}\"\r\n              id=\"{{form.key.slice(-1)[0]}}\"\r\n              sf-changed=\"form\"\r\n              placeholder=\"{{form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{form.key.slice(-1)[0]}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 19 */
+/***/ function(module, exports) {
+
+	module.exports = angular;
+
+/***/ },
+/* 20 */
+/***/ function(module, exports) {
+
+	module.exports = tv4;
 
 /***/ }
 /******/ ])
diff --git a/examples/bootstrap-example.html b/examples/bootstrap-example.html
index 4a6c577..0b3dc94 100644
--- a/examples/bootstrap-example.html
+++ b/examples/bootstrap-example.html
@@ -220,7 +220,6 @@ <h3>Schema</h3>
 <script type="text/javascript" src="../bower_components/angular-ui-ace/ui-ace.js"></script>
 <script type="text/javascript" src="../bower_components/pickadate/lib/picker.js"></script>
 <script type="text/javascript" src="../bower_components/pickadate/lib/picker.date.js"></script>
-<script type="text/javascript" src="../bower_components/pickadate/lib/translations/nl_NL.js"></script>
 
 <script type="text/javascript" src="../bower_components/spectrum/spectrum.js"></script>
 <script type="text/javascript" src="../bower_components/spectrum/i18n/jquery.spectrum-sv.js"></script>
diff --git a/package.json b/package.json
index fddc613..72214d9 100644
--- a/package.json
+++ b/package.json
@@ -4,11 +4,10 @@
   "description": "Bootstrap 3 decorator for Angular Schema Form",
   "main": "dist/bootstrap-decorator.js",
   "scripts": {
-    "templates": "gulp templates",
     "dist": "npm run build && npm run minify",
     "build": "webpack",
     "watch": "webpack --watch",
-    "minify": "uglifyjs dist/angular-schema-form-material.js --comments --output=dist/angular-schema-form-material.min.js",
+    "minify": "uglifyjs dist/angular-schema-form-bootstrap.js --comments --output=dist/angular-schema-form-bootstrap.min.js",
     "test": "echo \"Error: no test specified\" && exit 1",
     "test-not-yet-done": "karma start --single-run --browsers PhantomJS karma.conf.js --log-level info"
   },
@@ -41,6 +40,9 @@
     "gulp-uglify": "^1.2.0",
     "gulp-watch": "^4.2.4",
     "gulp-webserver": "^0.9.1",
+    "html": "^1.0.0",
+    "html-loader": "^0.4.4",
+    "html-webpack-plugin": "^2.22.0",
     "karma": "^0.13.22",
     "karma-chai-sinon": "^0.1.5",
     "karma-coverage": "^1.0.0",
@@ -51,6 +53,7 @@
     "mocha": "^2.5.3",
     "mocha-lcov-reporter": "0.0.1",
     "ng-cache-loader": "0.0.16",
+    "ngtemplate-loader": "^1.3.1",
     "protractor": "^2.5.1",
     "sinon": "^1.17.4",
     "sinon-chai": "^2.8.0",
diff --git a/src/bootstrap-decorator.js b/src/bootstrap-decorator.js
index 7fa6e2d..cfd714f 100644
--- a/src/bootstrap-decorator.js
+++ b/src/bootstrap-decorator.js
@@ -1,111 +1,131 @@
-(function(angular, undefined) {'use strict';
-  angular
-    .module('schemaForm')
-    .config(bootstrapDecoratorConfig)
-    .filter('sfCamelKey', sfCamelKeyFilter);
+// angular-templatecache-loader
+let textareaTemplate = require('./bootstrap/textarea.html');
+let fieldsetTemplate = require('./bootstrap/fieldset.html');
+let arrayTemplate = require('./bootstrap/array.html');
+let tabarrayTemplate = require('./bootstrap/tabarray.html');
+let tabsTemplate = require('./bootstrap/tabs.html');
+let sectionTemplate = require('./bootstrap/section.html');
+let actionsTemplate = require('./bootstrap/actions.html');
+let selectTemplate = require('./bootstrap/select.html');
+let checkboxTemplate = require('./bootstrap/checkbox.html');
+let checkboxesTemplate = require('./bootstrap/checkboxes.html');
+let submitTemplate = require('./bootstrap/submit.html');
+let radiosTemplate = require('./bootstrap/radios.html');
+let radiosInlineTemplate = require('./bootstrap/radios-inline.html');
+let radiobuttonsTemplate = require('./bootstrap/radio-buttons.html');
+let helpTemplate = require('./bootstrap/help.html');
+let defaultTemplate = require('./bootstrap/default.html');
 
-  bootstrapDecoratorConfig.$inject = [
-    'schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'
-  ];
+angular
+  .module('schemaForm')
+  .config(bootstrapDecoratorConfig)
+  .filter('sfCamelKey', sfCamelKeyFilter);
 
-  function bootstrapDecoratorConfig(
-      schemaFormProvider, decoratorsProvider, sfBuilderProvider, sfPathProvider, $injector) {
-    var base = 'decorators/bootstrap/';
+bootstrapDecoratorConfig.$inject = [
+  'schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'
+];
 
-    var simpleTransclusion  = sfBuilderProvider.builders.simpleTransclusion;
-    var ngModelOptions      = sfBuilderProvider.builders.ngModelOptions;
-    var ngModel             = sfBuilderProvider.builders.ngModel;
-    var sfField             = sfBuilderProvider.builders.sfField;
-    var condition           = sfBuilderProvider.builders.condition;
-    var array               = sfBuilderProvider.builders.array;
-    var numeric             = sfBuilderProvider.builders.numeric;
+function bootstrapDecoratorConfig(
+    schemaFormProvider, decoratorsProvider, sfBuilderProvider, sfPathProvider, $injector) {
+  var base = 'decorators/bootstrap/';
 
-    // Tabs is so bootstrap specific that it stays here.
-    var tabs = function(args) {
-      if (args.form.tabs && args.form.tabs.length > 0) {
-        var tabContent = args.fieldFrag.querySelector('.tab-content');
+  var simpleTransclusion  = sfBuilderProvider.builders.simpleTransclusion;
+  var ngModelOptions      = sfBuilderProvider.builders.ngModelOptions;
+  var ngModel             = sfBuilderProvider.builders.ngModel;
+  var sfField             = sfBuilderProvider.builders.sfField;
+  var condition           = sfBuilderProvider.builders.condition;
+  var array               = sfBuilderProvider.builders.array;
+  var numeric             = sfBuilderProvider.builders.numeric;
 
-        args.form.tabs.forEach(function(tab, index) {
-          var div = document.createElement('div');
-          div.className = 'tab-pane';
-          div.setAttribute('ng-disabled', 'form.readonly');
-          div.setAttribute('ng-show', 'selected.tab === ' + index);
-          div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
+  // Tabs is so bootstrap specific that it stays here.
+  var tabs = function(args) {
+    if (args.form.tabs && args.form.tabs.length > 0) {
+      var tabContent = args.fieldFrag.querySelector('.tab-content');
 
-          var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
-          div.appendChild(childFrag);
-          tabContent.appendChild(div);
-        });
-      }
-    };
+      args.form.tabs.forEach(function(tab, index) {
+        var evalExpr = '(evalExpr(' + args.path + '.tabs[' + index + ']' +
+                       '.condition, { model: model, "arrayIndex": $index}))';
+        var div = document.createElement('div');
+        div.className = 'tab-pane';
+        div.setAttribute('ng-disabled', 'form.readonly');
+        div.setAttribute('ng-show', 'selected.tab === ' + index);
+        div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
+        if(!!tab.condition) {
+          div.setAttribute('ng-if', evalExpr);
+        };
 
-    var selectPlaceholder = function(args) {
-      if (args.form.placeholder) {
-        var selectBox = args.fieldFrag.querySelector('select');
-        var option = document.createElement('option');
-        option.setAttribute('value', '');
-
-        /* We only want the placeholder to show when we do not have a value on the model.
-         * We make ngModel builder replace all so we can use $$value$$.
-         */
-        option.setAttribute('sf-field-model', 'replaceAll');
+        var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
+        div.appendChild(childFrag);
+        tabContent.appendChild(div);
+      });
+    }
+  };
 
-        /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
-         * angular > 1.4 does a emptyOption.attr('selected', true)
-         * which does not like the ng-if comment.
-         */
-        if (angular.version.major === 1 && angular.version.minor < 4) {
-          option.setAttribute('ng-if', '$$value$$ === undefined');
-        } else {
-          option.setAttribute('ng-show', '$$value$$ === undefined');
-        }
+  var selectPlaceholder = function(args) {
+    if (args.form.placeholder) {
+      var selectBox = args.fieldFrag.querySelector('select');
+      var option = document.createElement('option');
+      option.setAttribute('value', '');
 
-        option.textContent = args.form.placeholder;
+      /* We only want the placeholder to show when we do not have a value on the model.
+       * We make ngModel builder replace all so we can use $$value$$.
+       */
+      option.setAttribute('sf-field-model', 'replaceAll');
 
-        selectBox.appendChild(option);
+      /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
+       * angular > 1.4 does a emptyOption.attr('selected', true)
+       * which does not like the ng-if comment.
+       */
+      if (angular.version.major === 1 && angular.version.minor < 4) {
+        option.setAttribute('ng-if', '$$value$$ === undefined');
+      } else {
+        option.setAttribute('ng-show', '$$value$$ === undefined');
       }
-    };
 
-    var defaults = [sfField, ngModel, ngModelOptions, condition];
-    decoratorsProvider.defineDecorator('bootstrapDecorator', {
-      textarea: {template: base + 'textarea.html', builder: defaults},
-      fieldset: {template: base + 'fieldset.html', builder: [sfField, simpleTransclusion, condition]},
-      array: {template: base + 'array.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
-      tabarray: {template: base + 'tabarray.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
-      tabs: {template: base + 'tabs.html', builder: [sfField, ngModelOptions, tabs, condition]},
-      section: {template: base + 'section.html', builder: [sfField, simpleTransclusion, condition]},
-      conditional: {template: base + 'section.html', builder: [sfField, simpleTransclusion, condition]},
-      actions: {template: base + 'actions.html', builder: defaults},
-      select: {template: base + 'select.html', builder: defaults.concat(selectPlaceholder)},
-      checkbox: {template: base + 'checkbox.html', builder: defaults},
-      checkboxes: {template: base + 'checkboxes.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
-      number: {template: base + 'default.html', builder: defaults.concat(numeric)},
-      password: {template: base + 'default.html', builder: defaults},
-      submit: {template: base + 'submit.html', builder: defaults},
-      button: {template: base + 'submit.html', builder: defaults},
-      radios: {template: base + 'radios.html', builder: defaults},
-      'radios-inline': {template: base + 'radios-inline.html', builder: defaults},
-      radiobuttons: {template: base + 'radio-buttons.html', builder: defaults},
-      help: {template: base + 'help.html', builder: defaults},
-      'default': {template: base + 'default.html', builder: defaults}
-    }, []);
+      option.textContent = args.form.placeholder;
+
+      selectBox.appendChild(option);
+    }
   };
 
-  /**
-   * sfCamelKey Filter
-   */
-  function sfCamelKeyFilter() {
-    return function(formKey) {
-      if (!formKey) { return ''; };
-      var part, i, key;
-      key = formKey.slice();
-      for (i = 0; i < key.length; i++) {
-        part = key[i].toLowerCase().split('');
-        if (i && part.length) { part[0] = part[0].toUpperCase(); };
-        key[i] = part.join('');
-      };
-      return key.join('');
+  var defaults = [sfField, ngModel, ngModelOptions, condition];
+  decoratorsProvider.defineDecorator('bootstrapDecorator', {
+    textarea: {template: textareaTemplate, builder: defaults},
+    fieldset: {template: fieldsetTemplate, builder: [sfField, simpleTransclusion, condition]},
+    array: {template: arrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    tabarray: {template: tabarrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    tabs: {template: tabsTemplate, builder: [sfField, ngModelOptions, tabs, condition]},
+    section: {template: sectionTemplate, builder: [sfField, simpleTransclusion, condition]},
+    conditional: {template: sectionTemplate, builder: [sfField, simpleTransclusion, condition]},
+    actions: {template: actionsTemplate, builder: defaults},
+    select: {template: selectTemplate, builder: defaults.concat(selectPlaceholder)},
+    checkbox: {template: checkboxTemplate, builder: defaults},
+    checkboxes: {template: checkboxesTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    number: {template: defaultTemplate, builder: defaults.concat(numeric)},
+    password: {template: defaultTemplate, builder: defaults},
+    submit: {template: submitTemplate, builder: defaults},
+    button: {template: submitTemplate, builder: defaults},
+    radios: {template: radiosTemplate, builder: defaults},
+    'radios-inline': {template: radiosInlineTemplate, builder: defaults},
+    radiobuttons: {template: radiobuttonsTemplate, builder: defaults},
+    help: {template: helpTemplate, builder: defaults},
+    'default': {template: defaultTemplate, builder: defaults}
+  }, []);
+};
+
+/**
+ * sfCamelKey Filter
+ */
+function sfCamelKeyFilter() {
+  return function(formKey) {
+    if (!formKey) { return ''; };
+    var part, i, key;
+    key = formKey.slice();
+    for (i = 0; i < key.length; i++) {
+      part = key[i].toLowerCase().split('');
+      if (i && part.length) { part[0] = part[0].toUpperCase(); };
+      key[i] = part.join('');
     };
+    return key.join('');
   };
-
-})(angular, undefined);
+};
diff --git a/src/actions-trcl.html b/src/bootstrap/actions-trcl.html
similarity index 100%
rename from src/actions-trcl.html
rename to src/bootstrap/actions-trcl.html
diff --git a/src/actions.html b/src/bootstrap/actions.html
similarity index 100%
rename from src/actions.html
rename to src/bootstrap/actions.html
diff --git a/src/array.html b/src/bootstrap/array.html
similarity index 100%
rename from src/array.html
rename to src/bootstrap/array.html
diff --git a/src/checkbox.html b/src/bootstrap/checkbox.html
similarity index 100%
rename from src/checkbox.html
rename to src/bootstrap/checkbox.html
diff --git a/src/checkboxes.html b/src/bootstrap/checkboxes.html
similarity index 100%
rename from src/checkboxes.html
rename to src/bootstrap/checkboxes.html
diff --git a/src/default.html b/src/bootstrap/default.html
similarity index 100%
rename from src/default.html
rename to src/bootstrap/default.html
diff --git a/src/fieldset.html b/src/bootstrap/fieldset.html
similarity index 100%
rename from src/fieldset.html
rename to src/bootstrap/fieldset.html
diff --git a/src/help.html b/src/bootstrap/help.html
similarity index 100%
rename from src/help.html
rename to src/bootstrap/help.html
diff --git a/src/radio-buttons.html b/src/bootstrap/radio-buttons.html
similarity index 100%
rename from src/radio-buttons.html
rename to src/bootstrap/radio-buttons.html
diff --git a/src/radios-inline.html b/src/bootstrap/radios-inline.html
similarity index 100%
rename from src/radios-inline.html
rename to src/bootstrap/radios-inline.html
diff --git a/src/radios.html b/src/bootstrap/radios.html
similarity index 100%
rename from src/radios.html
rename to src/bootstrap/radios.html
diff --git a/src/section.html b/src/bootstrap/section.html
similarity index 100%
rename from src/section.html
rename to src/bootstrap/section.html
diff --git a/src/select.html b/src/bootstrap/select.html
similarity index 100%
rename from src/select.html
rename to src/bootstrap/select.html
diff --git a/src/submit.html b/src/bootstrap/submit.html
similarity index 100%
rename from src/submit.html
rename to src/bootstrap/submit.html
diff --git a/src/tabarray.html b/src/bootstrap/tabarray.html
similarity index 100%
rename from src/tabarray.html
rename to src/bootstrap/tabarray.html
diff --git a/src/tabs.html b/src/bootstrap/tabs.html
similarity index 71%
rename from src/tabs.html
rename to src/bootstrap/tabs.html
index 0950976..0a0e7b1 100644
--- a/src/tabs.html
+++ b/src/bootstrap/tabs.html
@@ -3,7 +3,8 @@
     <li ng-repeat="tab in form.tabs"
         ng-disabled="form.readonly"
         ng-click="$event.preventDefault() || (selected.tab = $index)"
-        ng-class="{active: selected.tab === $index}">
+        ng-class="{active: selected.tab === $index}"
+        ng-if="(!tab.condition || evalExpr(tab.condition, { model: model, arrayIndex: $index}))">
         <a href="#">{{ tab.title }}</a>
     </li>
   </ul>
diff --git a/src/textarea.html b/src/bootstrap/textarea.html
similarity index 100%
rename from src/textarea.html
rename to src/bootstrap/textarea.html
diff --git a/src/module.js b/src/module.js
index 24f297a..625dd1b 100644
--- a/src/module.js
+++ b/src/module.js
@@ -1,4 +1,4 @@
 require('../node_modules/angular-schema-form/dist/schema-form.js');
-require('./angular-schema-form-bootstrap-templates.js');
+//require('./angular-schema-form-bootstrap-templates.js');
 //require('./type-parser.js');
-require('./bootstrap-decorator.js');
+require('bootstrap-decorator.js');
diff --git a/webpack.config.js b/webpack.config.js
index d701a92..d37edfc 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -1,25 +1,50 @@
 /* global __dirname */
-var webpack = require('webpack');
-var path = require('path');
-var pjson = require('./package.json');
+const webpack = require('webpack');
+const path = require('path');
+//const ngAnnotatePlugin = require('ng-annotate-webpack-plugin');
+const HtmlWebpackPlugin = require('html-webpack-plugin');
+//const ExtractTextPlugin = require('extract-text-webpack-plugin');
+const getPath = (pathToFile) => path.resolve(__dirname, pathToFile);
+const pjson = require('./package.json');
 console.log('Angular Schema Form Bootstrap v' + pjson.version);
 
 module.exports = {
   entry: './src/module.js',
+  // entry: {
+  //   schema_form_decorators: [
+  //     getPath('./src/bootstrap-decorator.js'),
+  //   ]
+  //   // ,
+  //   // app: [
+  //   //   getPath('./src/app.js'),
+  //   //   getPath('./src/config/dev.config.js')
+  //   // ]
+  // },
   output: {
-    path: path.join(__dirname, 'dist'),
+    path: getPath('./dist'),
     filename: 'angular-schema-form-bootstrap.js',
+    sourceMapFilename: '[name].map',
     libraryTarget: 'umd'
   },
-  resolve: { extensions: [ '', '.js', '.html' ] },
+  resolve: {
+    modulesDirectories: [
+      'node_modules', 'src'
+    ],
+    extensions: [ '', '.js', '.html' ]
+  },
   module: {
     loaders: [
       {
         test: /\.js$/,
         include: [ path.join(__dirname, 'src') ],
+        exclude: /(node_modules)/,
         loader: 'babel',
       },
-      { test: /\.html$/, loader: "ng-cache?prefix=decorators/bootstrap" }
+      {
+        test: /\.html$/,
+        loader: 'ngtemplate?relativeTo=' + path.join(__dirname, 'src') + '/!html',
+        exclude: /(index)/
+      }
     ]
   },
   externals: {
@@ -27,6 +52,11 @@ module.exports = {
     'tv4': 'var tv4',
   },
   plugins: [
+    new webpack.optimize.AggressiveMergingPlugin({}),
+    new webpack.optimize.OccurenceOrderPlugin(true),
+    // new HtmlWebpackPlugin({
+    //   template: 'html!./src/index.html'
+    // }),
     new webpack.BannerPlugin(
       'angular-schema-form-bootstrap\n' +
       '@version ' +

From d9772ea6291f2fea056bf2db3e46d4919fc64c39 Mon Sep 17 00:00:00 2001
From: Marcel J Bennett <iamanthropic@gmail.com>
Date: Fri, 7 Oct 2016 00:06:11 +1100
Subject: [PATCH 19/50] Create ISSUE_TEMPLATE.md

---
 .github/ISSUE_TEMPLATE.md | 23 +++++++++++++++++++++++
 1 file changed, 23 insertions(+)
 create mode 100644 .github/ISSUE_TEMPLATE.md

diff --git a/.github/ISSUE_TEMPLATE.md b/.github/ISSUE_TEMPLATE.md
new file mode 100644
index 0000000..9a5d13a
--- /dev/null
+++ b/.github/ISSUE_TEMPLATE.md
@@ -0,0 +1,23 @@
+<!-- 
+Only include sections relevant to your issue.
+
+If you have not read json-schema-form/angular-schema-form/docs/support.md and followed its guidance you may be ignored or closed without response.
+
+Please use PREVIEW before you submit!!
+-->
+####  Enhancement
+As a user/developer, when I ... I should be able to ...
+
+####  Expected behaviour
+I expected ...
+
+####  Actual behaviour
+It actually ...
+
+####  Gist/Plunker/Demo
+[Description](url)
+
+####  Related issues
+This is/maybe related to ...
+
+@json-schema-form/angular-schema-form-bootstrap-lead

From cc1c6faece296c8fb34830c648b8f8aadcf1f6ba Mon Sep 17 00:00:00 2001
From: Marcel J Bennett <iamanthropic@gmail.com>
Date: Fri, 7 Oct 2016 00:08:25 +1100
Subject: [PATCH 20/50] Create PULL_REQUEST_TEMPLATE.md

---
 .github/PULL_REQUEST_TEMPLATE.md | 16 ++++++++++++++++
 1 file changed, 16 insertions(+)
 create mode 100644 .github/PULL_REQUEST_TEMPLATE.md

diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md
new file mode 100644
index 0000000..0fd2c87
--- /dev/null
+++ b/.github/PULL_REQUEST_TEMPLATE.md
@@ -0,0 +1,16 @@
+####  Description
+
+Add your description here
+
+####  Fixes Related issues
+- add related
+- issues here
+
+####  Checklist
+- [ ] I have read and understand the CONTRIBUTIONS.md file
+- [ ] I have searched for and linked related issues
+- [ ] I have created test cases to ensure quick resolution of the PR is easier
+- [ ] I am NOT targeting main branch
+- [ ] I did NOT include the dist folder in my PR
+
+@json-schema-form/angular-schema-form-bootstrap-lead

From cdb0b8133105aa4f4a010bf06177e1ced2e8d10f Mon Sep 17 00:00:00 2001
From: Marcel J Bennett <iamanthropic@gmail.com>
Date: Fri, 7 Oct 2016 00:13:25 +1100
Subject: [PATCH 21/50] Create CONTRIBUTING.md

---
 CONTRIBUTING.md | 22 ++++++++++++++++++++++
 1 file changed, 22 insertions(+)
 create mode 100644 CONTRIBUTING.md

diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
new file mode 100644
index 0000000..4cc90d9
--- /dev/null
+++ b/CONTRIBUTING.md
@@ -0,0 +1,22 @@
+Contributing
+------------
+We love contributions!
+
+**Please base any merge request on the *development* branch instead of *master*.**
+
+The reason for this is that we're trying to use
+[git flow](http://danielkummer.github.io/git-flow-cheatsheet/), and it makes merging your pull
+request heck of a lot easier for us.
+
+Please avoid including anything from the `dist/` directory as that can make merging harder, and we
+always generate these files when we make a new release.
+
+If its a new field type consider making it an add-on instead,
+especially if it has external dependencies. See [extending Schema Form documentation.](https://github.com/json-schema-form/angular-schema-form/blob/development/docs/extending.md)
+
+With new features we love to see updates to the docs as well as tests, that makes it super
+easy and fast for us to merge it!
+
+Also consider running any code through the code style checker [jscs](https://github.com/mdevils/node-jscs)
+(or even better use it in your editor) with preset set to `google`. You can also use `gulp jscs` to
+check your code.

From c63414e90004035dca797de70b52e986ed6a2793 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Thu, 13 Oct 2016 01:08:41 +1100
Subject: [PATCH 22/50] Clean up loader and compiler, remove more gulp

---
 .babelrc                                      |  3 ++
 examples/bootstrap-example.html               |  9 +++---
 gulp/tasks/bootstrap-datepicker.js            | 29 -----------------
 gulp/tasks/default.js                         |  2 +-
 gulp/tasks/minify.js                          | 32 -------------------
 gulp/tasks/templates.js                       | 31 ------------------
 gulp/tasks/watch.js                           |  5 ---
 package.json                                  |  4 +--
 ...angular-schema-form-bootstrap-templates.js | 17 ----------
 ...lar-schema-form-bootstrap-templates.min.js |  1 -
 src/bootstrap/tabarray.html                   |  1 -
 src/bootstrap/tabs.html                       |  3 +-
 src/module.js                                 |  2 --
 webpack.config.js                             |  2 +-
 14 files changed, 12 insertions(+), 129 deletions(-)
 create mode 100644 .babelrc
 delete mode 100644 gulp/tasks/bootstrap-datepicker.js
 delete mode 100644 gulp/tasks/minify.js
 delete mode 100644 gulp/tasks/templates.js
 delete mode 100644 gulp/tasks/watch.js
 delete mode 100644 src/angular-schema-form-bootstrap-templates.js
 delete mode 100644 src/angular-schema-form-bootstrap-templates.min.js

diff --git a/.babelrc b/.babelrc
new file mode 100644
index 0000000..c13c5f6
--- /dev/null
+++ b/.babelrc
@@ -0,0 +1,3 @@
+{
+  "presets": ["es2015"]
+}
diff --git a/examples/bootstrap-example.html b/examples/bootstrap-example.html
index 0b3dc94..8c059f7 100644
--- a/examples/bootstrap-example.html
+++ b/examples/bootstrap-example.html
@@ -199,7 +199,6 @@ <h3>Schema</h3>
 
 <script type="text/javascript" src="../bower_components/jquery/dist/jquery.min.js"></script>
 <!-- <script type="text/javascript" src="//cdn.jsdelivr.net/g/jquery.ui@1.10"></script> -->
-<script type="text/javascript" src="../bower_components/tv4/tv4.js"></script>
 <script type="text/javascript" src="../bower_components/ace-builds/src-min-noconflict/ace.js"></script>
 <script type="text/javascript" src="../bower_components/angular/angular.js"></script>
 <script type="text/javascript" src="../bower_components/angular-sanitize/angular-sanitize.min.js"></script>
@@ -210,10 +209,6 @@ <h3>Schema</h3>
 <script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/swfobject/2.2/swfobject.js"></script>
 <script type="text/javascript" src="//cdnjs.cloudflare.com/ajax/libs/angular-ui-bootstrap/0.12.1/ui-bootstrap.min.js"></script>
 
-<!-- <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.21/angular.min.js"></script> -->
-<!-- <script type="text/javascript" src="https://ajax.googleapis.com/ajax/libs/angularjs/1.2.21/angular-sanitize.min.js"></script> -->
-
-
 <script type="text/javascript" src="../bower_components/angular-ui-sortable/sortable.min.js"></script>
 <script type="text/javascript" src="../bower_components/jquery-ui/jquery-ui.min.js"></script>
 
@@ -225,7 +220,11 @@ <h3>Schema</h3>
 <script type="text/javascript" src="../bower_components/spectrum/i18n/jquery.spectrum-sv.js"></script>
 <script type="text/javascript" src="../bower_components/angular-spectrum-colorpicker/dist/angular-spectrum-colorpicker.min.js"></script>
 
+<!-- These are the main files that you must include along with Angular-->
+<script type="text/javascript" src="../bower_components/tv4/tv4.js"></script>
 <script type="text/javascript" src="../dist/angular-schema-form-bootstrap.js"></script>
+<!-- /These were the main files that you must include along with Angular-->
+
 <script type="text/javascript" src="../bower_components/angular-schema-form-datepicker/bootstrap-datepicker.min.js"></script>
 <script type="text/javascript" src="../bower_components/angular-schema-form-colorpicker/bootstrap-colorpicker.min.js"></script>
 
diff --git a/gulp/tasks/bootstrap-datepicker.js b/gulp/tasks/bootstrap-datepicker.js
deleted file mode 100644
index c3b066e..0000000
--- a/gulp/tasks/bootstrap-datepicker.js
+++ /dev/null
@@ -1,29 +0,0 @@
-var gulp = require('gulp'),
-  streamqueue = require('streamqueue'),
-  minifyHtml = require('gulp-minify-html'),
-  templateCache = require('gulp-angular-templatecache'),
-  concat = require('gulp-concat'),
-  uglify = require('gulp-uglify');
-
-gulp.task('bootstrap-datepicker', function() {
-  var stream = streamqueue({objectMode: true});
-  stream.queue(
-    gulp.src('./src/directives/decorators/bootstrap/datepicker/*.html')
-    .pipe(minifyHtml({
-      empty: true,
-      spare: true,
-      quotes: true
-    }))
-    .pipe(templateCache({
-      module: 'schemaForm',
-      root: 'directives/decorators/bootstrap/datepicker/'
-    }))
-    );
-  stream.queue(gulp.src('./src/directives/decorators/bootstrap/datepicker/*.js'));
-
-  stream.done()
-  .pipe(concat('bootstrap-datepicker.min.js'))
-  .pipe(uglify())
-  .pipe(gulp.dest('./dist/'));
-
-});
\ No newline at end of file
diff --git a/gulp/tasks/default.js b/gulp/tasks/default.js
index 8ea9789..b42fa3c 100644
--- a/gulp/tasks/default.js
+++ b/gulp/tasks/default.js
@@ -1,5 +1,5 @@
 var gulp = require('gulp');
 
 gulp.task('default', [
-  'minify'
+  'jscs'
 ]);
diff --git a/gulp/tasks/minify.js b/gulp/tasks/minify.js
deleted file mode 100644
index 70dbac9..0000000
--- a/gulp/tasks/minify.js
+++ /dev/null
@@ -1,32 +0,0 @@
-var gulp = require('gulp'),
-  streamqueue = require('streamqueue'),
-  minifyHtml = require('gulp-minify-html'),
-  templateCache = require('gulp-angular-templatecache'),
-  concat = require('gulp-concat'),
-  rename = require('gulp-rename'),
-  uglify = require('gulp-uglify');
-
-gulp.task('minify', function() {
-  var stream = streamqueue({objectMode: true});
-  stream.queue(
-    gulp.src('./src/**/*.html')
-    .pipe(minifyHtml({
-      empty: true,
-      spare: true,
-      quotes: true
-    }))
-    .pipe(templateCache({
-      module: 'schemaForm',
-      root: 'decorators/bootstrap/'
-    }))
-    );
-  stream.queue(gulp.src('./src/**/*.js'));
-
-  stream.done()
-  .pipe(rename('angular-schema-form-bootstrap-templates.js'))
-  .pipe(gulp.dest('./src'))
-  .pipe(uglify())
-  .pipe(rename('angular-schema-form-bootstrap-templates.min.js'))
-  .pipe(gulp.dest('./src'));
-
-});
diff --git a/gulp/tasks/templates.js b/gulp/tasks/templates.js
deleted file mode 100644
index e533f3f..0000000
--- a/gulp/tasks/templates.js
+++ /dev/null
@@ -1,31 +0,0 @@
-var gulp = require('gulp'),
-  streamqueue = require('streamqueue'),
-  minifyHtml = require('gulp-minify-html'),
-  templateCache = require('gulp-angular-templatecache'),
-  concat = require('gulp-concat'),
-  rename = require('gulp-rename'),
-  uglify = require('gulp-uglify');
-
-gulp.task('templates', function() {
-  var stream = streamqueue({objectMode: true});
-  stream.queue(
-    gulp.src('./src/**/*.html')
-    .pipe(minifyHtml({
-      empty: true,
-      spare: true,
-      quotes: true
-    }))
-    .pipe(templateCache({
-      module: 'schemaForm',
-      root: 'decorators/bootstrap/'
-    }))
-    );
-
-  stream.done()
-  .pipe(rename('angular-schema-form-bootstrap-templates.js'))
-  .pipe(gulp.dest('./src'))
-  .pipe(uglify())
-  .pipe(rename('angular-schema-form-bootstrap-templates.min.js'))
-  .pipe(gulp.dest('./src'));
-
-});
diff --git a/gulp/tasks/watch.js b/gulp/tasks/watch.js
deleted file mode 100644
index 6fdd634..0000000
--- a/gulp/tasks/watch.js
+++ /dev/null
@@ -1,5 +0,0 @@
-var gulp = require('gulp');
-
-gulp.task('watch', function() {
-  gulp.watch('./src/**/*', ['default']);
-});
diff --git a/package.json b/package.json
index 72214d9..e714b78 100644
--- a/package.json
+++ b/package.json
@@ -25,9 +25,9 @@
   },
   "devDependencies": {
     "babel-core": "^6.10.4",
-    "babel-loader": "^6.2.4",
+    "babel-loader": "^6.2.5",
     "babel-polyfill": "^6.9.1",
-    "babel-preset-es2015": "^6.9.0",
+    "babel-preset-es2015": "^6.16.0",
     "chai": "^3.5.0",
     "coveralls": "^2.11.0",
     "gulp": "^3.9.0",
diff --git a/src/angular-schema-form-bootstrap-templates.js b/src/angular-schema-form-bootstrap-templates.js
deleted file mode 100644
index 836efee..0000000
--- a/src/angular-schema-form-bootstrap-templates.js
+++ /dev/null
@@ -1,17 +0,0 @@
-angular.module("schemaForm").run(["$templateCache", function($templateCache) {$templateCache.put("decorators/bootstrap/actions-trcl.html","<div class=\"btn-group schema-form-actions {{form.htmlClass}}\" ng-transclude=\"\"></div>");
-$templateCache.put("decorators/bootstrap/actions.html","<div class=\"btn-group schema-form-actions {{form.htmlClass}}\"><input ng-repeat-start=\"item in form.items\" type=\"submit\" class=\"btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}\" value=\"{{item.title}}\" ng-if=\"item.type === \'submit\'\"> <button ng-repeat-end=\"\" class=\"btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}\" type=\"button\" ng-disabled=\"form.readonly\" ng-if=\"item.type !== \'submit\'\" ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button></div>");
-$templateCache.put("decorators/bootstrap/array.html","<div class=\"schema-form-array {{form.htmlClass}}\" sf-field-model=\"sf-new-array\" sf-new-array=\"\"><label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label><ol class=\"list-group\" sf-field-model=\"\" ui-sortable=\"form.sortOptions\"><li class=\"list-group-item {{form.fieldHtmlClass}}\" schema-form-array-items=\"\" sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\"><button ng-hide=\"form.readonly || form.remove === null\" ng-click=\"deleteFromArray($index)\" ng-disabled=\"form.schema.minItems >= modelArray.length\" style=\"position: relative; z-index: 20;\" type=\"button\" class=\"close pull-right\"><span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span></button></li></ol><div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\"><div class=\"help-block\" ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\" ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div><button ng-hide=\"form.readonly || form.add === null\" ng-click=\"appendToArray()\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" type=\"button\" class=\"btn {{ form.style.add || \'btn-default\' }} pull-right\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</button></div></div>");
-$templateCache.put("decorators/bootstrap/checkbox.html","<div class=\"checkbox schema-form-checkbox {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"{{form.labelHtmlClass}}\"><input type=\"checkbox\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" class=\"{{form.fieldHtmlClass}}\" name=\"{{form.key.slice(-1)[0]}}\"> <span ng-bind-html=\"form.title\"></span></label><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/checkboxes.html","<div sf-field-model=\"sf-new-array\" sf-new-array=\"\" class=\"form-group schema-form-checkboxes {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" sf-field-model=\"\" schema-validate=\"form\" ng-show=\"showTitle()\">{{form.title}}</label><div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\"><label><input type=\"checkbox\" ng-disabled=\"form.readonly\" sf-changed=\"form\" class=\"{{form.fieldHtmlClass}}\" ng-model=\"titleMapValues[$index]\" name=\"{{form.key.slice(-1)[0]}}\"> <span ng-bind-html=\"form.titleMap[$index].name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/default.html","<div class=\"form-group {{form.htmlClass}}\" ng-class=\"{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{\'sr-only\': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label> <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\" ng-show=\"form.key\" type=\"{{form.type}}\" step=\"any\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-field-model=\"\" ng-disabled=\"form.readonly\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\" aria-describedby=\"{{form.key.slice(-1)[0] + \'Status\'}}\"><div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\" ng-class=\"{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}\"><span ng-if=\"form.fieldAddonLeft\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonLeft\"></span> <input ng-show=\"form.key\" type=\"{{form.type}}\" step=\"any\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-field-model=\"\" ng-disabled=\"form.readonly\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\" aria-describedby=\"{{form.key.slice(-1)[0] + \'Status\'}}\"> <span ng-if=\"form.fieldAddonRight\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonRight\"></span></div><span ng-if=\"form.feedback !== false\" class=\"form-control-feedback\" ng-class=\"evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }\" aria-hidden=\"true\"></span> <span ng-if=\"hasError() || hasSuccess()\" id=\"{{form.key.slice(-1)[0] + \'Status\'}}\" class=\"sr-only\">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/fieldset.html","<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{form.htmlClass}}\"><legend ng-class=\"{\'sr-only\': !showTitle() }\">{{ form.title }}</legend><div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div></fieldset>");
-$templateCache.put("decorators/bootstrap/help.html","<div class=\"helpvalue schema-form-helpvalue {{form.htmlClass}}\" ng-bind-html=\"form.helpvalue\"></div>");
-$templateCache.put("decorators/bootstrap/radio-buttons.html","<div class=\"form-group schema-form-radiobuttons {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><div><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label></div><div class=\"btn-group\"><label sf-field-model=\"replaceAll\" class=\"btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}\" ng-class=\"{ active: item.value === $$value$$ }\" ng-repeat=\"item in form.titleMap\"><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" style=\"display: none;\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/radios-inline.html","<div class=\"form-group schema-form-radios-inline {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\" sf-field-model=\"\" schema-validate=\"form\">{{form.title}}</label><div><label class=\"radio-inline\" ng-repeat=\"item in form.titleMap\"><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/radios.html","<div class=\"form-group schema-form-radios {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" sf-field-model=\"\" schema-validate=\"form\" ng-show=\"showTitle()\">{{form.title}}</label><div class=\"radio\" ng-repeat=\"item in form.titleMap\"><label><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/section.html","<div class=\"schema-form-section {{form.htmlClass}}\"></div>");
-$templateCache.put("decorators/bootstrap/select.html","<div class=\"form-group {{form.htmlClass}} schema-form-select\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label><select sf-field-model=\"\" ng-disabled=\"form.readonly\" sf-changed=\"form\" class=\"form-control {{form.fieldHtmlClass}}\" schema-validate=\"form\" ng-options=\"item.value as item.name group by item.group for item in form.titleMap\" name=\"{{form.key.slice(-1)[0]}}\"></select><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/submit.html","<div class=\"form-group schema-form-submit {{form.htmlClass}}\"><input type=\"submit\" class=\"btn {{ form.style || \'btn-primary\' }} {{form.fieldHtmlClass}}\" value=\"{{form.title}}\" ng-disabled=\"form.readonly\" ng-if=\"form.type === \'submit\'\"> <button class=\"btn {{ form.style || \'btn-default\' }}\" type=\"button\" ng-click=\"buttonClick($event,form)\" ng-disabled=\"form.readonly\" ng-if=\"form.type !== \'submit\'\"><span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span> {{form.title}}</button></div>");
-$templateCache.put("decorators/bootstrap/tabarray.html","<div ng-init=\"selected = { tab: 0 }\" ng-model=\"modelArray\" schema-validate=\"form\" sf-field-model=\"sf-new-array\" sf-new-array=\"\" class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{form.htmlClass}}\"><div ng-if=\"!form.tabType || form.tabType !== \'right\'\" ng-class=\"{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}\"><ol class=\"nav nav-tabs\" ng-class=\"{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}\" sf-field-model=\"\" ui-sortable=\"form.sortOptions\"><li sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide=\"form.readonly || form.add === null\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\"><a href=\"#\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</a></li></ol></div><div ng-class=\"{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}\"><div class=\"tab-content {{form.fieldHtmlClass}}\"><div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\" sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-show=\"selected.tab === $index\" ng-class=\"{active: selected.tab === $index}\"><div schema-form-array-items=\"\"></div><button ng-hide=\"form.readonly || form.remove === null\" ng-click=\"selected.tab = deleteFromArray($index).length - 1\" ng-disabled=\"form.schema.minItems >= modelArray.length\" type=\"button\" class=\"btn {{ form.style.remove || \'btn-default\' }} pull-right\"><i class=\"glyphicon glyphicon-trash\"></i> {{ form.remove || \'Remove\'}}</button></div><div class=\"help-block\" ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\" ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div></div></div></div><div ng-if=\"form.tabType === \'right\'\" class=\"col-xs-3\"><ul class=\"nav nav-tabs tabs-right\"><li sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide=\"form.readonly || form.add === null\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\"><a href=\"#\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</a></li></ul></div>");
-$templateCache.put("decorators/bootstrap/tabs.html","<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{form.htmlClass}}\"><ul class=\"nav nav-tabs\"><li ng-repeat=\"tab in form.tabs\" ng-disabled=\"form.readonly\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{ tab.title }}</a></li></ul><div class=\"tab-content {{form.fieldHtmlClass}}\"></div></div>");
-$templateCache.put("decorators/bootstrap/textarea.html","<div class=\"form-group has-feedback {{form.htmlClass}} schema-form-textarea\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{\'sr-only\': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label> <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\"></textarea><div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\" ng-class=\"{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}\"><span ng-if=\"form.fieldAddonLeft\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonLeft\"></span> <textarea class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\"></textarea> <span ng-if=\"form.fieldAddonRight\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonRight\"></span></div><span class=\"help-block\" sf-message=\"form.description\"></span></div>");}]);
\ No newline at end of file
diff --git a/src/angular-schema-form-bootstrap-templates.min.js b/src/angular-schema-form-bootstrap-templates.min.js
deleted file mode 100644
index aa8b5a2..0000000
--- a/src/angular-schema-form-bootstrap-templates.min.js
+++ /dev/null
@@ -1 +0,0 @@
-angular.module("schemaForm").run(["$templateCache",function(e){e.put("decorators/bootstrap/actions-trcl.html",'<div class="btn-group schema-form-actions {{form.htmlClass}}" ng-transclude=""></div>'),e.put("decorators/bootstrap/actions.html",'<div class="btn-group schema-form-actions {{form.htmlClass}}"><input ng-repeat-start="item in form.items" type="submit" class="btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}" value="{{item.title}}" ng-if="item.type === \'submit\'"> <button ng-repeat-end="" class="btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}" type="button" ng-disabled="form.readonly" ng-if="item.type !== \'submit\'" ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button></div>'),e.put("decorators/bootstrap/array.html",'<div class="schema-form-array {{form.htmlClass}}" sf-field-model="sf-new-array" sf-new-array=""><label class="control-label" ng-show="showTitle()">{{ form.title }}</label><ol class="list-group" sf-field-model="" ui-sortable="form.sortOptions"><li class="list-group-item {{form.fieldHtmlClass}}" schema-form-array-items="" sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index"><button ng-hide="form.readonly || form.remove === null" ng-click="deleteFromArray($index)" ng-disabled="form.schema.minItems >= modelArray.length" style="position: relative; z-index: 20;" type="button" class="close pull-right"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button></li></ol><div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form"><div class="help-block" ng-show="(hasError() && errorMessage(schemaError())) || form.description" ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div><button ng-hide="form.readonly || form.add === null" ng-click="appendToArray()" ng-disabled="form.schema.maxItems <= modelArray.length" type="button" class="btn {{ form.style.add || \'btn-default\' }} pull-right"><i class="glyphicon glyphicon-plus"></i> {{ form.add || \'Add\'}}</button></div></div>'),e.put("decorators/bootstrap/checkbox.html",'<div class="checkbox schema-form-checkbox {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="{{form.labelHtmlClass}}"><input type="checkbox" sf-changed="form" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" class="{{form.fieldHtmlClass}}" name="{{form.key.slice(-1)[0]}}"> <span ng-bind-html="form.title"></span></label><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/checkboxes.html",'<div sf-field-model="sf-new-array" sf-new-array="" class="form-group schema-form-checkboxes {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" sf-field-model="" schema-validate="form" ng-show="showTitle()">{{form.title}}</label><div class="checkbox" ng-repeat="val in titleMapValues track by $index"><label><input type="checkbox" ng-disabled="form.readonly" sf-changed="form" class="{{form.fieldHtmlClass}}" ng-model="titleMapValues[$index]" name="{{form.key.slice(-1)[0]}}"> <span ng-bind-html="form.titleMap[$index].name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/default.html",'<div class="form-group {{form.htmlClass}}" ng-class="{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }"><label class="control-label {{form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label> <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight" ng-show="form.key" type="{{form.type}}" step="any" sf-changed="form" placeholder="{{form.placeholder}}" class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-field-model="" ng-disabled="form.readonly" schema-validate="form" name="{{form.key.slice(-1)[0]}}" aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}"><div ng-if="form.fieldAddonLeft || form.fieldAddonRight" ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}"><span ng-if="form.fieldAddonLeft" class="input-group-addon" ng-bind-html="form.fieldAddonLeft"></span> <input ng-show="form.key" type="{{form.type}}" step="any" sf-changed="form" placeholder="{{form.placeholder}}" class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-field-model="" ng-disabled="form.readonly" schema-validate="form" name="{{form.key.slice(-1)[0]}}" aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}"> <span ng-if="form.fieldAddonRight" class="input-group-addon" ng-bind-html="form.fieldAddonRight"></span></div><span ng-if="form.feedback !== false" class="form-control-feedback" ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }" aria-hidden="true"></span> <span ng-if="hasError() || hasSuccess()" id="{{form.key.slice(-1)[0] + \'Status\'}}" class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/fieldset.html",'<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{form.htmlClass}}"><legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend><div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div></fieldset>'),e.put("decorators/bootstrap/help.html",'<div class="helpvalue schema-form-helpvalue {{form.htmlClass}}" ng-bind-html="form.helpvalue"></div>'),e.put("decorators/bootstrap/radio-buttons.html",'<div class="form-group schema-form-radiobuttons {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><div><label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label></div><div class="btn-group"><label sf-field-model="replaceAll" class="btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}" ng-class="{ active: item.value === $$value$$ }" ng-repeat="item in form.titleMap"><input type="radio" class="{{form.fieldHtmlClass}}" sf-changed="form" style="display: none;" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" ng-value="item.value" name="{{form.key.join(\'.\')}}"> <span ng-bind-html="item.name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/radios-inline.html",'<div class="form-group schema-form-radios-inline {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()" sf-field-model="" schema-validate="form">{{form.title}}</label><div><label class="radio-inline" ng-repeat="item in form.titleMap"><input type="radio" class="{{form.fieldHtmlClass}}" sf-changed="form" ng-disabled="form.readonly" sf-field-model="" ng-value="item.value" name="{{form.key.join(\'.\')}}"> <span ng-bind-html="item.name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/radios.html",'<div class="form-group schema-form-radios {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" sf-field-model="" schema-validate="form" ng-show="showTitle()">{{form.title}}</label><div class="radio" ng-repeat="item in form.titleMap"><label><input type="radio" class="{{form.fieldHtmlClass}}" sf-changed="form" ng-disabled="form.readonly" sf-field-model="" ng-value="item.value" name="{{form.key.join(\'.\')}}"> <span ng-bind-html="item.name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/section.html",'<div class="schema-form-section {{form.htmlClass}}"></div>'),e.put("decorators/bootstrap/select.html",'<div class="form-group {{form.htmlClass}} schema-form-select" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}"><label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label><select sf-field-model="" ng-disabled="form.readonly" sf-changed="form" class="form-control {{form.fieldHtmlClass}}" schema-validate="form" ng-options="item.value as item.name group by item.group for item in form.titleMap" name="{{form.key.slice(-1)[0]}}"></select><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/submit.html",'<div class="form-group schema-form-submit {{form.htmlClass}}"><input type="submit" class="btn {{ form.style || \'btn-primary\' }} {{form.fieldHtmlClass}}" value="{{form.title}}" ng-disabled="form.readonly" ng-if="form.type === \'submit\'"> <button class="btn {{ form.style || \'btn-default\' }}" type="button" ng-click="buttonClick($event,form)" ng-disabled="form.readonly" ng-if="form.type !== \'submit\'"><span ng-if="form.icon" class="{{form.icon}}"></span> {{form.title}}</button></div>'),e.put("decorators/bootstrap/tabarray.html",'<div ng-init="selected = { tab: 0 }" ng-model="modelArray" schema-validate="form" sf-field-model="sf-new-array" sf-new-array="" class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{form.htmlClass}}"><div ng-if="!form.tabType || form.tabType !== \'right\'" ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}"><ol class="nav nav-tabs" ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}" sf-field-model="" ui-sortable="form.sortOptions"><li sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index" ng-click="$event.preventDefault() || (selected.tab = $index)" ng-class="{active: selected.tab === $index}"><a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide="form.readonly || form.add === null" ng-disabled="form.schema.maxItems <= modelArray.length" ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)"><a href="#"><i class="glyphicon glyphicon-plus"></i> {{ form.add || \'Add\'}}</a></li></ol></div><div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}"><div class="tab-content {{form.fieldHtmlClass}}"><div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}" sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index" ng-show="selected.tab === $index" ng-class="{active: selected.tab === $index}"><div schema-form-array-items=""></div><button ng-hide="form.readonly || form.remove === null" ng-click="selected.tab = deleteFromArray($index).length - 1" ng-disabled="form.schema.minItems >= modelArray.length" type="button" class="btn {{ form.style.remove || \'btn-default\' }} pull-right"><i class="glyphicon glyphicon-trash"></i> {{ form.remove || \'Remove\'}}</button></div><div class="help-block" ng-show="(hasError() && errorMessage(schemaError())) || form.description" ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div></div></div></div><div ng-if="form.tabType === \'right\'" class="col-xs-3"><ul class="nav nav-tabs tabs-right"><li sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index" ng-click="$event.preventDefault() || (selected.tab = $index)" ng-class="{active: selected.tab === $index}"><a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide="form.readonly || form.add === null" ng-disabled="form.schema.maxItems <= modelArray.length" ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)"><a href="#"><i class="glyphicon glyphicon-plus"></i> {{ form.add || \'Add\'}}</a></li></ul></div>'),e.put("decorators/bootstrap/tabs.html",'<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{form.htmlClass}}"><ul class="nav nav-tabs"><li ng-repeat="tab in form.tabs" ng-disabled="form.readonly" ng-click="$event.preventDefault() || (selected.tab = $index)" ng-class="{active: selected.tab === $index}"><a href="#">{{ tab.title }}</a></li></ul><div class="tab-content {{form.fieldHtmlClass}}"></div></div>'),e.put("decorators/bootstrap/textarea.html",'<div class="form-group has-feedback {{form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label> <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight" class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-changed="form" placeholder="{{form.placeholder}}" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" name="{{form.key.slice(-1)[0]}}"></textarea><div ng-if="form.fieldAddonLeft || form.fieldAddonRight" ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}"><span ng-if="form.fieldAddonLeft" class="input-group-addon" ng-bind-html="form.fieldAddonLeft"></span> <textarea class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-changed="form" placeholder="{{form.placeholder}}" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" name="{{form.key.slice(-1)[0]}}"></textarea> <span ng-if="form.fieldAddonRight" class="input-group-addon" ng-bind-html="form.fieldAddonRight"></span></div><span class="help-block" sf-message="form.description"></span></div>')}]);
\ No newline at end of file
diff --git a/src/bootstrap/tabarray.html b/src/bootstrap/tabarray.html
index 1e8de1b..54f4f61 100644
--- a/src/bootstrap/tabarray.html
+++ b/src/bootstrap/tabarray.html
@@ -1,4 +1,3 @@
-
 <div ng-init="selected = { tab: 0 }"
      ng-model="modelArray" schema-validate="form"
      sf-field-model="sf-new-array"
diff --git a/src/bootstrap/tabs.html b/src/bootstrap/tabs.html
index 0a0e7b1..0950976 100644
--- a/src/bootstrap/tabs.html
+++ b/src/bootstrap/tabs.html
@@ -3,8 +3,7 @@
     <li ng-repeat="tab in form.tabs"
         ng-disabled="form.readonly"
         ng-click="$event.preventDefault() || (selected.tab = $index)"
-        ng-class="{active: selected.tab === $index}"
-        ng-if="(!tab.condition || evalExpr(tab.condition, { model: model, arrayIndex: $index}))">
+        ng-class="{active: selected.tab === $index}">
         <a href="#">{{ tab.title }}</a>
     </li>
   </ul>
diff --git a/src/module.js b/src/module.js
index 625dd1b..3f82b33 100644
--- a/src/module.js
+++ b/src/module.js
@@ -1,4 +1,2 @@
 require('../node_modules/angular-schema-form/dist/schema-form.js');
-//require('./angular-schema-form-bootstrap-templates.js');
-//require('./type-parser.js');
 require('bootstrap-decorator.js');
diff --git a/webpack.config.js b/webpack.config.js
index d37edfc..3fa2af1 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -38,7 +38,7 @@ module.exports = {
         test: /\.js$/,
         include: [ path.join(__dirname, 'src') ],
         exclude: /(node_modules)/,
-        loader: 'babel',
+        loader: 'babel-loader',
       },
       {
         test: /\.html$/,

From a8cba385f3957c0132ff6a250447e6285e41eb6b Mon Sep 17 00:00:00 2001
From: mbennett <marcel@iamserious.com>
Date: Fri, 14 Oct 2016 18:33:51 +1100
Subject: [PATCH 23/50] Make bindings one-time, still need to replace id and
 name with one-time function call

---
 package.json                                  |  6 ++++-
 ...angular-schema-form-bootstrap-templates.js | 17 -------------
 ...lar-schema-form-bootstrap-templates.min.js |  1 -
 src/bootstrap-decorator.js                    | 24 +++++++++----------
 src/bootstrap/actions-trcl.html               |  2 +-
 src/bootstrap/actions.html                    |  6 ++---
 src/bootstrap/array.html                      |  4 ++--
 src/bootstrap/checkbox.html                   |  6 ++---
 src/bootstrap/checkboxes.html                 |  6 ++---
 src/bootstrap/default.html                    | 20 ++++++++--------
 src/bootstrap/fieldset.html                   |  2 +-
 src/bootstrap/help.html                       |  2 +-
 src/bootstrap/radio-buttons.html              |  6 ++---
 src/bootstrap/radios-inline.html              |  6 ++---
 src/bootstrap/radios.html                     |  6 ++---
 src/bootstrap/section.html                    |  2 +-
 src/bootstrap/select.html                     |  6 ++---
 src/bootstrap/submit.html                     |  4 ++--
 src/bootstrap/tabarray.html                   |  4 ++--
 src/bootstrap/tabs.html                       |  4 ++--
 src/bootstrap/textarea.html                   | 12 +++++-----
 webpack.config.js                             |  4 ++--
 22 files changed, 68 insertions(+), 82 deletions(-)
 delete mode 100644 src/angular-schema-form-bootstrap-templates.js
 delete mode 100644 src/angular-schema-form-bootstrap-templates.min.js

diff --git a/package.json b/package.json
index 72214d9..1dbaf29 100644
--- a/package.json
+++ b/package.json
@@ -21,7 +21,11 @@
   ],
   "license": "MIT",
   "dependencies": {
-    "angular-schema-form": "git://github.com/json-schema-form/angular-schema-form.git#feature/webpack-babel"
+    "angular": ">= 1.2",
+    "angular-messages": "^1.5.0",
+    "angular-sanitize": ">= 1.2",
+    "angular-schema-form": "git://github.com/json-schema-form/angular-schema-form.git#feature/webpack-babel",
+    "tv4": "~1.0.15"
   },
   "devDependencies": {
     "babel-core": "^6.10.4",
diff --git a/src/angular-schema-form-bootstrap-templates.js b/src/angular-schema-form-bootstrap-templates.js
deleted file mode 100644
index 836efee..0000000
--- a/src/angular-schema-form-bootstrap-templates.js
+++ /dev/null
@@ -1,17 +0,0 @@
-angular.module("schemaForm").run(["$templateCache", function($templateCache) {$templateCache.put("decorators/bootstrap/actions-trcl.html","<div class=\"btn-group schema-form-actions {{form.htmlClass}}\" ng-transclude=\"\"></div>");
-$templateCache.put("decorators/bootstrap/actions.html","<div class=\"btn-group schema-form-actions {{form.htmlClass}}\"><input ng-repeat-start=\"item in form.items\" type=\"submit\" class=\"btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}\" value=\"{{item.title}}\" ng-if=\"item.type === \'submit\'\"> <button ng-repeat-end=\"\" class=\"btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}\" type=\"button\" ng-disabled=\"form.readonly\" ng-if=\"item.type !== \'submit\'\" ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button></div>");
-$templateCache.put("decorators/bootstrap/array.html","<div class=\"schema-form-array {{form.htmlClass}}\" sf-field-model=\"sf-new-array\" sf-new-array=\"\"><label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label><ol class=\"list-group\" sf-field-model=\"\" ui-sortable=\"form.sortOptions\"><li class=\"list-group-item {{form.fieldHtmlClass}}\" schema-form-array-items=\"\" sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\"><button ng-hide=\"form.readonly || form.remove === null\" ng-click=\"deleteFromArray($index)\" ng-disabled=\"form.schema.minItems >= modelArray.length\" style=\"position: relative; z-index: 20;\" type=\"button\" class=\"close pull-right\"><span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span></button></li></ol><div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\"><div class=\"help-block\" ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\" ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div><button ng-hide=\"form.readonly || form.add === null\" ng-click=\"appendToArray()\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" type=\"button\" class=\"btn {{ form.style.add || \'btn-default\' }} pull-right\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</button></div></div>");
-$templateCache.put("decorators/bootstrap/checkbox.html","<div class=\"checkbox schema-form-checkbox {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"{{form.labelHtmlClass}}\"><input type=\"checkbox\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" class=\"{{form.fieldHtmlClass}}\" name=\"{{form.key.slice(-1)[0]}}\"> <span ng-bind-html=\"form.title\"></span></label><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/checkboxes.html","<div sf-field-model=\"sf-new-array\" sf-new-array=\"\" class=\"form-group schema-form-checkboxes {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" sf-field-model=\"\" schema-validate=\"form\" ng-show=\"showTitle()\">{{form.title}}</label><div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\"><label><input type=\"checkbox\" ng-disabled=\"form.readonly\" sf-changed=\"form\" class=\"{{form.fieldHtmlClass}}\" ng-model=\"titleMapValues[$index]\" name=\"{{form.key.slice(-1)[0]}}\"> <span ng-bind-html=\"form.titleMap[$index].name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/default.html","<div class=\"form-group {{form.htmlClass}}\" ng-class=\"{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{\'sr-only\': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label> <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\" ng-show=\"form.key\" type=\"{{form.type}}\" step=\"any\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-field-model=\"\" ng-disabled=\"form.readonly\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\" aria-describedby=\"{{form.key.slice(-1)[0] + \'Status\'}}\"><div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\" ng-class=\"{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}\"><span ng-if=\"form.fieldAddonLeft\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonLeft\"></span> <input ng-show=\"form.key\" type=\"{{form.type}}\" step=\"any\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-field-model=\"\" ng-disabled=\"form.readonly\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\" aria-describedby=\"{{form.key.slice(-1)[0] + \'Status\'}}\"> <span ng-if=\"form.fieldAddonRight\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonRight\"></span></div><span ng-if=\"form.feedback !== false\" class=\"form-control-feedback\" ng-class=\"evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }\" aria-hidden=\"true\"></span> <span ng-if=\"hasError() || hasSuccess()\" id=\"{{form.key.slice(-1)[0] + \'Status\'}}\" class=\"sr-only\">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/fieldset.html","<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{form.htmlClass}}\"><legend ng-class=\"{\'sr-only\': !showTitle() }\">{{ form.title }}</legend><div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div></fieldset>");
-$templateCache.put("decorators/bootstrap/help.html","<div class=\"helpvalue schema-form-helpvalue {{form.htmlClass}}\" ng-bind-html=\"form.helpvalue\"></div>");
-$templateCache.put("decorators/bootstrap/radio-buttons.html","<div class=\"form-group schema-form-radiobuttons {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><div><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label></div><div class=\"btn-group\"><label sf-field-model=\"replaceAll\" class=\"btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}\" ng-class=\"{ active: item.value === $$value$$ }\" ng-repeat=\"item in form.titleMap\"><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" style=\"display: none;\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/radios-inline.html","<div class=\"form-group schema-form-radios-inline {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\" sf-field-model=\"\" schema-validate=\"form\">{{form.title}}</label><div><label class=\"radio-inline\" ng-repeat=\"item in form.titleMap\"><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/radios.html","<div class=\"form-group schema-form-radios {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" sf-field-model=\"\" schema-validate=\"form\" ng-show=\"showTitle()\">{{form.title}}</label><div class=\"radio\" ng-repeat=\"item in form.titleMap\"><label><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/section.html","<div class=\"schema-form-section {{form.htmlClass}}\"></div>");
-$templateCache.put("decorators/bootstrap/select.html","<div class=\"form-group {{form.htmlClass}} schema-form-select\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label><select sf-field-model=\"\" ng-disabled=\"form.readonly\" sf-changed=\"form\" class=\"form-control {{form.fieldHtmlClass}}\" schema-validate=\"form\" ng-options=\"item.value as item.name group by item.group for item in form.titleMap\" name=\"{{form.key.slice(-1)[0]}}\"></select><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/submit.html","<div class=\"form-group schema-form-submit {{form.htmlClass}}\"><input type=\"submit\" class=\"btn {{ form.style || \'btn-primary\' }} {{form.fieldHtmlClass}}\" value=\"{{form.title}}\" ng-disabled=\"form.readonly\" ng-if=\"form.type === \'submit\'\"> <button class=\"btn {{ form.style || \'btn-default\' }}\" type=\"button\" ng-click=\"buttonClick($event,form)\" ng-disabled=\"form.readonly\" ng-if=\"form.type !== \'submit\'\"><span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span> {{form.title}}</button></div>");
-$templateCache.put("decorators/bootstrap/tabarray.html","<div ng-init=\"selected = { tab: 0 }\" ng-model=\"modelArray\" schema-validate=\"form\" sf-field-model=\"sf-new-array\" sf-new-array=\"\" class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{form.htmlClass}}\"><div ng-if=\"!form.tabType || form.tabType !== \'right\'\" ng-class=\"{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}\"><ol class=\"nav nav-tabs\" ng-class=\"{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}\" sf-field-model=\"\" ui-sortable=\"form.sortOptions\"><li sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide=\"form.readonly || form.add === null\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\"><a href=\"#\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</a></li></ol></div><div ng-class=\"{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}\"><div class=\"tab-content {{form.fieldHtmlClass}}\"><div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\" sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-show=\"selected.tab === $index\" ng-class=\"{active: selected.tab === $index}\"><div schema-form-array-items=\"\"></div><button ng-hide=\"form.readonly || form.remove === null\" ng-click=\"selected.tab = deleteFromArray($index).length - 1\" ng-disabled=\"form.schema.minItems >= modelArray.length\" type=\"button\" class=\"btn {{ form.style.remove || \'btn-default\' }} pull-right\"><i class=\"glyphicon glyphicon-trash\"></i> {{ form.remove || \'Remove\'}}</button></div><div class=\"help-block\" ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\" ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div></div></div></div><div ng-if=\"form.tabType === \'right\'\" class=\"col-xs-3\"><ul class=\"nav nav-tabs tabs-right\"><li sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide=\"form.readonly || form.add === null\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\"><a href=\"#\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</a></li></ul></div>");
-$templateCache.put("decorators/bootstrap/tabs.html","<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{form.htmlClass}}\"><ul class=\"nav nav-tabs\"><li ng-repeat=\"tab in form.tabs\" ng-disabled=\"form.readonly\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{ tab.title }}</a></li></ul><div class=\"tab-content {{form.fieldHtmlClass}}\"></div></div>");
-$templateCache.put("decorators/bootstrap/textarea.html","<div class=\"form-group has-feedback {{form.htmlClass}} schema-form-textarea\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{\'sr-only\': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label> <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\"></textarea><div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\" ng-class=\"{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}\"><span ng-if=\"form.fieldAddonLeft\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonLeft\"></span> <textarea class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\"></textarea> <span ng-if=\"form.fieldAddonRight\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonRight\"></span></div><span class=\"help-block\" sf-message=\"form.description\"></span></div>");}]);
\ No newline at end of file
diff --git a/src/angular-schema-form-bootstrap-templates.min.js b/src/angular-schema-form-bootstrap-templates.min.js
deleted file mode 100644
index aa8b5a2..0000000
--- a/src/angular-schema-form-bootstrap-templates.min.js
+++ /dev/null
@@ -1 +0,0 @@
-angular.module("schemaForm").run(["$templateCache",function(e){e.put("decorators/bootstrap/actions-trcl.html",'<div class="btn-group schema-form-actions {{form.htmlClass}}" ng-transclude=""></div>'),e.put("decorators/bootstrap/actions.html",'<div class="btn-group schema-form-actions {{form.htmlClass}}"><input ng-repeat-start="item in form.items" type="submit" class="btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}" value="{{item.title}}" ng-if="item.type === \'submit\'"> <button ng-repeat-end="" class="btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}" type="button" ng-disabled="form.readonly" ng-if="item.type !== \'submit\'" ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button></div>'),e.put("decorators/bootstrap/array.html",'<div class="schema-form-array {{form.htmlClass}}" sf-field-model="sf-new-array" sf-new-array=""><label class="control-label" ng-show="showTitle()">{{ form.title }}</label><ol class="list-group" sf-field-model="" ui-sortable="form.sortOptions"><li class="list-group-item {{form.fieldHtmlClass}}" schema-form-array-items="" sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index"><button ng-hide="form.readonly || form.remove === null" ng-click="deleteFromArray($index)" ng-disabled="form.schema.minItems >= modelArray.length" style="position: relative; z-index: 20;" type="button" class="close pull-right"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button></li></ol><div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form"><div class="help-block" ng-show="(hasError() && errorMessage(schemaError())) || form.description" ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div><button ng-hide="form.readonly || form.add === null" ng-click="appendToArray()" ng-disabled="form.schema.maxItems <= modelArray.length" type="button" class="btn {{ form.style.add || \'btn-default\' }} pull-right"><i class="glyphicon glyphicon-plus"></i> {{ form.add || \'Add\'}}</button></div></div>'),e.put("decorators/bootstrap/checkbox.html",'<div class="checkbox schema-form-checkbox {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="{{form.labelHtmlClass}}"><input type="checkbox" sf-changed="form" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" class="{{form.fieldHtmlClass}}" name="{{form.key.slice(-1)[0]}}"> <span ng-bind-html="form.title"></span></label><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/checkboxes.html",'<div sf-field-model="sf-new-array" sf-new-array="" class="form-group schema-form-checkboxes {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" sf-field-model="" schema-validate="form" ng-show="showTitle()">{{form.title}}</label><div class="checkbox" ng-repeat="val in titleMapValues track by $index"><label><input type="checkbox" ng-disabled="form.readonly" sf-changed="form" class="{{form.fieldHtmlClass}}" ng-model="titleMapValues[$index]" name="{{form.key.slice(-1)[0]}}"> <span ng-bind-html="form.titleMap[$index].name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/default.html",'<div class="form-group {{form.htmlClass}}" ng-class="{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }"><label class="control-label {{form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label> <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight" ng-show="form.key" type="{{form.type}}" step="any" sf-changed="form" placeholder="{{form.placeholder}}" class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-field-model="" ng-disabled="form.readonly" schema-validate="form" name="{{form.key.slice(-1)[0]}}" aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}"><div ng-if="form.fieldAddonLeft || form.fieldAddonRight" ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}"><span ng-if="form.fieldAddonLeft" class="input-group-addon" ng-bind-html="form.fieldAddonLeft"></span> <input ng-show="form.key" type="{{form.type}}" step="any" sf-changed="form" placeholder="{{form.placeholder}}" class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-field-model="" ng-disabled="form.readonly" schema-validate="form" name="{{form.key.slice(-1)[0]}}" aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}"> <span ng-if="form.fieldAddonRight" class="input-group-addon" ng-bind-html="form.fieldAddonRight"></span></div><span ng-if="form.feedback !== false" class="form-control-feedback" ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }" aria-hidden="true"></span> <span ng-if="hasError() || hasSuccess()" id="{{form.key.slice(-1)[0] + \'Status\'}}" class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/fieldset.html",'<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{form.htmlClass}}"><legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend><div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div></fieldset>'),e.put("decorators/bootstrap/help.html",'<div class="helpvalue schema-form-helpvalue {{form.htmlClass}}" ng-bind-html="form.helpvalue"></div>'),e.put("decorators/bootstrap/radio-buttons.html",'<div class="form-group schema-form-radiobuttons {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><div><label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label></div><div class="btn-group"><label sf-field-model="replaceAll" class="btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}" ng-class="{ active: item.value === $$value$$ }" ng-repeat="item in form.titleMap"><input type="radio" class="{{form.fieldHtmlClass}}" sf-changed="form" style="display: none;" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" ng-value="item.value" name="{{form.key.join(\'.\')}}"> <span ng-bind-html="item.name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/radios-inline.html",'<div class="form-group schema-form-radios-inline {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()" sf-field-model="" schema-validate="form">{{form.title}}</label><div><label class="radio-inline" ng-repeat="item in form.titleMap"><input type="radio" class="{{form.fieldHtmlClass}}" sf-changed="form" ng-disabled="form.readonly" sf-field-model="" ng-value="item.value" name="{{form.key.join(\'.\')}}"> <span ng-bind-html="item.name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/radios.html",'<div class="form-group schema-form-radios {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" sf-field-model="" schema-validate="form" ng-show="showTitle()">{{form.title}}</label><div class="radio" ng-repeat="item in form.titleMap"><label><input type="radio" class="{{form.fieldHtmlClass}}" sf-changed="form" ng-disabled="form.readonly" sf-field-model="" ng-value="item.value" name="{{form.key.join(\'.\')}}"> <span ng-bind-html="item.name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/section.html",'<div class="schema-form-section {{form.htmlClass}}"></div>'),e.put("decorators/bootstrap/select.html",'<div class="form-group {{form.htmlClass}} schema-form-select" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}"><label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label><select sf-field-model="" ng-disabled="form.readonly" sf-changed="form" class="form-control {{form.fieldHtmlClass}}" schema-validate="form" ng-options="item.value as item.name group by item.group for item in form.titleMap" name="{{form.key.slice(-1)[0]}}"></select><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/submit.html",'<div class="form-group schema-form-submit {{form.htmlClass}}"><input type="submit" class="btn {{ form.style || \'btn-primary\' }} {{form.fieldHtmlClass}}" value="{{form.title}}" ng-disabled="form.readonly" ng-if="form.type === \'submit\'"> <button class="btn {{ form.style || \'btn-default\' }}" type="button" ng-click="buttonClick($event,form)" ng-disabled="form.readonly" ng-if="form.type !== \'submit\'"><span ng-if="form.icon" class="{{form.icon}}"></span> {{form.title}}</button></div>'),e.put("decorators/bootstrap/tabarray.html",'<div ng-init="selected = { tab: 0 }" ng-model="modelArray" schema-validate="form" sf-field-model="sf-new-array" sf-new-array="" class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{form.htmlClass}}"><div ng-if="!form.tabType || form.tabType !== \'right\'" ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}"><ol class="nav nav-tabs" ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}" sf-field-model="" ui-sortable="form.sortOptions"><li sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index" ng-click="$event.preventDefault() || (selected.tab = $index)" ng-class="{active: selected.tab === $index}"><a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide="form.readonly || form.add === null" ng-disabled="form.schema.maxItems <= modelArray.length" ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)"><a href="#"><i class="glyphicon glyphicon-plus"></i> {{ form.add || \'Add\'}}</a></li></ol></div><div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}"><div class="tab-content {{form.fieldHtmlClass}}"><div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}" sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index" ng-show="selected.tab === $index" ng-class="{active: selected.tab === $index}"><div schema-form-array-items=""></div><button ng-hide="form.readonly || form.remove === null" ng-click="selected.tab = deleteFromArray($index).length - 1" ng-disabled="form.schema.minItems >= modelArray.length" type="button" class="btn {{ form.style.remove || \'btn-default\' }} pull-right"><i class="glyphicon glyphicon-trash"></i> {{ form.remove || \'Remove\'}}</button></div><div class="help-block" ng-show="(hasError() && errorMessage(schemaError())) || form.description" ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div></div></div></div><div ng-if="form.tabType === \'right\'" class="col-xs-3"><ul class="nav nav-tabs tabs-right"><li sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index" ng-click="$event.preventDefault() || (selected.tab = $index)" ng-class="{active: selected.tab === $index}"><a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide="form.readonly || form.add === null" ng-disabled="form.schema.maxItems <= modelArray.length" ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)"><a href="#"><i class="glyphicon glyphicon-plus"></i> {{ form.add || \'Add\'}}</a></li></ul></div>'),e.put("decorators/bootstrap/tabs.html",'<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{form.htmlClass}}"><ul class="nav nav-tabs"><li ng-repeat="tab in form.tabs" ng-disabled="form.readonly" ng-click="$event.preventDefault() || (selected.tab = $index)" ng-class="{active: selected.tab === $index}"><a href="#">{{ tab.title }}</a></li></ul><div class="tab-content {{form.fieldHtmlClass}}"></div></div>'),e.put("decorators/bootstrap/textarea.html",'<div class="form-group has-feedback {{form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label> <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight" class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-changed="form" placeholder="{{form.placeholder}}" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" name="{{form.key.slice(-1)[0]}}"></textarea><div ng-if="form.fieldAddonLeft || form.fieldAddonRight" ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}"><span ng-if="form.fieldAddonLeft" class="input-group-addon" ng-bind-html="form.fieldAddonLeft"></span> <textarea class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-changed="form" placeholder="{{form.placeholder}}" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" name="{{form.key.slice(-1)[0]}}"></textarea> <span ng-if="form.fieldAddonRight" class="input-group-addon" ng-bind-html="form.fieldAddonRight"></span></div><span class="help-block" sf-message="form.description"></span></div>')}]);
\ No newline at end of file
diff --git a/src/bootstrap-decorator.js b/src/bootstrap-decorator.js
index cfd714f..432631d 100644
--- a/src/bootstrap-decorator.js
+++ b/src/bootstrap-decorator.js
@@ -90,26 +90,26 @@ function bootstrapDecoratorConfig(
 
   var defaults = [sfField, ngModel, ngModelOptions, condition];
   decoratorsProvider.defineDecorator('bootstrapDecorator', {
-    textarea: {template: textareaTemplate, builder: defaults},
-    fieldset: {template: fieldsetTemplate, builder: [sfField, simpleTransclusion, condition]},
-    array: {template: arrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    tabarray: {template: tabarrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    tabs: {template: tabsTemplate, builder: [sfField, ngModelOptions, tabs, condition]},
-    section: {template: sectionTemplate, builder: [sfField, simpleTransclusion, condition]},
-    conditional: {template: sectionTemplate, builder: [sfField, simpleTransclusion, condition]},
     actions: {template: actionsTemplate, builder: defaults},
-    select: {template: selectTemplate, builder: defaults.concat(selectPlaceholder)},
+    array: {template: arrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    button: {template: submitTemplate, builder: defaults},
     checkbox: {template: checkboxTemplate, builder: defaults},
     checkboxes: {template: checkboxesTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    conditional: {template: sectionTemplate, builder: [sfField, simpleTransclusion, condition]},
+    'default': {template: defaultTemplate, builder: defaults}
+    fieldset: {template: fieldsetTemplate, builder: [sfField, simpleTransclusion, condition]},
+    help: {template: helpTemplate, builder: defaults},
     number: {template: defaultTemplate, builder: defaults.concat(numeric)},
     password: {template: defaultTemplate, builder: defaults},
-    submit: {template: submitTemplate, builder: defaults},
-    button: {template: submitTemplate, builder: defaults},
     radios: {template: radiosTemplate, builder: defaults},
     'radios-inline': {template: radiosInlineTemplate, builder: defaults},
     radiobuttons: {template: radiobuttonsTemplate, builder: defaults},
-    help: {template: helpTemplate, builder: defaults},
-    'default': {template: defaultTemplate, builder: defaults}
+    section: {template: sectionTemplate, builder: [sfField, simpleTransclusion, condition]},
+    select: {template: selectTemplate, builder: defaults.concat(selectPlaceholder)},
+    submit: {template: submitTemplate, builder: defaults},
+    tabarray: {template: tabarrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    tabs: {template: tabsTemplate, builder: [sfField, ngModelOptions, tabs, condition]},
+    textarea: {template: textareaTemplate, builder: defaults},
   }, []);
 };
 
diff --git a/src/bootstrap/actions-trcl.html b/src/bootstrap/actions-trcl.html
index 0b32cbc..de33f95 100644
--- a/src/bootstrap/actions-trcl.html
+++ b/src/bootstrap/actions-trcl.html
@@ -1 +1 @@
-<div class="btn-group schema-form-actions {{form.htmlClass}}" ng-transclude></div>
+<div class="btn-group schema-form-actions {{::form.htmlClass}}" ng-transclude></div>
diff --git a/src/bootstrap/actions.html b/src/bootstrap/actions.html
index ddf0789..db0a9f3 100644
--- a/src/bootstrap/actions.html
+++ b/src/bootstrap/actions.html
@@ -1,11 +1,11 @@
-<div class="btn-group schema-form-actions {{form.htmlClass}}">
+<div class="btn-group schema-form-actions {{::form.htmlClass}}">
   <input ng-repeat-start="item in form.items"
          type="submit"
-         class="btn {{ item.style || 'btn-default' }} {{form.fieldHtmlClass}}"
+         class="btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}"
          value="{{item.title}}"
          ng-if="item.type === 'submit'">
   <button ng-repeat-end
-          class="btn {{ item.style || 'btn-default' }} {{form.fieldHtmlClass}}"
+          class="btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}"
           type="button"
           ng-disabled="form.readonly"
           ng-if="item.type !== 'submit'"
diff --git a/src/bootstrap/array.html b/src/bootstrap/array.html
index 8df5d6d..3cc6e9d 100644
--- a/src/bootstrap/array.html
+++ b/src/bootstrap/array.html
@@ -1,9 +1,9 @@
-<div  class="schema-form-array {{form.htmlClass}}"
+<div  class="schema-form-array {{::form.htmlClass}}"
       sf-field-model="sf-new-array"
       sf-new-array>
   <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>
   <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">
-    <li class="list-group-item {{form.fieldHtmlClass}}"
+    <li class="list-group-item {{::form.fieldHtmlClass}}"
         schema-form-array-items
         sf-field-model="ng-repeat"
         ng-repeat="item in $$value$$ track by $index">
diff --git a/src/bootstrap/checkbox.html b/src/bootstrap/checkbox.html
index ad382c2..bba07ef 100644
--- a/src/bootstrap/checkbox.html
+++ b/src/bootstrap/checkbox.html
@@ -1,12 +1,12 @@
-<div class="checkbox schema-form-checkbox {{form.htmlClass}}"
+<div class="checkbox schema-form-checkbox {{::form.htmlClass}}"
      ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
-  <label class="{{form.labelHtmlClass}}">
+  <label class="{{::form.labelHtmlClass}}">
     <input type="checkbox"
            sf-changed="form"
            ng-disabled="form.readonly"
            sf-field-model
            schema-validate="form"
-           class="{{form.fieldHtmlClass}}"
+           class="{{::form.fieldHtmlClass}}"
            name="{{form.key.slice(-1)[0]}}">
     <span ng-bind-html="form.title"></span>
   </label>
diff --git a/src/bootstrap/checkboxes.html b/src/bootstrap/checkboxes.html
index 10def31..1383ac7 100644
--- a/src/bootstrap/checkboxes.html
+++ b/src/bootstrap/checkboxes.html
@@ -1,8 +1,8 @@
 <div sf-field-model="sf-new-array"
      sf-new-array
-     class="form-group schema-form-checkboxes {{form.htmlClass}}"
+     class="form-group schema-form-checkboxes {{::form.htmlClass}}"
      ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
-  <label class="control-label {{form.labelHtmlClass}}"
+  <label class="control-label {{::form.labelHtmlClass}}"
          sf-field-model
          schema-validate="form"
          ng-show="showTitle()">{{form.title}}</label>
@@ -12,7 +12,7 @@
       <input type="checkbox"
              ng-disabled="form.readonly"
              sf-changed="form"
-             class="{{form.fieldHtmlClass}}"
+             class="{{::form.fieldHtmlClass}}"
              ng-model="titleMapValues[$index]"
              name="{{form.key.slice(-1)[0]}}">
       <span ng-bind-html="form.titleMap[$index].name"></span>
diff --git a/src/bootstrap/default.html b/src/bootstrap/default.html
index 86b20ad..2cbb8c0 100644
--- a/src/bootstrap/default.html
+++ b/src/bootstrap/default.html
@@ -1,14 +1,14 @@
-<div class="form-group {{form.htmlClass}}"
+<div class="form-group {{::form.htmlClass}}"
      ng-class="{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }">
-  <label class="control-label {{form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>
+  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>
 
   <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"
-         ng-show="form.key"
-         type="{{form.type}}"
+         ng-show="::form.key"
+         type="{{::form.type}}"
          step="any"
          sf-changed="form"
-         placeholder="{{form.placeholder}}"
-         class="form-control {{form.fieldHtmlClass}}"
+         placeholder="{{::form.placeholder}}"
+         class="form-control {{::form.fieldHtmlClass}}"
          id="{{form.key.slice(-1)[0]}}"
          sf-field-model
          ng-disabled="form.readonly"
@@ -21,12 +21,12 @@
     <span ng-if="form.fieldAddonLeft"
           class="input-group-addon"
           ng-bind-html="form.fieldAddonLeft"></span>
-    <input ng-show="form.key"
-           type="{{form.type}}"
+    <input ng-show="::form.key"
+           type="{{::form.type}}"
            step="any"
            sf-changed="form"
-           placeholder="{{form.placeholder}}"
-           class="form-control {{form.fieldHtmlClass}}"
+           placeholder="{{::form.placeholder}}"
+           class="form-control {{::form.fieldHtmlClass}}"
            id="{{form.key.slice(-1)[0]}}"
            sf-field-model
            ng-disabled="form.readonly"
diff --git a/src/bootstrap/fieldset.html b/src/bootstrap/fieldset.html
index 204aa5d..5eeea33 100644
--- a/src/bootstrap/fieldset.html
+++ b/src/bootstrap/fieldset.html
@@ -1,4 +1,4 @@
-<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{form.htmlClass}}">
+<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass}}">
   <legend ng-class="{'sr-only': !showTitle() }">{{ form.title }}</legend>
   <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>
 </fieldset>
diff --git a/src/bootstrap/help.html b/src/bootstrap/help.html
index aca5bb5..74e54d0 100644
--- a/src/bootstrap/help.html
+++ b/src/bootstrap/help.html
@@ -1 +1 @@
-<div class="helpvalue schema-form-helpvalue {{form.htmlClass}}" ng-bind-html="form.helpvalue"></div>
+<div class="helpvalue schema-form-helpvalue {{::form.htmlClass}}" ng-bind-html="form.helpvalue"></div>
diff --git a/src/bootstrap/radio-buttons.html b/src/bootstrap/radio-buttons.html
index c10da7c..3530342 100644
--- a/src/bootstrap/radio-buttons.html
+++ b/src/bootstrap/radio-buttons.html
@@ -1,14 +1,14 @@
-<div class="form-group schema-form-radiobuttons {{form.htmlClass}}"
+<div class="form-group schema-form-radiobuttons {{::form.htmlClass}}"
      ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
   <div>
-    <label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>
+    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>
   </div>
   <div class="btn-group">
     <label sf-field-model="replaceAll" class="btn {{ (item.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}"
            ng-class="{ active: item.value === $$value$$ }"
            ng-repeat="item in form.titleMap">
       <input type="radio"
-             class="{{form.fieldHtmlClass}}"
+             class="{{::form.fieldHtmlClass}}"
              sf-changed="form"
              style="display: none;"
              ng-disabled="form.readonly"
diff --git a/src/bootstrap/radios-inline.html b/src/bootstrap/radios-inline.html
index a4c3d5e..7b0df63 100644
--- a/src/bootstrap/radios-inline.html
+++ b/src/bootstrap/radios-inline.html
@@ -1,12 +1,12 @@
-<div class="form-group schema-form-radios-inline {{form.htmlClass}}"
+<div class="form-group schema-form-radios-inline {{::form.htmlClass}}"
      ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}">
-  <label class="control-label {{form.labelHtmlClass}}"
+  <label class="control-label {{::form.labelHtmlClass}}"
         ng-show="showTitle()" sf-field-model
         schema-validate="form" >{{form.title}}</label>
   <div>
       <label class="radio-inline" ng-repeat="item in form.titleMap" >
       <input type="radio"
-             class="{{form.fieldHtmlClass}}"
+             class="{{::form.fieldHtmlClass}}"
              sf-changed="form"
              ng-disabled="form.readonly"
              sf-field-model
diff --git a/src/bootstrap/radios.html b/src/bootstrap/radios.html
index a68997b..278715d 100644
--- a/src/bootstrap/radios.html
+++ b/src/bootstrap/radios.html
@@ -1,11 +1,11 @@
-<div class="form-group schema-form-radios {{form.htmlClass}}" ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}">
-  <label class="control-label {{form.labelHtmlClass}}"
+<div class="form-group schema-form-radios {{::form.htmlClass}}" ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}">
+  <label class="control-label {{::form.labelHtmlClass}}"
          sf-field-model schema-validate="form"
          ng-show="showTitle()">{{form.title}}</label>
   <div class="radio" ng-repeat="item in form.titleMap">
     <label>
       <input type="radio"
-             class="{{form.fieldHtmlClass}}"
+             class="{{::form.fieldHtmlClass}}"
              sf-changed="form"
              ng-disabled="form.readonly"
              sf-field-model
diff --git a/src/bootstrap/section.html b/src/bootstrap/section.html
index ba95ae9..ac37169 100644
--- a/src/bootstrap/section.html
+++ b/src/bootstrap/section.html
@@ -1 +1 @@
-<div class="schema-form-section {{form.htmlClass}}"></div>
+<div class="schema-form-section {{::form.htmlClass}}"></div>
diff --git a/src/bootstrap/select.html b/src/bootstrap/select.html
index 2949dda..fb1e6dd 100644
--- a/src/bootstrap/select.html
+++ b/src/bootstrap/select.html
@@ -1,12 +1,12 @@
-<div class="form-group {{form.htmlClass}} schema-form-select"
+<div class="form-group {{::form.htmlClass}} schema-form-select"
      ng-class="{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}">
-  <label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()">
+  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">
     {{form.title}}
   </label>
   <select sf-field-model
           ng-disabled="form.readonly"
           sf-changed="form"
-          class="form-control {{form.fieldHtmlClass}}"
+          class="form-control {{::form.fieldHtmlClass}}"
           schema-validate="form"
           ng-options="item.value as item.name group by item.group for item in form.titleMap"
           name="{{form.key.slice(-1)[0]}}">
diff --git a/src/bootstrap/submit.html b/src/bootstrap/submit.html
index f2b6661..1a0b43b 100644
--- a/src/bootstrap/submit.html
+++ b/src/bootstrap/submit.html
@@ -1,6 +1,6 @@
-<div class="form-group schema-form-submit {{form.htmlClass}}">
+<div class="form-group schema-form-submit {{::form.htmlClass}}">
   <input type="submit"
-         class="btn {{ form.style || 'btn-primary' }} {{form.fieldHtmlClass}}"
+         class="btn {{ form.style || 'btn-primary' }} {{::form.fieldHtmlClass}}"
          value="{{form.title}}"
          ng-disabled="form.readonly"
          ng-if="form.type === 'submit'">
diff --git a/src/bootstrap/tabarray.html b/src/bootstrap/tabarray.html
index 1e8de1b..ba3e399 100644
--- a/src/bootstrap/tabarray.html
+++ b/src/bootstrap/tabarray.html
@@ -3,7 +3,7 @@
      ng-model="modelArray" schema-validate="form"
      sf-field-model="sf-new-array"
      sf-new-array
-     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{form.htmlClass}}">
+     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{::form.htmlClass}}">
   <div ng-if="!form.tabType || form.tabType !== 'right'"
        ng-class="{'col-xs-3': !form.tabType || form.tabType === 'left'}">
     <ol class="nav nav-tabs"
@@ -27,7 +27,7 @@
   </div>
 
   <div ng-class="{'col-xs-9': !form.tabType || form.tabType === 'left' || form.tabType === 'right'}">
-    <div class="tab-content {{form.fieldHtmlClass}}">
+    <div class="tab-content {{::form.fieldHtmlClass}}">
       <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"
            sf-field-model="ng-repeat"
            ng-repeat="item in $$value$$ track by $index"
diff --git a/src/bootstrap/tabs.html b/src/bootstrap/tabs.html
index 0a0e7b1..935b0fe 100644
--- a/src/bootstrap/tabs.html
+++ b/src/bootstrap/tabs.html
@@ -1,4 +1,4 @@
-<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{form.htmlClass}}">
+<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass}}">
   <ul class="nav nav-tabs">
     <li ng-repeat="tab in form.tabs"
         ng-disabled="form.readonly"
@@ -9,6 +9,6 @@
     </li>
   </ul>
 
-  <div class="tab-content {{form.fieldHtmlClass}}">
+  <div class="tab-content {{::form.fieldHtmlClass}}">
   </div>
 </div>
diff --git a/src/bootstrap/textarea.html b/src/bootstrap/textarea.html
index a87745e..5af5b65 100644
--- a/src/bootstrap/textarea.html
+++ b/src/bootstrap/textarea.html
@@ -1,11 +1,11 @@
-<div class="form-group has-feedback {{form.htmlClass}} schema-form-textarea" ng-class="{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
-  <label class="control-label {{form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>
+<div class="form-group has-feedback {{::form.htmlClass}} schema-form-textarea" ng-class="{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
+  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>
 
   <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"
-            class="form-control {{form.fieldHtmlClass}}"
+            class="form-control {{::form.fieldHtmlClass}}"
             id="{{form.key.slice(-1)[0]}}"
             sf-changed="form"
-            placeholder="{{form.placeholder}}"
+            placeholder="{{::form.placeholder}}"
             ng-disabled="form.readonly"
             sf-field-model
             schema-validate="form"
@@ -16,10 +16,10 @@
     <span ng-if="form.fieldAddonLeft"
           class="input-group-addon"
           ng-bind-html="form.fieldAddonLeft"></span>
-    <textarea class="form-control {{form.fieldHtmlClass}}"
+    <textarea class="form-control {{::form.fieldHtmlClass}}"
               id="{{form.key.slice(-1)[0]}}"
               sf-changed="form"
-              placeholder="{{form.placeholder}}"
+              placeholder="{{::form.placeholder}}"
               ng-disabled="form.readonly"
               sf-field-model
               schema-validate="form"
diff --git a/webpack.config.js b/webpack.config.js
index d37edfc..70130a5 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -1,9 +1,9 @@
 /* global __dirname */
+//const ngAnnotatePlugin = require('ng-annotate-webpack-plugin');
+//const ExtractTextPlugin = require('extract-text-webpack-plugin');
 const webpack = require('webpack');
 const path = require('path');
-//const ngAnnotatePlugin = require('ng-annotate-webpack-plugin');
 const HtmlWebpackPlugin = require('html-webpack-plugin');
-//const ExtractTextPlugin = require('extract-text-webpack-plugin');
 const getPath = (pathToFile) => path.resolve(__dirname, pathToFile);
 const pjson = require('./package.json');
 console.log('Angular Schema Form Bootstrap v' + pjson.version);

From c90d686f0f963586a13d556ccc1ce8e38fd8cb69 Mon Sep 17 00:00:00 2001
From: mbennett <marcel@iamserious.com>
Date: Fri, 14 Oct 2016 18:37:10 +1100
Subject: [PATCH 24/50] Copy change from Merge pull request #28 from
 @paulmorrishill/develop

---
 src/bootstrap/textarea.html | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/bootstrap/textarea.html b/src/bootstrap/textarea.html
index 5af5b65..37f60de 100644
--- a/src/bootstrap/textarea.html
+++ b/src/bootstrap/textarea.html
@@ -5,7 +5,7 @@
             class="form-control {{::form.fieldHtmlClass}}"
             id="{{form.key.slice(-1)[0]}}"
             sf-changed="form"
-            placeholder="{{::form.placeholder}}"
+            ng-attr-placeholder="{{::form.placeholder}}"
             ng-disabled="form.readonly"
             sf-field-model
             schema-validate="form"
@@ -19,7 +19,7 @@
     <textarea class="form-control {{::form.fieldHtmlClass}}"
               id="{{form.key.slice(-1)[0]}}"
               sf-changed="form"
-              placeholder="{{::form.placeholder}}"
+              ng-attr-placeholder="{{::form.placeholder}}"
               ng-disabled="form.readonly"
               sf-field-model
               schema-validate="form"

From 109c5ddd8cfec3915ad8df3362396c64570fe4dd Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Mon, 17 Oct 2016 09:43:15 +1100
Subject: [PATCH 25/50] Array template change, needs application in tabarray
 also

---
 src/bootstrap/array.html | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bootstrap/array.html b/src/bootstrap/array.html
index 8df5d6d..8e6ce48 100644
--- a/src/bootstrap/array.html
+++ b/src/bootstrap/array.html
@@ -4,7 +4,6 @@
   <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>
   <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">
     <li class="list-group-item {{form.fieldHtmlClass}}"
-        schema-form-array-items
         sf-field-model="ng-repeat"
         ng-repeat="item in $$value$$ track by $index">
       <button ng-hide="form.readonly || form.remove === null"
@@ -14,6 +13,7 @@
               type="button" class="close pull-right">
               <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>
       </button>
+      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join('][')}}]" sf-index="{{$index}}"></div>
     </li>
   </ol>
   <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">

From 3824db6114fb0da6a3ad086894a7f574f3a704ba Mon Sep 17 00:00:00 2001
From: mbennett <marcel@iamserious.com>
Date: Mon, 17 Oct 2016 19:51:36 +1100
Subject: [PATCH 26/50] Started to look at tab array, needs more work

---
 src/bootstrap/tabarray.html | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bootstrap/tabarray.html b/src/bootstrap/tabarray.html
index f5da6ae..1d56088 100644
--- a/src/bootstrap/tabarray.html
+++ b/src/bootstrap/tabarray.html
@@ -33,7 +33,7 @@
            ng-show="selected.tab === $index"
            ng-class="{active: selected.tab === $index}">
 
-           <div schema-form-array-items></div>
+           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join('][')}}]" sf-index="{{$index}}"></div>
 
            <button ng-hide="form.readonly || form.remove === null"
                    ng-click="selected.tab = deleteFromArray($index).length - 1"

From e324ca7e1fd80895c97131f1b6297cb0467d6358 Mon Sep 17 00:00:00 2001
From: mbennett <marcel@iamserious.com>
Date: Wed, 19 Oct 2016 18:01:52 +1100
Subject: [PATCH 27/50] Generate bundled and unbundled, only bundled has been
 tested at all

---
 bootstrap-decorator.js                        |   72 -
 bootstrap-decorator.min.js                    |    1 -
 ...gular-schema-form-bootstrap-bundled.min.js |   23 +
 dist/angular-schema-form-bootstrap.js         | 3737 +----------------
 dist/angular-schema-form-bootstrap.min.js     |   18 +-
 package.json                                  |    7 +-
 src/bootstrap-decorator.js                    |    2 +-
 src/module-bundled.js                         |    2 +
 src/module.js                                 |    1 -
 webpack.config.js                             |   20 +-
 10 files changed, 102 insertions(+), 3781 deletions(-)
 delete mode 100644 bootstrap-decorator.js
 delete mode 100644 bootstrap-decorator.min.js
 create mode 100644 dist/angular-schema-form-bootstrap-bundled.min.js
 create mode 100644 src/module-bundled.js

diff --git a/bootstrap-decorator.js b/bootstrap-decorator.js
deleted file mode 100644
index 76c52f9..0000000
--- a/bootstrap-decorator.js
+++ /dev/null
@@ -1,72 +0,0 @@
-angular.module("schemaForm").run(["$templateCache", function($templateCache) {$templateCache.put("decorators/bootstrap/actions-trcl.html","<div class=\"btn-group schema-form-actions {{form.htmlClass}}\" ng-transclude=\"\"></div>");
-$templateCache.put("decorators/bootstrap/actions.html","<div class=\"btn-group schema-form-actions {{form.htmlClass}}\"><input ng-repeat-start=\"item in form.items\" type=\"submit\" class=\"btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}\" value=\"{{item.title}}\" ng-if=\"item.type === \'submit\'\"> <button ng-repeat-end=\"\" class=\"btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}\" type=\"button\" ng-disabled=\"form.readonly\" ng-if=\"item.type !== \'submit\'\" ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button></div>");
-$templateCache.put("decorators/bootstrap/array.html","<div class=\"schema-form-array {{form.htmlClass}}\" sf-field-model=\"sf-new-array\" sf-new-array=\"\"><label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label><ol class=\"list-group\" sf-field-model=\"\" ui-sortable=\"form.sortOptions\"><li class=\"list-group-item {{form.fieldHtmlClass}}\" schema-form-array-items=\"\" sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\"><button ng-hide=\"form.readonly || form.remove === null\" ng-click=\"deleteFromArray($index)\" ng-disabled=\"form.schema.minItems >= modelArray.length\" style=\"position: relative; z-index: 20;\" type=\"button\" class=\"close pull-right\"><span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span></button></li></ol><div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\"><div class=\"help-block\" ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\" ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div><button ng-hide=\"form.readonly || form.add === null\" ng-click=\"appendToArray()\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" type=\"button\" class=\"btn {{ form.style.add || \'btn-default\' }} pull-right\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</button></div></div>");
-$templateCache.put("decorators/bootstrap/checkbox.html","<div class=\"checkbox schema-form-checkbox {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"{{form.labelHtmlClass}}\"><input type=\"checkbox\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" class=\"{{form.fieldHtmlClass}}\" name=\"{{form.key.slice(-1)[0]}}\"> <span ng-bind-html=\"form.title\"></span></label><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/checkboxes.html","<div sf-field-model=\"sf-new-array\" sf-new-array=\"\" class=\"form-group schema-form-checkboxes {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" sf-field-model=\"\" schema-validate=\"form\" ng-show=\"showTitle()\">{{form.title}}</label><div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\"><label><input type=\"checkbox\" ng-disabled=\"form.readonly\" sf-changed=\"form\" class=\"{{form.fieldHtmlClass}}\" ng-model=\"titleMapValues[$index]\" name=\"{{form.key.slice(-1)[0]}}\"> <span ng-bind-html=\"form.titleMap[$index].name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/default.html","<div class=\"form-group schema-form-{{form.type}} {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{\'sr-only\': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label> <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\" ng-show=\"form.key\" type=\"{{form.type}}\" step=\"any\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-field-model=\"\" ng-disabled=\"form.readonly\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\" aria-describedby=\"{{form.key.slice(-1)[0] + \'Status\'}}\"><div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\" ng-class=\"{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}\"><span ng-if=\"form.fieldAddonLeft\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonLeft\"></span> <input ng-show=\"form.key\" type=\"{{form.type}}\" step=\"any\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-field-model=\"\" ng-disabled=\"form.readonly\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\" aria-describedby=\"{{form.key.slice(-1)[0] + \'Status\'}}\"> <span ng-if=\"form.fieldAddonRight\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonRight\"></span></div><span ng-if=\"form.feedback !== false\" class=\"form-control-feedback\" ng-class=\"evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': hasSuccess(), \'glyphicon-remove\': hasError() }\" aria-hidden=\"true\"></span> <span ng-if=\"hasError() || hasSuccess()\" id=\"{{form.key.slice(-1)[0] + \'Status\'}}\" class=\"sr-only\">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/fieldset.html","<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{form.htmlClass}}\"><legend ng-class=\"{\'sr-only\': !showTitle() }\">{{ form.title }}</legend><div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div></fieldset>");
-$templateCache.put("decorators/bootstrap/help.html","<div class=\"helpvalue schema-form-helpvalue {{form.htmlClass}}\" ng-bind-html=\"form.helpvalue\"></div>");
-$templateCache.put("decorators/bootstrap/radio-buttons.html","<div class=\"form-group schema-form-radiobuttons {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><div><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label></div><div class=\"btn-group\"><label sf-field-model=\"replaceAll\" class=\"btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}\" ng-class=\"{ active: item.value === $$value$$ }\" ng-repeat=\"item in form.titleMap\"><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" style=\"display: none;\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/radios-inline.html","<div class=\"form-group schema-form-radios-inline {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\" sf-field-model=\"\" schema-validate=\"form\">{{form.title}}</label><div><label class=\"radio-inline\" ng-repeat=\"item in form.titleMap\"><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/radios.html","<div class=\"form-group schema-form-radios {{form.htmlClass}}\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" sf-field-model=\"\" schema-validate=\"form\" ng-show=\"showTitle()\">{{form.title}}</label><div class=\"radio\" ng-repeat=\"item in form.titleMap\"><label><input type=\"radio\" class=\"{{form.fieldHtmlClass}}\" sf-changed=\"form\" ng-disabled=\"form.readonly\" sf-field-model=\"\" ng-value=\"item.value\" name=\"{{form.key.join(\'.\')}}\"> <span ng-bind-html=\"item.name\"></span></label></div><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/section.html","<div class=\"schema-form-section {{form.htmlClass}}\"></div>");
-$templateCache.put("decorators/bootstrap/select.html","<div class=\"form-group {{form.htmlClass}} schema-form-select\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label><select sf-field-model=\"\" ng-disabled=\"form.readonly\" sf-changed=\"form\" class=\"form-control {{form.fieldHtmlClass}}\" schema-validate=\"form\" ng-options=\"item.value as item.name group by item.group for item in form.titleMap\" name=\"{{form.key.slice(-1)[0]}}\"></select><div class=\"help-block\" sf-message=\"form.description\"></div></div>");
-$templateCache.put("decorators/bootstrap/submit.html","<div class=\"form-group schema-form-submit {{form.htmlClass}}\"><input type=\"submit\" class=\"btn {{ form.style || \'btn-primary\' }} {{form.fieldHtmlClass}}\" value=\"{{form.title}}\" ng-disabled=\"form.readonly\" ng-if=\"form.type === \'submit\'\"> <button class=\"btn {{ form.style || \'btn-default\' }}\" type=\"button\" ng-click=\"buttonClick($event,form)\" ng-disabled=\"form.readonly\" ng-if=\"form.type !== \'submit\'\"><span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span> {{form.title}}</button></div>");
-$templateCache.put("decorators/bootstrap/tabarray.html","<div ng-init=\"selected = { tab: 0 }\" ng-model=\"modelArray\" schema-validate=\"form\" sf-field-model=\"sf-new-array\" sf-new-array=\"\" class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{form.htmlClass}}\"><div ng-if=\"!form.tabType || form.tabType !== \'right\'\" ng-class=\"{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}\"><ul class=\"nav nav-tabs\" ng-class=\"{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}\"><li sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide=\"form.readonly\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\"><a href=\"#\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</a></li></ul></div><div ng-class=\"{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}\"><div class=\"tab-content {{form.fieldHtmlClass}}\"><div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\" sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-show=\"selected.tab === $index\" ng-class=\"{active: selected.tab === $index}\"><div schema-form-array-items=\"\"></div><button ng-hide=\"form.readonly\" ng-click=\"selected.tab = deleteFromArray($index).length - 1\" ng-disabled=\"form.schema.minItems >= modelArray.length\" type=\"button\" class=\"btn {{ form.style.remove || \'btn-default\' }} pull-right\"><i class=\"glyphicon glyphicon-trash\"></i> {{ form.remove || \'Remove\'}}</button></div><div class=\"help-block\" ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\" ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div></div></div></div><div ng-if=\"form.tabType === \'right\'\" class=\"col-xs-3\"><ul class=\"nav nav-tabs tabs-right\"><li sf-field-model=\"ng-repeat\" ng-repeat=\"item in $$value$$ track by $index\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide=\"form.readonly\" ng-disabled=\"form.schema.maxItems <= modelArray.length\" ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\"><a href=\"#\"><i class=\"glyphicon glyphicon-plus\"></i> {{ form.add || \'Add\'}}</a></li></ul></div>");
-$templateCache.put("decorators/bootstrap/tabs.html","<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{form.htmlClass}}\"><ul class=\"nav nav-tabs\"><li ng-repeat=\"tab in form.tabs\" ng-disabled=\"form.readonly\" ng-click=\"$event.preventDefault() || (selected.tab = $index)\" ng-class=\"{active: selected.tab === $index}\"><a href=\"#\">{{ tab.title }}</a></li></ul><div class=\"tab-content {{form.fieldHtmlClass}}\"></div></div>");
-$templateCache.put("decorators/bootstrap/textarea.html","<div class=\"form-group has-feedback {{form.htmlClass}} schema-form-textarea\" ng-class=\"{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}\"><label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{\'sr-only\': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label> <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\" class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\"></textarea><div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\" ng-class=\"{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}\"><span ng-if=\"form.fieldAddonLeft\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonLeft\"></span> <textarea class=\"form-control {{form.fieldHtmlClass}}\" id=\"{{form.key.slice(-1)[0]}}\" sf-changed=\"form\" placeholder=\"{{form.placeholder}}\" ng-disabled=\"form.readonly\" sf-field-model=\"\" schema-validate=\"form\" name=\"{{form.key.slice(-1)[0]}}\"></textarea> <span ng-if=\"form.fieldAddonRight\" class=\"input-group-addon\" ng-bind-html=\"form.fieldAddonRight\"></span></div><span class=\"help-block\" sf-message=\"form.description\"></span></div>");}]);
-angular.module('schemaForm').config(['schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider',
-function(decoratorsProvider, sfBuilderProvider, sfPathProvider) {
-  var base = 'decorators/bootstrap/';
-
-  var simpleTransclusion  = sfBuilderProvider.builders.simpleTransclusion;
-  var ngModelOptions      = sfBuilderProvider.builders.ngModelOptions;
-  var ngModel             = sfBuilderProvider.builders.ngModel;
-  var sfField             = sfBuilderProvider.builders.sfField;
-  var condition           = sfBuilderProvider.builders.condition;
-  var array               = sfBuilderProvider.builders.array;
-
-  // Tabs is so bootstrap specific that it stays here.
-  var tabs = function(args) {
-    if (args.form.tabs && args.form.tabs.length > 0) {
-      var tabContent = args.fieldFrag.querySelector('.tab-content');
-
-      args.form.tabs.forEach(function(tab, index) {
-        var div = document.createElement('div');
-        div.className = 'tab-pane';
-        div.setAttribute('ng-disabled', 'form.readonly');
-        div.setAttribute('ng-show', 'selected.tab === ' + index);
-        div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
-
-        var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
-        div.appendChild(childFrag);
-        tabContent.appendChild(div);
-      });
-    }
-  };
-
-  var defaults = [sfField, ngModel, ngModelOptions, condition];
-  decoratorsProvider.defineDecorator('bootstrapDecorator', {
-    textarea: {template: base + 'textarea.html', builder: defaults},
-    fieldset: {template: base + 'fieldset.html', builder: [sfField, simpleTransclusion, condition]},
-    array: {template: base + 'array.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    tabarray: {template: base + 'tabarray.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    tabs: {template: base + 'tabs.html', builder: [sfField, ngModelOptions, tabs, condition]},
-    section: {template: base + 'section.html', builder: [sfField, simpleTransclusion, condition]},
-    conditional: {template: base + 'section.html', builder: [sfField, simpleTransclusion, condition]},
-    actions: {template: base + 'actions.html', builder: defaults},
-    select: {template: base + 'select.html', builder: defaults},
-    checkbox: {template: base + 'checkbox.html', builder: defaults},
-    checkboxes: {template: base + 'checkboxes.html', builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    number: {template: base + 'default.html', builder: defaults},
-    password: {template: base + 'default.html', builder: defaults},
-    submit: {template: base + 'submit.html', builder: defaults},
-    button: {template: base + 'submit.html', builder: defaults},
-    radios: {template: base + 'radios.html', builder: defaults},
-    'radios-inline': {template: base + 'radios-inline.html', builder: defaults},
-    radiobuttons: {template: base + 'radio-buttons.html', builder: defaults},
-    help: {template: base + 'help.html', builder: defaults},
-    'default': {template: base + 'default.html', builder: defaults}
-  }, []);
-
-}]);
diff --git a/bootstrap-decorator.min.js b/bootstrap-decorator.min.js
deleted file mode 100644
index 4057913..0000000
--- a/bootstrap-decorator.min.js
+++ /dev/null
@@ -1 +0,0 @@
-angular.module("schemaForm").run(["$templateCache",function(e){e.put("decorators/bootstrap/actions-trcl.html",'<div class="btn-group schema-form-actions {{form.htmlClass}}" ng-transclude=""></div>'),e.put("decorators/bootstrap/actions.html",'<div class="btn-group schema-form-actions {{form.htmlClass}}"><input ng-repeat-start="item in form.items" type="submit" class="btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}" value="{{item.title}}" ng-if="item.type === \'submit\'"> <button ng-repeat-end="" class="btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}" type="button" ng-disabled="form.readonly" ng-if="item.type !== \'submit\'" ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button></div>'),e.put("decorators/bootstrap/array.html",'<div class="schema-form-array {{form.htmlClass}}" sf-field-model="sf-new-array" sf-new-array=""><label class="control-label" ng-show="showTitle()">{{ form.title }}</label><ol class="list-group" sf-field-model="" ui-sortable="form.sortOptions"><li class="list-group-item {{form.fieldHtmlClass}}" schema-form-array-items="" sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index"><button ng-hide="form.readonly || form.remove === null" ng-click="deleteFromArray($index)" ng-disabled="form.schema.minItems >= modelArray.length" style="position: relative; z-index: 20;" type="button" class="close pull-right"><span aria-hidden="true">&times;</span><span class="sr-only">Close</span></button></li></ol><div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form"><div class="help-block" ng-show="(hasError() && errorMessage(schemaError())) || form.description" ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div><button ng-hide="form.readonly || form.add === null" ng-click="appendToArray()" ng-disabled="form.schema.maxItems <= modelArray.length" type="button" class="btn {{ form.style.add || \'btn-default\' }} pull-right"><i class="glyphicon glyphicon-plus"></i> {{ form.add || \'Add\'}}</button></div></div>'),e.put("decorators/bootstrap/checkbox.html",'<div class="checkbox schema-form-checkbox {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="{{form.labelHtmlClass}}"><input type="checkbox" sf-changed="form" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" class="{{form.fieldHtmlClass}}" name="{{form.key.slice(-1)[0]}}"> <span ng-bind-html="form.title"></span></label><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/checkboxes.html",'<div sf-field-model="sf-new-array" sf-new-array="" class="form-group schema-form-checkboxes {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" sf-field-model="" schema-validate="form" ng-show="showTitle()">{{form.title}}</label><div class="checkbox" ng-repeat="val in titleMapValues track by $index"><label><input type="checkbox" ng-disabled="form.readonly" sf-changed="form" class="{{form.fieldHtmlClass}}" ng-model="titleMapValues[$index]" name="{{form.key.slice(-1)[0]}}"> <span ng-bind-html="form.titleMap[$index].name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/default.html",'<div class="form-group schema-form-{{form.type}} {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }"><label class="control-label {{form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label> <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight" ng-show="form.key" type="{{form.type}}" step="any" sf-changed="form" placeholder="{{form.placeholder}}" class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-field-model="" ng-disabled="form.readonly" schema-validate="form" name="{{form.key.slice(-1)[0]}}" aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}"><div ng-if="form.fieldAddonLeft || form.fieldAddonRight" ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}"><span ng-if="form.fieldAddonLeft" class="input-group-addon" ng-bind-html="form.fieldAddonLeft"></span> <input ng-show="form.key" type="{{form.type}}" step="any" sf-changed="form" placeholder="{{form.placeholder}}" class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-field-model="" ng-disabled="form.readonly" schema-validate="form" name="{{form.key.slice(-1)[0]}}" aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}"> <span ng-if="form.fieldAddonRight" class="input-group-addon" ng-bind-html="form.fieldAddonRight"></span></div><span ng-if="form.feedback !== false" class="form-control-feedback" ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': hasSuccess(), \'glyphicon-remove\': hasError() }" aria-hidden="true"></span> <span ng-if="hasError() || hasSuccess()" id="{{form.key.slice(-1)[0] + \'Status\'}}" class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/fieldset.html",'<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{form.htmlClass}}"><legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend><div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div></fieldset>'),e.put("decorators/bootstrap/help.html",'<div class="helpvalue schema-form-helpvalue {{form.htmlClass}}" ng-bind-html="form.helpvalue"></div>'),e.put("decorators/bootstrap/radio-buttons.html",'<div class="form-group schema-form-radiobuttons {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><div><label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label></div><div class="btn-group"><label sf-field-model="replaceAll" class="btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}" ng-class="{ active: item.value === $$value$$ }" ng-repeat="item in form.titleMap"><input type="radio" class="{{form.fieldHtmlClass}}" sf-changed="form" style="display: none;" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" ng-value="item.value" name="{{form.key.join(\'.\')}}"> <span ng-bind-html="item.name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/radios-inline.html",'<div class="form-group schema-form-radios-inline {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()" sf-field-model="" schema-validate="form">{{form.title}}</label><div><label class="radio-inline" ng-repeat="item in form.titleMap"><input type="radio" class="{{form.fieldHtmlClass}}" sf-changed="form" ng-disabled="form.readonly" sf-field-model="" ng-value="item.value" name="{{form.key.join(\'.\')}}"> <span ng-bind-html="item.name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/radios.html",'<div class="form-group schema-form-radios {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" sf-field-model="" schema-validate="form" ng-show="showTitle()">{{form.title}}</label><div class="radio" ng-repeat="item in form.titleMap"><label><input type="radio" class="{{form.fieldHtmlClass}}" sf-changed="form" ng-disabled="form.readonly" sf-field-model="" ng-value="item.value" name="{{form.key.join(\'.\')}}"> <span ng-bind-html="item.name"></span></label></div><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/section.html",'<div class="schema-form-section {{form.htmlClass}}"></div>'),e.put("decorators/bootstrap/select.html",'<div class="form-group {{form.htmlClass}} schema-form-select" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}"><label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label><select sf-field-model="" ng-disabled="form.readonly" sf-changed="form" class="form-control {{form.fieldHtmlClass}}" schema-validate="form" ng-options="item.value as item.name group by item.group for item in form.titleMap" name="{{form.key.slice(-1)[0]}}"></select><div class="help-block" sf-message="form.description"></div></div>'),e.put("decorators/bootstrap/submit.html",'<div class="form-group schema-form-submit {{form.htmlClass}}"><input type="submit" class="btn {{ form.style || \'btn-primary\' }} {{form.fieldHtmlClass}}" value="{{form.title}}" ng-disabled="form.readonly" ng-if="form.type === \'submit\'"> <button class="btn {{ form.style || \'btn-default\' }}" type="button" ng-click="buttonClick($event,form)" ng-disabled="form.readonly" ng-if="form.type !== \'submit\'"><span ng-if="form.icon" class="{{form.icon}}"></span> {{form.title}}</button></div>'),e.put("decorators/bootstrap/tabarray.html",'<div ng-init="selected = { tab: 0 }" ng-model="modelArray" schema-validate="form" sf-field-model="sf-new-array" sf-new-array="" class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{form.htmlClass}}"><div ng-if="!form.tabType || form.tabType !== \'right\'" ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}"><ul class="nav nav-tabs" ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"><li sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index" ng-click="$event.preventDefault() || (selected.tab = $index)" ng-class="{active: selected.tab === $index}"><a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide="form.readonly" ng-disabled="form.schema.maxItems <= modelArray.length" ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)"><a href="#"><i class="glyphicon glyphicon-plus"></i> {{ form.add || \'Add\'}}</a></li></ul></div><div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}"><div class="tab-content {{form.fieldHtmlClass}}"><div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}" sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index" ng-show="selected.tab === $index" ng-class="{active: selected.tab === $index}"><div schema-form-array-items=""></div><button ng-hide="form.readonly" ng-click="selected.tab = deleteFromArray($index).length - 1" ng-disabled="form.schema.minItems >= modelArray.length" type="button" class="btn {{ form.style.remove || \'btn-default\' }} pull-right"><i class="glyphicon glyphicon-trash"></i> {{ form.remove || \'Remove\'}}</button></div><div class="help-block" ng-show="(hasError() && errorMessage(schemaError())) || form.description" ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div></div></div></div><div ng-if="form.tabType === \'right\'" class="col-xs-3"><ul class="nav nav-tabs tabs-right"><li sf-field-model="ng-repeat" ng-repeat="item in $$value$$ track by $index" ng-click="$event.preventDefault() || (selected.tab = $index)" ng-class="{active: selected.tab === $index}"><a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a></li><li ng-hide="form.readonly" ng-disabled="form.schema.maxItems <= modelArray.length" ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)"><a href="#"><i class="glyphicon glyphicon-plus"></i> {{ form.add || \'Add\'}}</a></li></ul></div>'),e.put("decorators/bootstrap/tabs.html",'<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{form.htmlClass}}"><ul class="nav nav-tabs"><li ng-repeat="tab in form.tabs" ng-disabled="form.readonly" ng-click="$event.preventDefault() || (selected.tab = $index)" ng-class="{active: selected.tab === $index}"><a href="#">{{ tab.title }}</a></li></ul><div class="tab-content {{form.fieldHtmlClass}}"></div></div>'),e.put("decorators/bootstrap/textarea.html",'<div class="form-group has-feedback {{form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}"><label class="control-label {{form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label> <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight" class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-changed="form" placeholder="{{form.placeholder}}" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" name="{{form.key.slice(-1)[0]}}"></textarea><div ng-if="form.fieldAddonLeft || form.fieldAddonRight" ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}"><span ng-if="form.fieldAddonLeft" class="input-group-addon" ng-bind-html="form.fieldAddonLeft"></span> <textarea class="form-control {{form.fieldHtmlClass}}" id="{{form.key.slice(-1)[0]}}" sf-changed="form" placeholder="{{form.placeholder}}" ng-disabled="form.readonly" sf-field-model="" schema-validate="form" name="{{form.key.slice(-1)[0]}}"></textarea> <span ng-if="form.fieldAddonRight" class="input-group-addon" ng-bind-html="form.fieldAddonRight"></span></div><span class="help-block" sf-message="form.description"></span></div>')}]),angular.module("schemaForm").config(["schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider",function(e,l,s){var a="decorators/bootstrap/",t=l.builders.simpleTransclusion,r=l.builders.ngModelOptions,o=l.builders.ngModel,i=l.builders.sfField,d=l.builders.condition,m=l.builders.array,n=function(e){if(e.form.tabs&&e.form.tabs.length>0){var l=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(s,a){var t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}");var r=e.build(s.items,e.path+".tabs["+a+"].items",e.state);t.appendChild(r),l.appendChild(t)})}},f=[i,o,r,d];e.defineDecorator("bootstrapDecorator",{textarea:{template:a+"textarea.html",builder:f},fieldset:{template:a+"fieldset.html",builder:[i,t,d]},array:{template:a+"array.html",builder:[i,r,o,m,d]},tabarray:{template:a+"tabarray.html",builder:[i,r,o,m,d]},tabs:{template:a+"tabs.html",builder:[i,r,n,d]},section:{template:a+"section.html",builder:[i,t,d]},conditional:{template:a+"section.html",builder:[i,t,d]},actions:{template:a+"actions.html",builder:f},select:{template:a+"select.html",builder:f},checkbox:{template:a+"checkbox.html",builder:f},checkboxes:{template:a+"checkboxes.html",builder:[i,r,o,m,d]},number:{template:a+"default.html",builder:f},password:{template:a+"default.html",builder:f},submit:{template:a+"submit.html",builder:f},button:{template:a+"submit.html",builder:f},radios:{template:a+"radios.html",builder:f},"radios-inline":{template:a+"radios-inline.html",builder:f},radiobuttons:{template:a+"radio-buttons.html",builder:f},help:{template:a+"help.html",builder:f},"default":{template:a+"default.html",builder:f}},[])}]);
\ No newline at end of file
diff --git a/dist/angular-schema-form-bootstrap-bundled.min.js b/dist/angular-schema-form-bootstrap-bundled.min.js
new file mode 100644
index 0000000..04d148b
--- /dev/null
+++ b/dist/angular-schema-form-bootstrap-bundled.min.js
@@ -0,0 +1,23 @@
+/*!
+ * angular-schema-form-bootstrap
+ * @version 1.0.0-alpha.1
+ * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
+ * @license MIT
+ * Copyright (c) 2016 JSON Schema Form
+ */
+(function webpackUniversalModuleDefinition(root,factory){if(typeof exports==="object"&&typeof module==="object")module.exports=factory(require("angular"),require("tv4"));else if(typeof define==="function"&&define.amd)define(["angular","tv4"],factory);else{var a=typeof exports==="object"?factory(require("angular"),require("tv4")):factory(root["angular"],root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_19__,__WEBPACK_EXTERNAL_MODULE_20__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){"use strict";__webpack_require__(18);__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var textareaTemplate=__webpack_require__(17);var fieldsetTemplate=__webpack_require__(7);var arrayTemplate=__webpack_require__(3);var tabarrayTemplate=__webpack_require__(15);var tabsTemplate=__webpack_require__(16);var sectionTemplate=__webpack_require__(12);var actionsTemplate=__webpack_require__(2);var selectTemplate=__webpack_require__(13);var checkboxTemplate=__webpack_require__(4);var checkboxesTemplate=__webpack_require__(5);var submitTemplate=__webpack_require__(14);var radiosTemplate=__webpack_require__(11);var radiosInlineTemplate=__webpack_require__(10);var radiobuttonsTemplate=__webpack_require__(9);var helpTemplate=__webpack_require__(8);var defaultTemplate=__webpack_require__(6);angular.module("schemaForm").config(bootstrapDecoratorConfig).filter("sfCamelKey",sfCamelKeyFilter);bootstrapDecoratorConfig.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"];function bootstrapDecoratorConfig(schemaFormProvider,decoratorsProvider,sfBuilderProvider,sfPathProvider,$injector){var base="decorators/bootstrap/";var simpleTransclusion=sfBuilderProvider.builders.simpleTransclusion;var ngModelOptions=sfBuilderProvider.builders.ngModelOptions;var ngModel=sfBuilderProvider.builders.ngModel;var sfField=sfBuilderProvider.builders.sfField;var condition=sfBuilderProvider.builders.condition;var array=sfBuilderProvider.builders.array;var numeric=sfBuilderProvider.builders.numeric;var tabs=function tabs(args){if(args.form.tabs&&args.form.tabs.length>0){var tabContent=args.fieldFrag.querySelector(".tab-content");args.form.tabs.forEach(function(tab,index){var evalExpr="(evalExpr("+args.path+".tabs["+index+"]"+'.condition, { model: model, "arrayIndex": $index}))';var div=document.createElement("div");div.className="tab-pane";div.setAttribute("ng-disabled","form.readonly");div.setAttribute("ng-show","selected.tab === "+index);div.setAttribute("ng-class","{active: selected.tab === "+index+"}");if(!!tab.condition){div.setAttribute("ng-if",evalExpr)}var childFrag=args.build(tab.items,args.path+".tabs["+index+"].items",args.state);div.appendChild(childFrag);tabContent.appendChild(div)})}};var selectPlaceholder=function selectPlaceholder(args){if(args.form.placeholder){var selectBox=args.fieldFrag.querySelector("select");var option=document.createElement("option");option.setAttribute("value","");option.setAttribute("sf-field-model","replaceAll");if(angular.version.major===1&&angular.version.minor<4){option.setAttribute("ng-if","$$value$$ === undefined")}else{option.setAttribute("ng-show","$$value$$ === undefined")}option.textContent=args.form.placeholder;selectBox.appendChild(option)}};var defaults=[sfField,ngModel,ngModelOptions,condition];decoratorsProvider.defineDecorator("bootstrapDecorator",{actions:{template:actionsTemplate,builder:defaults},array:{template:arrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},button:{template:submitTemplate,builder:defaults},checkbox:{template:checkboxTemplate,builder:defaults},checkboxes:{template:checkboxesTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},conditional:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},"default":{template:defaultTemplate,builder:defaults},fieldset:{template:fieldsetTemplate,builder:[sfField,simpleTransclusion,condition]},help:{template:helpTemplate,builder:defaults},number:{template:defaultTemplate,builder:defaults.concat(numeric)},password:{template:defaultTemplate,builder:defaults},radios:{template:radiosTemplate,builder:defaults},"radios-inline":{template:radiosInlineTemplate,builder:defaults},radiobuttons:{template:radiobuttonsTemplate,builder:defaults},section:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},select:{template:selectTemplate,builder:defaults.concat(selectPlaceholder)},submit:{template:submitTemplate,builder:defaults},tabarray:{template:tabarrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},tabs:{template:tabsTemplate,builder:[sfField,ngModelOptions,tabs,condition]},textarea:{template:textareaTemplate,builder:defaults}},[])}function sfCamelKeyFilter(){return function(formKey){if(!formKey){return""}var part,i,key;key=formKey.slice();for(i=0;i<key.length;i++){part=key[i].toLowerCase().split("");if(i&&part.length){part[0]=part[0].toUpperCase()}key[i]=part.join("")}return key.join("")}}},function(module,exports){var path="bootstrap/actions.html";var html='<div class="btn-group schema-form-actions {{::form.htmlClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/array.html";var html='<div  class="schema-form-array {{::form.htmlClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkbox.html";var html='<div class="checkbox schema-form-checkbox {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{form.key.slice(-1)[0]}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkboxes.html";var html='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{form.key.slice(-1)[0]}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/default.html";var html='<div class="form-group {{::form.htmlClass}}"\r\n     ng-class="{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{form.key.slice(-1)[0]}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{form.key.slice(-1)[0]}}"\r\n         aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{form.key.slice(-1)[0]}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{form.key.slice(-1)[0]}}"\r\n           aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{form.key.slice(-1)[0] + \'Status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/fieldset.html";var html='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/help.html";var html='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radio-buttons.html";var html='<div class="form-group schema-form-radiobuttons {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: item.value === $$value$$ }"\r\n           ng-repeat="item in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios-inline.html";var html='<div class="form-group schema-form-radios-inline {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="item in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios.html";var html='<div class="form-group schema-form-radios {{::form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="item in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/section.html";var html='<div class="schema-form-section {{::form.htmlClass}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/select.html";var html='<div class="form-group {{::form.htmlClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{form.key.slice(-1)[0]}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/submit.html";var html='<div class="form-group schema-form-submit {{::form.htmlClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabarray.html";var html='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabs.html";var html='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/textarea.html";var html='<div class="form-group has-feedback {{::form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{form.key.slice(-1)[0]}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{form.key.slice(-1)[0]}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{form.key.slice(-1)[0]}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{form.key.slice(-1)[0]}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports,__webpack_require__){/*!
+	 * angular-schema-form
+	 * @version 1.0.0-alpha.2
+	 * @link https://github.com/json-schema-form/angular-schema-form
+	 * @license MIT
+	 * Copyright (c) 2016 JSON Schema Form
+	 */
+(function webpackUniversalModuleDefinition(root,factory){if(true)module.exports=factory(__webpack_require__(19),__webpack_require__(20));else if(typeof define==="function"&&define.amd)define(["angular","tv4"],factory);else{var a=typeof exports==="object"?factory(require("angular"),require("tv4")):factory(root["angular"],root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_2__,__WEBPACK_EXTERNAL_MODULE_7__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){module.exports=__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _builder=__webpack_require__(3);var _builder2=_interopRequireDefault(_builder);var _decorators=__webpack_require__(4);var _decorators2=_interopRequireDefault(_decorators);var _schemaForm=__webpack_require__(5);var _schemaForm2=_interopRequireDefault(_schemaForm);var _jsonSchemaFormCore=__webpack_require__(6);var _validator=__webpack_require__(8);var _validator2=_interopRequireDefault(_validator);var _errors=__webpack_require__(9);var _errors2=_interopRequireDefault(_errors);var _sfPath=__webpack_require__(10);var _sfPath2=_interopRequireDefault(_sfPath);var _array=__webpack_require__(11);var _array2=_interopRequireDefault(_array);var _changed=__webpack_require__(12);var _changed2=_interopRequireDefault(_changed);var _field=__webpack_require__(13);var _field2=_interopRequireDefault(_field);var _message=__webpack_require__(14);var _message2=_interopRequireDefault(_message);var _newArray=__webpack_require__(15);var _newArray2=_interopRequireDefault(_newArray);var _keyController=__webpack_require__(16);var _keyController2=_interopRequireDefault(_keyController);var _schemaForm3=__webpack_require__(17);var _schemaForm4=_interopRequireDefault(_schemaForm3);var _schemaValidate=__webpack_require__(18);var _schemaValidate2=_interopRequireDefault(_schemaValidate);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}var deps=[];try{_angular2.default.module("ngSanitize");deps.push("ngSanitize")}catch(e){}try{_angular2.default.module("ui.sortable");deps.push("ui.sortable")}catch(e){}try{_angular2.default.module("angularSpectrumColorpicker");deps.push("angularSpectrumColorpicker")}catch(e){}_angular2.default.module("schemaForm",deps).provider("sfPath",_sfPath2.default).provider("sfBuilder",["sfPathProvider",_builder2.default]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",_decorators2.default]).provider("sfErrorMessage",_errors2.default).provider("schemaForm",["sfPathProvider",_schemaForm2.default]).factory("sfSelect",function(){return _jsonSchemaFormCore.select}).factory("sfValidator",_validator2.default).directive("sfArray",["sfSelect","schemaForm","sfValidator","sfPath",_array2.default]).directive("sfChanged",_changed2.default).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",_field2.default]).directive("sfMessage",["$injector","sfErrorMessage",_message2.default]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",_newArray2.default]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",_schemaForm4.default]).directive("schemaValidate",["sfValidator","$parse","sfSelect",_schemaValidate2.default]).directive("sfKeyController",["schemaForm","sfPath",_keyController2.default])},function(module,exports){module.exports=angular},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfPathProvider){var SNAKE_CASE_REGEXP=/[A-Z]/g;var snakeCase=function snakeCase(name,separator){separator=separator||"_";return name.replace(SNAKE_CASE_REGEXP,function(letter,pos){return(pos?separator:"")+letter.toLowerCase()})};var formId=0;var builders={sfField:function sfField(args){args.fieldFrag.firstChild.setAttribute("sf-field",formId);args.lookup["f"+formId]=args.form;formId++},ngModel:function ngModel(args){if(!args.form.key){return}var key=args.form.key;if(args.state.keyRedaction){key=key.slice(args.state.keyRedaction)}var modelValue;if(!args.state.modelValue){var strKey=sfPathProvider.stringify(key).replace(/"/g,"&quot;");modelValue=args.state.modelName||"model";if(strKey){modelValue+=(strKey[0]!=="["?".":"")+strKey}}else{modelValue=args.state.modelValue}var nodes=args.fieldFrag.querySelectorAll("[sf-field-model]");for(var i=0;i<nodes.length;i++){var n=nodes[i];var conf=n.getAttribute("sf-field-model");if(!conf||conf===""){n.setAttribute("ng-model",modelValue)}else if(conf==="replaceAll"){var attributes=n.attributes;for(var j=0;j<attributes.length;j++){if(attributes[j].value&&attributes[j].value.indexOf("$$value")!==-1){attributes[j].value=attributes[j].value.replace(/\$\$value\$\$/g,modelValue)}}}else{var val=n.getAttribute(conf);if(val&&val.indexOf("$$value$$")){n.setAttribute(conf,val.replace(/\$\$value\$\$/g,modelValue))}else{n.setAttribute(conf,modelValue)}}}},simpleTransclusion:function simpleTransclusion(args){var children=args.build(args.form.items,args.path+".items",args.state);args.fieldFrag.firstChild.appendChild(children)},ngModelOptions:function ngModelOptions(args){if(args.form.ngModelOptions&&Object.keys(args.form.ngModelOptions).length>0){args.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(args.form.ngModelOptions))}},transclusion:function transclusion(args){var transclusions=args.fieldFrag.querySelectorAll("[sf-field-transclude]");if(transclusions.length){for(var i=0;i<transclusions.length;i++){var n=transclusions[i];var sub=n.getAttribute("sf-field-transclude")||"items";var items=args.form[sub];if(items){var childFrag=args.build(items,args.path+"."+sub,args.state);n.appendChild(childFrag)}}}},condition:function condition(args){if(args.form.condition){var evalExpr="evalExpr("+args.path+'.condition, { model: model, "arrayIndex": $index})';if(args.form.key){var strKey=sfPathProvider.stringify(args.form.key);var arrayDepth=args.form.key.filter(function(e){return e===""}).length;var arrayIndices=arrayDepth>1?Array(arrayDepth-1).join("$parent.$parent.$parent.")+"$parent.$parent.$index,":"";for(var i=arrayDepth;i>2;i--){arrayIndices+=Array(i-1).join("$parent.$parent.$parent.")+"$index,"}arrayIndices+="$index";evalExpr="evalExpr("+args.path+'.condition,{ model: model, "arrayIndex": $index, '+'"arrayIndices": ['+arrayIndices+"],"+'"modelValue": model'+(strKey[0]==="["?"":".")+strKey+"})"}var children=args.fieldFrag.children||args.fieldFrag.childNodes;for(var i=0;i<children.length;i++){var child=children[i];var ngIf=child.getAttribute("ng-if");child.setAttribute("ng-if",ngIf?"("+ngIf+") || ("+evalExpr+")":evalExpr)}}},array:function array(args){var items=args.fieldFrag.querySelector("[schema-form-array-items]");if(args.form.key){var arrayDepth=args.form.key.filter(function(e){return e===""}).length}if(items){var state=angular.copy(args.state);state.keyRedaction=0;state.keyRedaction+=args.form.key.length+1;if(args.form.schema&&args.form.schema.items&&args.form.schema.items.type&&args.form.schema.items.type.indexOf("object")===-1&&args.form.schema.items.type.indexOf("array")===-1){var strKey=sfPathProvider.stringify(args.form.key).replace(/"/g,"&quot;")+"[$index]";state.modelValue="modelArray[$index]"}else{state.modelName="item"}state.arrayCompatFlag=true;var childFrag=args.build(args.form.items,args.path+".items",state);items.appendChild(childFrag)}},numeric:function numeric(args){var inputFrag=args.fieldFrag.querySelector("input");var maximum=args.form.maximum||false;var exclusiveMaximum=args.form.exclusiveMaximum||false;var minimum=args.form.minimum||false;var exclusiveMinimum=args.form.exclusiveMinimum||false;var multipleOf=args.form.multipleOf||false;if(inputFrag){if(multipleOf!==false){inputFrag.setAttribute("step",multipleOf)}if(maximum!==false){if(exclusiveMaximum!==false&&multipleOf!==false){maximum=maximum-multipleOf}inputFrag.setAttribute("max",maximum)}if(minimum!==false){if(exclusiveMinimum!==false&&multipleOf!==false){minimum=minimum+multipleOf}inputFrag.setAttribute("min",minimum)}}}};this.builders=builders;var stdBuilders=[builders.sfField,builders.ngModel,builders.ngModelOptions,builders.condition];this.stdBuilders=stdBuilders;this.$get=["$templateCache","schemaFormDecorators","sfPath",function($templateCache,schemaFormDecorators,sfPath){var checkForSlot=function checkForSlot(form,slots){if(form.key){var slot=slots[sfPath.stringify(form.key)];if(slot){while(slot.firstChild){slot.removeChild(slot.firstChild)}return slot}}};var _build=function _build(items,decorator,templateFn,slots,path,state,lookup){state=state||{};state=state||{};lookup=lookup||Object.create(null);path=path||"schemaForm.form";var container=document.createDocumentFragment();items.reduce(function(frag,f,index){if(!f.type){return frag}var field=decorator[f.type]||decorator["default"];if(!field.replace){var n=document.createElement(snakeCase(decorator.__name,"-"));if(state.arrayCompatFlag){n.setAttribute("form","copyWithIndex($index)")}else{n.setAttribute("form",path+"["+index+"]")}(checkForSlot(f,slots)||frag).appendChild(n)}else{var tmpl;state.arrayCompatFlag=false;var div=document.createElement("div");var template=templateFn(f,field)||templateFn(f,decorator["default"]);div.innerHTML=template;tmpl=document.createDocumentFragment();while(div.childNodes.length>0){tmpl.appendChild(div.childNodes[0])}var args={fieldFrag:tmpl,form:f,lookup:lookup,state:state,path:path+"["+index+"]",build:function build(items,path,state){return _build(items,decorator,templateFn,slots,path,state,lookup)}};var builderFn=f.builder||field.builder;if(typeof builderFn==="function"){builderFn(args)}else{builderFn.forEach(function(fn){fn(args)})}(checkForSlot(f,slots)||frag).appendChild(tmpl)}return frag},container);return container};return{build:function build(form,decorator,slots,lookup){return _build(form,decorator,function(form,field){if(form.type==="template"){return form.template}return $templateCache.get(field.template)},slots,undefined,undefined,lookup)},builder:builders,stdBuilders:stdBuilders,internalBuild:_build}}]}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($compileProvider,sfPathProvider){var defaultDecorator="";var decorators={};var templateUrl=function templateUrl(name,form){if(name==="sfDecorator"){name=defaultDecorator}var decorator=decorators[name];if(decorator[form.type]){return decorator[form.type].template}return decorator["default"].template};var createDirective=function createDirective(name){$compileProvider.directive(name,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function($parse,$compile,$http,$templateCache,$interpolate,$q,sfErrorMessage,sfPath,sfSelect){return{restrict:"AE",replace:false,transclude:false,scope:true,require:["^sfSchema","?^form"],link:function link(scope,element,attrs,ctrl){var sfSchema=ctrl[0];var formCtrl=ctrl[1];scope.$on("schemaFormPropagateNgModelController",function(event,ngModel){event.stopPropagation();event.preventDefault();scope.ngModel=ngModel});scope.showTitle=function(){return scope.form&&scope.form.notitle!==true&&scope.form.title};scope.fieldId=function(prependFormName,omitArrayIndexes){var key=scope.parentKey||[];if(scope.form.key){if(typeof key[key.length-1]==="number"){var combinedKey=key.concat(scope.form.key.slice(-1));var formName=prependFormName&&formCtrl&&formCtrl.$name?formCtrl.$name:undefined;return sfPath.name(combinedKey,"-",formName,omitArrayIndexes)}else{var formName=prependFormName&&formCtrl&&formCtrl.$name?formCtrl.$name:undefined;return sfPath.name(scope.form.key,"-",formName,omitArrayIndexes)}}else{return""}};scope.listToCheckboxValues=function(list){var values={};_angular2.default.forEach(list,function(v){values[v]=true});return values};scope.checkboxValuesToList=function(values){var lst=[];_angular2.default.forEach(values,function(v,k){if(v){lst.push(k)}});return lst};scope.buttonClick=function($event,form){if(_angular2.default.isFunction(form.onClick)){form.onClick($event,form)}else if(_angular2.default.isString(form.onClick)){if(sfSchema){sfSchema.evalInParentScope(form.onClick,{$event:$event,form:form})}else{scope.$eval(form.onClick,{$event:$event,form:form})}}};scope.evalExpr=function(expression,locals){if(sfSchema){return sfSchema.evalInParentScope(expression,locals)}return scope.$eval(expression,locals)};scope.evalInScope=function(expression,locals){if(expression){return scope.$eval(expression,locals)}};scope.interp=function(expression,locals){return expression&&$interpolate(expression)(locals)};scope.hasSuccess=function(){if(!scope.ngModel){return false}if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return scope.ngModel.$valid&&!scope.ngModel.$pristine&&!scope.ngModel.$isEmpty(scope.ngModel.$modelValue)}else{return scope.ngModel.$valid&&(!scope.ngModel.$pristine||!scope.ngModel.$isEmpty(scope.ngModel.$modelValue))}};scope.hasError=function(){if(!scope.ngModel){return false}return scope.ngModel.$invalid&&!scope.ngModel.$pristine};scope.errorMessage=function(schemaError){return sfErrorMessage.interpolate(schemaError&&schemaError.code+""||"default",scope.ngModel&&scope.ngModel.$modelValue||"",scope.ngModel&&scope.ngModel.$viewValue||"",scope.form,scope.options&&scope.options.validationMessage)};var once=scope.$watch(attrs.form,function(form){if(form){form.ngModelOptions=form.ngModelOptions||{};scope.form=form;var templatePromise;if(form.type==="template"&&form.template){templatePromise=$q.when(form.template)}else{var url=form.type==="template"?form.templateUrl:templateUrl(name,form);templatePromise=$http.get(url,{cache:$templateCache}).then(function(res){return res.data})}templatePromise.then(function(template){if(form.key){var key=form.key?sfPathProvider.stringify(form.key).replace(/"/g,"&quot;"):"";template=template.replace(/\$\$value\$\$/g,"model"+(key[0]!=="["?".":"")+key)}element.html(template);if(form.condition){var evalExpr='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';if(form.key){evalExpr="evalExpr(form.condition, {"+'model: model, "arrayIndex": arrayIndex, "modelValue": model'+sfPath.stringify(form.key)+"})"}_angular2.default.forEach(element.children(),function(child){var ngIf=child.getAttribute("ng-if");child.setAttribute("ng-if",ngIf?"("+ngIf+") || ("+evalExpr+")":evalExpr)})}$compile(element.contents())(scope)});if(form.key){scope.$on("schemaForm.error."+form.key.join("."),function(event,error,validationMessage,validity,formName){formName=validity;if(validationMessage===true||validationMessage===false){validity=validationMessage;validationMessage=undefined}if(formName!=undefined&&scope.ngModel.$$parentForm.$name!==formName){return}if(scope.ngModel&&error){if(scope.ngModel.$setDirty){scope.ngModel.$setDirty()}else{scope.ngModel.$dirty=true;scope.ngModel.$pristine=false}if(validationMessage){if(!form.validationMessage){form.validationMessage={}}form.validationMessage[error]=validationMessage}scope.ngModel.$setValidity(error,validity===true);if(validity===true){scope.ngModel.$validate();scope.$broadcast("schemaFormValidate")}}});scope.$on("$destroy",function(){if(!scope.externalDestructionInProgress){var destroyStrategy=form.destroyStrategy||scope.options&&scope.options.destroyStrategy||"remove";if(form.key&&destroyStrategy!=="retain"){var obj=scope.model;if(form.key.length>1){obj=sfSelect(form.key.slice(0,form.key.length-1),obj)}if(obj===undefined){return}var type=form.schema&&form.schema.type||"";if(destroyStrategy==="empty"&&type.indexOf("string")!==-1){obj[form.key.slice(-1)]=""}else if(destroyStrategy==="empty"&&type.indexOf("object")!==-1){obj[form.key.slice(-1)]={}}else if(destroyStrategy==="empty"&&type.indexOf("array")!==-1){obj[form.key.slice(-1)]=[]}else if(destroyStrategy==="null"){obj[form.key.slice(-1)]=null}else{delete obj[form.key.slice(-1)]}}}})}once()}})}}}])};var createManualDirective=function createManualDirective(type,templateUrl,transclude){transclude=_angular2.default.isDefined(transclude)?transclude:false;$compileProvider.directive("sf"+_angular2.default.uppercase(type[0])+type.substr(1),function(){return{restrict:"EAC",scope:true,replace:true,transclude:transclude,template:'<sf-decorator form="form"></sf-decorator>',link:function link(scope,element,attrs){var watchThis={items:"c",titleMap:"c",schema:"c"};var form={type:type};var once=true;_angular2.default.forEach(attrs,function(value,name){if(name[0]!=="$"&&name.indexOf("ng")!==0&&name!=="sfField"){var updateForm=function updateForm(val){if(_angular2.default.isDefined(val)&&val!==form[name]){form[name]=val;if(once&&form.type&&(form.key||_angular2.default.isUndefined(attrs.key))){scope.form=form;once=false}}};if(name==="model"){scope.$watch(value,function(val){if(val&&scope.model!==val){scope.model=val}})}else if(watchThis[name]==="c"){scope.$watchCollection(value,updateForm)}else{attrs.$observe(name,updateForm)}}})}}})};this.createDecorator=function(name,templates){decorators[name]={__name:name};_angular2.default.forEach(templates,function(url,type){decorators[name][type]={template:url,replace:false,builder:[]}});if(!decorators[defaultDecorator]){defaultDecorator=name}createDirective(name)};this.defineDecorator=function(name,fields){decorators[name]={__name:name};_angular2.default.forEach(fields,function(field,type){field.builder=field.builder||[];field.replace=_angular2.default.isDefined(field.replace)?field.replace:true;decorators[name][type]=field});if(!decorators[defaultDecorator]){defaultDecorator=name}createDirective(name)};this.createDirective=createManualDirective;this.createDirectives=function(templates){_angular2.default.forEach(templates,function(url,type){createManualDirective(type,url)})};this.decorator=function(name){name=name||defaultDecorator;return decorators[name]};this.addMapping=function(name,type,url,builder,replace){if(decorators[name]){decorators[name][type]={template:url,builder:builder,replace:!!replace}}};this.defineAddOn=function(name,type,url,builder){if(decorators[name]){decorators[name][type]={template:url,builder:builder,replace:true}}};this.$get=function(){return{decorator:function decorator(name){return decorators[name]||decorators[defaultDecorator]},defaultDecorator:defaultDecorator}};createDirective("sfDecorator")};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var postProcessFn=function postProcessFn(form){return form};var defaults=_jsonSchemaFormCore.schemaDefaults.createDefaults();this.defaults=defaults;this.stdFormObj=_jsonSchemaFormCore.schemaDefaults.stdFormObj;this.defaultFormDefinition=_jsonSchemaFormCore.schemaDefaults.defaultFormDefinition;this.postProcess=function(fn){postProcessFn=fn};this.appendRule=function(type,rule){if(!defaults[type]){defaults[type]=[]}defaults[type].push(rule)};this.prependRule=function(type,rule){if(!defaults[type]){defaults[type]=[]}defaults[type].unshift(rule)};this.createStandardForm=_jsonSchemaFormCore.schemaDefaults.stdFormObj;this.$get=function(){var service={};var typeDefault=this.defaults;service.merge=function(schema,form,ignore,options,readonly,asyncTemplates){form=form||["*"];options=options||{};readonly=readonly||schema.readonly||schema.readOnly;var stdForm=_jsonSchemaFormCore.schemaDefaults.defaultForm(schema,typeDefault,ignore,options);var idx=form.indexOf("*");if(idx!==-1){form=form.slice(0,idx).concat(stdForm.form).concat(form.slice(idx+1))}var canonical=(0,_jsonSchemaFormCore.merge)(stdForm.lookup,form,options,readonly,asyncTemplates);return postProcessFn(canonical)};service.defaults=_jsonSchemaFormCore.schemaDefaults.defaultForm;service.typeDefault=typeDefault;service.traverseSchema=_jsonSchemaFormCore.traverseSchema;service.traverseForm=_jsonSchemaFormCore.traverseForm;return service}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _jsonSchemaFormCore=__webpack_require__(6);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){/*!
+		 * json-schema-form
+		 * @version 1.0.0-alpha.2
+		 * @link https://github.com/json-schema-form/json-schema-form-core
+		 * @license MIT
+		 * Copyright (c) 2016 JSON Schema Form
+		 */
+(function webpackUniversalModuleDefinition(root,factory){if(true)module.exports=factory(__webpack_require__(7));else if(typeof define==="function"&&define.amd)define(["tv4"],factory);else{var a=typeof exports==="object"?factory(require("tv4")):factory(root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_10__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){module.exports=__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.canonicalTitleMap=exports.schemaDefaults=exports.sfPath=undefined;var _merge=__webpack_require__(2);Object.keys(_merge).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _merge[key]}})});var _select=__webpack_require__(7);Object.keys(_select).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _select[key]}})});var _traverse=__webpack_require__(8);Object.keys(_traverse).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _traverse[key]}})});var _validate=__webpack_require__(9);Object.keys(_validate).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _validate[key]}})});var _schemaDefaults=__webpack_require__(11);var schemaDefaultsImp=_interopRequireWildcard(_schemaDefaults);var _sfPath=__webpack_require__(3);var sfPathImp=_interopRequireWildcard(_sfPath);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}function _interopRequireWildcard(obj){if(obj&&obj.__esModule){return obj}else{var newObj={};if(obj!=null){for(var key in obj){if(Object.prototype.hasOwnProperty.call(obj,key))newObj[key]=obj[key]}}newObj.default=obj;return newObj}}var sfPath=exports.sfPath=sfPathImp;var schemaDefaults=exports.schemaDefaults=schemaDefaultsImp;var canonicalTitleMap=exports.canonicalTitleMap=_canonicalTitleMap2.default},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.merge=merge;var _sfPath=__webpack_require__(3);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}function merge(lookup,form,options,readonly,asyncTemplates){form=form||[];options=options||{};return form.map(function(obj){if(typeof obj==="string"){obj={key:obj}}if(obj.key){if(typeof obj.key==="string"){obj.key=(0,_sfPath.parse)(obj.key)}}if(obj.titleMap){obj.titleMap=(0,_canonicalTitleMap2.default)(obj.titleMap)}if(obj.key){var strid=(0,_sfPath.stringify)(obj.key);if(lookup[strid]){(function(){var schemaDefaults=lookup[strid];if(schemaDefaults){Object.keys(schemaDefaults).forEach(function(attr){if(obj[attr]===undefined){obj[attr]=schemaDefaults[attr]}})}})()}}if(readonly===true){obj.readonly=true}if(obj.items){obj.items=merge(lookup,obj.items,options,obj.readonly,asyncTemplates)}if(obj.tabs){obj.tabs.forEach(function(tab){if(tab.items){tab.items=merge(lookup,tab.items,options,obj.readonly,asyncTemplates)}})}if(obj.type==="checkbox"&&obj.schema["default"]===undefined){obj.schema["default"]=false}if(asyncTemplates&&obj.type==="template"&&!obj.template&&obj.templateUrl){asyncTemplates.push(obj)}return obj})}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.name=exports.normalize=exports.stringify=exports.parse=undefined;var _objectpath=__webpack_require__(4);var name=function name(key,separator,formName,omitNumbers){if(key){var fieldKey=key;var fieldSeparator=separator||"-";if(omitNumbers){fieldKey=fieldKey.filter(function(key){return typeof key!=="number"})}return(formName?formName+fieldSeparator:"")+fieldKey.join(fieldSeparator)}return""};exports.parse=_objectpath.parse;exports.stringify=_objectpath.stringify;exports.normalize=_objectpath.normalize;exports.name=name},function(module,exports,__webpack_require__){"use strict";module.exports=__webpack_require__(5).ObjectPath},function(module,exports,__webpack_require__){var __WEBPACK_AMD_DEFINE_RESULT__;"use strict";var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};!function(undefined){var ObjectPath={parse:function parse(str){if(typeof str!=="string"){throw new TypeError("ObjectPath.parse must be passed a string")}var i=0;var parts=[];var d,b,q,c;while(i<str.length){d=str.indexOf(".",i);b=str.indexOf("[",i);if(d===-1&&b===-1){parts.push(str.slice(i,str.length));i=str.length}else if(b===-1||d!==-1&&d<b){parts.push(str.slice(i,d));i=d+1}else{if(b>i){parts.push(str.slice(i,b));i=b}q=str.slice(b+1,b+2);if(q!=='"'&&q!=="'"){c=str.indexOf("]",b);if(c===-1)c=str.length;parts.push(str.slice(i+1,c));i=str.slice(c+1,c+2)==="."?c+2:c+1}else{c=str.indexOf(q+"]",b);if(c===-1)c=str.length;while(str.slice(c-1,c)==="\\"&&b<str.length){b++;c=str.indexOf(q+"]",b)}parts.push(str.slice(i+2,c).replace(new RegExp("\\"+q,"g"),q));i=str.slice(c+2,c+3)==="."?c+3:c+2}}}return parts},stringify:function stringify(arr,quote){if(!Array.isArray(arr))arr=[arr.toString()];quote=quote==='"'?'"':"'";return arr.map(function(n){return"["+quote+n.toString().replace(new RegExp(quote,"g"),"\\"+quote)+quote+"]"}).join("")},normalize:function normalize(data,quote){return ObjectPath.stringify(Array.isArray(data)?data:ObjectPath.parse(data),quote)},registerModule:function registerModule(angular){angular.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=ObjectPath.parse;this.stringify=ObjectPath.stringify;this.normalize=ObjectPath.normalize;this.$get=function(){return ObjectPath}})}};if(true){!(__WEBPACK_AMD_DEFINE_RESULT__=function(){return{ObjectPath:ObjectPath}}.call(exports,__webpack_require__,exports,module),__WEBPACK_AMD_DEFINE_RESULT__!==undefined&&(module.exports=__WEBPACK_AMD_DEFINE_RESULT__))}else if((typeof exports==="undefined"?"undefined":_typeof(exports))==="object"){exports.ObjectPath=ObjectPath}else{window.ObjectPath=ObjectPath}}()},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.default=function(titleMap,originalEnum){if(!Array.isArray(titleMap)){var _ret=function(){var canonical=[];if(originalEnum){originalEnum.forEach(function(value){canonical.push({name:titleMap[value],value:value})})}else{Object.keys(titleMap).forEach(function(value){canonical.push({name:titleMap[value],value:value})})}return{v:canonical}}();if((typeof _ret==="undefined"?"undefined":_typeof(_ret))==="object")return _ret.v}return titleMap}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.select=select;var _sfPath=__webpack_require__(3);var _sfPath2=_interopRequireDefault(_sfPath);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}var numRe=/^\d+$/;function select(projection,obj,valueToSet){if(!obj){obj=this}var parts=typeof projection==="string"?_sfPath2.default.parse(projection):projection;if(typeof valueToSet!=="undefined"&&parts.length===1){obj[parts[0]]=valueToSet;return obj}if(typeof valueToSet!=="undefined"&&typeof obj[parts[0]]==="undefined"){obj[parts[0]]=parts.length>2&&numRe.test(parts[1])?[]:{}}var value=obj[parts[0]];for(var i=1;i<parts.length;i++){if(parts[i]===""){return undefined}if(typeof valueToSet!=="undefined"){if(i===parts.length-1){value[parts[i]]=valueToSet;return valueToSet}else{var tmp=value[parts[i]];if(typeof tmp==="undefined"||tmp===null){tmp=numRe.test(parts[i+1])?[]:{};value[parts[i]]=tmp}value=tmp}}else if(value){value=value[parts[i]]}}return value}},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.traverseSchema=traverseSchema;exports.traverseForm=traverseForm;function traverseSchema(schema,fn,path,ignoreArrays){ignoreArrays=ignoreArrays===undefined?true:ignoreArrays;path=path||[];var traverse=function traverse(schema,fn,path){fn(schema,path);if(schema.properties){Object.keys(schema.properties).forEach(function(name){var currentPath=path.slice();currentPath.push(name);traverse(schema.properties[name],fn,currentPath)})}if(!ignoreArrays&&schema.items){var arrPath=path.slice();arrPath.push("");traverse(schema.items,fn,arrPath)}};traverse(schema,fn,path||[])}function traverseForm(form,fn){fn(form);if(form.items){form.items.forEach(function(f){traverseForm(f,fn)})}if(form.tabs){form.tabs.forEach(function(tab){if(tab.items){tab.items.forEach(function(f){traverseForm(f,fn)})}})}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.validate=validate;var _tv=__webpack_require__(10);var _tv2=_interopRequireDefault(_tv);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}function validate(form,value){if(!form){return{valid:true}}var schema=form.schema;if(!schema){return{valid:true}}if(value===""){value=undefined}if(form.type==="number"&&value===null){value=undefined}var wrap={type:"object",properties:{}};var propName=form.key[form.key.length-1];wrap.properties[propName]=schema;if(form.required){wrap.required=[propName]}var valueWrap={};if(!!value){valueWrap[propName]=value}return _tv2.default.validateResult(valueWrap,wrap)}},function(module,exports){module.exports=tv4},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.defaultFormDefinition=defaultFormDefinition;exports.stdFormObj=stdFormObj;exports.text=text;exports.number=number;exports.integer=integer;exports.checkbox=checkbox;exports.select=select;exports.checkboxes=checkboxes;exports.fieldset=fieldset;exports.array=array;exports.createDefaults=createDefaults;exports.defaultForm=defaultForm;var _sfPath=__webpack_require__(3);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}var stripNullType=function stripNullType(type){if(Array.isArray(type)&&type.length==2){if(type[0]==="null"){return type[1]}if(type[1]==="null"){return type[0]}}return type};var enumToTitleMap=function enumToTitleMap(enm){var titleMap=[];enm.forEach(function(name){titleMap.push({name:name,value:name})});return titleMap};function defaultFormDefinition(schemaTypes,name,schema,options){var rules=schemaTypes[stripNullType(schema.type)];if(rules){var def=void 0;var innerDefaultFormDefinition=function innerDefaultFormDefinition(childName,childSchema,childOptions){return defaultFormDefinition(schemaTypes,childName,childSchema,childOptions)};for(var i=0;i<rules.length;i++){def=rules[i](name,schema,options,innerDefaultFormDefinition);if(def){if(def.schema["x-schema-form"]){Object.assign(def,def.schema["x-schema-form"])}return def}}}}function stdFormObj(name,schema,options){options=options||{};var f=options.global&&options.global.formDefaults?Object.assign({},options.global.formDefaults):{};if(options.global&&options.global.supressPropertyTitles===true){f.title=schema.title}else{f.title=schema.title||name}if(schema.description){f.description=schema.description}if(options.required===true||schema.required===true){f.required=true}if(schema.maxLength){f.maxlength=schema.maxLength}if(schema.minLength){f.minlength=schema.minLength}if(schema.readOnly||schema.readonly){f.readonly=true}if(schema.minimum){f.minimum=schema.minimum+(schema.exclusiveMinimum?1:0)}if(schema.maximum){f.maximum=schema.maximum-(schema.exclusiveMaximum?1:0)}if(schema.validationMessage){f.validationMessage=schema.validationMessage}if(schema.enumNames){f.titleMap=(0,_canonicalTitleMap2.default)(schema.enumNames,schema["enum"])}f.schema=schema;f.ngModelOptions=f.ngModelOptions||{};return f}function text(name,schema,options){if(stripNullType(schema.type)==="string"&&!schema["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="text";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function number(name,schema,options){if(stripNullType(schema.type)==="number"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="number";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function integer(name,schema,options){if(stripNullType(schema.type)==="integer"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="number";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function checkbox(name,schema,options){if(stripNullType(schema.type)==="boolean"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="checkbox";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function select(name,schema,options){if(stripNullType(schema.type)==="string"&&schema["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="select";if(!f.titleMap){f.titleMap=enumToTitleMap(schema["enum"])}options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function checkboxes(name,schema,options){if(stripNullType(schema.type)==="array"&&schema.items&&schema.items["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="checkboxes";if(!f.titleMap){f.titleMap=enumToTitleMap(schema.items["enum"])}options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function fieldset(name,schema,options,defaultFormDef){if(stripNullType(schema.type)==="object"){var _ret=function(){var f=stdFormObj(name,schema,options);f.type="fieldset";f.key=options.path;f.items=[];options.lookup[(0,_sfPath.stringify)(options.path)]=f;if(schema.properties){Object.keys(schema.properties).forEach(function(key){var value=schema.properties[key];var path=options.path.slice();path.push(key);if(options.ignore[(0,_sfPath.stringify)(path)]!==true){var required=schema.required&&schema.required.indexOf(key)!==-1;var def=defaultFormDef(key,value,{path:path,required:required||false,lookup:options.lookup,ignore:options.ignore,global:options.global});if(def){f.items.push(def)}}})}return{v:f}}();if((typeof _ret==="undefined"?"undefined":_typeof(_ret))==="object")return _ret.v}}function array(name,schema,options,defaultFormDef){if(stripNullType(schema.type)==="array"){var f=stdFormObj(name,schema,options);f.type="array";f.key=options.path;options.lookup[(0,_sfPath.stringify)(options.path)]=f;var required=schema.required&&schema.required.indexOf(options.path[options.path.length-1])!==-1;var arrPath=options.path.slice();arrPath.push("");f.items=[defaultFormDef(name,schema.items,{path:arrPath,required:required||false,lookup:options.lookup,ignore:options.ignore,global:options.global})];return f}}function createDefaults(){return{string:[select,text],object:[fieldset],number:[number],integer:[integer],"boolean":[checkbox],array:[checkboxes,array]}}function defaultForm(schema,defaultSchemaTypes,ignore,globalOptions){var form=[];var lookup={};ignore=ignore||{};globalOptions=globalOptions||{};defaultSchemaTypes=defaultSchemaTypes||createDefaults();if(schema.properties){Object.keys(schema.properties).forEach(function(key){if(ignore[key]!==true){var required=schema.required&&schema.required.indexOf(key)!==-1;var def=defaultFormDefinition(defaultSchemaTypes,key,schema.properties[key],{path:[key],lookup:lookup,ignore:ignore,required:required,global:globalOptions});if(def){form.push(def)}}})}else{throw new Error('Not implemented. Only type "object" allowed at root level of schema.')}return{form:form,lookup:lookup}}}])})},function(module,exports){module.exports=tv4},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var validator={};validator.validate=function(form,value){if(!form){return{valid:true}}var schema=form.schema;if(!schema){return{valid:true}}if(value===""){value=undefined}if(form.type==="number"&&value===null){value=undefined}var wrap={type:"object",properties:{}};var propName=form.key[form.key.length-1];wrap.properties[propName]=schema;if(form.required){wrap.required=[propName]}var valueWrap={};if(_angular2.default.isDefined(value)){valueWrap[propName]=value}return _tv2.default.validateResult(valueWrap,wrap)};return validator};var _tv=__webpack_require__(7);var _tv2=_interopRequireDefault(_tv);var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var defaultMessages={"default":"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};defaultMessages.number=defaultMessages[105];defaultMessages.required=defaultMessages[302];defaultMessages.min=defaultMessages[101];defaultMessages.max=defaultMessages[103];defaultMessages.maxlength=defaultMessages[201];defaultMessages.minlength=defaultMessages[200];defaultMessages.pattern=defaultMessages[202];this.setDefaultMessages=function(messages){defaultMessages=messages};this.getDefaultMessages=function(){return defaultMessages};this.setDefaultMessage=function(error,msg){defaultMessages[error]=msg};this.$get=["$interpolate",function($interpolate){var service={};service.defaultMessages=defaultMessages;service.interpolate=function(error,value,viewValue,form,global){global=global||{};var validationMessage=form.validationMessage||{};if(error.indexOf("tv4-")===0){error=error.substring(4)}var message=validationMessage["default"]||global["default"]||"";[validationMessage,global,defaultMessages].some(function(val){if(_angular2.default.isString(val)||_angular2.default.isFunction(val)){message=val;return true}if(val&&val[error]){message=val[error];return true}});var context={error:error,value:value,viewValue:viewValue,form:form,schema:form.schema,title:form.title||form.schema&&form.schema.title};if(_angular2.default.isFunction(message)){return message(context)}else{return $interpolate(message)(context)}};return service}]};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){this.parse=_jsonSchemaFormCore.sfPath.parse;this.stringify=_jsonSchemaFormCore.sfPath.stringify;this.normalize=_jsonSchemaFormCore.sfPath.normalize;this.$get=function(){return _jsonSchemaFormCore.sfPath}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _jsonSchemaFormCore=__webpack_require__(6);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfSelect,schemaForm,sfValidator,sfPath){var setIndex=function setIndex(index){return function(form){if(form.key){form.key[form.key.indexOf("")]=index}}};return{restrict:"A",scope:true,require:"?ngModel",link:function link(scope,element,attrs,ngModel){var formDefCache={};scope.validateArray=_angular2.default.noop;if(ngModel){scope.$emit("schemaFormPropagateNgModelController",ngModel)}var once=scope.$watch(attrs.sfArray,function(form){if(!form){return}var list=sfSelect(form.key,scope.model);var key=sfPath.normalize(form.key);scope.$watch("model"+(key[0]!=="["?".":"")+key,function(value){list=scope.modelArray=value});if(_angular2.default.isUndefined(list)){list=[];sfSelect(form.key,scope.model,list)}scope.modelArray=list;if(form.items){var subForm=form.items[0];if(form.items.length>1){subForm={type:"section",items:form.items.map(function(item){item.ngModelOptions=form.ngModelOptions;if(_angular2.default.isUndefined(item.readonly)){item.readonly=form.readonly}return item})}}}scope.copyWithIndex=function(index){if(!formDefCache[index]){if(subForm){var copy=_angular2.default.copy(subForm);copy.arrayIndex=index;schemaForm.traverseForm(copy,setIndex(index));formDefCache[index]=copy}}return formDefCache[index]};scope.appendToArray=function(){var len=list.length;var copy=scope.copyWithIndex(len);schemaForm.traverseForm(copy,function(part){if(part.key){var def;if(_angular2.default.isDefined(part["default"])){def=part["default"]}if(_angular2.default.isDefined(part.schema)&&_angular2.default.isDefined(part.schema["default"])){def=part.schema["default"]}if(_angular2.default.isDefined(def)){sfSelect(part.key,scope.model,def)}}});if(len===list.length){var type=sfSelect("schema.items.type",form);var dflt;if(type==="object"){dflt={}}else if(type==="array"){dflt=[]}list.push(dflt)}scope.validateArray();return list};scope.deleteFromArray=function(index){list.splice(index,1);scope.validateArray();if(ngModel&&ngModel.$setDirty){ngModel.$setDirty()}return list};if(!form.titleMap&&form.startEmpty!==true&&list.length===0){scope.appendToArray()}if(form.titleMap&&form.titleMap.length>0){scope.titleMapValues=[];var updateTitleMapValues=function updateTitleMapValues(arr){scope.titleMapValues=[];arr=arr||[];form.titleMap.forEach(function(item){scope.titleMapValues.push(arr.indexOf(item.value)!==-1)})};updateTitleMapValues(scope.modelArray);scope.$watchCollection("modelArray",updateTitleMapValues);scope.$watchCollection("titleMapValues",function(vals,old){if(vals&&vals!==old){var arr=scope.modelArray;while(arr.length>0){arr.pop()}form.titleMap.forEach(function(item,index){if(vals[index]){arr.push(item.value)}});scope.validateArray()}})}if(ngModel){var error;scope.validateArray=function(){var result=sfValidator.validate(form,scope.modelArray.length>0?scope.modelArray:undefined);Object.keys(ngModel.$error).filter(function(k){return k.indexOf("tv4-")===0}).forEach(function(k){ngModel.$setValidity(k,true)});if(result.valid===false&&result.error&&(result.error.dataPath===""||result.error.dataPath==="/"+form.key[form.key.length-1])){ngModel.$setViewValue(scope.modelArray);error=result.error;ngModel.$setValidity("tv4-"+result.error.code,false)}};scope.$on("schemaFormValidate",scope.validateArray);scope.hasSuccess=function(){if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return ngModel.$valid&&!ngModel.$pristine&&!ngModel.$isEmpty(ngModel.$modelValue)}else{return ngModel.$valid&&(!ngModel.$pristine||!ngModel.$isEmpty(ngModel.$modelValue))}};scope.hasError=function(){if(!scope.options||!scope.options.pristine||scope.options.pristine.errors!==false){return ngModel.$invalid}else{return ngModel.$invalid&&!ngModel.$pristine}};scope.schemaError=function(){return error}}once()})}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){return{require:"ngModel",restrict:"AC",scope:false,link:function link(scope,element,attrs,ctrl){var form=scope.$eval(attrs.sfChanged);if(form&&form.onChange){ctrl.$viewChangeListeners.push(function(){if(_angular2.default.isFunction(form.onChange)){form.onChange(ctrl.$modelValue,form)}else{scope.evalExpr(form.onChange,{modelValue:ctrl.$modelValue,form:form})}})}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.default=function($parse,$compile,$http,$templateCache,$interpolate,$q,sfErrorMessage,sfPath,sfSelect){var keyFormat={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:false,transclude:false,scope:true,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function pre(scope,element,attrs,ctrl){var sfSchema=ctrl[0];var formCtrl=ctrl[1];var keyCtrl=ctrl[2];scope.$on("schemaFormPropagateNgModelController",function(event,ngModel){event.stopPropagation();event.preventDefault();scope.ngModel=ngModel});scope.form=sfSchema.lookup["f"+attrs.sfField]},post:function post(scope,element,attrs,ctrl){var sfSchema=ctrl[0];var formCtrl=ctrl[1];var keyCtrl=ctrl[2];scope.showTitle=function(){return scope.form&&scope.form.notitle!==true&&scope.form.title};scope.getKey=function(requiredFormat){var format=requiredFormat||keyFormat.COMPLETE;var key=scope.parentKey?scope.parentKey.slice(0,scope.parentKey.length-1):[];if(typeof scope.$index==="number"){key=key.concat(scope.$index)}if(scope.form.key&&scope.form.key.length){if(typeof key[key.length-1]==="number"&&scope.form.key.length>=1){scope.completeKey=key.concat(scope.form.key.slice(-1))}else{scope.completeKey=scope.form.key.slice()}}if(!Array.isArray(scope.completeKey)){return undefined}if(format===keyFormat.COMPLETE){return scope.completeKey}return scope.completeKey.reduce(function(output,input,i){if(-1!==[format].indexOf(typeof input==="undefined"?"undefined":_typeof(input))){return output.concat(input)}return output},[])};if(scope.form.key)scope.completeKey=scope.getKey();scope.path=function(modelPath){var i=-1;modelPath=modelPath.replace(/\[\]/gi,function(matched){i++;return scope.$i[i]});return scope.$eval(modelPath,scope)};scope.fieldId=function(prependFormName,omitArrayIndexes){var formName=prependFormName&&formCtrl&&formCtrl.$name?formCtrl.$name:undefined;var key=scope.getKey();if(Array.isArray(key)){return sfPath.name(key,"-",formName,omitArrayIndexes)}else{return""}};scope.listToCheckboxValues=function(list){var values={};_angular2.default.forEach(list,function(v){values[v]=true});return values};scope.checkboxValuesToList=function(values){var lst=[];_angular2.default.forEach(values,function(v,k){if(v){lst.push(k)}});return lst};scope.buttonClick=function($event,form){if(_angular2.default.isFunction(form.onClick)){form.onClick($event,form)}else if(_angular2.default.isString(form.onClick)){if(sfSchema){sfSchema.evalInParentScope(form.onClick,{$event:$event,form:form})}else{scope.$eval(form.onClick,{$event:$event,form:form})}}};scope.evalExpr=function(expression,locals){if(sfSchema){return sfSchema.evalInParentScope(expression,locals)}return scope.$eval(expression,locals)};scope.evalInScope=function(expression,locals){if(expression){return scope.$eval(expression,locals)}};scope.interp=function(expression,locals){return expression&&$interpolate(expression)(locals)};scope.hasSuccess=function(){if(!scope.ngModel){return false}if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return scope.ngModel.$valid&&!scope.ngModel.$pristine&&!scope.ngModel.$isEmpty(scope.ngModel.$modelValue)}else{return scope.ngModel.$valid&&(!scope.ngModel.$pristine||!scope.ngModel.$isEmpty(scope.ngModel.$modelValue))}};scope.hasError=function(){if(!scope.ngModel){return false}if(!scope.options||!scope.options.pristine||scope.options.pristine.errors!==false){return scope.ngModel.$invalid}else{return scope.ngModel.$invalid&&!scope.ngModel.$pristine}};scope.errorMessage=function(schemaError){return sfErrorMessage.interpolate(schemaError&&schemaError.code+""||"default",scope.ngModel&&scope.ngModel.$modelValue||"",scope.ngModel&&scope.ngModel.$viewValue||"",scope.form,scope.options&&scope.options.validationMessage)};scope.form.htmlClass=scope.form.htmlClass||"";scope.form.htmlClass+=(scope.form.htmlClass?" ":"")+scope.fieldId(false,true);var form=scope.form;if(form.key){scope.$on("schemaForm.error."+form.key.join("."),function(event,error,validationMessage,validity,formName){formName=validity;if(validationMessage===true||validationMessage===false){validity=validationMessage;validationMessage=undefined}if(formName!=undefined&&scope.ngModel.$$parentForm.$name!==formName){return}if(scope.ngModel&&error){if(scope.ngModel.$setDirty){scope.ngModel.$setDirty()}else{scope.ngModel.$dirty=true;scope.ngModel.$pristine=false}if(validationMessage){if(!form.validationMessage){form.validationMessage={}}form.validationMessage[error]=validationMessage}scope.ngModel.$setValidity(error,validity===true);if(validity===true){scope.ngModel.$validate();scope.$broadcast("schemaFormValidate")}}});scope.$on("$destroy",function(){var key=scope.getKey();if(!scope.externalDestructionInProgress){var destroyStrategy=form.destroyStrategy||scope.options&&scope.options.destroyStrategy||"remove";if(key&&destroyStrategy!=="retain"){var obj=scope.model;if(key.length>1){obj=sfSelect(key.slice(0,key.length-1),obj)}if(obj===undefined){return}var type=form.schema&&form.schema.type||"";if(destroyStrategy==="empty"&&type.indexOf("string")!==-1){obj[key.slice(-1)]=""}else if(destroyStrategy==="empty"&&type.indexOf("object")!==-1){obj[key.slice(-1)]={}}else if(destroyStrategy==="empty"&&type.indexOf("array")!==-1){obj[key.slice(-1)]=[]}else if(destroyStrategy==="null"){obj[key.slice(-1)]=null}else{delete obj[key.slice(-1)]}}}})}}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){
+return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($injector,sfErrorMessage){var $sanitize=$injector.has("$sanitize")?$injector.get("$sanitize"):function(html){return html};return{scope:false,restrict:"EA",link:function link(scope,element,attrs){var message="";if(attrs.sfMessage){scope.$watch(attrs.sfMessage,function(msg){if(msg){message=$sanitize(msg);update(!!scope.ngModel)}})}var currentMessage;var setMessage=function setMessage(msg){if(msg!==currentMessage){element.html(msg);currentMessage=msg}};var update=function update(checkForErrors){if(checkForErrors){if(!scope.hasError()){setMessage(message)}else{var errors=[];_angular2.default.forEach(scope.ngModel&&scope.ngModel.$error,function(status,code){if(status){errors.push(code)}});errors=errors.filter(function(e){return e!=="schemaForm"});var error=errors[0];if(error){setMessage(sfErrorMessage.interpolate(error,scope.ngModel.$modelValue,scope.ngModel.$viewValue,scope.form,scope.options&&scope.options.validationMessage))}else{setMessage(message)}}}else{setMessage(message)}};update();var once=scope.$watch("ngModel",function(ngModel){if(ngModel){ngModel.$parsers.push(function(val){update(true);return val});ngModel.$formatters.push(function(val){update(true);return val});once()}});scope.$watchCollection("ngModel.$error",function(){update(!!scope.ngModel)})}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sel,sfPath,schemaForm){return{scope:true,controller:["$scope",function SFArrayController($scope){this.key=$scope.form&&$scope.form.key?$scope.form.key.splice(0,-2):[]}],link:function link(scope,element,attrs){scope.min=0;scope.modelArray=scope.$eval(attrs.sfNewArray);var watchFn=function watchFn(){scope.modelArray=scope.$eval(attrs.sfNewArray);if(scope.ngModel&&scope.ngModel.$pristine&&scope.firstDigest&&(!scope.options||scope.options.validateOnRender!==true)){return}else if(scope.validateField){scope.validateField()}};var onChangeFn=function onChangeFn(){if(scope.form&&scope.form.onChange){if(_angular2.default.isFunction(scope.form.onChange)){scope.form.onChange(scope.modelArray,scope.form)}else{scope.evalExpr(scope.form.onChange,{modelValue:scope.modelArray,form:scope.form})}}};var getOrCreateModel=function getOrCreateModel(){var model=scope.modelArray;if(!model){var selection=sfPath.parse(attrs.sfNewArray);model=[];sel(selection,scope,model);scope.modelArray=model}return model};var once=scope.$watch("form",function(form){if(!form){return}if(!form.titleMap&&form.startEmpty!==true&&(!scope.modelArray||scope.modelArray.length===0)){scope.appendToArray()}if(scope.form&&scope.form.schema&&scope.form.schema.uniqueItems===true){scope.$watch(attrs.sfNewArray,watchFn,true);scope.$watch([attrs.sfNewArray,attrs.sfNewArray+".length"],onChangeFn)}else{if(scope.$watchGroup){scope.$watchGroup([attrs.sfNewArray,attrs.sfNewArray+".length"],function(){watchFn();onChangeFn()})}else{scope.$watch(attrs.sfNewArray,function(){watchFn();onChangeFn()});scope.$watch(attrs.sfNewArray+".length",function(){watchFn();onChangeFn()})}}if(form.titleMap&&form.titleMap.length>0){scope.titleMapValues=[];var updateTitleMapValues=function updateTitleMapValues(arr){scope.titleMapValues=[];arr=arr||[];form.titleMap.forEach(function(item){scope.titleMapValues.push(arr.indexOf(item.value)!==-1)})};updateTitleMapValues(scope.modelArray);scope.$watchCollection("modelArray",updateTitleMapValues);scope.$watchCollection("titleMapValues",function(vals,old){if(vals&&vals!==old){var arr=getOrCreateModel();form.titleMap.forEach(function(item,index){var arrIndex=arr.indexOf(item.value);if(arrIndex===-1&&vals[index]){arr.push(item.value)}if(arrIndex!==-1&&!vals[index]){arr.splice(arrIndex,1)}});if(scope.validateField){scope.validateField()}}})}once()});scope.appendToArray=function(){var empty;var model=getOrCreateModel();if(scope.form&&scope.form.schema&&scope.form.schema.items){var items=scope.form.schema.items;if(items.type&&items.type.indexOf("object")!==-1){empty={};if(!scope.options||scope.options.setSchemaDefaults!==false){empty=_angular2.default.isDefined(items["default"])?items["default"]:empty;if(empty){schemaForm.traverseSchema(items,function(prop,path){if(_angular2.default.isDefined(prop["default"])){sel(path,empty,prop["default"])}})}}}else if(items.type&&items.type.indexOf("array")!==-1){empty=[];if(!scope.options||scope.options.setSchemaDefaults!==false){empty=items["default"]||empty}}else{if(!scope.options||scope.options.setSchemaDefaults!==false){empty=items["default"]||empty}}}model.push(empty);return model};scope.deleteFromArray=function(index){var model=scope.modelArray;if(model){model.splice(index,1)}return model};var setIndex=function setIndex(index){return function(form){if(form.key){form.key[form.key.indexOf("")]=index}}};var formDefCache={};scope.copyWithIndex=function(index){var form=scope.form;if(!formDefCache[index]){var subForm=form.items[0];if(form.items.length>1){subForm={type:"section",items:form.items.map(function(item){item.ngModelOptions=form.ngModelOptions;if(_angular2.default.isUndefined(item.readonly)){item.readonly=form.readonly}return item})}}if(subForm){var copy=_angular2.default.copy(subForm);copy.arrayIndex=index;schemaForm.traverseForm(copy,setIndex(index));formDefCache[index]=copy}}return formDefCache[index]}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(schemaForm,sfPath){return{scope:true,require:["^^sfNewArray"],link:function link(scope,element,attrs,ctrl){var currentKey=sfPath.parse(attrs.sfParentKey);if(currentKey.length>1)currentKey=currentKey.splice(-1);scope.parentKey=scope.parentKey||[];scope.parentKey=scope.parentKey.concat(currentKey,Number(attrs.sfIndex));scope.arrayIndex=Number(attrs.sfIndex);scope.arrayIndices=scope.arrayIndices||[];scope.arrayIndices=scope.arrayIndices.concat(scope.arrayIndex);scope.$i=scope.arrayIndices}}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($compile,$http,$templateCache,$q,schemaForm,schemaFormDecorators,sfSelect,sfPath,sfBuilder){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function($scope){this.evalInParentScope=function(expr,locals){return $scope.$parent.$eval(expr,locals)};var that=this;$scope.lookup=function(lookup){if(lookup){that.lookup=lookup}return that.lookup}}],replace:false,restrict:"A",transclude:true,require:"?form",link:function link(scope,element,attrs,formCtrl,transclude){scope.formCtrl=formCtrl;var ignore={};transclude(scope,function(clone){clone.addClass("schema-form-ignore");element.prepend(clone);if(element[0].querySelectorAll){var models=element[0].querySelectorAll("[ng-model]");if(models){for(var i=0;i<models.length;i++){var key=models[i].getAttribute("ng-model");ignore[key.substring(key.indexOf(".")+1)]=true}}}});var lastDigest={};var childScope;var render=function render(schema,form){var asyncTemplates=[];var merged=schemaForm.merge(schema,form,ignore,scope.options,undefined,asyncTemplates);if(asyncTemplates.length>0){$q.all(asyncTemplates.map(function(form){return $http.get(form.templateUrl,{cache:$templateCache}).then(function(res){form.template=res.data})})).then(function(){internalRender(schema,form,merged)})}else{internalRender(schema,form,merged)}};var internalRender=function internalRender(schema,form,merged){if(childScope){scope.externalDestructionInProgress=true;childScope.$destroy();scope.externalDestructionInProgress=false}childScope=scope.$new();childScope.schemaForm={form:merged,schema:schema};element.children(":not(.schema-form-ignore)").remove();var slots={};var slotsFound=element[0].querySelectorAll("*[sf-insert-field]");for(var i=0;i<slotsFound.length;i++){slots[slotsFound[i].getAttribute("sf-insert-field")]=slotsFound[i]}var decorator=schemaFormDecorators.decorator(attrs.sfUseDecorator);var lookup=Object.create(null);scope.lookup(lookup);element[0].appendChild(sfBuilder.build(merged,decorator,slots,lookup));childScope.firstDigest=true;setTimeout(function(){childScope.firstDigest=false},0);$compile(element.children())(childScope);if(!scope.options||scope.options.setSchemaDefaults!==false){schemaForm.traverseSchema(schema,function(prop,path){if(_angular2.default.isDefined(prop["default"])){var val=sfSelect(path,scope.model);if(_angular2.default.isUndefined(val)){sfSelect(path,scope.model,prop["default"])}}})}scope.$emit("sf-render-finished",element)};var defaultForm=["*"];scope.$watch(function(){var schema=scope.schema;var form=scope.initialForm||defaultForm;if(form&&schema&&schema.type&&(lastDigest.form!==form||lastDigest.schema!==schema)&&Object.keys(schema.properties).length>0){lastDigest.schema=schema;lastDigest.form=form;render(schema,form)}});scope.$on("schemaFormRedraw",function(){var schema=scope.schema;var form=scope.initialForm?_angular2.default.copy(scope.initialForm):["*"];if(schema){render(schema,form)}});scope.$on("$destroy",function(){scope.externalDestructionInProgress=true});scope.evalExpr=function(expression,locals){return scope.$parent.$eval(expression,locals)}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfValidator,$parse,sfSelect){return{restrict:"A",scope:false,priority:500,require:"ngModel",link:function link(scope,element,attrs,ngModel){scope.$emit("schemaFormPropagateNgModelController",ngModel);var error=null;var form=scope.$eval(attrs.schemaValidate);if(form.copyValueTo){ngModel.$viewChangeListeners.push(function(){var paths=form.copyValueTo;_angular2.default.forEach(paths,function(path){sfSelect(path,scope.model,ngModel.$modelValue)})})}var validate=function validate(viewValue){if(!form){return viewValue}if(scope.options&&scope.options.tv4Validation===false){return viewValue}var result=sfValidator.validate(form,viewValue);Object.keys(ngModel.$error).filter(function(k){return k.indexOf("tv4-")===0}).forEach(function(k){ngModel.$setValidity(k,true)});if(!result.valid){ngModel.$setValidity("tv4-"+result.error.code,false);error=result.error;if(ngModel.$validators){return viewValue}return undefined}return viewValue};if(typeof form.ngModel==="function"){form.ngModel(ngModel)}["$parsers","$viewChangeListeners","$formatters"].forEach(function(attr){if(form[attr]&&ngModel[attr]){form[attr].forEach(function(fn){ngModel[attr].push(fn)})}});["$validators","$asyncValidators"].forEach(function(attr){if(form[attr]&&ngModel[attr]){_angular2.default.forEach(form[attr],function(fn,name){ngModel[attr][name]=fn})}});ngModel.$parsers.push(validate);if(ngModel.$validators){ngModel.$validators.schemaForm=function(){return!Object.keys(ngModel.$error).some(function(e){return e!=="schemaForm"})}}var schema=form.schema;scope.validateField=function(formName){if(formName!=undefined&&ngModel.$$parentForm.$name!==formName){return}if(schema&&schema.type.indexOf("array")!==-1){validate(ngModel.$modelValue)}if(ngModel.$setDirty){ngModel.$setDirty();ngModel.$setViewValue(ngModel.$viewValue);ngModel.$commitViewValue();if(form.type==="checkbox"){if(form.required&&ngModel.$modelValue===undefined){ngModel.$setValidity("tv4-302",false)}}else if(form.required&&ngModel.$isEmpty(ngModel.$modelValue)){ngModel.$setValidity("tv4-302",false)}}else{ngModel.$setViewValue(ngModel.$viewValue)}};var first=true;ngModel.$formatters.push(function(val){if(ngModel.$pristine&&first&&(!scope.options||scope.options.validateOnRender!==true)){first=false;return val}validate(ngModel.$modelValue);return val});scope.$on("schemaFormValidate",function(event,formName){scope.validateField(formName)});scope.schemaError=function(){return error}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}}])})},function(module,exports){module.exports=angular},function(module,exports){module.exports=tv4}])});
\ No newline at end of file
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index fc3a91d..5548285 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -7,14 +7,14 @@
  */
 (function webpackUniversalModuleDefinition(root, factory) {
 	if(typeof exports === 'object' && typeof module === 'object')
-		module.exports = factory(require("angular"), require("tv4"));
+		module.exports = factory();
 	else if(typeof define === 'function' && define.amd)
-		define(["angular", "tv4"], factory);
+		define([], factory);
 	else {
-		var a = typeof exports === 'object' ? factory(require("angular"), require("tv4")) : factory(root["angular"], root["tv4"]);
+		var a = factory();
 		for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
 	}
-})(this, function(__WEBPACK_EXTERNAL_MODULE_19__, __WEBPACK_EXTERNAL_MODULE_20__) {
+})(this, function() {
 return /******/ (function(modules) { // webpackBootstrap
 /******/ 	// The module cache
 /******/ 	var installedModules = {};
@@ -64,3627 +64,30 @@ return /******/ (function(modules) { // webpackBootstrap
 	'use strict';
 
 	__webpack_require__(1);
-	__webpack_require__(2);
 
 /***/ },
 /* 1 */
-/***/ function(module, exports, __webpack_require__) {
-
-	/*!
-	 * angular-schema-form
-	 * @version 1.0.0-alpha.2
-	 * @link https://github.com/json-schema-form/angular-schema-form
-	 * @license MIT
-	 * Copyright (c) 2016 JSON Schema Form
-	 */
-	(function webpackUniversalModuleDefinition(root, factory) {
-		if(true)
-			module.exports = factory(__webpack_require__(19), __webpack_require__(20));
-		else if(typeof define === 'function' && define.amd)
-			define(["angular", "tv4"], factory);
-		else {
-			var a = typeof exports === 'object' ? factory(require("angular"), require("tv4")) : factory(root["angular"], root["tv4"]);
-			for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
-		}
-	})(this, function(__WEBPACK_EXTERNAL_MODULE_2__, __WEBPACK_EXTERNAL_MODULE_8__) {
-	return /******/ (function(modules) { // webpackBootstrap
-	/******/ 	// The module cache
-	/******/ 	var installedModules = {};
-
-	/******/ 	// The require function
-	/******/ 	function __webpack_require__(moduleId) {
-
-	/******/ 		// Check if module is in cache
-	/******/ 		if(installedModules[moduleId])
-	/******/ 			return installedModules[moduleId].exports;
-
-	/******/ 		// Create a new module (and put it into the cache)
-	/******/ 		var module = installedModules[moduleId] = {
-	/******/ 			exports: {},
-	/******/ 			id: moduleId,
-	/******/ 			loaded: false
-	/******/ 		};
-
-	/******/ 		// Execute the module function
-	/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
-
-	/******/ 		// Flag the module as loaded
-	/******/ 		module.loaded = true;
-
-	/******/ 		// Return the exports of the module
-	/******/ 		return module.exports;
-	/******/ 	}
-
-
-	/******/ 	// expose the modules object (__webpack_modules__)
-	/******/ 	__webpack_require__.m = modules;
-
-	/******/ 	// expose the module cache
-	/******/ 	__webpack_require__.c = installedModules;
-
-	/******/ 	// __webpack_public_path__
-	/******/ 	__webpack_require__.p = "";
-
-	/******/ 	// Load entry module and return exports
-	/******/ 	return __webpack_require__(0);
-	/******/ })
-	/************************************************************************/
-	/******/ ([
-	/* 0 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		module.exports = __webpack_require__(1);
-
-
-	/***/ },
-	/* 1 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		var _builder = __webpack_require__(3);
-
-		var _builder2 = _interopRequireDefault(_builder);
-
-		var _decorators = __webpack_require__(4);
-
-		var _decorators2 = _interopRequireDefault(_decorators);
-
-		var _schemaForm = __webpack_require__(5);
-
-		var _schemaForm2 = _interopRequireDefault(_schemaForm);
-
-		var _jsonSchemaFormCore = __webpack_require__(6);
-
-		var _validator = __webpack_require__(7);
-
-		var _validator2 = _interopRequireDefault(_validator);
-
-		var _errors = __webpack_require__(9);
-
-		var _errors2 = _interopRequireDefault(_errors);
-
-		var _sfPath = __webpack_require__(10);
-
-		var _sfPath2 = _interopRequireDefault(_sfPath);
-
-		var _array = __webpack_require__(11);
-
-		var _array2 = _interopRequireDefault(_array);
-
-		var _changed = __webpack_require__(12);
-
-		var _changed2 = _interopRequireDefault(_changed);
-
-		var _field = __webpack_require__(13);
-
-		var _field2 = _interopRequireDefault(_field);
-
-		var _message = __webpack_require__(14);
-
-		var _message2 = _interopRequireDefault(_message);
-
-		var _newArray = __webpack_require__(15);
-
-		var _newArray2 = _interopRequireDefault(_newArray);
-
-		var _schemaForm3 = __webpack_require__(16);
-
-		var _schemaForm4 = _interopRequireDefault(_schemaForm3);
-
-		var _schemaValidate = __webpack_require__(17);
-
-		var _schemaValidate2 = _interopRequireDefault(_schemaValidate);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-		// Deps is sort of a problem for us, maybe in the future we will ask the user to depend
-		// on modules for add-ons
-
-		var deps = [];
-		try {
-		  //This throws an expection if module does not exist.
-		  _angular2.default.module('ngSanitize');
-		  deps.push('ngSanitize');
-		} catch (e) {}
-
-		try {
-		  //This throws an expection if module does not exist.
-		  _angular2.default.module('ui.sortable');
-		  deps.push('ui.sortable');
-		} catch (e) {}
-
-		try {
-		  //This throws an expection if module does not exist.
-		  _angular2.default.module('angularSpectrumColorpicker');
-		  deps.push('angularSpectrumColorpicker');
-		} catch (e) {}
-
-		_angular2.default.module('schemaForm', deps)
-		// Providers and services
-		.provider('sfPath', _sfPath2.default).provider('sfBuilder', ['sfPathProvider', _builder2.default]).provider('schemaFormDecorators', ['$compileProvider', 'sfPathProvider', _decorators2.default]).provider('sfErrorMessage', _errors2.default).provider('schemaForm', ['sfPathProvider', _schemaForm2.default]).factory('sfSelect', function () {
-		  return _jsonSchemaFormCore.select;
-		}).factory('sfValidator', _validator2.default)
-
-		// Directives
-		.directive('sfArray', ['sfSelect', 'schemaForm', 'sfValidator', 'sfPath', _array2.default]).directive('sfChanged', _changed2.default).directive('sfField', ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', _field2.default]).directive('sfMessage', ['$injector', 'sfErrorMessage', _message2.default]).directive('sfNewArray', ['sfSelect', 'sfPath', 'schemaForm', _newArray2.default]).directive('sfSchema', ['$compile', '$http', '$templateCache', '$q', 'schemaForm', 'schemaFormDecorators', 'sfSelect', 'sfPath', 'sfBuilder', _schemaForm4.default]).directive('schemaValidate', ['sfValidator', '$parse', 'sfSelect', _schemaValidate2.default]);
-
-	/***/ },
-	/* 2 */
-	/***/ function(module, exports) {
-
-		module.exports = angular;
-
-	/***/ },
-	/* 3 */
-	/***/ function(module, exports) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function (sfPathProvider) {
-
-		  var SNAKE_CASE_REGEXP = /[A-Z]/g;
-		  var snakeCase = function snakeCase(name, separator) {
-		    separator = separator || '_';
-		    return name.replace(SNAKE_CASE_REGEXP, function (letter, pos) {
-		      return (pos ? separator : '') + letter.toLowerCase();
-		    });
-		  };
-		  var formId = 0;
-
-		  var builders = {
-		    sfField: function sfField(args) {
-		      args.fieldFrag.firstChild.setAttribute('sf-field', formId);
-
-		      // We use a lookup table for easy access to our form.
-		      args.lookup['f' + formId] = args.form;
-		      formId++;
-		    },
-		    ngModel: function ngModel(args) {
-		      if (!args.form.key) {
-		        return;
-		      }
-		      var key = args.form.key;
-
-		      // Redact part of the key, used in arrays
-		      // KISS keyRedaction is a number.
-		      if (args.state.keyRedaction) {
-		        key = key.slice(args.state.keyRedaction);
-		      }
-
-		      // Stringify key.
-		      var modelValue;
-		      if (!args.state.modelValue) {
-		        var strKey = sfPathProvider.stringify(key).replace(/"/g, '&quot;');
-		        modelValue = args.state.modelName || 'model';
-
-		        if (strKey) {
-		          // Sometimes, like with arrays directly in arrays strKey is nothing.
-		          modelValue += (strKey[0] !== '[' ? '.' : '') + strKey;
-		        }
-		      } else {
-		        // Another builder, i.e. array has overriden the modelValue
-		        modelValue = args.state.modelValue;
-		      }
-
-		      // Find all sf-field-value attributes.
-		      // No value means a add a ng-model.
-		      // sf-field-value="replaceAll", loop over attributes and replace $$value$$ in each.
-		      // sf-field-value="attrName", replace or set value of that attribute.
-		      var nodes = args.fieldFrag.querySelectorAll('[sf-field-model]');
-		      for (var i = 0; i < nodes.length; i++) {
-		        var n = nodes[i];
-		        var conf = n.getAttribute('sf-field-model');
-		        if (!conf || conf === '') {
-		          n.setAttribute('ng-model', modelValue);
-		        } else if (conf === 'replaceAll') {
-		          var attributes = n.attributes;
-		          for (var j = 0; j < attributes.length; j++) {
-		            if (attributes[j].value && attributes[j].value.indexOf('$$value') !== -1) {
-		              attributes[j].value = attributes[j].value.replace(/\$\$value\$\$/g, modelValue);
-		            }
-		          }
-		        } else {
-		          var val = n.getAttribute(conf);
-		          if (val && val.indexOf('$$value$$')) {
-		            n.setAttribute(conf, val.replace(/\$\$value\$\$/g, modelValue));
-		          } else {
-		            n.setAttribute(conf, modelValue);
-		          }
-		        }
-		      }
-		    },
-		    simpleTransclusion: function simpleTransclusion(args) {
-		      var children = args.build(args.form.items, args.path + '.items', args.state);
-		      args.fieldFrag.firstChild.appendChild(children);
-		    },
-
-		    // Patch on ngModelOptions, since it doesn't like waiting for its value.
-		    ngModelOptions: function ngModelOptions(args) {
-		      if (args.form.ngModelOptions && Object.keys(args.form.ngModelOptions).length > 0) {
-		        args.fieldFrag.firstChild.setAttribute('ng-model-options', JSON.stringify(args.form.ngModelOptions));
-		      }
-		    },
-		    transclusion: function transclusion(args) {
-		      var transclusions = args.fieldFrag.querySelectorAll('[sf-field-transclude]');
-
-		      if (transclusions.length) {
-		        for (var i = 0; i < transclusions.length; i++) {
-		          var n = transclusions[i];
-
-		          // The sf-transclude attribute is not a directive,
-		          // but has the name of what we're supposed to
-		          // traverse. Default to `items`
-		          var sub = n.getAttribute('sf-field-transclude') || 'items';
-		          var items = args.form[sub];
-
-		          if (items) {
-		            var childFrag = args.build(items, args.path + '.' + sub, args.state);
-		            n.appendChild(childFrag);
-		          }
-		        }
-		      }
-		    },
-		    condition: function condition(args) {
-		      // Do we have a condition? Then we slap on an ng-if on all children,
-		      // but be nice to existing ng-if.
-		      if (args.form.condition) {
-		        var evalExpr = 'evalExpr(' + args.path + '.condition, { model: model, "arrayIndex": $index})';
-		        if (args.form.key) {
-		          var strKey = sfPathProvider.stringify(args.form.key);
-		          evalExpr = 'evalExpr(' + args.path + '.condition,{ model: model, "arrayIndex": $index, ' + '"modelValue": model' + (strKey[0] === '[' ? '' : '.') + strKey + '})';
-		        };
-
-		        var children = args.fieldFrag.children || args.fieldFrag.childNodes;
-		        for (var i = 0; i < children.length; i++) {
-		          var child = children[i];
-		          var ngIf = child.getAttribute('ng-if');
-		          child.setAttribute('ng-if', ngIf ? '(' + ngIf + ') || (' + evalExpr + ')' : evalExpr);
-		        }
-		      }
-		    },
-		    array: function array(args) {
-		      var items = args.fieldFrag.querySelector('[schema-form-array-items]');
-		      if (items) {
-		        var state = angular.copy(args.state);
-		        state.keyRedaction = 0;
-		        state.keyRedaction += args.form.key.length + 1;
-
-		        // Special case, an array with just one item in it that is not an object.
-		        // So then we just override the modelValue
-		        if (args.form.schema && args.form.schema.items && args.form.schema.items.type && args.form.schema.items.type.indexOf('object') === -1 && args.form.schema.items.type.indexOf('array') === -1) {
-		          var strKey = sfPathProvider.stringify(args.form.key).replace(/"/g, '&quot;') + '[$index]';
-		          state.modelValue = 'modelArray[$index]';
-		        } else {
-		          state.modelName = 'item';
-		        }
-
-		        // Flag to the builder that where in an array.
-		        // This is needed for compatabiliy if a "old" add-on is used that
-		        // hasn't been transitioned to the new builder.
-		        state.arrayCompatFlag = true;
-
-		        var childFrag = args.build(args.form.items, args.path + '.items', state);
-		        items.appendChild(childFrag);
-		      }
-		    },
-		    numeric: function numeric(args) {
-		      var inputFrag = args.fieldFrag.querySelector('input');
-		      var maximum = args.form.maximum || false;
-		      var exclusiveMaximum = args.form.exclusiveMaximum || false;
-		      var minimum = args.form.minimum || false;
-		      var exclusiveMinimum = args.form.exclusiveMinimum || false;
-		      var multipleOf = args.form.multipleOf || false;
-		      if (inputFrag) {
-		        if (multipleOf !== false) {
-		          inputFrag.setAttribute('step', multipleOf);
-		        };
-
-		        if (maximum !== false) {
-		          if (exclusiveMaximum !== false && multipleOf !== false) {
-		            maximum = maximum - multipleOf;
-		          };
-		          inputFrag.setAttribute('max', maximum);
-		        };
-
-		        if (minimum !== false) {
-		          if (exclusiveMinimum !== false && multipleOf !== false) {
-		            minimum = minimum + multipleOf;
-		          };
-		          inputFrag.setAttribute('min', minimum);
-		        };
-		      };
-		    }
-		  };
-		  this.builders = builders;
-		  var stdBuilders = [builders.sfField, builders.ngModel, builders.ngModelOptions, builders.condition];
-		  this.stdBuilders = stdBuilders;
-
-		  this.$get = ['$templateCache', 'schemaFormDecorators', 'sfPath', function ($templateCache, schemaFormDecorators, sfPath) {
-		    var checkForSlot = function checkForSlot(form, slots) {
-		      // Finally append this field to the frag.
-		      // Check for slots
-		      if (form.key) {
-		        var slot = slots[sfPath.stringify(form.key)];
-		        if (slot) {
-		          while (slot.firstChild) {
-		            slot.removeChild(slot.firstChild);
-		          }
-		          return slot;
-		        }
-		      }
-		    };
-
-		    var _build = function _build(items, decorator, templateFn, slots, path, state, lookup) {
-		      state = state || {};
-		      lookup = lookup || Object.create(null);
-		      path = path || 'schemaForm.form';
-		      var container = document.createDocumentFragment();
-		      items.reduce(function (frag, f, index) {
-
-		        // Sanity check.
-		        if (!f.type) {
-		          return frag;
-		        }
-
-		        var field = decorator[f.type] || decorator['default'];
-		        if (!field.replace) {
-		          // Backwards compatability build
-		          var n = document.createElement(snakeCase(decorator.__name, '-'));
-		          if (state.arrayCompatFlag) {
-		            n.setAttribute('form', 'copyWithIndex($index)');
-		          } else {
-		            n.setAttribute('form', path + '[' + index + ']');
-		          }
-
-		          (checkForSlot(f, slots) || frag).appendChild(n);
-		        } else {
-		          var tmpl;
-
-		          // Reset arrayCompatFlag, it's only valid for direct children of the array.
-		          state.arrayCompatFlag = false;
-
-		          // TODO: Create a couple of testcases, small and large and
-		          //       measure optmization. A good start is probably a
-		          //       cache of DOM nodes for a particular template
-		          //       that can be cloned instead of using innerHTML
-		          var div = document.createElement('div');
-		          var template = templateFn(f, field) || templateFn(f, decorator['default']);
-		          div.innerHTML = template;
-
-		          // Move node to a document fragment, we don't want the div.
-		          tmpl = document.createDocumentFragment();
-		          while (div.childNodes.length > 0) {
-		            tmpl.appendChild(div.childNodes[0]);
-		          }
-
-		          // Possible builder, often a noop
-		          var args = {
-		            fieldFrag: tmpl,
-		            form: f,
-		            lookup: lookup,
-		            state: state,
-		            path: path + '[' + index + ']',
-
-		            // Recursive build fn
-		            build: function build(items, path, state) {
-		              return _build(items, decorator, templateFn, slots, path, state, lookup);
-		            }
-
-		          };
-
-		          // Let the form definiton override builders if it wants to.
-		          var builderFn = f.builder || field.builder;
-
-		          // Builders are either a function or a list of functions.
-		          if (typeof builderFn === 'function') {
-		            builderFn(args);
-		          } else {
-		            builderFn.forEach(function (fn) {
-		              fn(args);
-		            });
-		          }
-
-		          // Append
-		          (checkForSlot(f, slots) || frag).appendChild(tmpl);
-		        }
-		        return frag;
-		      }, container);
-
-		      return container;
-		    };
-
-		    return {
-		      /**
-		       * Builds a form from a canonical form definition
-		       */
-		      build: function build(form, decorator, slots, lookup) {
-		        return _build(form, decorator, function (form, field) {
-		          if (form.type === 'template') {
-		            return form.template;
-		          }
-		          return $templateCache.get(field.template);
-		        }, slots, undefined, undefined, lookup);
-		      },
-		      builder: builders,
-		      stdBuilders: stdBuilders,
-		      internalBuild: _build
-		    };
-		  }];
-		};
-
-	/***/ },
-	/* 4 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function ($compileProvider, sfPathProvider) {
-		  var defaultDecorator = '';
-		  var decorators = {};
-
-		  // Map template after decorator and type.
-		  var templateUrl = function templateUrl(name, form) {
-		    //schemaDecorator is alias for whatever is set as default
-		    if (name === 'sfDecorator') {
-		      name = defaultDecorator;
-		    }
-
-		    var decorator = decorators[name];
-		    if (decorator[form.type]) {
-		      return decorator[form.type].template;
-		    }
-
-		    //try default
-		    return decorator['default'].template;
-		  };
-
-		  /**************************************************
-		   * DEPRECATED                                     *
-		   * The new builder and sf-field is preferred, but *
-		   * we keep this in during a transitional period   *
-		   * so that add-ons that don't use the new builder *
-		   * works.                                         *
-		   **************************************************/
-		  //TODO: Move to a compatability extra script.
-		  var createDirective = function createDirective(name) {
-		    $compileProvider.directive(name, ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', function ($parse, $compile, $http, $templateCache, $interpolate, $q, sfErrorMessage, sfPath, sfSelect) {
-
-		      return {
-		        restrict: 'AE',
-		        replace: false,
-		        transclude: false,
-		        scope: true,
-		        require: '?^sfSchema',
-		        link: function link(scope, element, attrs, sfSchema) {
-
-		          //The ngModelController is used in some templates and
-		          //is needed for error messages,
-		          scope.$on('schemaFormPropagateNgModelController', function (event, ngModel) {
-		            event.stopPropagation();
-		            event.preventDefault();
-		            scope.ngModel = ngModel;
-		          });
-
-		          //Keep error prone logic from the template
-		          scope.showTitle = function () {
-		            return scope.form && scope.form.notitle !== true && scope.form.title;
-		          };
-
-		          scope.listToCheckboxValues = function (list) {
-		            var values = {};
-		            _angular2.default.forEach(list, function (v) {
-		              values[v] = true;
-		            });
-		            return values;
-		          };
-
-		          scope.checkboxValuesToList = function (values) {
-		            var lst = [];
-		            _angular2.default.forEach(values, function (v, k) {
-		              if (v) {
-		                lst.push(k);
-		              }
-		            });
-		            return lst;
-		          };
-
-		          scope.buttonClick = function ($event, form) {
-		            if (_angular2.default.isFunction(form.onClick)) {
-		              form.onClick($event, form);
-		            } else if (_angular2.default.isString(form.onClick)) {
-		              if (sfSchema) {
-		                //evaluating in scope outside of sfSchemas isolated scope
-		                sfSchema.evalInParentScope(form.onClick, { '$event': $event, form: form });
-		              } else {
-		                scope.$eval(form.onClick, { '$event': $event, form: form });
-		              };
-		            };
-		          };
-
-		          /**
-		           * Evaluate an expression, i.e. scope.$eval
-		           * but do it in sfSchemas parent scope sf-schema directive is used
-		           * @param {string} expression
-		           * @param {Object} locals (optional)
-		           * @return {Any} the result of the expression
-		           */
-		          scope.evalExpr = function (expression, locals) {
-		            if (sfSchema) {
-		              //evaluating in scope outside of sfSchemas isolated scope
-		              return sfSchema.evalInParentScope(expression, locals);
-		            }
-
-		            return scope.$eval(expression, locals);
-		          };
-
-		          /**
-		           * Evaluate an expression, i.e. scope.$eval
-		           * in this decorators scope
-		           * @param {string} expression
-		           * @param {Object} locals (optional)
-		           * @return {Any} the result of the expression
-		           */
-		          scope.evalInScope = function (expression, locals) {
-		            if (expression) {
-		              return scope.$eval(expression, locals);
-		            }
-		          };
-
-		          /**
-		           * Interpolate the expression.
-		           * Similar to `evalExpr()` and `evalInScope()`
-		           * but will not fail if the expression is
-		           * text that contains spaces.
-		           *
-		           * Use the Angular `{{ interpolation }}`
-		           * braces to access properties on `locals`.
-		           *
-		           * @param  {string} content The string to interpolate.
-		           * @param  {Object} locals (optional) Properties that may be accessed in the
-		           *                         `expression` string.
-		           * @return {Any} The result of the expression or `undefined`.
-		           */
-		          scope.interp = function (expression, locals) {
-		            return expression && $interpolate(expression)(locals);
-		          };
-
-		          //This works since we ot the ngModel from the array or the schema-validate directive.
-		          scope.hasSuccess = function () {
-		            if (!scope.ngModel) {
-		              return false;
-		            }
-		            return scope.ngModel.$valid && (!scope.ngModel.$pristine || !scope.ngModel.$isEmpty(scope.ngModel.$modelValue));
-		          };
-
-		          scope.hasError = function () {
-		            if (!scope.ngModel) {
-		              return false;
-		            }
-		            return scope.ngModel.$invalid && !scope.ngModel.$pristine;
-		          };
-
-		          /**
-		           * DEPRECATED: use sf-messages instead.
-		           * Error message handler
-		           * An error can either be a schema validation message or a angular js validtion
-		           * error (i.e. required)
-		           */
-		          scope.errorMessage = function (schemaError) {
-		            return sfErrorMessage.interpolate(schemaError && schemaError.code + '' || 'default', scope.ngModel && scope.ngModel.$modelValue || '', scope.ngModel && scope.ngModel.$viewValue || '', scope.form, scope.options && scope.options.validationMessage);
-		          };
-
-		          // Rebind our part of the form to the scope.
-		          var once = scope.$watch(attrs.form, function (form) {
-		            if (form) {
-		              // Workaround for 'updateOn' error from ngModelOptions
-		              // see https://github.com/Textalk/angular-schema-form/issues/255
-		              // and https://github.com/Textalk/angular-schema-form/issues/206
-		              form.ngModelOptions = form.ngModelOptions || {};
-		              scope.form = form;
-
-		              //ok let's replace that template!
-		              //We do this manually since we need to bind ng-model properly and also
-		              //for fieldsets to recurse properly.
-		              var templatePromise;
-
-		              // type: "template" is a special case. It can contain a template inline or an url.
-		              // otherwise we find out the url to the template and load them.
-		              if (form.type === 'template' && form.template) {
-		                templatePromise = $q.when(form.template);
-		              } else {
-		                var url = form.type === 'template' ? form.templateUrl : templateUrl(name, form);
-		                templatePromise = $http.get(url, { cache: $templateCache }).then(function (res) {
-		                  return res.data;
-		                });
-		              }
-
-		              templatePromise.then(function (template) {
-		                if (form.key) {
-		                  var key = form.key ? sfPathProvider.stringify(form.key).replace(/"/g, '&quot;') : '';
-		                  template = template.replace(/\$\$value\$\$/g, 'model' + (key[0] !== '[' ? '.' : '') + key);
-		                }
-		                element.html(template);
-
-		                // Do we have a condition? Then we slap on an ng-if on all children,
-		                // but be nice to existing ng-if.
-		                if (form.condition) {
-
-		                  var evalExpr = 'evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';
-		                  if (form.key) {
-		                    evalExpr = 'evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex, "modelValue": model' + sfPath.stringify(form.key) + '})';
-		                  }
-
-		                  _angular2.default.forEach(element.children(), function (child) {
-		                    var ngIf = child.getAttribute('ng-if');
-		                    child.setAttribute('ng-if', ngIf ? '(' + ngIf + ') || (' + evalExpr + ')' : evalExpr);
-		                  });
-		                }
-		                $compile(element.contents())(scope);
-		              });
-
-		              // Where there is a key there is probably a ngModel
-		              if (form.key) {
-		                // It looks better with dot notation.
-		                scope.$on('schemaForm.error.' + form.key.join('.'), function (event, error, validationMessage, validity, formName) {
-		                  // validationMessage and validity are mutually exclusive
-		                  formName = validity;
-		                  if (validationMessage === true || validationMessage === false) {
-		                    validity = validationMessage;
-		                    validationMessage = undefined;
-		                  };
-
-		                  // If we have specified a form name, and this model is not within
-		                  // that form, then leave things be.
-		                  if (formName != undefined && scope.ngModel.$$parentForm.$name !== formName) {
-		                    return;
-		                  };
-
-		                  if (scope.ngModel && error) {
-		                    if (scope.ngModel.$setDirty) {
-		                      scope.ngModel.$setDirty();
-		                    } else {
-		                      // FIXME: Check that this actually works on 1.2
-		                      scope.ngModel.$dirty = true;
-		                      scope.ngModel.$pristine = false;
-		                    };
-
-		                    // Set the new validation message if one is supplied
-		                    // Does not work when validationMessage is just a string.
-		                    if (validationMessage) {
-		                      if (!form.validationMessage) {
-		                        form.validationMessage = {};
-		                      }
-		                      form.validationMessage[error] = validationMessage;
-		                    }
-
-		                    scope.ngModel.$setValidity(error, validity === true);
-
-		                    if (validity === true) {
-		                      // Re-trigger model validator, that model itself would be re-validated
-		                      scope.ngModel.$validate();
-
-		                      // Setting or removing a validity can change the field to believe its valid
-		                      // but its not. So lets trigger its validation as well.
-		                      scope.$broadcast('schemaFormValidate');
-		                    }
-		                  }
-		                });
-
-		                // Clean up the model when the corresponding form field is $destroy-ed.
-		                // Default behavior can be supplied as a globalOption, and behavior can be overridden in the form definition.
-		                scope.$on('$destroy', function () {
-		                  // If the entire schema form is destroyed we don't touch the model
-		                  if (!scope.externalDestructionInProgress) {
-		                    var destroyStrategy = form.destroyStrategy || scope.options && scope.options.destroyStrategy || 'remove';
-		                    // No key no model, and we might have strategy 'retain'
-		                    if (form.key && destroyStrategy !== 'retain') {
-
-		                      // Get the object that has the property we wan't to clear.
-		                      var obj = scope.model;
-		                      if (form.key.length > 1) {
-		                        obj = sfSelect(form.key.slice(0, form.key.length - 1), obj);
-		                      }
-
-		                      // We can get undefined here if the form hasn't been filled out entirely
-		                      if (obj === undefined) {
-		                        return;
-		                      }
-
-		                      // Type can also be a list in JSON Schema
-		                      var type = form.schema && form.schema.type || '';
-
-		                      // Empty means '',{} and [] for appropriate types and undefined for the rest
-		                      if (destroyStrategy === 'empty' && type.indexOf('string') !== -1) {
-		                        obj[form.key.slice(-1)] = '';
-		                      } else if (destroyStrategy === 'empty' && type.indexOf('object') !== -1) {
-		                        obj[form.key.slice(-1)] = {};
-		                      } else if (destroyStrategy === 'empty' && type.indexOf('array') !== -1) {
-		                        obj[form.key.slice(-1)] = [];
-		                      } else if (destroyStrategy === 'null') {
-		                        obj[form.key.slice(-1)] = null;
-		                      } else {
-		                        delete obj[form.key.slice(-1)];
-		                      }
-		                    }
-		                  }
-		                });
-		              }
-
-		              once();
-		            }
-		          });
-		        }
-		      };
-		    }]);
-		  };
-
-		  var createManualDirective = function createManualDirective(type, templateUrl, transclude) {
-		    transclude = _angular2.default.isDefined(transclude) ? transclude : false;
-		    $compileProvider.directive('sf' + _angular2.default.uppercase(type[0]) + type.substr(1), function () {
-		      return {
-		        restrict: 'EAC',
-		        scope: true,
-		        replace: true,
-		        transclude: transclude,
-		        template: '<sf-decorator form="form"></sf-decorator>',
-		        link: function link(scope, element, attrs) {
-		          var watchThis = {
-		            'items': 'c',
-		            'titleMap': 'c',
-		            'schema': 'c'
-		          };
-		          var form = { type: type };
-		          var once = true;
-		          _angular2.default.forEach(attrs, function (value, name) {
-		            if (name[0] !== '$' && name.indexOf('ng') !== 0 && name !== 'sfField') {
-
-		              var updateForm = function updateForm(val) {
-		                if (_angular2.default.isDefined(val) && val !== form[name]) {
-		                  form[name] = val;
-
-		                  //when we have type, and if specified key we apply it on scope.
-		                  if (once && form.type && (form.key || _angular2.default.isUndefined(attrs.key))) {
-		                    scope.form = form;
-		                    once = false;
-		                  }
-		                }
-		              };
-
-		              if (name === 'model') {
-		                //"model" is bound to scope under the name "model" since this is what the decorators
-		                //know and love.
-		                scope.$watch(value, function (val) {
-		                  if (val && scope.model !== val) {
-		                    scope.model = val;
-		                  }
-		                });
-		              } else if (watchThis[name] === 'c') {
-		                //watch collection
-		                scope.$watchCollection(value, updateForm);
-		              } else {
-		                //$observe
-		                attrs.$observe(name, updateForm);
-		              }
-		            }
-		          });
-		        }
-		      };
-		    });
-		  };
-
-		  /**
-		   * DEPRECATED: use defineDecorator instead.
-		   * Create a decorator directive and its sibling "manual" use decorators.
-		   * The directive can be used to create form fields or other form entities.
-		   * It can be used in conjunction with <schema-form> directive in which case the decorator is
-		   * given it's configuration via a the "form" attribute.
-		   *
-		   * ex. Basic usage
-		   *   <sf-decorator form="myform"></sf-decorator>
-		   **
-		   * @param {string} name directive name (CamelCased)
-		   * @param {Object} templates, an object that maps "type" => "templateUrl"
-		   */
-		  this.createDecorator = function (name, templates) {
-		    //console.warn('schemaFormDecorators.createDecorator is DEPRECATED, use defineDecorator instead.');
-		    decorators[name] = { '__name': name };
-
-		    _angular2.default.forEach(templates, function (url, type) {
-		      decorators[name][type] = { template: url, replace: false, builder: [] };
-		    });
-
-		    if (!decorators[defaultDecorator]) {
-		      defaultDecorator = name;
-		    }
-		    createDirective(name);
-		  };
-
-		  /**
-		   * Define a decorator. A decorator is a set of form types with templates and builder functions
-		   * that help set up the form.
-		   *
-		   * @param {string} name directive name (CamelCased)
-		   * @param {Object} fields, an object that maps "type" => `{ template, builder, replace}`.
-		                     attributes `builder` and `replace` are optional, and replace defaults to true.
-		                       `template` should be the key of the template to load and it should be pre-loaded
-		                     in `$templateCache`.
-		                       `builder` can be a function or an array of functions. They will be called in
-		                     the order they are supplied.
-		                       `replace` (DEPRECATED) is for backwards compatability. If false the builder
-		                     will use the "old" way of building that form field using a <sf-decorator>
-		                     directive.
-		   */
-		  this.defineDecorator = function (name, fields) {
-		    decorators[name] = { '__name': name }; // TODO: this feels like a hack, come up with a better way.
-
-		    _angular2.default.forEach(fields, function (field, type) {
-		      field.builder = field.builder || [];
-		      field.replace = _angular2.default.isDefined(field.replace) ? field.replace : true;
-		      decorators[name][type] = field;
-		    });
-
-		    if (!decorators[defaultDecorator]) {
-		      defaultDecorator = name;
-		    }
-		    createDirective(name);
-		  };
-
-		  /**
-		   * DEPRECATED
-		   * Creates a directive of a decorator
-		   * Usable when you want to use the decorators without using <schema-form> directive.
-		   * Specifically when you need to reuse styling.
-		   *
-		   * ex. createDirective('text','...')
-		   *  <sf-text title="foobar" model="person" key="name" schema="schema"></sf-text>
-		   *
-		   * @param {string}  type The type of the directive, resulting directive will have sf- prefixed
-		   * @param {string}  templateUrl
-		   * @param {boolean} transclude (optional) sets transclude option of directive, defaults to false.
-		   */
-		  this.createDirective = createManualDirective;
-
-		  /**
-		   * DEPRECATED
-		   * Same as createDirective, but takes an object where key is 'type' and value is 'templateUrl'
-		   * Useful for batching.
-		   * @param {Object} templates
-		   */
-		  this.createDirectives = function (templates) {
-		    _angular2.default.forEach(templates, function (url, type) {
-		      createManualDirective(type, url);
-		    });
-		  };
-
-		  /**
-		   * Getter for decorator settings
-		   * @param {string} name (optional) defaults to defaultDecorator
-		   * @return {Object} rules and templates { rules: [],templates: {}}
-		   */
-		  this.decorator = function (name) {
-		    name = name || defaultDecorator;
-		    return decorators[name];
-		  };
-
-		  /**
-		   * DEPRECATED use defineAddOn() instead.
-		   * Adds a mapping to an existing decorator.
-		   * @param {String} name Decorator name
-		   * @param {String} type Form type for the mapping
-		   * @param {String} url  The template url
-		   * @param {Function} builder (optional) builder function
-		   * @param {boolean} replace (optional) defaults to false. Replace decorator directive with template.
-		   */
-		  this.addMapping = function (name, type, url, builder, replace) {
-		    if (decorators[name]) {
-		      decorators[name][type] = {
-		        template: url,
-		        builder: builder,
-		        replace: !!replace
-		      };
-		    }
-		  };
-
-		  /**
-		   * Adds an add-on to an existing decorator.
-		   * @param {String} name Decorator name
-		   * @param {String} type Form type for the mapping
-		   * @param {String} url  The template url
-		   * @param {Function|Array} builder (optional) builder function(s),
-		   */
-		  this.defineAddOn = function (name, type, url, builder) {
-		    if (decorators[name]) {
-		      decorators[name][type] = {
-		        template: url,
-		        builder: builder,
-		        replace: true
-		      };
-		    }
-		  };
-
-		  //Service is just a getter for directive templates and rules
-		  this.$get = function () {
-		    return {
-		      decorator: function decorator(name) {
-		        return decorators[name] || decorators[defaultDecorator];
-		      },
-		      defaultDecorator: defaultDecorator
-		    };
-		  };
-
-		  //Create a default directive
-		  createDirective('sfDecorator');
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 5 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function () {
-
-		  var postProcessFn = function postProcessFn(form) {
-		    return form;
-		  };
-		  var defaults = _jsonSchemaFormCore.schemaDefaults.createDefaults();
-
-		  /**
-		   * Provider API
-		   */
-		  this.defaults = defaults;
-		  this.stdFormObj = _jsonSchemaFormCore.schemaDefaults.stdFormObj;
-		  this.defaultFormDefinition = _jsonSchemaFormCore.schemaDefaults.defaultFormDefinition;
-
-		  /**
-		   * Register a post process function.
-		   * This function is called with the fully merged
-		   * form definition (i.e. after merging with schema)
-		   * and whatever it returns is used as form.
-		   */
-		  this.postProcess = function (fn) {
-		    postProcessFn = fn;
-		  };
-
-		  /**
-		   * Append default form rule
-		   *
-		   * @param {string}   type json schema type
-		   * @param {Function} rule a function(propertyName,propertySchema,options) that returns a form
-		   *                        definition or undefined
-		   */
-		  this.appendRule = function (type, rule) {
-		    if (!defaults[type]) {
-		      defaults[type] = [];
-		    }
-		    defaults[type].push(rule);
-		  };
-
-		  /**
-		   * Prepend default form rule
-		   *
-		   * @param {string}   type json schema type
-		   * @param {Function} rule a function(propertyName,propertySchema,options) that returns a form
-		   *                        definition or undefined
-		   */
-		  this.prependRule = function (type, rule) {
-		    if (!defaults[type]) {
-		      defaults[type] = [];
-		    }
-		    defaults[type].unshift(rule);
-		  };
-
-		  /**
-		   * Utility function to create a standard form object.
-		   * This does *not* set the type of the form but rather all shared attributes.
-		   * You probably want to start your rule with creating the form with this method
-		   * then setting type and any other values you need.
-		   * @param {Object} schema
-		   * @param {Object} options
-		   * @return {Object} a form field defintion
-		   */
-		  this.createStandardForm = _jsonSchemaFormCore.schemaDefaults.stdFormObj;
-		  /* End Provider API */
-
-		  this.$get = function () {
-
-		    var service = {};
-		    var typeDefault = this.defaults;
-
-		    service.merge = function (schema, form, ignore, options, readonly, asyncTemplates) {
-		      form = form || ['*'];
-		      options = options || {};
-
-		      // Get readonly from root object
-		      readonly = readonly || schema.readonly || schema.readOnly;
-
-		      var stdForm = _jsonSchemaFormCore.schemaDefaults.defaultForm(schema, typeDefault, ignore, options);
-
-		      //simple case, we have a "*", just put the stdForm there
-		      var idx = form.indexOf('*');
-		      if (idx !== -1) {
-		        form = form.slice(0, idx).concat(stdForm.form).concat(form.slice(idx + 1));
-		      }
-
-		      //ok let's merge!
-		      //We look at the supplied form and extend it with schema standards
-		      var canonical = (0, _jsonSchemaFormCore.merge)(stdForm.lookup, form, options, readonly, asyncTemplates);
-		      return postProcessFn(canonical);
-		    };
-
-		    /**
-		     * Create form defaults from schema
-		     */
-		    service.defaults = _jsonSchemaFormCore.schemaDefaults.defaultForm;
-
-		    //Utility functions
-		    /**
-		     * Form defaults for schema by type
-		     * As a form is generated from a schema these are the definitions of each json-schema type
-		     */
-		    service.typeDefault = typeDefault;
-
-		    /**
-		     * Traverse a schema, applying a function(schema,path) on every sub schema
-		     * i.e. every property of an object.
-		     */
-		    service.traverseSchema = _jsonSchemaFormCore.traverseSchema;
-
-		    service.traverseForm = _jsonSchemaFormCore.traverseForm;
-
-		    return service;
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		var _jsonSchemaFormCore = __webpack_require__(6);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 6 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		/*!
-		 * json-schema-form
-		 * @version 1.0.0-alpha.1
-		 * @link https://github.com/json-schema-form/json-schema-form-core
-		 * @license MIT
-		 * Copyright (c) 2016 JSON Schema Form
-		 */
-		(function webpackUniversalModuleDefinition(root, factory) {
-			if(true)
-				module.exports = factory();
-			else if(typeof define === 'function' && define.amd)
-				define([], factory);
-			else {
-				var a = factory();
-				for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
-			}
-		})(this, function() {
-		return /******/ (function(modules) { // webpackBootstrap
-		/******/ 	// The module cache
-		/******/ 	var installedModules = {};
-
-		/******/ 	// The require function
-		/******/ 	function __webpack_require__(moduleId) {
-
-		/******/ 		// Check if module is in cache
-		/******/ 		if(installedModules[moduleId])
-		/******/ 			return installedModules[moduleId].exports;
-
-		/******/ 		// Create a new module (and put it into the cache)
-		/******/ 		var module = installedModules[moduleId] = {
-		/******/ 			exports: {},
-		/******/ 			id: moduleId,
-		/******/ 			loaded: false
-		/******/ 		};
-
-		/******/ 		// Execute the module function
-		/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
-
-		/******/ 		// Flag the module as loaded
-		/******/ 		module.loaded = true;
-
-		/******/ 		// Return the exports of the module
-		/******/ 		return module.exports;
-		/******/ 	}
-
-
-		/******/ 	// expose the modules object (__webpack_modules__)
-		/******/ 	__webpack_require__.m = modules;
-
-		/******/ 	// expose the module cache
-		/******/ 	__webpack_require__.c = installedModules;
-
-		/******/ 	// __webpack_public_path__
-		/******/ 	__webpack_require__.p = "";
-
-		/******/ 	// Load entry module and return exports
-		/******/ 	return __webpack_require__(0);
-		/******/ })
-		/************************************************************************/
-		/******/ ([
-		/* 0 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			module.exports = __webpack_require__(1);
-
-
-		/***/ },
-		/* 1 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-			exports.canonicalTitleMap = exports.schemaDefaults = exports.sfPath = undefined;
-
-			var _merge = __webpack_require__(2);
-
-			Object.keys(_merge).forEach(function (key) {
-			  if (key === "default") return;
-			  Object.defineProperty(exports, key, {
-			    enumerable: true,
-			    get: function get() {
-			      return _merge[key];
-			    }
-			  });
-			});
-
-			var _select = __webpack_require__(7);
-
-			Object.keys(_select).forEach(function (key) {
-			  if (key === "default") return;
-			  Object.defineProperty(exports, key, {
-			    enumerable: true,
-			    get: function get() {
-			      return _select[key];
-			    }
-			  });
-			});
-
-			var _traverse = __webpack_require__(8);
-
-			Object.keys(_traverse).forEach(function (key) {
-			  if (key === "default") return;
-			  Object.defineProperty(exports, key, {
-			    enumerable: true,
-			    get: function get() {
-			      return _traverse[key];
-			    }
-			  });
-			});
-
-			var _schemaDefaults = __webpack_require__(9);
-
-			var schemaDefaultsImp = _interopRequireWildcard(_schemaDefaults);
-
-			var _sfPath = __webpack_require__(3);
-
-			var sfPathImp = _interopRequireWildcard(_sfPath);
-
-			var _canonicalTitleMap = __webpack_require__(6);
-
-			var _canonicalTitleMap2 = _interopRequireDefault(_canonicalTitleMap);
-
-			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-			function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
-
-			var sfPath = exports.sfPath = sfPathImp;
-			var schemaDefaults = exports.schemaDefaults = schemaDefaultsImp;
-			var canonicalTitleMap = exports.canonicalTitleMap = _canonicalTitleMap2.default;
-
-		/***/ },
-		/* 2 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-			exports.merge = merge;
-
-			var _sfPath = __webpack_require__(3);
-
-			var _canonicalTitleMap = __webpack_require__(6);
-
-			var _canonicalTitleMap2 = _interopRequireDefault(_canonicalTitleMap);
-
-			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-			//export function merge(schema, form, schemaDefaultTypes, ignore, options, readonly, asyncTemplates) {
-			function merge(lookup, form, options, readonly, asyncTemplates) {
-			  form = form || [];
-			  options = options || {};
-
-			  //ok let's merge!
-			  //We look at the supplied form and extend it with schema standards
-			  return form.map(function (obj) {
-
-			    //handle the shortcut with just a name
-			    if (typeof obj === 'string') {
-			      obj = { key: obj };
-			    }
-
-			    if (obj.key) {
-			      if (typeof obj.key === 'string') {
-			        obj.key = (0, _sfPath.parse)(obj.key);
-			      }
-			    }
-
-			    //If it has a titleMap make sure it's a list
-			    if (obj.titleMap) {
-			      obj.titleMap = (0, _canonicalTitleMap2.default)(obj.titleMap);
-			    }
-
-			    //extend with std form from schema.
-			    if (obj.key) {
-			      var strid = (0, _sfPath.stringify)(obj.key);
-			      if (lookup[strid]) {
-			        (function () {
-			          var schemaDefaults = lookup[strid];
-			          if (schemaDefaults) {
-			            Object.keys(schemaDefaults).forEach(function (attr) {
-			              if (obj[attr] === undefined) {
-			                obj[attr] = schemaDefaults[attr];
-			              }
-			            });
-			          }
-			        })();
-			      }
-			    }
-
-			    // Are we inheriting readonly?
-			    if (readonly === true) {
-			      // Inheriting false is not cool.
-			      obj.readonly = true;
-			    }
-
-			    //if it's a type with items, merge 'em!
-			    if (obj.items) {
-			      obj.items = merge(lookup, obj.items, options, obj.readonly, asyncTemplates);
-			    }
-
-			    //if its has tabs, merge them also!
-			    if (obj.tabs) {
-			      obj.tabs.forEach(function (tab) {
-			        if (tab.items) {
-			          tab.items = merge(lookup, tab.items, options, obj.readonly, asyncTemplates);
-			        }
-			      });
-			    }
-
-			    // Special case: checkbox
-			    // Since have to ternary state we need a default
-			    if (obj.type === 'checkbox' && obj.schema['default'] === undefined) {
-			      obj.schema['default'] = false;
-			    };
-
-			    // Special case: template type with tempplateUrl that's needs to be loaded before rendering
-			    // TODO: this is not a clean solution. Maybe something cleaner can be made when $ref support
-			    // is introduced since we need to go async then anyway
-			    if (asyncTemplates && obj.type === 'template' && !obj.template && obj.templateUrl) {
-			      asyncTemplates.push(obj);
-			    }
-
-			    return obj;
-			  });
-			}
-
-		/***/ },
-		/* 3 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-
-			var _objectpath = __webpack_require__(4);
-
-			Object.defineProperty(exports, 'parse', {
-			  enumerable: true,
-			  get: function get() {
-			    return _objectpath.parse;
-			  }
-			});
-			Object.defineProperty(exports, 'stringify', {
-			  enumerable: true,
-			  get: function get() {
-			    return _objectpath.stringify;
-			  }
-			});
-			Object.defineProperty(exports, 'normalize', {
-			  enumerable: true,
-			  get: function get() {
-			    return _objectpath.normalize;
-			  }
-			});
-
-		/***/ },
-		/* 4 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			module.exports = __webpack_require__(5).ObjectPath;
-
-		/***/ },
-		/* 5 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			var __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
-
-			var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; };
-
-			;!function (undefined) {
-
-				var ObjectPath = {
-					parse: function parse(str) {
-						if (typeof str !== 'string') {
-							throw new TypeError('ObjectPath.parse must be passed a string');
-						}
-
-						var i = 0;
-						var parts = [];
-						var d, b, q, c;
-						while (i < str.length) {
-							d = str.indexOf('.', i);
-							b = str.indexOf('[', i);
-
-							// we've reached the end
-							if (d === -1 && b === -1) {
-								parts.push(str.slice(i, str.length));
-								i = str.length;
-							}
-
-							// dots
-							else if (b === -1 || d !== -1 && d < b) {
-									parts.push(str.slice(i, d));
-									i = d + 1;
-								}
-
-								// brackets
-								else {
-										if (b > i) {
-											parts.push(str.slice(i, b));
-											i = b;
-										}
-										q = str.slice(b + 1, b + 2);
-										if (q !== '"' && q !== '\'') {
-											c = str.indexOf(']', b);
-											if (c === -1) c = str.length;
-											parts.push(str.slice(i + 1, c));
-											i = str.slice(c + 1, c + 2) === '.' ? c + 2 : c + 1;
-										} else {
-											c = str.indexOf(q + ']', b);
-											if (c === -1) c = str.length;
-											while (str.slice(c - 1, c) === '\\' && b < str.length) {
-												b++;
-												c = str.indexOf(q + ']', b);
-											}
-											parts.push(str.slice(i + 2, c).replace(new RegExp('\\' + q, 'g'), q));
-											i = str.slice(c + 2, c + 3) === '.' ? c + 3 : c + 2;
-										}
-									}
-						}
-						return parts;
-					},
-
-					// root === true : auto calculate root; must be dot-notation friendly
-					// root String : the string to use as root
-					stringify: function stringify(arr, quote) {
-
-						if (!Array.isArray(arr)) arr = [arr.toString()];
-
-						quote = quote === '"' ? '"' : '\'';
-
-						return arr.map(function (n) {
-							return '[' + quote + n.toString().replace(new RegExp(quote, 'g'), '\\' + quote) + quote + ']';
-						}).join('');
-					},
-
-					normalize: function normalize(data, quote) {
-						return ObjectPath.stringify(Array.isArray(data) ? data : ObjectPath.parse(data), quote);
-					},
-
-					// Angular
-					registerModule: function registerModule(angular) {
-						angular.module('ObjectPath', []).provider('ObjectPath', function () {
-							this.parse = ObjectPath.parse;
-							this.stringify = ObjectPath.stringify;
-							this.normalize = ObjectPath.normalize;
-							this.$get = function () {
-								return ObjectPath;
-							};
-						});
-					}
-				};
-
-				// AMD
-				if (true) {
-					!(__WEBPACK_AMD_DEFINE_RESULT__ = function () {
-						return { ObjectPath: ObjectPath };
-					}.call(exports, __webpack_require__, exports, module), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
-				}
-
-				// CommonJS
-				else if ((typeof exports === 'undefined' ? 'undefined' : _typeof(exports)) === 'object') {
-						exports.ObjectPath = ObjectPath;
-					}
-
-					// Browser global
-					else {
-							window.ObjectPath = ObjectPath;
-						}
-			}();
-
-		/***/ },
-		/* 6 */
-		/***/ function(module, exports) {
-
-			"use strict";
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-
-			var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; }; // Takes a titleMap in either object or list format and returns one in
-			// in the list format.
-
-
-			exports.default = function (titleMap, originalEnum) {
-			  if (!Array.isArray(titleMap)) {
-			    var _ret = function () {
-			      var canonical = [];
-			      if (originalEnum) {
-			        originalEnum.forEach(function (value) {
-			          canonical.push({ name: titleMap[value], value: value });
-			        });
-			      } else {
-			        Object.keys(titleMap).forEach(function (value) {
-			          canonical.push({ name: titleMap[value], value: value });
-			        });
-			      }
-			      return {
-			        v: canonical
-			      };
-			    }();
-
-			    if ((typeof _ret === "undefined" ? "undefined" : _typeof(_ret)) === "object") return _ret.v;
-			  }
-			  return titleMap;
-			};
-
-		/***/ },
-		/* 7 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-			exports.select = select;
-
-			var _sfPath = __webpack_require__(3);
-
-			var _sfPath2 = _interopRequireDefault(_sfPath);
-
-			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-			var numRe = /^\d+$/;
-
-			/**
-			  * @description
-			  * Utility method to access deep properties without
-			  * throwing errors when things are not defined.
-			  * Can also set a value in a deep structure, creating objects when missing
-			  * ex.
-			  * var foo = Select('address.contact.name',obj)
-			  * Select('address.contact.name',obj,'Leeroy')
-			  *
-			  * @param {string} projection A dot path to the property you want to get/set
-			  * @param {object} obj   (optional) The object to project on, defaults to 'this'
-			  * @param {Any}    valueToSet (opional)  The value to set, if parts of the path of
-			  *                 the projection is missing empty objects will be created.
-			  * @returns {Any|undefined} returns the value at the end of the projection path
-			  *                          or undefined if there is none.
-			  */
-			function select(projection, obj, valueToSet) {
-			  if (!obj) {
-			    obj = this;
-			  }
-			  //Support [] array syntax
-			  var parts = typeof projection === 'string' ? _sfPath2.default.parse(projection) : projection;
-
-			  if (typeof valueToSet !== 'undefined' && parts.length === 1) {
-			    //special case, just setting one variable
-			    obj[parts[0]] = valueToSet;
-			    return obj;
-			  }
-
-			  if (typeof valueToSet !== 'undefined' && typeof obj[parts[0]] === 'undefined') {
-			    // We need to look ahead to check if array is appropriate
-			    obj[parts[0]] = parts.length > 2 && numRe.test(parts[1]) ? [] : {};
-			  }
-
-			  var value = obj[parts[0]];
-			  for (var i = 1; i < parts.length; i++) {
-			    // Special case: We allow JSON Form syntax for arrays using empty brackets
-			    // These will of course not work here so we exit if they are found.
-			    if (parts[i] === '') {
-			      return undefined;
-			    }
-			    if (typeof valueToSet !== 'undefined') {
-			      if (i === parts.length - 1) {
-			        //last step. Let's set the value
-			        value[parts[i]] = valueToSet;
-			        return valueToSet;
-			      } else {
-			        // Make sure to create new objects on the way if they are not there.
-			        // We need to look ahead to check if array is appropriate
-			        var tmp = value[parts[i]];
-			        if (typeof tmp === 'undefined' || tmp === null) {
-			          tmp = numRe.test(parts[i + 1]) ? [] : {};
-			          value[parts[i]] = tmp;
-			        }
-			        value = tmp;
-			      }
-			    } else if (value) {
-			      //Just get nex value.
-			      value = value[parts[i]];
-			    }
-			  }
-			  return value;
-			}
-
-		/***/ },
-		/* 8 */
-		/***/ function(module, exports) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-			exports.traverseSchema = traverseSchema;
-			exports.traverseForm = traverseForm;
-			/**
-			 * Traverse a schema, applying a function(schema,path) on every sub schema
-			 * i.e. every property of an object.
-			 */
-			function traverseSchema(schema, fn, path, ignoreArrays) {
-			  ignoreArrays = ignoreArrays === undefined ? true : ignoreArrays;
-
-			  path = path || [];
-
-			  var traverse = function traverse(schema, fn, path) {
-			    fn(schema, path);
-			    if (schema.properties) {
-			      Object.keys(schema.properties).forEach(function (name) {
-			        var currentPath = path.slice();
-			        currentPath.push(name);
-			        traverse(schema.properties[name], fn, currentPath);
-			      });
-			    }
-
-			    //Only support type "array" which have a schema as "items".
-			    if (!ignoreArrays && schema.items) {
-			      var arrPath = path.slice();arrPath.push('');
-			      traverse(schema.items, fn, arrPath);
-			    }
-			  };
-
-			  traverse(schema, fn, path || []);
-			}
-
-			function traverseForm(form, fn) {
-			  fn(form);
-			  if (form.items) {
-			    form.items.forEach(function (f) {
-			      traverseForm(f, fn);
-			    });
-			  }
-
-			  if (form.tabs) {
-			    form.tabs.forEach(function (tab) {
-			      if (tab.items) {
-			        tab.items.forEach(function (f) {
-			          traverseForm(f, fn);
-			        });
-			      }
-			    });
-			  }
-			}
-
-		/***/ },
-		/* 9 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-
-			var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; };
-
-			exports.defaultFormDefinition = defaultFormDefinition;
-			exports.stdFormObj = stdFormObj;
-			exports.text = text;
-			exports.number = number;
-			exports.integer = integer;
-			exports.checkbox = checkbox;
-			exports.select = select;
-			exports.checkboxes = checkboxes;
-			exports.fieldset = fieldset;
-			exports.array = array;
-			exports.createDefaults = createDefaults;
-			exports.defaultForm = defaultForm;
-
-			var _sfPath = __webpack_require__(3);
-
-			var _canonicalTitleMap = __webpack_require__(6);
-
-			var _canonicalTitleMap2 = _interopRequireDefault(_canonicalTitleMap);
-
-			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-			/* Utils */
-			var stripNullType = function stripNullType(type) {
-			  if (Array.isArray(type) && type.length == 2) {
-			    if (type[0] === 'null') {
-			      return type[1];
-			    };
-			    if (type[1] === 'null') {
-			      return type[0];
-			    };
-			  };
-			  return type;
-			};
-
-			//Creates an default titleMap list from an enum, i.e. a list of strings.
-			var enumToTitleMap = function enumToTitleMap(enm) {
-			  var titleMap = []; //canonical titleMap format is a list.
-			  enm.forEach(function (name) {
-			    titleMap.push({ name: name, value: name });
-			  });
-			  return titleMap;
-			};
-
-			/**
-			 * Creates a default form definition from a schema.
-			 */
-			function defaultFormDefinition(schemaTypes, name, schema, options) {
-			  var rules = schemaTypes[stripNullType(schema.type)];
-			  if (rules) {
-			    var def = void 0;
-			    // We give each rule a possibility to recurse it's children.
-			    var innerDefaultFormDefinition = function innerDefaultFormDefinition(childName, childSchema, childOptions) {
-			      return defaultFormDefinition(schemaTypes, childName, childSchema, childOptions);
-			    };
-			    for (var i = 0; i < rules.length; i++) {
-			      def = rules[i](name, schema, options, innerDefaultFormDefinition);
-
-			      //first handler in list that actually returns something is our handler!
-			      if (def) {
-
-			        // Do we have form defaults in the schema under the x-schema-form-attribute?
-			        if (def.schema['x-schema-form']) {
-			          Object.assign(def, def.schema['x-schema-form']);
-			        }
-
-			        return def;
-			      }
-			    }
-			  }
-			}
-
-			/**
-			 * Creates a form object with all common properties
-			 */
-			function stdFormObj(name, schema, options) {
-			  options = options || {};
-
-			  // The Object.assign used to be a angular.copy. Should work though.
-			  var f = options.global && options.global.formDefaults ? Object.assign({}, options.global.formDefaults) : {};
-			  if (options.global && options.global.supressPropertyTitles === true) {
-			    f.title = schema.title;
-			  } else {
-			    f.title = schema.title || name;
-			  }
-
-			  if (schema.description) {
-			    f.description = schema.description;
-			  }
-			  if (options.required === true || schema.required === true) {
-			    f.required = true;
-			  }
-			  if (schema.maxLength) {
-			    f.maxlength = schema.maxLength;
-			  }
-			  if (schema.minLength) {
-			    f.minlength = schema.minLength;
-			  }
-			  if (schema.readOnly || schema.readonly) {
-			    f.readonly = true;
-			  }
-			  if (schema.minimum) {
-			    f.minimum = schema.minimum + (schema.exclusiveMinimum ? 1 : 0);
-			  }
-			  if (schema.maximum) {
-			    f.maximum = schema.maximum - (schema.exclusiveMaximum ? 1 : 0);
-			  }
-
-			  // Non standard attributes (DONT USE DEPRECATED)
-			  // If you must set stuff like this in the schema use the x-schema-form attribute
-			  if (schema.validationMessage) {
-			    f.validationMessage = schema.validationMessage;
-			  }
-			  if (schema.enumNames) {
-			    f.titleMap = (0, _canonicalTitleMap2.default)(schema.enumNames, schema['enum']);
-			  }
-			  f.schema = schema;
-
-			  // Ng model options doesn't play nice with undefined, might be defined
-			  // globally though
-			  f.ngModelOptions = f.ngModelOptions || {};
-
-			  return f;
-			};
-
-			/*** Schema types to form type mappings, with defaults ***/
-			function text(name, schema, options) {
-			  if (stripNullType(schema.type) === 'string' && !schema['enum']) {
-			    var f = stdFormObj(name, schema, options);
-			    f.key = options.path;
-			    f.type = 'text';
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-			    return f;
-			  }
-			}
-
-			//default in json form for number and integer is a text field
-			//input type="number" would be more suitable don't ya think?
-			function number(name, schema, options) {
-			  if (stripNullType(schema.type) === 'number') {
-			    var f = stdFormObj(name, schema, options);
-			    f.key = options.path;
-			    f.type = 'number';
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-			    return f;
-			  }
-			}
-
-			function integer(name, schema, options) {
-			  if (stripNullType(schema.type) === 'integer') {
-			    var f = stdFormObj(name, schema, options);
-			    f.key = options.path;
-			    f.type = 'number';
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-			    return f;
-			  }
-			}
-
-			function checkbox(name, schema, options) {
-			  if (stripNullType(schema.type) === 'boolean') {
-			    var f = stdFormObj(name, schema, options);
-			    f.key = options.path;
-			    f.type = 'checkbox';
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-			    return f;
-			  }
-			}
-
-			function select(name, schema, options) {
-			  if (stripNullType(schema.type) === 'string' && schema['enum']) {
-			    var f = stdFormObj(name, schema, options);
-			    f.key = options.path;
-			    f.type = 'select';
-			    if (!f.titleMap) {
-			      f.titleMap = enumToTitleMap(schema['enum']);
-			    }
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-			    return f;
-			  }
-			}
-
-			function checkboxes(name, schema, options) {
-			  if (stripNullType(schema.type) === 'array' && schema.items && schema.items['enum']) {
-			    var f = stdFormObj(name, schema, options);
-			    f.key = options.path;
-			    f.type = 'checkboxes';
-			    if (!f.titleMap) {
-			      f.titleMap = enumToTitleMap(schema.items['enum']);
-			    }
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-			    return f;
-			  }
-			}
-
-			function fieldset(name, schema, options, defaultFormDef) {
-			  if (stripNullType(schema.type) === 'object') {
-			    var _ret = function () {
-			      var f = stdFormObj(name, schema, options);
-			      f.type = 'fieldset';
-			      f.key = options.path;
-			      f.items = [];
-			      options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-
-			      //recurse down into properties
-			      if (schema.properties) {
-			        Object.keys(schema.properties).forEach(function (key) {
-			          var value = schema.properties[key];
-			          var path = options.path.slice();
-			          path.push(key);
-			          if (options.ignore[(0, _sfPath.stringify)(path)] !== true) {
-			            var required = schema.required && schema.required.indexOf(key) !== -1;
-
-			            var def = defaultFormDef(key, value, {
-			              path: path,
-			              required: required || false,
-			              lookup: options.lookup,
-			              ignore: options.ignore,
-			              global: options.global
-			            });
-			            if (def) {
-			              f.items.push(def);
-			            }
-			          }
-			        });
-			      }
-			      return {
-			        v: f
-			      };
-			    }();
-
-			    if ((typeof _ret === 'undefined' ? 'undefined' : _typeof(_ret)) === "object") return _ret.v;
-			  }
-			}
-
-			function array(name, schema, options, defaultFormDef) {
-			  if (stripNullType(schema.type) === 'array') {
-			    var f = stdFormObj(name, schema, options);
-			    f.type = 'array';
-			    f.key = options.path;
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-
-			    var required = schema.required && schema.required.indexOf(options.path[options.path.length - 1]) !== -1;
-
-			    // The default is to always just create one child. This works since if the
-			    // schemas items declaration is of type: "object" then we get a fieldset.
-			    // We also follow json form notatation, adding empty brackets "[]" to
-			    // signify arrays.
-
-			    var arrPath = options.path.slice();
-			    arrPath.push('');
-
-			    f.items = [defaultFormDef(name, schema.items, {
-			      path: arrPath,
-			      required: required || false,
-			      lookup: options.lookup,
-			      ignore: options.ignore,
-			      global: options.global
-			    })];
-
-			    return f;
-			  }
-			}
-
-			function createDefaults() {
-			  //First sorted by schema type then a list.
-			  //Order has importance. First handler returning an form snippet will be used.
-			  return {
-			    string: [select, text],
-			    object: [fieldset],
-			    number: [number],
-			    integer: [integer],
-			    boolean: [checkbox],
-			    array: [checkboxes, array]
-			  };
-			};
-
-			/**
-			 * Create form defaults from schema
-			 */
-			function defaultForm(schema, defaultSchemaTypes, ignore, globalOptions) {
-			  var form = [];
-			  var lookup = {}; //Map path => form obj for fast lookup in merging
-			  ignore = ignore || {};
-			  globalOptions = globalOptions || {};
-			  defaultSchemaTypes = defaultSchemaTypes || createDefaults();
-
-			  if (schema.properties) {
-			    Object.keys(schema.properties).forEach(function (key) {
-			      if (ignore[key] !== true) {
-			        var required = schema.required && schema.required.indexOf(key) !== -1;
-			        var def = defaultFormDefinition(defaultSchemaTypes, key, schema.properties[key], {
-			          path: [key], // Path to this property in bracket notation.
-			          lookup: lookup, // Extra map to register with. Optimization for merger.
-			          ignore: ignore, // The ignore list of paths (sans root level name)
-			          required: required, // Is it required? (v4 json schema style)
-			          global: globalOptions // Global options, including form defaults
-			        });
-			        if (def) {
-			          form.push(def);
-			        }
-			      }
-			    });
-			  } else {
-			    throw new Error('Not implemented. Only type "object" allowed at root level of schema.');
-			  }
-			  return { form: form, lookup: lookup };
-			}
-
-		/***/ }
-		/******/ ])
-		});
-		;
-
-	/***/ },
-	/* 7 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function () {
-
-		  var validator = {};
-
-		  /**
-		   * Validate a value against its form definition and schema.
-		   * The value should either be of proper type or a string, some type
-		   * coercion is applied.
-		   *
-		   * @param {Object} form A merged form definition, i.e. one with a schema.
-		   * @param {Any} value the value to validate.
-		   * @return a tv4js result object.
-		   */
-		  validator.validate = function (form, value) {
-		    if (!form) {
-		      return { valid: true };
-		    }
-		    var schema = form.schema;
-
-		    if (!schema) {
-		      return { valid: true };
-		    }
-
-		    // Input of type text and textareas will give us a viewValue of ''
-		    // when empty, this is a valid value in a schema and does not count as something
-		    // that breaks validation of 'required'. But for our own sanity an empty field should
-		    // not validate if it's required.
-		    if (value === '') {
-		      value = undefined;
-		    }
-
-		    // Numbers fields will give a null value, which also means empty field
-		    if (form.type === 'number' && value === null) {
-		      value = undefined;
-		    }
-
-		    // Version 4 of JSON Schema has the required property not on the
-		    // property itself but on the wrapping object. Since we like to test
-		    // only this property we wrap it in a fake object.
-		    var wrap = { type: 'object', 'properties': {} };
-		    var propName = form.key[form.key.length - 1];
-		    wrap.properties[propName] = schema;
-
-		    if (form.required) {
-		      wrap.required = [propName];
-		    }
-		    var valueWrap = {};
-		    if (_angular2.default.isDefined(value)) {
-		      valueWrap[propName] = value;
-		    }
-		    return _tv2.default.validateResult(valueWrap, wrap);
-		  };
-
-		  return validator;
-		};
-
-		var _tv = __webpack_require__(8);
-
-		var _tv2 = _interopRequireDefault(_tv);
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 8 */
-	/***/ function(module, exports) {
-
-		module.exports = tv4;
-
-	/***/ },
-	/* 9 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function () {
-
-		  // The codes are tv4 error codes.
-		  // Not all of these can actually happen in a field, but for
-		  // we never know when one might pop up so it's best to cover them all.
-
-		  // TODO: Humanize these.
-		  var defaultMessages = {
-		    'default': 'Field does not validate',
-		    0: 'Invalid type, expected {{schema.type}}',
-		    1: 'No enum match for: {{viewValue}}',
-		    10: 'Data does not match any schemas from "anyOf"',
-		    11: 'Data does not match any schemas from "oneOf"',
-		    12: 'Data is valid against more than one schema from "oneOf"',
-		    13: 'Data matches schema from "not"',
-		    // Numeric errors
-		    100: 'Value is not a multiple of {{schema.multipleOf}}',
-		    101: '{{viewValue}} is less than the allowed minimum of {{schema.minimum}}',
-		    102: '{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}',
-		    103: '{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}',
-		    104: '{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}',
-		    105: 'Value is not a valid number',
-		    // String errors
-		    200: 'String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}',
-		    201: 'String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}',
-		    202: 'String does not match pattern: {{schema.pattern}}',
-		    // Object errors
-		    300: 'Too few properties defined, minimum {{schema.minProperties}}',
-		    301: 'Too many properties defined, maximum {{schema.maxProperties}}',
-		    302: 'Required',
-		    303: 'Additional properties not allowed',
-		    304: 'Dependency failed - key must exist',
-		    // Array errors
-		    400: 'Array is too short ({{value.length}}), minimum {{schema.minItems}}',
-		    401: 'Array is too long ({{value.length}}), maximum {{schema.maxItems}}',
-		    402: 'Array items are not unique',
-		    403: 'Additional items not allowed',
-		    // Format errors
-		    500: 'Format validation failed',
-		    501: 'Keyword failed: "{{title}}"',
-		    // Schema structure
-		    600: 'Circular $refs',
-		    // Non-standard validation options
-		    1000: 'Unknown property (not in schema)'
-		  };
-
-		  // In some cases we get hit with an angular validation error
-		  defaultMessages.number = defaultMessages[105];
-		  defaultMessages.required = defaultMessages[302];
-		  defaultMessages.min = defaultMessages[101];
-		  defaultMessages.max = defaultMessages[103];
-		  defaultMessages.maxlength = defaultMessages[201];
-		  defaultMessages.minlength = defaultMessages[200];
-		  defaultMessages.pattern = defaultMessages[202];
-
-		  this.setDefaultMessages = function (messages) {
-		    defaultMessages = messages;
-		  };
-
-		  this.getDefaultMessages = function () {
-		    return defaultMessages;
-		  };
-
-		  this.setDefaultMessage = function (error, msg) {
-		    defaultMessages[error] = msg;
-		  };
-
-		  this.$get = ['$interpolate', function ($interpolate) {
-
-		    var service = {};
-		    service.defaultMessages = defaultMessages;
-
-		    /**
-		     * Interpolate and return proper error for an eror code.
-		     * Validation message on form trumps global error messages.
-		     * and if the message is a function instead of a string that function will be called instead.
-		     * @param {string} error the error code, i.e. tv4-xxx for tv4 errors, otherwise it's whats on
-		     *                       ngModel.$error for custom errors.
-		     * @param {Any} value the actual model value.
-		     * @param {Any} viewValue the viewValue
-		     * @param {Object} form a form definition object for this field
-		     * @param  {Object} global the global validation messages object (even though its called global
-		     *                         its actually just shared in one instance of sf-schema)
-		     * @return {string} The error message.
-		     */
-		    service.interpolate = function (error, value, viewValue, form, global) {
-		      global = global || {};
-		      var validationMessage = form.validationMessage || {};
-
-		      // Drop tv4 prefix so only the code is left.
-		      if (error.indexOf('tv4-') === 0) {
-		        error = error.substring(4);
-		      }
-
-		      // First find apropriate message or function
-		      var message = validationMessage['default'] || global['default'] || '';
-
-		      [validationMessage, global, defaultMessages].some(function (val) {
-		        if (_angular2.default.isString(val) || _angular2.default.isFunction(val)) {
-		          message = val;
-		          return true;
-		        }
-		        if (val && val[error]) {
-		          message = val[error];
-		          return true;
-		        }
-		      });
-
-		      var context = {
-		        error: error,
-		        value: value,
-		        viewValue: viewValue,
-		        form: form,
-		        schema: form.schema,
-		        title: form.title || form.schema && form.schema.title
-		      };
-		      if (_angular2.default.isFunction(message)) {
-		        return message(context);
-		      } else {
-		        return $interpolate(message)(context);
-		      }
-		    };
-
-		    return service;
-		  }];
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 10 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function () {
-
-		  // expose the methods in sfPathProvider
-		  this.parse = _jsonSchemaFormCore.sfPath.parse;
-		  this.stringify = _jsonSchemaFormCore.sfPath.stringify;
-		  this.normalize = _jsonSchemaFormCore.sfPath.normalize;
-
-		  this.$get = function () {
-		    return _jsonSchemaFormCore.sfPath;
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		var _jsonSchemaFormCore = __webpack_require__(6);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 11 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function (sfSelect, schemaForm, sfValidator, sfPath) {
-
-		  var setIndex = function setIndex(index) {
-		    return function (form) {
-		      if (form.key) {
-		        form.key[form.key.indexOf('')] = index;
-		      }
-		    };
-		  };
-
-		  return {
-		    restrict: 'A',
-		    scope: true,
-		    require: '?ngModel',
-		    link: function link(scope, element, attrs, ngModel) {
-		      var formDefCache = {};
-
-		      scope.validateArray = _angular2.default.noop;
-
-		      if (ngModel) {
-		        // We need the ngModelController on several places,
-		        // most notably for errors.
-		        // So we emit it up to the decorator directive so it can put it on scope.
-		        scope.$emit('schemaFormPropagateNgModelController', ngModel);
-		      }
-
-		      // Watch for the form definition and then rewrite it.
-		      // It's the (first) array part of the key, '[]' that needs a number
-		      // corresponding to an index of the form.
-		      var once = scope.$watch(attrs.sfArray, function (form) {
-		        if (!form) {
-		          return;
-		        }
-
-		        // An array model always needs a key so we know what part of the model
-		        // to look at. This makes us a bit incompatible with JSON Form, on the
-		        // other hand it enables two way binding.
-		        var list = sfSelect(form.key, scope.model);
-
-		        // We only modify the same array instance but someone might change the array from
-		        // the outside so let's watch for that. We use an ordinary watch since the only case
-		        // we're really interested in is if its a new instance.
-		        var key = sfPath.normalize(form.key);
-		        scope.$watch('model' + (key[0] !== '[' ? '.' : '') + key, function (value) {
-		          list = scope.modelArray = value;
-		        });
-
-		        // Since ng-model happily creates objects in a deep path when setting a
-		        // a value but not arrays we need to create the array.
-		        if (_angular2.default.isUndefined(list)) {
-		          list = [];
-		          sfSelect(form.key, scope.model, list);
-		        }
-		        scope.modelArray = list;
-
-		        // Arrays with titleMaps, i.e. checkboxes doesn't have items.
-		        if (form.items) {
-
-		          // To be more compatible with JSON Form we support an array of items
-		          // in the form definition of "array" (the schema just a value).
-		          // for the subforms code to work this means we wrap everything in a
-		          // section. Unless there is just one.
-		          var subForm = form.items[0];
-		          if (form.items.length > 1) {
-		            subForm = {
-		              type: 'section',
-		              items: form.items.map(function (item) {
-		                item.ngModelOptions = form.ngModelOptions;
-		                if (_angular2.default.isUndefined(item.readonly)) {
-		                  item.readonly = form.readonly;
-		                }
-		                return item;
-		              })
-		            };
-		          }
-		        }
-
-		        // We ceate copies of the form on demand, caching them for
-		        // later requests
-		        scope.copyWithIndex = function (index) {
-		          if (!formDefCache[index]) {
-		            if (subForm) {
-		              var copy = _angular2.default.copy(subForm);
-		              copy.arrayIndex = index;
-		              schemaForm.traverseForm(copy, setIndex(index));
-		              formDefCache[index] = copy;
-		            }
-		          }
-		          return formDefCache[index];
-		        };
-
-		        scope.appendToArray = function () {
-		          var len = list.length;
-		          var copy = scope.copyWithIndex(len);
-		          schemaForm.traverseForm(copy, function (part) {
-
-		            if (part.key) {
-		              var def;
-		              if (_angular2.default.isDefined(part['default'])) {
-		                def = part['default'];
-		              }
-		              if (_angular2.default.isDefined(part.schema) && _angular2.default.isDefined(part.schema['default'])) {
-		                def = part.schema['default'];
-		              }
-
-		              if (_angular2.default.isDefined(def)) {
-		                sfSelect(part.key, scope.model, def);
-		              }
-		            }
-		          });
-
-		          // If there are no defaults nothing is added so we need to initialize
-		          // the array. undefined for basic values, {} or [] for the others.
-		          if (len === list.length) {
-		            var type = sfSelect('schema.items.type', form);
-		            var dflt;
-		            if (type === 'object') {
-		              dflt = {};
-		            } else if (type === 'array') {
-		              dflt = [];
-		            }
-		            list.push(dflt);
-		          }
-
-		          // Trigger validation.
-		          scope.validateArray();
-		          return list;
-		        };
-
-		        scope.deleteFromArray = function (index) {
-		          list.splice(index, 1);
-
-		          // Trigger validation.
-		          scope.validateArray();
-
-		          // Angular 1.2 lacks setDirty
-		          if (ngModel && ngModel.$setDirty) {
-		            ngModel.$setDirty();
-		          }
-		          return list;
-		        };
-
-		        // Always start with one empty form unless configured otherwise.
-		        // Special case: don't do it if form has a titleMap
-		        if (!form.titleMap && form.startEmpty !== true && list.length === 0) {
-		          scope.appendToArray();
-		        }
-
-		        // Title Map handling
-		        // If form has a titleMap configured we'd like to enable looping over
-		        // titleMap instead of modelArray, this is used for intance in
-		        // checkboxes. So instead of variable number of things we like to create
-		        // a array value from a subset of values in the titleMap.
-		        // The problem here is that ng-model on a checkbox doesn't really map to
-		        // a list of values. This is here to fix that.
-		        if (form.titleMap && form.titleMap.length > 0) {
-		          scope.titleMapValues = [];
-
-		          // We watch the model for changes and the titleMapValues to reflect
-		          // the modelArray
-		          var updateTitleMapValues = function updateTitleMapValues(arr) {
-		            scope.titleMapValues = [];
-		            arr = arr || [];
-
-		            form.titleMap.forEach(function (item) {
-		              scope.titleMapValues.push(arr.indexOf(item.value) !== -1);
-		            });
-		          };
-		          //Catch default values
-		          updateTitleMapValues(scope.modelArray);
-		          scope.$watchCollection('modelArray', updateTitleMapValues);
-
-		          //To get two way binding we also watch our titleMapValues
-		          scope.$watchCollection('titleMapValues', function (vals, old) {
-		            if (vals && vals !== old) {
-		              var arr = scope.modelArray;
-
-		              // Apparently the fastest way to clear an array, readable too.
-		              // http://jsperf.com/array-destroy/32
-		              while (arr.length > 0) {
-		                arr.pop();
-		              }
-		              form.titleMap.forEach(function (item, index) {
-		                if (vals[index]) {
-		                  arr.push(item.value);
-		                }
-		              });
-
-		              // Time to validate the rebuilt array.
-		              scope.validateArray();
-		            }
-		          });
-		        }
-
-		        // If there is a ngModel present we need to validate when asked.
-		        if (ngModel) {
-		          var error;
-
-		          scope.validateArray = function () {
-		            // The actual content of the array is validated by each field
-		            // so we settle for checking validations specific to arrays
-
-		            // Since we prefill with empty arrays we can get the funny situation
-		            // where the array is required but empty in the gui but still validates.
-		            // Thats why we check the length.
-		            var result = sfValidator.validate(form, scope.modelArray.length > 0 ? scope.modelArray : undefined);
-
-		            // TODO: DRY this up, it has a lot of similarities with schema-validate
-		            // Since we might have different tv4 errors we must clear all
-		            // errors that start with tv4-
-		            Object.keys(ngModel.$error).filter(function (k) {
-		              return k.indexOf('tv4-') === 0;
-		            }).forEach(function (k) {
-		              ngModel.$setValidity(k, true);
-		            });
-
-		            if (result.valid === false && result.error && (result.error.dataPath === '' || result.error.dataPath === '/' + form.key[form.key.length - 1])) {
-
-		              // Set viewValue to trigger $dirty on field. If someone knows a
-		              // a better way to do it please tell.
-		              ngModel.$setViewValue(scope.modelArray);
-		              error = result.error;
-		              ngModel.$setValidity('tv4-' + result.error.code, false);
-		            }
-		          };
-
-		          scope.$on('schemaFormValidate', scope.validateArray);
-
-		          scope.hasSuccess = function () {
-		            if (scope.options && scope.options.pristine && scope.options.pristine.success === false) {
-		              return ngModel.$valid && !ngModel.$pristine && !ngModel.$isEmpty(ngModel.$modelValue);
-		            } else {
-		              return ngModel.$valid && (!ngModel.$pristine || !ngModel.$isEmpty(ngModel.$modelValue));
-		            }
-		          };
-
-		          scope.hasError = function () {
-		            if (!scope.options || !scope.options.pristine || scope.options.pristine.errors !== false) {
-		              // Show errors in pristine forms. The default.
-		              // Note that "validateOnRender" option defaults to *not* validate initial form.
-		              // so as a default there won't be any error anyway, but if the model is modified
-		              // from the outside the error will show even if the field is pristine.
-		              return ngModel.$invalid;
-		            } else {
-		              // Don't show errors in pristine forms.
-		              return ngModel.$invalid && !ngModel.$pristine;
-		            }
-		          };
-
-		          scope.schemaError = function () {
-		            return error;
-		          };
-		        }
-
-		        once();
-		      });
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 12 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function () {
-		  return {
-		    require: 'ngModel',
-		    restrict: 'AC',
-		    scope: false,
-		    link: function link(scope, element, attrs, ctrl) {
-		      var form = scope.$eval(attrs.sfChanged);
-		      //"form" is really guaranteed to be here since the decorator directive
-		      //waits for it. But best be sure.
-		      if (form && form.onChange) {
-		        ctrl.$viewChangeListeners.push(function () {
-		          if (_angular2.default.isFunction(form.onChange)) {
-		            form.onChange(ctrl.$modelValue, form);
-		          } else {
-		            scope.evalExpr(form.onChange, { 'modelValue': ctrl.$modelValue, form: form });
-		          }
-		        });
-		      }
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 13 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function ($parse, $compile, $http, $templateCache, $interpolate, $q, sfErrorMessage, sfPath, sfSelect) {
-
-		  return {
-		    restrict: 'AE',
-		    replace: false,
-		    transclude: false,
-		    scope: true,
-		    require: '^sfSchema',
-		    link: {
-		      pre: function pre(scope, element, attrs, sfSchema) {
-		        //The ngModelController is used in some templates and
-		        //is needed for error messages,
-		        scope.$on('schemaFormPropagateNgModelController', function (event, ngModel) {
-		          event.stopPropagation();
-		          event.preventDefault();
-		          scope.ngModel = ngModel;
-		        });
-
-		        // Fetch our form.
-		        scope.form = sfSchema.lookup['f' + attrs.sfField];
-		      },
-		      post: function post(scope, element, attrs, sfSchema) {
-		        //Keep error prone logic from the template
-		        scope.showTitle = function () {
-		          return scope.form && scope.form.notitle !== true && scope.form.title;
-		        };
-
-		        scope.listToCheckboxValues = function (list) {
-		          var values = {};
-		          _angular2.default.forEach(list, function (v) {
-		            values[v] = true;
-		          });
-		          return values;
-		        };
-
-		        scope.checkboxValuesToList = function (values) {
-		          var lst = [];
-		          _angular2.default.forEach(values, function (v, k) {
-		            if (v) {
-		              lst.push(k);
-		            }
-		          });
-		          return lst;
-		        };
-
-		        scope.buttonClick = function ($event, form) {
-		          if (_angular2.default.isFunction(form.onClick)) {
-		            form.onClick($event, form);
-		          } else if (_angular2.default.isString(form.onClick)) {
-		            if (sfSchema) {
-		              //evaluating in scope outside of sfSchemas isolated scope
-		              sfSchema.evalInParentScope(form.onClick, { '$event': $event, form: form });
-		            } else {
-		              scope.$eval(form.onClick, { '$event': $event, form: form });
-		            }
-		          }
-		        };
-
-		        /**
-		         * Evaluate an expression, i.e. scope.$eval
-		         * but do it in sfSchemas parent scope sf-schema directive is used
-		         *
-		         * @param {string} expression
-		         * @param {Object} locals (optional)
-		         * @return {Any} the result of the expression
-		         */
-		        scope.evalExpr = function (expression, locals) {
-		          if (sfSchema) {
-		            //evaluating in scope outside of sfSchemas isolated scope
-		            return sfSchema.evalInParentScope(expression, locals);
-		          }
-
-		          return scope.$eval(expression, locals);
-		        };
-
-		        /**
-		         * Evaluate an expression, i.e. scope.$eval
-		         * in this decorators scope
-		         * @param {string} expression
-		         * @param {Object} locals (optional)
-		         * @return {Any} the result of the expression
-		         */
-		        scope.evalInScope = function (expression, locals) {
-		          if (expression) {
-		            return scope.$eval(expression, locals);
-		          }
-		        };
-
-		        /**
-		         * Interpolate the expression.
-		         * Similar to `evalExpr()` and `evalInScope()`
-		         * but will not fail if the expression is
-		         * text that contains spaces.
-		         *
-		         * Use the Angular `{{ interpolation }}`
-		         * braces to access properties on `locals`.
-		         *
-		         * @param  {string} content The string to interpolate.
-		         * @param  {Object} locals (optional) Properties that may be accessed in the
-		         *                         `expression` string.
-		         * @return {Any} The result of the expression or `undefined`.
-		         */
-		        scope.interp = function (expression, locals) {
-		          return expression && $interpolate(expression)(locals);
-		        };
-
-		        //This works since we get the ngModel from the array or the schema-validate directive.
-		        scope.hasSuccess = function () {
-		          if (!scope.ngModel) {
-		            return false;
-		          }
-		          if (scope.options && scope.options.pristine && scope.options.pristine.success === false) {
-		            return scope.ngModel.$valid && !scope.ngModel.$pristine && !scope.ngModel.$isEmpty(scope.ngModel.$modelValue);
-		          } else {
-		            return scope.ngModel.$valid && (!scope.ngModel.$pristine || !scope.ngModel.$isEmpty(scope.ngModel.$modelValue));
-		          }
-		        };
-
-		        scope.hasError = function () {
-		          if (!scope.ngModel) {
-		            return false;
-		          }
-		          if (!scope.options || !scope.options.pristine || scope.options.pristine.errors !== false) {
-		            // Show errors in pristine forms. The default.
-		            // Note that "validateOnRender" option defaults to *not* validate initial form.
-		            // so as a default there won't be any error anyway, but if the model is modified
-		            // from the outside the error will show even if the field is pristine.
-		            return scope.ngModel.$invalid;
-		          } else {
-		            // Don't show errors in pristine forms.
-		            return scope.ngModel.$invalid && !scope.ngModel.$pristine;
-		          }
-		        };
-
-		        /**
-		         * DEPRECATED: use sf-messages instead.
-		         * Error message handler
-		         * An error can either be a schema validation message or a angular js validtion
-		         * error (i.e. required)
-		         */
-		        scope.errorMessage = function (schemaError) {
-		          return sfErrorMessage.interpolate(schemaError && schemaError.code + '' || 'default', scope.ngModel && scope.ngModel.$modelValue || '', scope.ngModel && scope.ngModel.$viewValue || '', scope.form, scope.options && scope.options.validationMessage);
-		        };
-
-		        var form = scope.form;
-
-		        // Where there is a key there is probably a ngModel
-		        if (form.key) {
-		          // It looks better with dot notation.
-		          scope.$on('schemaForm.error.' + form.key.join('.'), function (event, error, validationMessage, validity, formName) {
-		            // validationMessage and validity are mutually exclusive
-		            formName = validity;
-		            if (validationMessage === true || validationMessage === false) {
-		              validity = validationMessage;
-		              validationMessage = undefined;
-		            };
-
-		            // If we have specified a form name, and this model is not within
-		            // that form, then leave things be.
-		            if (formName != undefined && scope.ngModel.$$parentForm.$name !== formName) {
-		              return;
-		            };
-
-		            if (scope.ngModel && error) {
-		              if (scope.ngModel.$setDirty) {
-		                scope.ngModel.$setDirty();
-		              } else {
-		                // FIXME: Check that this actually works on 1.2
-		                scope.ngModel.$dirty = true;
-		                scope.ngModel.$pristine = false;
-		              }
-
-		              // Set the new validation message if one is supplied
-		              // Does not work when validationMessage is just a string.
-		              if (validationMessage) {
-		                if (!form.validationMessage) {
-		                  form.validationMessage = {};
-		                }
-		                form.validationMessage[error] = validationMessage;
-		              }
-
-		              scope.ngModel.$setValidity(error, validity === true);
-
-		              if (validity === true) {
-		                // Re-trigger model validator, that model itself would be re-validated
-		                scope.ngModel.$validate();
-
-		                // Setting or removing a validity can change the field to believe its valid
-		                // but its not. So lets trigger its validation as well.
-		                scope.$broadcast('schemaFormValidate');
-		              }
-		            }
-		          });
-
-		          // Clean up the model when the corresponding form field is $destroy-ed.
-		          // Default behavior can be supplied as a globalOption, and behavior can be overridden
-		          // in the form definition.
-		          scope.$on('$destroy', function () {
-		            // If the entire schema form is destroyed we don't touch the model
-		            if (!scope.externalDestructionInProgress) {
-		              var destroyStrategy = form.destroyStrategy || scope.options && scope.options.destroyStrategy || 'remove';
-		              // No key no model, and we might have strategy 'retain'
-		              if (form.key && destroyStrategy !== 'retain') {
-
-		                // Get the object that has the property we wan't to clear.
-		                var obj = scope.model;
-		                if (form.key.length > 1) {
-		                  obj = sfSelect(form.key.slice(0, form.key.length - 1), obj);
-		                }
-
-		                // We can get undefined here if the form hasn't been filled out entirely
-		                if (obj === undefined) {
-		                  return;
-		                }
-
-		                // Type can also be a list in JSON Schema
-		                var type = form.schema && form.schema.type || '';
-
-		                // Empty means '',{} and [] for appropriate types and undefined for the rest
-		                //console.log('destroy', destroyStrategy, form.key, type, obj);
-		                if (destroyStrategy === 'empty' && type.indexOf('string') !== -1) {
-		                  obj[form.key.slice(-1)] = '';
-		                } else if (destroyStrategy === 'empty' && type.indexOf('object') !== -1) {
-		                  obj[form.key.slice(-1)] = {};
-		                } else if (destroyStrategy === 'empty' && type.indexOf('array') !== -1) {
-		                  obj[form.key.slice(-1)] = [];
-		                } else if (destroyStrategy === 'null') {
-		                  obj[form.key.slice(-1)] = null;
-		                } else {
-		                  delete obj[form.key.slice(-1)];
-		                }
-		              }
-		            }
-		          });
-		        }
-		      }
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 14 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function ($injector, sfErrorMessage) {
-
-		  //Inject sanitizer if it exists
-		  var $sanitize = $injector.has('$sanitize') ? $injector.get('$sanitize') : function (html) {
-		    return html;
-		  };
-
-		  return {
-		    scope: false,
-		    restrict: 'EA',
-		    link: function link(scope, element, attrs) {
-
-		      var message = '';
-		      if (attrs.sfMessage) {
-		        scope.$watch(attrs.sfMessage, function (msg) {
-		          if (msg) {
-		            message = $sanitize(msg);
-		            update(!!scope.ngModel);
-		          }
-		        });
-		      }
-
-		      var currentMessage;
-		      // Only call html() if needed.
-		      var setMessage = function setMessage(msg) {
-		        if (msg !== currentMessage) {
-		          element.html(msg);
-		          currentMessage = msg;
-		        }
-		      };
-
-		      var update = function update(checkForErrors) {
-		        if (checkForErrors) {
-		          if (!scope.hasError()) {
-		            setMessage(message);
-		          } else {
-		            var errors = [];
-		            _angular2.default.forEach(scope.ngModel && scope.ngModel.$error, function (status, code) {
-		              if (status) {
-		                // if true then there is an error
-		                // Angular 1.3 removes properties, so we will always just have errors.
-		                // Angular 1.2 sets them to false.
-		                errors.push(code);
-		              }
-		            });
-
-		            // In Angular 1.3 we use one $validator to stop the model value from getting updated.
-		            // this means that we always end up with a 'schemaForm' error.
-		            errors = errors.filter(function (e) {
-		              return e !== 'schemaForm';
-		            });
-
-		            // We only show one error.
-		            // TODO: Make that optional
-		            var error = errors[0];
-
-		            if (error) {
-		              setMessage(sfErrorMessage.interpolate(error, scope.ngModel.$modelValue, scope.ngModel.$viewValue, scope.form, scope.options && scope.options.validationMessage));
-		            } else {
-		              setMessage(message);
-		            }
-		          }
-		        } else {
-		          setMessage(message);
-		        }
-		      };
-
-		      // Update once.
-		      update();
-
-		      var once = scope.$watch('ngModel', function (ngModel) {
-		        if (ngModel) {
-		          // We also listen to changes of the model via parsers and formatters.
-		          // This is since both the error message can change and given a pristine
-		          // option to not show errors the ngModel.$error might not have changed
-		          // but we're not pristine any more so we should change!
-		          ngModel.$parsers.push(function (val) {
-		            update(true);return val;
-		          });
-		          ngModel.$formatters.push(function (val) {
-		            update(true);return val;
-		          });
-		          once();
-		        }
-		      });
-
-		      // We watch for changes in $error
-		      scope.$watchCollection('ngModel.$error', function () {
-		        update(!!scope.ngModel);
-		      });
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 15 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function (sel, sfPath, schemaForm) {
-		  return {
-		    scope: false,
-		    link: function link(scope, element, attrs) {
-		      scope.min = 0;
-
-		      scope.modelArray = scope.$eval(attrs.sfNewArray);
-
-		      // We need to have a ngModel to hook into validation. It doesn't really play well with
-		      // arrays though so we both need to trigger validation and onChange.
-		      // So we watch the value as well. But watching an array can be tricky. We wan't to know
-		      // when it changes so we can validate,
-		      var watchFn = function watchFn() {
-		        //scope.modelArray = modelArray;
-		        scope.modelArray = scope.$eval(attrs.sfNewArray);
-		        // validateField method is exported by schema-validate
-		        if (scope.ngModel && scope.ngModel.$pristine && scope.firstDigest && (!scope.options || scope.options.validateOnRender !== true)) {
-		          return;
-		        } else if (scope.validateField) {
-		          scope.validateField();
-		        }
-		      };
-
-		      var onChangeFn = function onChangeFn() {
-		        if (scope.form && scope.form.onChange) {
-		          if (_angular2.default.isFunction(scope.form.onChange)) {
-		            scope.form.onChange(scope.modelArray, scope.form);
-		          } else {
-		            scope.evalExpr(scope.form.onChange, { 'modelValue': scope.modelArray, form: scope.form });
-		          }
-		        }
-		      };
-
-		      // If model is undefined make sure it gets set.
-		      var getOrCreateModel = function getOrCreateModel() {
-		        var model = scope.modelArray;
-		        if (!model) {
-		          var selection = sfPath.parse(attrs.sfNewArray);
-		          model = [];
-		          sel(selection, scope, model);
-		          scope.modelArray = model;
-		        }
-		        return model;
-		      };
-
-		      // We need the form definition to make a decision on how we should listen.
-		      var once = scope.$watch('form', function (form) {
-		        if (!form) {
-		          return;
-		        }
-
-		        // Always start with one empty form unless configured otherwise.
-		        // Special case: don't do it if form has a titleMap
-		        if (!form.titleMap && form.startEmpty !== true && (!scope.modelArray || scope.modelArray.length === 0)) {
-		          scope.appendToArray();
-		        }
-
-		        // If we have "uniqueItems" set to true, we must deep watch for changes.
-		        if (scope.form && scope.form.schema && scope.form.schema.uniqueItems === true) {
-		          scope.$watch(attrs.sfNewArray, watchFn, true);
-
-		          // We still need to trigger onChange though.
-		          scope.$watch([attrs.sfNewArray, attrs.sfNewArray + '.length'], onChangeFn);
-		        } else {
-		          // Otherwise we like to check if the instance of the array has changed, or if something
-		          // has been added/removed.
-		          if (scope.$watchGroup) {
-		            scope.$watchGroup([attrs.sfNewArray, attrs.sfNewArray + '.length'], function () {
-		              watchFn();
-		              onChangeFn();
-		            });
-		          } else {
-		            // Angular 1.2 support
-		            scope.$watch(attrs.sfNewArray, function () {
-		              watchFn();
-		              onChangeFn();
-		            });
-		            scope.$watch(attrs.sfNewArray + '.length', function () {
-		              watchFn();
-		              onChangeFn();
-		            });
-		          }
-		        }
-
-		        // Title Map handling
-		        // If form has a titleMap configured we'd like to enable looping over
-		        // titleMap instead of modelArray, this is used for intance in
-		        // checkboxes. So instead of variable number of things we like to create
-		        // a array value from a subset of values in the titleMap.
-		        // The problem here is that ng-model on a checkbox doesn't really map to
-		        // a list of values. This is here to fix that.
-		        if (form.titleMap && form.titleMap.length > 0) {
-		          scope.titleMapValues = [];
-
-		          // We watch the model for changes and the titleMapValues to reflect
-		          // the modelArray
-		          var updateTitleMapValues = function updateTitleMapValues(arr) {
-		            scope.titleMapValues = [];
-		            arr = arr || [];
-
-		            form.titleMap.forEach(function (item) {
-		              scope.titleMapValues.push(arr.indexOf(item.value) !== -1);
-		            });
-		          };
-		          //Catch default values
-		          updateTitleMapValues(scope.modelArray);
-
-		          // TODO: Refactor and see if we can get rid of this watch by piggy backing on the
-		          // validation watch.
-		          scope.$watchCollection('modelArray', updateTitleMapValues);
-
-		          //To get two way binding we also watch our titleMapValues
-		          scope.$watchCollection('titleMapValues', function (vals, old) {
-		            if (vals && vals !== old) {
-		              var arr = getOrCreateModel();
-
-		              form.titleMap.forEach(function (item, index) {
-		                var arrIndex = arr.indexOf(item.value);
-		                if (arrIndex === -1 && vals[index]) arr.push(item.value);
-		                if (arrIndex !== -1 && !vals[index]) arr.splice(arrIndex, 1);
-		              });
-		              // Time to validate the rebuilt array.
-		              // validateField method is exported by schema-validate
-		              if (scope.validateField) {
-		                scope.validateField();
-		              }
-		            }
-		          });
-		        }
-
-		        once();
-		      });
-
-		      scope.appendToArray = function () {
-		        var empty;
-
-		        // Create and set an array if needed.
-		        var model = getOrCreateModel();
-
-		        // Same old add empty things to the array hack :(
-		        if (scope.form && scope.form.schema && scope.form.schema.items) {
-
-		          var items = scope.form.schema.items;
-		          if (items.type && items.type.indexOf('object') !== -1) {
-		            empty = {};
-
-		            // Check for possible defaults
-		            if (!scope.options || scope.options.setSchemaDefaults !== false) {
-		              empty = _angular2.default.isDefined(items['default']) ? items['default'] : empty;
-
-		              // Check for defaults further down in the schema.
-		              // If the default instance sets the new array item to something falsy, i.e. null
-		              // then there is no need to go further down.
-		              if (empty) {
-		                schemaForm.traverseSchema(items, function (prop, path) {
-		                  if (_angular2.default.isDefined(prop['default'])) {
-		                    sel(path, empty, prop['default']);
-		                  }
-		                });
-		              }
-		            }
-		          } else if (items.type && items.type.indexOf('array') !== -1) {
-		            empty = [];
-		            if (!scope.options || scope.options.setSchemaDefaults !== false) {
-		              empty = items['default'] || empty;
-		            }
-		          } else {
-		            // No type? could still have defaults.
-		            if (!scope.options || scope.options.setSchemaDefaults !== false) {
-		              empty = items['default'] || empty;
-		            }
-		          }
-		        }
-		        model.push(empty);
-
-		        return model;
-		      };
-
-		      scope.deleteFromArray = function (index) {
-		        var model = scope.modelArray;
-		        if (model) {
-		          model.splice(index, 1);
-		        }
-		        return model;
-		      };
-
-		      // For backwards compatability, i.e. when a bootstrap-decorator tag is used
-		      // as child to the array.
-		      var setIndex = function setIndex(index) {
-		        return function (form) {
-		          if (form.key) {
-		            form.key[form.key.indexOf('')] = index;
-		          }
-		        };
-		      };
-		      var formDefCache = {};
-		      scope.copyWithIndex = function (index) {
-		        var form = scope.form;
-		        if (!formDefCache[index]) {
-
-		          // To be more compatible with JSON Form we support an array of items
-		          // in the form definition of "array" (the schema just a value).
-		          // for the subforms code to work this means we wrap everything in a
-		          // section. Unless there is just one.
-		          var subForm = form.items[0];
-		          if (form.items.length > 1) {
-		            subForm = {
-		              type: 'section',
-		              items: form.items.map(function (item) {
-		                item.ngModelOptions = form.ngModelOptions;
-		                if (_angular2.default.isUndefined(item.readonly)) {
-		                  item.readonly = form.readonly;
-		                }
-		                return item;
-		              })
-		            };
-		          }
-
-		          if (subForm) {
-		            var copy = _angular2.default.copy(subForm);
-		            copy.arrayIndex = index;
-		            schemaForm.traverseForm(copy, setIndex(index));
-		            formDefCache[index] = copy;
-		          }
-		        }
-		        return formDefCache[index];
-		      };
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 16 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function ($compile, $http, $templateCache, $q, schemaForm, schemaFormDecorators, sfSelect, sfPath, sfBuilder) {
-
-		  return {
-		    scope: {
-		      schema: '=sfSchema',
-		      initialForm: '=sfForm',
-		      model: '=sfModel',
-		      options: '=sfOptions'
-		    },
-		    controller: ['$scope', function ($scope) {
-		      this.evalInParentScope = function (expr, locals) {
-		        return $scope.$parent.$eval(expr, locals);
-		      };
-
-		      // Set up form lookup map
-		      var that = this;
-		      $scope.lookup = function (lookup) {
-		        if (lookup) {
-		          that.lookup = lookup;
-		        }
-		        return that.lookup;
-		      };
-		    }],
-		    replace: false,
-		    restrict: 'A',
-		    transclude: true,
-		    require: '?form',
-		    link: function link(scope, element, attrs, formCtrl, transclude) {
-
-		      //expose form controller on scope so that we don't force authors to use name on form
-		      scope.formCtrl = formCtrl;
-
-		      //We'd like to handle existing markup,
-		      //besides using it in our template we also
-		      //check for ng-model and add that to an ignore list
-		      //i.e. even if form has a definition for it or form is ["*"]
-		      //we don't generate it.
-		      var ignore = {};
-		      transclude(scope, function (clone) {
-		        clone.addClass('schema-form-ignore');
-		        element.prepend(clone);
-
-		        if (element[0].querySelectorAll) {
-		          var models = element[0].querySelectorAll('[ng-model]');
-		          if (models) {
-		            for (var i = 0; i < models.length; i++) {
-		              var key = models[i].getAttribute('ng-model');
-		              //skip first part before .
-		              ignore[key.substring(key.indexOf('.') + 1)] = true;
-		            }
-		          }
-		        }
-		      });
-
-		      var lastDigest = {};
-		      var childScope;
-
-		      // Common renderer function, can either be triggered by a watch or by an event.
-		      var render = function render(schema, form) {
-		        var asyncTemplates = [];
-		        var merged = schemaForm.merge(schema, form, ignore, scope.options, undefined, asyncTemplates);
-
-		        if (asyncTemplates.length > 0) {
-		          // Pre load all async templates and put them on the form for the builder to use.
-		          $q.all(asyncTemplates.map(function (form) {
-		            return $http.get(form.templateUrl, { cache: $templateCache }).then(function (res) {
-		              form.template = res.data;
-		            });
-		          })).then(function () {
-		            internalRender(schema, form, merged);
-		          });
-		        } else {
-		          internalRender(schema, form, merged);
-		        }
-		      };
-
-		      var internalRender = function internalRender(schema, form, merged) {
-		        // Create a new form and destroy the old one.
-		        // Not doing keeps old form elements hanging around after
-		        // they have been removed from the DOM
-		        // https://github.com/Textalk/angular-schema-form/issues/200
-		        if (childScope) {
-		          // Destroy strategy should not be acted upon
-		          scope.externalDestructionInProgress = true;
-		          childScope.$destroy();
-		          scope.externalDestructionInProgress = false;
-		        }
-		        childScope = scope.$new();
-
-		        //make the form available to decorators
-		        childScope.schemaForm = { form: merged, schema: schema };
-
-		        //clean all but pre existing html.
-		        element.children(':not(.schema-form-ignore)').remove();
-
-		        // Find all slots.
-		        var slots = {};
-		        var slotsFound = element[0].querySelectorAll('*[sf-insert-field]');
-
-		        for (var i = 0; i < slotsFound.length; i++) {
-		          slots[slotsFound[i].getAttribute('sf-insert-field')] = slotsFound[i];
-		        }
-
-		        // if sfUseDecorator is undefined the default decorator is used.
-		        var decorator = schemaFormDecorators.decorator(attrs.sfUseDecorator);
-		        // Use the builder to build it and append the result
-		        var lookup = Object.create(null);
-		        scope.lookup(lookup); // give the new lookup to the controller.
-		        element[0].appendChild(sfBuilder.build(merged, decorator, slots, lookup));
-
-		        // We need to know if we're in the first digest looping
-		        // I.e. just rendered the form so we know not to validate
-		        // empty fields.
-		        childScope.firstDigest = true;
-		        // We use a ordinary timeout since we don't need a digest after this.
-		        setTimeout(function () {
-		          childScope.firstDigest = false;
-		        }, 0);
-
-		        //compile only children
-		        $compile(element.children())(childScope);
-
-		        //ok, now that that is done let's set any defaults
-		        if (!scope.options || scope.options.setSchemaDefaults !== false) {
-		          schemaForm.traverseSchema(schema, function (prop, path) {
-		            if (_angular2.default.isDefined(prop['default'])) {
-		              var val = sfSelect(path, scope.model);
-		              if (_angular2.default.isUndefined(val)) {
-		                sfSelect(path, scope.model, prop['default']);
-		              }
-		            }
-		          });
-		        }
-
-		        scope.$emit('sf-render-finished', element);
-		      };
-
-		      var defaultForm = ['*'];
-
-		      //Since we are dependant on up to three
-		      //attributes we'll do a common watch
-		      scope.$watch(function () {
-
-		        var schema = scope.schema;
-		        var form = scope.initialForm || defaultForm;
-
-		        //The check for schema.type is to ensure that schema is not {}
-		        if (form && schema && schema.type && (lastDigest.form !== form || lastDigest.schema !== schema) && Object.keys(schema.properties).length > 0) {
-		          lastDigest.schema = schema;
-		          lastDigest.form = form;
-
-		          render(schema, form);
-		        }
-		      });
-
-		      // We also listen to the event schemaFormRedraw so you can manually trigger a change if
-		      // part of the form or schema is chnaged without it being a new instance.
-		      scope.$on('schemaFormRedraw', function () {
-		        var schema = scope.schema;
-		        var form = scope.initialForm ? _angular2.default.copy(scope.initialForm) : ['*'];
-		        if (schema) {
-		          render(schema, form);
-		        }
-		      });
-
-		      scope.$on('$destroy', function () {
-		        // Each field listens to the $destroy event so that it can remove any value
-		        // from the model if that field is removed from the form. This is the default
-		        // destroy strategy. But if the entire form (or at least the part we're on)
-		        // gets removed, like when routing away to another page, then we definetly want to
-		        // keep the model intact. So therefore we set a flag to tell the others it's time to just
-		        // let it be.
-		        scope.externalDestructionInProgress = true;
-		      });
-
-		      /**
-		       * Evaluate an expression, i.e. scope.$eval
-		       * but do it in parent scope
-		       *
-		       * @param {String} expression
-		       * @param {Object} locals (optional)
-		       * @return {Any} the result of the expression
-		       */
-		      scope.evalExpr = function (expression, locals) {
-		        return scope.$parent.$eval(expression, locals);
-		      };
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 17 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function (sfValidator, $parse, sfSelect) {
-
-		  return {
-		    restrict: 'A',
-		    scope: false,
-		    // We want the link function to be *after* the input directives link function so we get access
-		    // the parsed value, ex. a number instead of a string
-		    priority: 500,
-		    require: 'ngModel',
-		    link: function link(scope, element, attrs, ngModel) {
-		      // We need the ngModelController on several places,
-		      // most notably for errors.
-		      // So we emit it up to the decorator directive so it can put it on scope.
-		      scope.$emit('schemaFormPropagateNgModelController', ngModel);
-
-		      var error = null;
-		      var form = scope.$eval(attrs.schemaValidate);
-
-		      if (form.copyValueTo) {
-		        ngModel.$viewChangeListeners.push(function () {
-		          var paths = form.copyValueTo;
-		          _angular2.default.forEach(paths, function (path) {
-		            sfSelect(path, scope.model, ngModel.$modelValue);
-		          });
-		        });
-		      };
-
-		      // Validate against the schema.
-
-		      var validate = function validate(viewValue) {
-		        //console.log('validate called', viewValue)
-		        //Still might be undefined
-		        if (!form) {
-		          return viewValue;
-		        }
-
-		        // Omit TV4 validation
-		        if (scope.options && scope.options.tv4Validation === false) {
-		          return viewValue;
-		        }
-
-		        var result = sfValidator.validate(form, viewValue);
-		        //console.log('result is', result)
-		        // Since we might have different tv4 errors we must clear all
-		        // errors that start with tv4-
-		        Object.keys(ngModel.$error).filter(function (k) {
-		          return k.indexOf('tv4-') === 0;
-		        }).forEach(function (k) {
-		          ngModel.$setValidity(k, true);
-		        });
-
-		        if (!result.valid) {
-		          // it is invalid, return undefined (no model update)
-		          ngModel.$setValidity('tv4-' + result.error.code, false);
-		          error = result.error;
-
-		          // In Angular 1.3+ return the viewValue, otherwise we inadvertenly
-		          // will trigger a 'parse' error.
-		          // we will stop the model value from updating with our own $validator
-		          // later.
-		          if (ngModel.$validators) {
-		            return viewValue;
-		          }
-		          // Angular 1.2 on the other hand lacks $validators and don't add a 'parse' error.
-		          return undefined;
-		        }
-		        return viewValue;
-		      };
-
-		      // Custom validators, parsers, formatters etc
-		      if (typeof form.ngModel === 'function') {
-		        form.ngModel(ngModel);
-		      }
-
-		      ['$parsers', '$viewChangeListeners', '$formatters'].forEach(function (attr) {
-		        if (form[attr] && ngModel[attr]) {
-		          form[attr].forEach(function (fn) {
-		            ngModel[attr].push(fn);
-		          });
-		        }
-		      });
-
-		      ['$validators', '$asyncValidators'].forEach(function (attr) {
-		        // Check if our version of angular has validators, i.e. 1.3+
-		        if (form[attr] && ngModel[attr]) {
-		          _angular2.default.forEach(form[attr], function (fn, name) {
-		            ngModel[attr][name] = fn;
-		          });
-		        }
-		      });
-
-		      // Get in last of the parses so the parsed value has the correct type.
-		      // We don't use $validators since we like to set different errors depending tv4 error codes
-		      ngModel.$parsers.push(validate);
-
-		      // But we do use one custom validator in the case of Angular 1.3 to stop the model from
-		      // updating if we've found an error.
-		      if (ngModel.$validators) {
-		        ngModel.$validators.schemaForm = function () {
-		          //console.log('validators called.')
-		          // Any error and we're out of here!
-		          return !Object.keys(ngModel.$error).some(function (e) {
-		            return e !== 'schemaForm';
-		          });
-		        };
-		      }
-
-		      var schema = form.schema;
-
-		      // A bit ugly but useful.
-		      scope.validateField = function (formName) {
-		        // If we have specified a form name, and this model is not within
-		        // that form, then leave things be.
-		        if (formName != undefined && ngModel.$$parentForm.$name !== formName) {
-		          return;
-		        }
-
-		        // Special case: arrays
-		        // TODO: Can this be generalized in a way that works consistently?
-		        // Just setting the viewValue isn't enough to trigger validation
-		        // since it's the same value. This will be better when we drop
-		        // 1.2 support.
-		        if (schema && schema.type.indexOf('array') !== -1) {
-		          validate(ngModel.$modelValue);
-		        }
-
-		        // We set the viewValue to trigger parsers,
-		        // since modelValue might be empty and validating just that
-		        // might change an existing error to a "required" error message.
-		        if (ngModel.$setDirty) {
-
-		          // Angular 1.3+
-		          ngModel.$setDirty();
-		          ngModel.$setViewValue(ngModel.$viewValue);
-		          ngModel.$commitViewValue();
-
-		          // In Angular 1.3 setting undefined as a viewValue does not trigger parsers
-		          // so we need to do a special required check.
-
-		          // angulars checkbox directive isEmpty does not do the check we want.
-		          if (form.type === 'checkbox') {
-		            if (form.required && ngModel.$modelValue === undefined) {
-		              ngModel.$setValidity('tv4-302', false);
-		            }
-		          } else if (form.required && ngModel.$isEmpty(ngModel.$modelValue)) {
-		            ngModel.$setValidity('tv4-302', false);
-		          }
-		        } else {
-		          // Angular 1.2
-		          // In angular 1.2 setting a viewValue of undefined will trigger the parser.
-		          // hence required works.
-		          ngModel.$setViewValue(ngModel.$viewValue);
-		        }
-		      };
-
-		      var first = true;
-		      ngModel.$formatters.push(function (val) {
-		        // When a form first loads this will be called for each field.
-		        // we usually don't want that.
-		        if (ngModel.$pristine && first && (!scope.options || scope.options.validateOnRender !== true)) {
-		          first = false;
-		          return val;
-		        }
-		        validate(ngModel.$modelValue);
-		        return val;
-		      });
-
-		      // Listen to an event so we can validate the input on request
-		      scope.$on('schemaFormValidate', function (event, formName) {
-		        scope.validateField(formName);
-		      });
-
-		      scope.schemaError = function () {
-		        return error;
-		      };
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ }
-	/******/ ])
-	});
-	;
-
-/***/ },
-/* 2 */
 /***/ function(module, exports, __webpack_require__) {
 
 	'use strict';
 
 	// angular-templatecache-loader
-	var textareaTemplate = __webpack_require__(18);
-	var fieldsetTemplate = __webpack_require__(8);
-	var arrayTemplate = __webpack_require__(4);
-	var tabarrayTemplate = __webpack_require__(16);
-	var tabsTemplate = __webpack_require__(17);
-	var sectionTemplate = __webpack_require__(13);
-	var actionsTemplate = __webpack_require__(3);
-	var selectTemplate = __webpack_require__(14);
-	var checkboxTemplate = __webpack_require__(5);
-	var checkboxesTemplate = __webpack_require__(6);
-	var submitTemplate = __webpack_require__(15);
-	var radiosTemplate = __webpack_require__(12);
-	var radiosInlineTemplate = __webpack_require__(11);
-	var radiobuttonsTemplate = __webpack_require__(10);
-	var helpTemplate = __webpack_require__(9);
-	var defaultTemplate = __webpack_require__(7);
+	var textareaTemplate = __webpack_require__(17);
+	var fieldsetTemplate = __webpack_require__(7);
+	var arrayTemplate = __webpack_require__(3);
+	var tabarrayTemplate = __webpack_require__(15);
+	var tabsTemplate = __webpack_require__(16);
+	var sectionTemplate = __webpack_require__(12);
+	var actionsTemplate = __webpack_require__(2);
+	var selectTemplate = __webpack_require__(13);
+	var checkboxTemplate = __webpack_require__(4);
+	var checkboxesTemplate = __webpack_require__(5);
+	var submitTemplate = __webpack_require__(14);
+	var radiosTemplate = __webpack_require__(11);
+	var radiosInlineTemplate = __webpack_require__(10);
+	var radiobuttonsTemplate = __webpack_require__(9);
+	var helpTemplate = __webpack_require__(8);
+	var defaultTemplate = __webpack_require__(6);
 
 	angular.module('schemaForm').config(bootstrapDecoratorConfig).filter('sfCamelKey', sfCamelKeyFilter);
 
@@ -3753,26 +156,26 @@ return /******/ (function(modules) { // webpackBootstrap
 
 	  var defaults = [sfField, ngModel, ngModelOptions, condition];
 	  decoratorsProvider.defineDecorator('bootstrapDecorator', {
-	    textarea: { template: textareaTemplate, builder: defaults },
-	    fieldset: { template: fieldsetTemplate, builder: [sfField, simpleTransclusion, condition] },
-	    array: { template: arrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
-	    tabarray: { template: tabarrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
-	    tabs: { template: tabsTemplate, builder: [sfField, ngModelOptions, tabs, condition] },
-	    section: { template: sectionTemplate, builder: [sfField, simpleTransclusion, condition] },
-	    conditional: { template: sectionTemplate, builder: [sfField, simpleTransclusion, condition] },
 	    actions: { template: actionsTemplate, builder: defaults },
-	    select: { template: selectTemplate, builder: defaults.concat(selectPlaceholder) },
+	    array: { template: arrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
+	    button: { template: submitTemplate, builder: defaults },
 	    checkbox: { template: checkboxTemplate, builder: defaults },
 	    checkboxes: { template: checkboxesTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
+	    conditional: { template: sectionTemplate, builder: [sfField, simpleTransclusion, condition] },
+	    'default': { template: defaultTemplate, builder: defaults },
+	    fieldset: { template: fieldsetTemplate, builder: [sfField, simpleTransclusion, condition] },
+	    help: { template: helpTemplate, builder: defaults },
 	    number: { template: defaultTemplate, builder: defaults.concat(numeric) },
 	    password: { template: defaultTemplate, builder: defaults },
-	    submit: { template: submitTemplate, builder: defaults },
-	    button: { template: submitTemplate, builder: defaults },
 	    radios: { template: radiosTemplate, builder: defaults },
 	    'radios-inline': { template: radiosInlineTemplate, builder: defaults },
 	    radiobuttons: { template: radiobuttonsTemplate, builder: defaults },
-	    help: { template: helpTemplate, builder: defaults },
-	    'default': { template: defaultTemplate, builder: defaults }
+	    section: { template: sectionTemplate, builder: [sfField, simpleTransclusion, condition] },
+	    select: { template: selectTemplate, builder: defaults.concat(selectPlaceholder) },
+	    submit: { template: submitTemplate, builder: defaults },
+	    tabarray: { template: tabarrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
+	    tabs: { template: tabsTemplate, builder: [sfField, ngModelOptions, tabs, condition] },
+	    textarea: { template: textareaTemplate, builder: defaults }
 	  }, []);
 	};
 
@@ -3798,161 +201,149 @@ return /******/ (function(modules) { // webpackBootstrap
 	};
 
 /***/ },
-/* 3 */
+/* 2 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/actions.html';
-	var html = "<div class=\"btn-group schema-form-actions {{form.htmlClass}}\">\r\n  <input ng-repeat-start=\"item in form.items\"\r\n         type=\"submit\"\r\n         class=\"btn {{ item.style || 'btn-default' }} {{form.fieldHtmlClass}}\"\r\n         value=\"{{item.title}}\"\r\n         ng-if=\"item.type === 'submit'\">\r\n  <button ng-repeat-end\r\n          class=\"btn {{ item.style || 'btn-default' }} {{form.fieldHtmlClass}}\"\r\n          type=\"button\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"item.type !== 'submit'\"\r\n          ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button>\r\n</div>\r\n";
+	var html = "<div class=\"btn-group schema-form-actions {{::form.htmlClass}}\">\r\n  <input ng-repeat-start=\"item in form.items\"\r\n         type=\"submit\"\r\n         class=\"btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}\"\r\n         value=\"{{item.title}}\"\r\n         ng-if=\"item.type === 'submit'\">\r\n  <button ng-repeat-end\r\n          class=\"btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}\"\r\n          type=\"button\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"item.type !== 'submit'\"\r\n          ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 4 */
+/* 3 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/array.html';
-	var html = "<div  class=\"schema-form-array {{form.htmlClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{form.fieldHtmlClass}}\"\r\n        schema-form-array-items\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $index\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
+	var html = "<div  class=\"schema-form-array {{::form.htmlClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $index\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 5 */
+/* 4 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/checkbox.html';
-	var html = "<div class=\"checkbox schema-form-checkbox {{form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{form.fieldHtmlClass}}\"\r\n           name=\"{{form.key.slice(-1)[0]}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{form.key.slice(-1)[0]}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 6 */
+/* 5 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/checkboxes.html';
-	var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{form.key.slice(-1)[0]}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{form.key.slice(-1)[0]}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 7 */
+/* 6 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/default.html';
-	var html = "<div class=\"form-group {{form.htmlClass}}\"\r\n     ng-class=\"{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"form.key\"\r\n         type=\"{{form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{form.placeholder}}\"\r\n         class=\"form-control {{form.fieldHtmlClass}}\"\r\n         id=\"{{form.key.slice(-1)[0]}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{form.key.slice(-1)[0]}}\"\r\n         aria-describedby=\"{{form.key.slice(-1)[0] + 'Status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"form.key\"\r\n           type=\"{{form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{form.placeholder}}\"\r\n           class=\"form-control {{form.fieldHtmlClass}}\"\r\n           id=\"{{form.key.slice(-1)[0]}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{form.key.slice(-1)[0]}}\"\r\n           aria-describedby=\"{{form.key.slice(-1)[0] + 'Status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{form.key.slice(-1)[0] + 'Status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group {{::form.htmlClass}}\"\r\n     ng-class=\"{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{form.key.slice(-1)[0]}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{form.key.slice(-1)[0]}}\"\r\n         aria-describedby=\"{{form.key.slice(-1)[0] + 'Status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{form.key.slice(-1)[0]}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{form.key.slice(-1)[0]}}\"\r\n           aria-describedby=\"{{form.key.slice(-1)[0] + 'Status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{form.key.slice(-1)[0] + 'Status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 8 */
+/* 7 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/fieldset.html';
-	var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{form.htmlClass}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
+	var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 9 */
+/* 8 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/help.html';
-	var html = "<div class=\"helpvalue schema-form-helpvalue {{form.htmlClass}}\" ng-bind-html=\"form.helpvalue\"></div>\r\n";
+	var html = "<div class=\"helpvalue schema-form-helpvalue {{::form.htmlClass}}\" ng-bind-html=\"form.helpvalue\"></div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 10 */
+/* 9 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/radio-buttons.html';
-	var html = "<div class=\"form-group schema-form-radiobuttons {{form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (item.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: item.value === $$value$$ }\"\r\n           ng-repeat=\"item in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (item.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: item.value === $$value$$ }\"\r\n           ng-repeat=\"item in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 11 */
+/* 10 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/radios-inline.html';
-	var html = "<div class=\"form-group schema-form-radios-inline {{form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"item in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"item in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 12 */
+/* 11 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/radios.html';
-	var html = "<div class=\"form-group schema-form-radios {{form.htmlClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"item in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"item in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 13 */
+/* 12 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/section.html';
-	var html = "<div class=\"schema-form-section {{form.htmlClass}}\"></div>\r\n";
+	var html = "<div class=\"schema-form-section {{::form.htmlClass}}\"></div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 14 */
+/* 13 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/select.html';
-	var html = "<div class=\"form-group {{form.htmlClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{form.labelHtmlClass}}\" ng-show=\"showTitle()\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{form.key.slice(-1)[0]}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group {{::form.htmlClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{form.key.slice(-1)[0]}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 15 */
+/* 14 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/submit.html';
-	var html = "<div class=\"form-group schema-form-submit {{form.htmlClass}}\">\r\n  <input type=\"submit\"\r\n         class=\"btn {{ form.style || 'btn-primary' }} {{form.fieldHtmlClass}}\"\r\n         value=\"{{form.title}}\"\r\n         ng-disabled=\"form.readonly\"\r\n         ng-if=\"form.type === 'submit'\">\r\n  <button class=\"btn {{ form.style || 'btn-default' }}\"\r\n          type=\"button\"\r\n          ng-click=\"buttonClick($event,form)\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"form.type !== 'submit'\">\r\n      <span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n";
+	var html = "<div class=\"form-group schema-form-submit {{::form.htmlClass}}\">\r\n  <input type=\"submit\"\r\n         class=\"btn {{ form.style || 'btn-primary' }} {{::form.fieldHtmlClass}}\"\r\n         value=\"{{form.title}}\"\r\n         ng-disabled=\"form.readonly\"\r\n         ng-if=\"form.type === 'submit'\">\r\n  <button class=\"btn {{ form.style || 'btn-default' }}\"\r\n          type=\"button\"\r\n          ng-click=\"buttonClick($event,form)\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"form.type !== 'submit'\">\r\n      <span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 16 */
+/* 15 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/tabarray.html';
-	var html = "<div ng-init=\"selected = { tab: 0 }\"\r\n     ng-model=\"modelArray\" schema-validate=\"form\"\r\n     sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{form.htmlClass}}\">\r\n  <div ng-if=\"!form.tabType || form.tabType !== 'right'\"\r\n       ng-class=\"{'col-xs-3': !form.tabType || form.tabType === 'left'}\">\r\n    <ol class=\"nav nav-tabs\"\r\n        ng-class=\"{ 'tabs-left': !form.tabType || form.tabType === 'left'}\"\r\n        sf-field-model ui-sortable=\"form.sortOptions\">\r\n      <li sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class=\"{'col-xs-9': !form.tabType || form.tabType === 'left' || form.tabType === 'right'}\">\r\n    <div class=\"tab-content {{form.fieldHtmlClass}}\">\r\n      <div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\"\r\n           sf-field-model=\"ng-repeat\"\r\n           ng-repeat=\"item in $$value$$ track by $index\"\r\n           ng-show=\"selected.tab === $index\"\r\n           ng-class=\"{active: selected.tab === $index}\">\r\n\r\n           <div schema-form-array-items></div>\r\n\r\n           <button ng-hide=\"form.readonly || form.remove === null\"\r\n                   ng-click=\"selected.tab = deleteFromArray($index).length - 1\"\r\n                   ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n                   type=\"button\"\r\n                   class=\"btn {{ form.style.remove || 'btn-default' }} pull-right\">\r\n             <i class=\"glyphicon glyphicon-trash\"></i>\r\n             {{ form.remove || 'Remove'}}\r\n           </button>\r\n      </div>\r\n      <div class=\"help-block\"\r\n           ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n           ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if=\"form.tabType === 'right'\" class=\"col-xs-3\">\r\n    <ul class=\"nav nav-tabs tabs-right\">\r\n      <li  sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n";
+	var html = "<div ng-init=\"selected = { tab: 0 }\"\r\n     ng-model=\"modelArray\" schema-validate=\"form\"\r\n     sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{::form.htmlClass}}\">\r\n  <div ng-if=\"!form.tabType || form.tabType !== 'right'\"\r\n       ng-class=\"{'col-xs-3': !form.tabType || form.tabType === 'left'}\">\r\n    <ol class=\"nav nav-tabs\"\r\n        ng-class=\"{ 'tabs-left': !form.tabType || form.tabType === 'left'}\"\r\n        sf-field-model ui-sortable=\"form.sortOptions\">\r\n      <li sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class=\"{'col-xs-9': !form.tabType || form.tabType === 'left' || form.tabType === 'right'}\">\r\n    <div class=\"tab-content {{::form.fieldHtmlClass}}\">\r\n      <div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\"\r\n           sf-field-model=\"ng-repeat\"\r\n           ng-repeat=\"item in $$value$$ track by $index\"\r\n           ng-show=\"selected.tab === $index\"\r\n           ng-class=\"{active: selected.tab === $index}\">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n\r\n           <button ng-hide=\"form.readonly || form.remove === null\"\r\n                   ng-click=\"selected.tab = deleteFromArray($index).length - 1\"\r\n                   ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n                   type=\"button\"\r\n                   class=\"btn {{ form.style.remove || 'btn-default' }} pull-right\">\r\n             <i class=\"glyphicon glyphicon-trash\"></i>\r\n             {{ form.remove || 'Remove'}}\r\n           </button>\r\n      </div>\r\n      <div class=\"help-block\"\r\n           ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n           ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if=\"form.tabType === 'right'\" class=\"col-xs-3\">\r\n    <ul class=\"nav nav-tabs tabs-right\">\r\n      <li  sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 17 */
+/* 16 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/tabs.html';
-	var html = "<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{form.htmlClass}}\">\r\n  <ul class=\"nav nav-tabs\">\r\n    <li ng-repeat=\"tab in form.tabs\"\r\n        ng-disabled=\"form.readonly\"\r\n        ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n        ng-class=\"{active: selected.tab === $index}\">\r\n        <a href=\"#\">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class=\"tab-content {{form.fieldHtmlClass}}\">\r\n  </div>\r\n</div>\r\n";
+	var html = "<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{::form.htmlClass}}\">\r\n  <ul class=\"nav nav-tabs\">\r\n    <li ng-repeat=\"tab in form.tabs\"\r\n        ng-disabled=\"form.readonly\"\r\n        ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n        ng-class=\"{active: selected.tab === $index}\">\r\n        <a href=\"#\">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class=\"tab-content {{::form.fieldHtmlClass}}\">\r\n  </div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
 /***/ },
-/* 18 */
+/* 17 */
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/textarea.html';
-	var html = "<div class=\"form-group has-feedback {{form.htmlClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{form.fieldHtmlClass}}\"\r\n            id=\"{{form.key.slice(-1)[0]}}\"\r\n            sf-changed=\"form\"\r\n            placeholder=\"{{form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{form.key.slice(-1)[0]}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{form.fieldHtmlClass}}\"\r\n              id=\"{{form.key.slice(-1)[0]}}\"\r\n              sf-changed=\"form\"\r\n              placeholder=\"{{form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{form.key.slice(-1)[0]}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
+	var html = "<div class=\"form-group has-feedback {{::form.htmlClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{form.key.slice(-1)[0]}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{form.key.slice(-1)[0]}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{form.key.slice(-1)[0]}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{form.key.slice(-1)[0]}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
-/***/ },
-/* 19 */
-/***/ function(module, exports) {
-
-	module.exports = angular;
-
-/***/ },
-/* 20 */
-/***/ function(module, exports) {
-
-	module.exports = tv4;
-
 /***/ }
 /******/ ])
 });
diff --git a/dist/angular-schema-form-bootstrap.min.js b/dist/angular-schema-form-bootstrap.min.js
index 2753399..8aa67f6 100644
--- a/dist/angular-schema-form-bootstrap.min.js
+++ b/dist/angular-schema-form-bootstrap.min.js
@@ -5,20 +5,4 @@
  * @license MIT
  * Copyright (c) 2016 JSON Schema Form
  */
-(function webpackUniversalModuleDefinition(root,factory){if(typeof exports==="object"&&typeof module==="object")module.exports=factory(require("angular"),require("tv4"));else if(typeof define==="function"&&define.amd)define(["angular","tv4"],factory);else{var a=typeof exports==="object"?factory(require("angular"),require("tv4")):factory(root["angular"],root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_19__,__WEBPACK_EXTERNAL_MODULE_20__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){__webpack_require__(1);__webpack_require__(2)},function(module,exports,__webpack_require__){/*!
-	 * angular-schema-form
-	 * @version 1.0.0-alpha.2
-	 * @link https://github.com/json-schema-form/angular-schema-form
-	 * @license MIT
-	 * Copyright (c) 2016 JSON Schema Form
-	 */
-(function webpackUniversalModuleDefinition(root,factory){if(true)module.exports=factory(__webpack_require__(19),__webpack_require__(20));else if(typeof define==="function"&&define.amd)define(["angular","tv4"],factory);else{var a=typeof exports==="object"?factory(require("angular"),require("tv4")):factory(root["angular"],root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_2__,__WEBPACK_EXTERNAL_MODULE_8__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){module.exports=__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _builder=__webpack_require__(3);var _builder2=_interopRequireDefault(_builder);var _decorators=__webpack_require__(4);var _decorators2=_interopRequireDefault(_decorators);var _schemaForm=__webpack_require__(5);var _schemaForm2=_interopRequireDefault(_schemaForm);var _jsonSchemaFormCore=__webpack_require__(6);var _validator=__webpack_require__(7);var _validator2=_interopRequireDefault(_validator);var _errors=__webpack_require__(9);var _errors2=_interopRequireDefault(_errors);var _sfPath=__webpack_require__(10);var _sfPath2=_interopRequireDefault(_sfPath);var _array=__webpack_require__(11);var _array2=_interopRequireDefault(_array);var _changed=__webpack_require__(12);var _changed2=_interopRequireDefault(_changed);var _field=__webpack_require__(13);var _field2=_interopRequireDefault(_field);var _message=__webpack_require__(14);var _message2=_interopRequireDefault(_message);var _newArray=__webpack_require__(15);var _newArray2=_interopRequireDefault(_newArray);var _schemaForm3=__webpack_require__(16);var _schemaForm4=_interopRequireDefault(_schemaForm3);var _schemaValidate=__webpack_require__(17);var _schemaValidate2=_interopRequireDefault(_schemaValidate);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}var deps=[];try{_angular2.default.module("ngSanitize");deps.push("ngSanitize")}catch(e){}try{_angular2.default.module("ui.sortable");deps.push("ui.sortable")}catch(e){}try{_angular2.default.module("angularSpectrumColorpicker");deps.push("angularSpectrumColorpicker")}catch(e){}_angular2.default.module("schemaForm",deps).provider("sfPath",_sfPath2.default).provider("sfBuilder",["sfPathProvider",_builder2.default]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",_decorators2.default]).provider("sfErrorMessage",_errors2.default).provider("schemaForm",["sfPathProvider",_schemaForm2.default]).factory("sfSelect",function(){return _jsonSchemaFormCore.select}).factory("sfValidator",_validator2.default).directive("sfArray",["sfSelect","schemaForm","sfValidator","sfPath",_array2.default]).directive("sfChanged",_changed2.default).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",_field2.default]).directive("sfMessage",["$injector","sfErrorMessage",_message2.default]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",_newArray2.default]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",_schemaForm4.default]).directive("schemaValidate",["sfValidator","$parse","sfSelect",_schemaValidate2.default])},function(module,exports){module.exports=angular},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfPathProvider){var SNAKE_CASE_REGEXP=/[A-Z]/g;var snakeCase=function snakeCase(name,separator){separator=separator||"_";return name.replace(SNAKE_CASE_REGEXP,function(letter,pos){return(pos?separator:"")+letter.toLowerCase()})};var formId=0;var builders={sfField:function sfField(args){args.fieldFrag.firstChild.setAttribute("sf-field",formId);args.lookup["f"+formId]=args.form;formId++},ngModel:function ngModel(args){if(!args.form.key){return}var key=args.form.key;if(args.state.keyRedaction){key=key.slice(args.state.keyRedaction)}var modelValue;if(!args.state.modelValue){var strKey=sfPathProvider.stringify(key).replace(/"/g,"&quot;");modelValue=args.state.modelName||"model";if(strKey){modelValue+=(strKey[0]!=="["?".":"")+strKey}}else{modelValue=args.state.modelValue}var nodes=args.fieldFrag.querySelectorAll("[sf-field-model]");for(var i=0;i<nodes.length;i++){var n=nodes[i];var conf=n.getAttribute("sf-field-model");if(!conf||conf===""){n.setAttribute("ng-model",modelValue)}else if(conf==="replaceAll"){var attributes=n.attributes;for(var j=0;j<attributes.length;j++){if(attributes[j].value&&attributes[j].value.indexOf("$$value")!==-1){attributes[j].value=attributes[j].value.replace(/\$\$value\$\$/g,modelValue)}}}else{var val=n.getAttribute(conf);if(val&&val.indexOf("$$value$$")){n.setAttribute(conf,val.replace(/\$\$value\$\$/g,modelValue))}else{n.setAttribute(conf,modelValue)}}}},simpleTransclusion:function simpleTransclusion(args){var children=args.build(args.form.items,args.path+".items",args.state);args.fieldFrag.firstChild.appendChild(children)},ngModelOptions:function ngModelOptions(args){if(args.form.ngModelOptions&&Object.keys(args.form.ngModelOptions).length>0){args.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(args.form.ngModelOptions))}},transclusion:function transclusion(args){var transclusions=args.fieldFrag.querySelectorAll("[sf-field-transclude]");if(transclusions.length){for(var i=0;i<transclusions.length;i++){var n=transclusions[i];var sub=n.getAttribute("sf-field-transclude")||"items";var items=args.form[sub];if(items){var childFrag=args.build(items,args.path+"."+sub,args.state);n.appendChild(childFrag)}}}},condition:function condition(args){if(args.form.condition){var evalExpr="evalExpr("+args.path+'.condition, { model: model, "arrayIndex": $index})';if(args.form.key){var strKey=sfPathProvider.stringify(args.form.key);evalExpr="evalExpr("+args.path+'.condition,{ model: model, "arrayIndex": $index, '+'"modelValue": model'+(strKey[0]==="["?"":".")+strKey+"})"}var children=args.fieldFrag.children||args.fieldFrag.childNodes;for(var i=0;i<children.length;i++){var child=children[i];var ngIf=child.getAttribute("ng-if");child.setAttribute("ng-if",ngIf?"("+ngIf+") || ("+evalExpr+")":evalExpr)}}},array:function array(args){var items=args.fieldFrag.querySelector("[schema-form-array-items]");if(items){var state=angular.copy(args.state);state.keyRedaction=0;state.keyRedaction+=args.form.key.length+1;if(args.form.schema&&args.form.schema.items&&args.form.schema.items.type&&args.form.schema.items.type.indexOf("object")===-1&&args.form.schema.items.type.indexOf("array")===-1){var strKey=sfPathProvider.stringify(args.form.key).replace(/"/g,"&quot;")+"[$index]";state.modelValue="modelArray[$index]"}else{state.modelName="item"}state.arrayCompatFlag=true;var childFrag=args.build(args.form.items,args.path+".items",state);items.appendChild(childFrag)}},numeric:function numeric(args){var inputFrag=args.fieldFrag.querySelector("input");var maximum=args.form.maximum||false;var exclusiveMaximum=args.form.exclusiveMaximum||false;var minimum=args.form.minimum||false;var exclusiveMinimum=args.form.exclusiveMinimum||false;var multipleOf=args.form.multipleOf||false;if(inputFrag){if(multipleOf!==false){inputFrag.setAttribute("step",multipleOf)}if(maximum!==false){if(exclusiveMaximum!==false&&multipleOf!==false){maximum=maximum-multipleOf}inputFrag.setAttribute("max",maximum)}if(minimum!==false){if(exclusiveMinimum!==false&&multipleOf!==false){minimum=minimum+multipleOf}inputFrag.setAttribute("min",minimum)}}}};this.builders=builders;var stdBuilders=[builders.sfField,builders.ngModel,builders.ngModelOptions,builders.condition];this.stdBuilders=stdBuilders;this.$get=["$templateCache","schemaFormDecorators","sfPath",function($templateCache,schemaFormDecorators,sfPath){var checkForSlot=function checkForSlot(form,slots){if(form.key){var slot=slots[sfPath.stringify(form.key)];if(slot){while(slot.firstChild){slot.removeChild(slot.firstChild)}return slot}}};var _build=function _build(items,decorator,templateFn,slots,path,state,lookup){state=state||{};lookup=lookup||Object.create(null);path=path||"schemaForm.form";var container=document.createDocumentFragment();items.reduce(function(frag,f,index){if(!f.type){return frag}var field=decorator[f.type]||decorator["default"];if(!field.replace){var n=document.createElement(snakeCase(decorator.__name,"-"));if(state.arrayCompatFlag){n.setAttribute("form","copyWithIndex($index)")}else{n.setAttribute("form",path+"["+index+"]")}(checkForSlot(f,slots)||frag).appendChild(n)}else{var tmpl;state.arrayCompatFlag=false;var div=document.createElement("div");var template=templateFn(f,field)||templateFn(f,decorator["default"]);div.innerHTML=template;tmpl=document.createDocumentFragment();while(div.childNodes.length>0){tmpl.appendChild(div.childNodes[0])}var args={fieldFrag:tmpl,form:f,lookup:lookup,state:state,path:path+"["+index+"]",build:function build(items,path,state){return _build(items,decorator,templateFn,slots,path,state,lookup)}};var builderFn=f.builder||field.builder;if(typeof builderFn==="function"){builderFn(args)}else{builderFn.forEach(function(fn){fn(args)})}(checkForSlot(f,slots)||frag).appendChild(tmpl)}return frag},container);return container};return{build:function build(form,decorator,slots,lookup){return _build(form,decorator,function(form,field){if(form.type==="template"){return form.template}return $templateCache.get(field.template)},slots,undefined,undefined,lookup)},builder:builders,stdBuilders:stdBuilders,internalBuild:_build}}]}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($compileProvider,sfPathProvider){var defaultDecorator="";var decorators={};var templateUrl=function templateUrl(name,form){if(name==="sfDecorator"){name=defaultDecorator}var decorator=decorators[name];if(decorator[form.type]){return decorator[form.type].template}return decorator["default"].template};var createDirective=function createDirective(name){$compileProvider.directive(name,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function($parse,$compile,$http,$templateCache,$interpolate,$q,sfErrorMessage,sfPath,sfSelect){return{restrict:"AE",replace:false,transclude:false,scope:true,require:"?^sfSchema",link:function link(scope,element,attrs,sfSchema){scope.$on("schemaFormPropagateNgModelController",function(event,ngModel){event.stopPropagation();event.preventDefault();scope.ngModel=ngModel});scope.showTitle=function(){return scope.form&&scope.form.notitle!==true&&scope.form.title};scope.listToCheckboxValues=function(list){var values={};_angular2.default.forEach(list,function(v){values[v]=true});return values};scope.checkboxValuesToList=function(values){var lst=[];_angular2.default.forEach(values,function(v,k){if(v){lst.push(k)}});return lst};scope.buttonClick=function($event,form){if(_angular2.default.isFunction(form.onClick)){form.onClick($event,form)}else if(_angular2.default.isString(form.onClick)){if(sfSchema){sfSchema.evalInParentScope(form.onClick,{$event:$event,form:form})}else{scope.$eval(form.onClick,{$event:$event,form:form})}}};scope.evalExpr=function(expression,locals){if(sfSchema){return sfSchema.evalInParentScope(expression,locals)}return scope.$eval(expression,locals)};scope.evalInScope=function(expression,locals){if(expression){return scope.$eval(expression,locals)}};scope.interp=function(expression,locals){return expression&&$interpolate(expression)(locals)};scope.hasSuccess=function(){if(!scope.ngModel){return false}return scope.ngModel.$valid&&(!scope.ngModel.$pristine||!scope.ngModel.$isEmpty(scope.ngModel.$modelValue))};scope.hasError=function(){if(!scope.ngModel){return false}return scope.ngModel.$invalid&&!scope.ngModel.$pristine};scope.errorMessage=function(schemaError){return sfErrorMessage.interpolate(schemaError&&schemaError.code+""||"default",scope.ngModel&&scope.ngModel.$modelValue||"",scope.ngModel&&scope.ngModel.$viewValue||"",scope.form,scope.options&&scope.options.validationMessage)};var once=scope.$watch(attrs.form,function(form){if(form){form.ngModelOptions=form.ngModelOptions||{};scope.form=form;var templatePromise;if(form.type==="template"&&form.template){templatePromise=$q.when(form.template)}else{var url=form.type==="template"?form.templateUrl:templateUrl(name,form);templatePromise=$http.get(url,{cache:$templateCache}).then(function(res){return res.data})}templatePromise.then(function(template){if(form.key){var key=form.key?sfPathProvider.stringify(form.key).replace(/"/g,"&quot;"):"";template=template.replace(/\$\$value\$\$/g,"model"+(key[0]!=="["?".":"")+key)}element.html(template);if(form.condition){var evalExpr='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';if(form.key){evalExpr='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex, "modelValue": model'+sfPath.stringify(form.key)+"})"}_angular2.default.forEach(element.children(),function(child){var ngIf=child.getAttribute("ng-if");child.setAttribute("ng-if",ngIf?"("+ngIf+") || ("+evalExpr+")":evalExpr)})}$compile(element.contents())(scope)});if(form.key){scope.$on("schemaForm.error."+form.key.join("."),function(event,error,validationMessage,validity,formName){formName=validity;if(validationMessage===true||validationMessage===false){validity=validationMessage;validationMessage=undefined}if(formName!=undefined&&scope.ngModel.$$parentForm.$name!==formName){return}if(scope.ngModel&&error){if(scope.ngModel.$setDirty){scope.ngModel.$setDirty()}else{scope.ngModel.$dirty=true;scope.ngModel.$pristine=false}if(validationMessage){if(!form.validationMessage){form.validationMessage={}}form.validationMessage[error]=validationMessage}scope.ngModel.$setValidity(error,validity===true);if(validity===true){scope.ngModel.$validate();scope.$broadcast("schemaFormValidate")}}});scope.$on("$destroy",function(){if(!scope.externalDestructionInProgress){var destroyStrategy=form.destroyStrategy||scope.options&&scope.options.destroyStrategy||"remove";if(form.key&&destroyStrategy!=="retain"){var obj=scope.model;if(form.key.length>1){obj=sfSelect(form.key.slice(0,form.key.length-1),obj)}if(obj===undefined){return}var type=form.schema&&form.schema.type||"";if(destroyStrategy==="empty"&&type.indexOf("string")!==-1){obj[form.key.slice(-1)]=""}else if(destroyStrategy==="empty"&&type.indexOf("object")!==-1){obj[form.key.slice(-1)]={}}else if(destroyStrategy==="empty"&&type.indexOf("array")!==-1){obj[form.key.slice(-1)]=[]}else if(destroyStrategy==="null"){obj[form.key.slice(-1)]=null}else{delete obj[form.key.slice(-1)]}}}})}once()}})}}}])};var createManualDirective=function createManualDirective(type,templateUrl,transclude){transclude=_angular2.default.isDefined(transclude)?transclude:false;$compileProvider.directive("sf"+_angular2.default.uppercase(type[0])+type.substr(1),function(){return{restrict:"EAC",scope:true,replace:true,transclude:transclude,template:'<sf-decorator form="form"></sf-decorator>',link:function link(scope,element,attrs){var watchThis={items:"c",titleMap:"c",schema:"c"};var form={type:type};var once=true;_angular2.default.forEach(attrs,function(value,name){if(name[0]!=="$"&&name.indexOf("ng")!==0&&name!=="sfField"){var updateForm=function updateForm(val){if(_angular2.default.isDefined(val)&&val!==form[name]){form[name]=val;if(once&&form.type&&(form.key||_angular2.default.isUndefined(attrs.key))){scope.form=form;once=false}}};if(name==="model"){scope.$watch(value,function(val){if(val&&scope.model!==val){scope.model=val}})}else if(watchThis[name]==="c"){scope.$watchCollection(value,updateForm)}else{attrs.$observe(name,updateForm)}}})}}})};this.createDecorator=function(name,templates){decorators[name]={__name:name};_angular2.default.forEach(templates,function(url,type){decorators[name][type]={template:url,replace:false,builder:[]}});if(!decorators[defaultDecorator]){defaultDecorator=name}createDirective(name)};this.defineDecorator=function(name,fields){decorators[name]={__name:name};_angular2.default.forEach(fields,function(field,type){field.builder=field.builder||[];field.replace=_angular2.default.isDefined(field.replace)?field.replace:true;decorators[name][type]=field});if(!decorators[defaultDecorator]){defaultDecorator=name}createDirective(name)};this.createDirective=createManualDirective;this.createDirectives=function(templates){_angular2.default.forEach(templates,function(url,type){createManualDirective(type,url)})};this.decorator=function(name){name=name||defaultDecorator;return decorators[name]};this.addMapping=function(name,type,url,builder,replace){if(decorators[name]){decorators[name][type]={template:url,builder:builder,replace:!!replace}}};this.defineAddOn=function(name,type,url,builder){if(decorators[name]){decorators[name][type]={template:url,builder:builder,replace:true}}};this.$get=function(){return{decorator:function decorator(name){return decorators[name]||decorators[defaultDecorator]},defaultDecorator:defaultDecorator}};createDirective("sfDecorator")};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var postProcessFn=function postProcessFn(form){return form};var defaults=_jsonSchemaFormCore.schemaDefaults.createDefaults();this.defaults=defaults;this.stdFormObj=_jsonSchemaFormCore.schemaDefaults.stdFormObj;this.defaultFormDefinition=_jsonSchemaFormCore.schemaDefaults.defaultFormDefinition;this.postProcess=function(fn){postProcessFn=fn};this.appendRule=function(type,rule){if(!defaults[type]){defaults[type]=[]}defaults[type].push(rule)};this.prependRule=function(type,rule){if(!defaults[type]){defaults[type]=[]}defaults[type].unshift(rule)};this.createStandardForm=_jsonSchemaFormCore.schemaDefaults.stdFormObj;this.$get=function(){var service={};var typeDefault=this.defaults;service.merge=function(schema,form,ignore,options,readonly,asyncTemplates){form=form||["*"];options=options||{};readonly=readonly||schema.readonly||schema.readOnly;var stdForm=_jsonSchemaFormCore.schemaDefaults.defaultForm(schema,typeDefault,ignore,options);var idx=form.indexOf("*");if(idx!==-1){form=form.slice(0,idx).concat(stdForm.form).concat(form.slice(idx+1))}var canonical=(0,_jsonSchemaFormCore.merge)(stdForm.lookup,form,options,readonly,asyncTemplates);return postProcessFn(canonical)};service.defaults=_jsonSchemaFormCore.schemaDefaults.defaultForm;service.typeDefault=typeDefault;service.traverseSchema=_jsonSchemaFormCore.traverseSchema;service.traverseForm=_jsonSchemaFormCore.traverseForm;return service}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _jsonSchemaFormCore=__webpack_require__(6);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){/*!
-		 * json-schema-form
-		 * @version 1.0.0-alpha.1
-		 * @link https://github.com/json-schema-form/json-schema-form-core
-		 * @license MIT
-		 * Copyright (c) 2016 JSON Schema Form
-		 */
-(function webpackUniversalModuleDefinition(root,factory){if(true)module.exports=factory();else if(typeof define==="function"&&define.amd)define([],factory);else{var a=factory();for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){module.exports=__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.canonicalTitleMap=exports.schemaDefaults=exports.sfPath=undefined;var _merge=__webpack_require__(2);Object.keys(_merge).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _merge[key]}})});var _select=__webpack_require__(7);Object.keys(_select).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _select[key]}})});var _traverse=__webpack_require__(8);Object.keys(_traverse).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _traverse[key]}})});var _schemaDefaults=__webpack_require__(9);var schemaDefaultsImp=_interopRequireWildcard(_schemaDefaults);var _sfPath=__webpack_require__(3);var sfPathImp=_interopRequireWildcard(_sfPath);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _interopRequireWildcard(obj){if(obj&&obj.__esModule){return obj}else{var newObj={};if(obj!=null){for(var key in obj){if(Object.prototype.hasOwnProperty.call(obj,key))newObj[key]=obj[key]}}newObj.default=obj;return newObj}}var sfPath=exports.sfPath=sfPathImp;var schemaDefaults=exports.schemaDefaults=schemaDefaultsImp;var canonicalTitleMap=exports.canonicalTitleMap=_canonicalTitleMap2.default},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.merge=merge;var _sfPath=__webpack_require__(3);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function merge(lookup,form,options,readonly,asyncTemplates){form=form||[];options=options||{};return form.map(function(obj){if(typeof obj==="string"){obj={key:obj}}if(obj.key){if(typeof obj.key==="string"){obj.key=(0,_sfPath.parse)(obj.key)}}if(obj.titleMap){obj.titleMap=(0,_canonicalTitleMap2.default)(obj.titleMap)}if(obj.key){var strid=(0,_sfPath.stringify)(obj.key);if(lookup[strid]){(function(){var schemaDefaults=lookup[strid];if(schemaDefaults){Object.keys(schemaDefaults).forEach(function(attr){if(obj[attr]===undefined){obj[attr]=schemaDefaults[attr]}})}})()}}if(readonly===true){obj.readonly=true}if(obj.items){obj.items=merge(lookup,obj.items,options,obj.readonly,asyncTemplates)}if(obj.tabs){obj.tabs.forEach(function(tab){if(tab.items){tab.items=merge(lookup,tab.items,options,obj.readonly,asyncTemplates)}})}if(obj.type==="checkbox"&&obj.schema["default"]===undefined){obj.schema["default"]=false}if(asyncTemplates&&obj.type==="template"&&!obj.template&&obj.templateUrl){asyncTemplates.push(obj)}return obj})}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _objectpath=__webpack_require__(4);Object.defineProperty(exports,"parse",{enumerable:true,get:function get(){return _objectpath.parse}});Object.defineProperty(exports,"stringify",{enumerable:true,get:function get(){return _objectpath.stringify}});Object.defineProperty(exports,"normalize",{enumerable:true,get:function get(){return _objectpath.normalize}})},function(module,exports,__webpack_require__){"use strict";module.exports=__webpack_require__(5).ObjectPath},function(module,exports,__webpack_require__){var __WEBPACK_AMD_DEFINE_RESULT__;"use strict";var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};!function(undefined){var ObjectPath={parse:function parse(str){if(typeof str!=="string"){throw new TypeError("ObjectPath.parse must be passed a string")}var i=0;var parts=[];var d,b,q,c;while(i<str.length){d=str.indexOf(".",i);b=str.indexOf("[",i);if(d===-1&&b===-1){parts.push(str.slice(i,str.length));i=str.length}else if(b===-1||d!==-1&&d<b){parts.push(str.slice(i,d));i=d+1}else{if(b>i){parts.push(str.slice(i,b));i=b}q=str.slice(b+1,b+2);if(q!=='"'&&q!=="'"){c=str.indexOf("]",b);if(c===-1)c=str.length;parts.push(str.slice(i+1,c));i=str.slice(c+1,c+2)==="."?c+2:c+1}else{c=str.indexOf(q+"]",b);if(c===-1)c=str.length;while(str.slice(c-1,c)==="\\"&&b<str.length){b++;c=str.indexOf(q+"]",b)}parts.push(str.slice(i+2,c).replace(new RegExp("\\"+q,"g"),q));i=str.slice(c+2,c+3)==="."?c+3:c+2}}}return parts},stringify:function stringify(arr,quote){if(!Array.isArray(arr))arr=[arr.toString()];quote=quote==='"'?'"':"'";return arr.map(function(n){return"["+quote+n.toString().replace(new RegExp(quote,"g"),"\\"+quote)+quote+"]"}).join("")},normalize:function normalize(data,quote){return ObjectPath.stringify(Array.isArray(data)?data:ObjectPath.parse(data),quote)},registerModule:function registerModule(angular){angular.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=ObjectPath.parse;this.stringify=ObjectPath.stringify;this.normalize=ObjectPath.normalize;this.$get=function(){return ObjectPath}})}};if(true){!(__WEBPACK_AMD_DEFINE_RESULT__=function(){return{ObjectPath:ObjectPath}}.call(exports,__webpack_require__,exports,module),__WEBPACK_AMD_DEFINE_RESULT__!==undefined&&(module.exports=__WEBPACK_AMD_DEFINE_RESULT__))}else if((typeof exports==="undefined"?"undefined":_typeof(exports))==="object"){exports.ObjectPath=ObjectPath}else{window.ObjectPath=ObjectPath}}()},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.default=function(titleMap,originalEnum){if(!Array.isArray(titleMap)){var _ret=function(){var canonical=[];if(originalEnum){originalEnum.forEach(function(value){canonical.push({name:titleMap[value],value:value})})}else{Object.keys(titleMap).forEach(function(value){canonical.push({name:titleMap[value],value:value})})}return{v:canonical}}();if((typeof _ret==="undefined"?"undefined":_typeof(_ret))==="object")return _ret.v}return titleMap}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.select=select;var _sfPath=__webpack_require__(3);var _sfPath2=_interopRequireDefault(_sfPath);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}var numRe=/^\d+$/;function select(projection,obj,valueToSet){if(!obj){obj=this}var parts=typeof projection==="string"?_sfPath2.default.parse(projection):projection;if(typeof valueToSet!=="undefined"&&parts.length===1){obj[parts[0]]=valueToSet;return obj}if(typeof valueToSet!=="undefined"&&typeof obj[parts[0]]==="undefined"){obj[parts[0]]=parts.length>2&&numRe.test(parts[1])?[]:{}}var value=obj[parts[0]];for(var i=1;i<parts.length;i++){if(parts[i]===""){return undefined}if(typeof valueToSet!=="undefined"){if(i===parts.length-1){value[parts[i]]=valueToSet;return valueToSet}else{var tmp=value[parts[i]];if(typeof tmp==="undefined"||tmp===null){tmp=numRe.test(parts[i+1])?[]:{};value[parts[i]]=tmp}value=tmp}}else if(value){value=value[parts[i]]}}return value}},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.traverseSchema=traverseSchema;exports.traverseForm=traverseForm;function traverseSchema(schema,fn,path,ignoreArrays){ignoreArrays=ignoreArrays===undefined?true:ignoreArrays;path=path||[];var traverse=function traverse(schema,fn,path){fn(schema,path);if(schema.properties){Object.keys(schema.properties).forEach(function(name){var currentPath=path.slice();currentPath.push(name);traverse(schema.properties[name],fn,currentPath)})}if(!ignoreArrays&&schema.items){var arrPath=path.slice();arrPath.push("");traverse(schema.items,fn,arrPath)}};traverse(schema,fn,path||[])}function traverseForm(form,fn){fn(form);if(form.items){form.items.forEach(function(f){traverseForm(f,fn)})}if(form.tabs){form.tabs.forEach(function(tab){if(tab.items){tab.items.forEach(function(f){traverseForm(f,fn)})}})}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.defaultFormDefinition=defaultFormDefinition;exports.stdFormObj=stdFormObj;exports.text=text;exports.number=number;exports.integer=integer;exports.checkbox=checkbox;exports.select=select;exports.checkboxes=checkboxes;exports.fieldset=fieldset;exports.array=array;exports.createDefaults=createDefaults;exports.defaultForm=defaultForm;var _sfPath=__webpack_require__(3);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}var stripNullType=function stripNullType(type){if(Array.isArray(type)&&type.length==2){if(type[0]==="null"){return type[1]}if(type[1]==="null"){return type[0]}}return type};var enumToTitleMap=function enumToTitleMap(enm){var titleMap=[];enm.forEach(function(name){titleMap.push({name:name,value:name})});return titleMap};function defaultFormDefinition(schemaTypes,name,schema,options){var rules=schemaTypes[stripNullType(schema.type)];if(rules){var def=void 0;var innerDefaultFormDefinition=function innerDefaultFormDefinition(childName,childSchema,childOptions){return defaultFormDefinition(schemaTypes,childName,childSchema,childOptions)};for(var i=0;i<rules.length;i++){def=rules[i](name,schema,options,innerDefaultFormDefinition);if(def){if(def.schema["x-schema-form"]){Object.assign(def,def.schema["x-schema-form"])}return def}}}}function stdFormObj(name,schema,options){options=options||{};var f=options.global&&options.global.formDefaults?Object.assign({},options.global.formDefaults):{};if(options.global&&options.global.supressPropertyTitles===true){f.title=schema.title}else{f.title=schema.title||name}if(schema.description){f.description=schema.description}if(options.required===true||schema.required===true){f.required=true}if(schema.maxLength){f.maxlength=schema.maxLength}if(schema.minLength){f.minlength=schema.minLength}if(schema.readOnly||schema.readonly){f.readonly=true}if(schema.minimum){f.minimum=schema.minimum+(schema.exclusiveMinimum?1:0)}if(schema.maximum){f.maximum=schema.maximum-(schema.exclusiveMaximum?1:0)}if(schema.validationMessage){f.validationMessage=schema.validationMessage}if(schema.enumNames){f.titleMap=(0,_canonicalTitleMap2.default)(schema.enumNames,schema["enum"])}f.schema=schema;f.ngModelOptions=f.ngModelOptions||{};return f}function text(name,schema,options){if(stripNullType(schema.type)==="string"&&!schema["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="text";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function number(name,schema,options){if(stripNullType(schema.type)==="number"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="number";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function integer(name,schema,options){if(stripNullType(schema.type)==="integer"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="number";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function checkbox(name,schema,options){if(stripNullType(schema.type)==="boolean"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="checkbox";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function select(name,schema,options){if(stripNullType(schema.type)==="string"&&schema["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="select";if(!f.titleMap){f.titleMap=enumToTitleMap(schema["enum"])}options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function checkboxes(name,schema,options){if(stripNullType(schema.type)==="array"&&schema.items&&schema.items["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="checkboxes";if(!f.titleMap){f.titleMap=enumToTitleMap(schema.items["enum"])}options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function fieldset(name,schema,options,defaultFormDef){if(stripNullType(schema.type)==="object"){var _ret=function(){var f=stdFormObj(name,schema,options);f.type="fieldset";f.key=options.path;f.items=[];options.lookup[(0,_sfPath.stringify)(options.path)]=f;if(schema.properties){Object.keys(schema.properties).forEach(function(key){var value=schema.properties[key];var path=options.path.slice();path.push(key);if(options.ignore[(0,_sfPath.stringify)(path)]!==true){var required=schema.required&&schema.required.indexOf(key)!==-1;var def=defaultFormDef(key,value,{path:path,required:required||false,lookup:options.lookup,ignore:options.ignore,global:options.global});if(def){f.items.push(def)}}})}return{v:f}}();if((typeof _ret==="undefined"?"undefined":_typeof(_ret))==="object")return _ret.v}}function array(name,schema,options,defaultFormDef){if(stripNullType(schema.type)==="array"){var f=stdFormObj(name,schema,options);f.type="array";f.key=options.path;options.lookup[(0,_sfPath.stringify)(options.path)]=f;var required=schema.required&&schema.required.indexOf(options.path[options.path.length-1])!==-1;var arrPath=options.path.slice();arrPath.push("");f.items=[defaultFormDef(name,schema.items,{path:arrPath,required:required||false,lookup:options.lookup,ignore:options.ignore,global:options.global})];return f}}function createDefaults(){return{string:[select,text],object:[fieldset],number:[number],integer:[integer],boolean:[checkbox],array:[checkboxes,array]}}function defaultForm(schema,defaultSchemaTypes,ignore,globalOptions){var form=[];var lookup={};ignore=ignore||{};globalOptions=globalOptions||{};defaultSchemaTypes=defaultSchemaTypes||createDefaults();if(schema.properties){Object.keys(schema.properties).forEach(function(key){if(ignore[key]!==true){var required=schema.required&&schema.required.indexOf(key)!==-1;var def=defaultFormDefinition(defaultSchemaTypes,key,schema.properties[key],{path:[key],lookup:lookup,ignore:ignore,required:required,global:globalOptions});if(def){form.push(def)}}})}else{throw new Error('Not implemented. Only type "object" allowed at root level of schema.')}return{form:form,lookup:lookup}}}])})},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var validator={};validator.validate=function(form,value){if(!form){return{valid:true}}var schema=form.schema;if(!schema){return{valid:true}}if(value===""){value=undefined}if(form.type==="number"&&value===null){value=undefined}var wrap={type:"object",properties:{}};var propName=form.key[form.key.length-1];wrap.properties[propName]=schema;if(form.required){wrap.required=[propName]}var valueWrap={};if(_angular2.default.isDefined(value)){valueWrap[propName]=value}return _tv2.default.validateResult(valueWrap,wrap)};return validator};var _tv=__webpack_require__(8);var _tv2=_interopRequireDefault(_tv);var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports){module.exports=tv4},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var defaultMessages={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};defaultMessages.number=defaultMessages[105];defaultMessages.required=defaultMessages[302];defaultMessages.min=defaultMessages[101];defaultMessages.max=defaultMessages[103];defaultMessages.maxlength=defaultMessages[201];defaultMessages.minlength=defaultMessages[200];defaultMessages.pattern=defaultMessages[202];this.setDefaultMessages=function(messages){defaultMessages=messages};this.getDefaultMessages=function(){return defaultMessages};this.setDefaultMessage=function(error,msg){defaultMessages[error]=msg};this.$get=["$interpolate",function($interpolate){var service={};service.defaultMessages=defaultMessages;service.interpolate=function(error,value,viewValue,form,global){global=global||{};var validationMessage=form.validationMessage||{};if(error.indexOf("tv4-")===0){error=error.substring(4)}var message=validationMessage["default"]||global["default"]||"";[validationMessage,global,defaultMessages].some(function(val){if(_angular2.default.isString(val)||_angular2.default.isFunction(val)){message=val;return true}if(val&&val[error]){message=val[error];return true}});var context={error:error,value:value,viewValue:viewValue,form:form,schema:form.schema,title:form.title||form.schema&&form.schema.title};if(_angular2.default.isFunction(message)){return message(context)}else{return $interpolate(message)(context)}};return service}]};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){this.parse=_jsonSchemaFormCore.sfPath.parse;this.stringify=_jsonSchemaFormCore.sfPath.stringify;this.normalize=_jsonSchemaFormCore.sfPath.normalize;this.$get=function(){return _jsonSchemaFormCore.sfPath}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _jsonSchemaFormCore=__webpack_require__(6);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfSelect,schemaForm,sfValidator,sfPath){var setIndex=function setIndex(index){return function(form){if(form.key){form.key[form.key.indexOf("")]=index}}};return{restrict:"A",scope:true,require:"?ngModel",link:function link(scope,element,attrs,ngModel){var formDefCache={};scope.validateArray=_angular2.default.noop;if(ngModel){scope.$emit("schemaFormPropagateNgModelController",ngModel)}var once=scope.$watch(attrs.sfArray,function(form){if(!form){return}var list=sfSelect(form.key,scope.model);var key=sfPath.normalize(form.key);scope.$watch("model"+(key[0]!=="["?".":"")+key,function(value){list=scope.modelArray=value});if(_angular2.default.isUndefined(list)){list=[];sfSelect(form.key,scope.model,list)}scope.modelArray=list;if(form.items){var subForm=form.items[0];if(form.items.length>1){subForm={type:"section",items:form.items.map(function(item){item.ngModelOptions=form.ngModelOptions;if(_angular2.default.isUndefined(item.readonly)){item.readonly=form.readonly}return item})}}}scope.copyWithIndex=function(index){if(!formDefCache[index]){if(subForm){var copy=_angular2.default.copy(subForm);copy.arrayIndex=index;schemaForm.traverseForm(copy,setIndex(index));formDefCache[index]=copy}}return formDefCache[index]};scope.appendToArray=function(){var len=list.length;var copy=scope.copyWithIndex(len);schemaForm.traverseForm(copy,function(part){if(part.key){var def;if(_angular2.default.isDefined(part["default"])){def=part["default"]}if(_angular2.default.isDefined(part.schema)&&_angular2.default.isDefined(part.schema["default"])){def=part.schema["default"]}if(_angular2.default.isDefined(def)){sfSelect(part.key,scope.model,def)}}});if(len===list.length){var type=sfSelect("schema.items.type",form);var dflt;if(type==="object"){dflt={}}else if(type==="array"){dflt=[]}list.push(dflt)}scope.validateArray();return list};scope.deleteFromArray=function(index){list.splice(index,1);scope.validateArray();if(ngModel&&ngModel.$setDirty){ngModel.$setDirty()}return list};if(!form.titleMap&&form.startEmpty!==true&&list.length===0){scope.appendToArray()}if(form.titleMap&&form.titleMap.length>0){scope.titleMapValues=[];var updateTitleMapValues=function updateTitleMapValues(arr){scope.titleMapValues=[];arr=arr||[];form.titleMap.forEach(function(item){scope.titleMapValues.push(arr.indexOf(item.value)!==-1)})};updateTitleMapValues(scope.modelArray);scope.$watchCollection("modelArray",updateTitleMapValues);scope.$watchCollection("titleMapValues",function(vals,old){if(vals&&vals!==old){var arr=scope.modelArray;while(arr.length>0){arr.pop()}form.titleMap.forEach(function(item,index){if(vals[index]){arr.push(item.value)}});scope.validateArray()}})}if(ngModel){var error;scope.validateArray=function(){var result=sfValidator.validate(form,scope.modelArray.length>0?scope.modelArray:undefined);Object.keys(ngModel.$error).filter(function(k){return k.indexOf("tv4-")===0}).forEach(function(k){ngModel.$setValidity(k,true)});if(result.valid===false&&result.error&&(result.error.dataPath===""||result.error.dataPath==="/"+form.key[form.key.length-1])){ngModel.$setViewValue(scope.modelArray);error=result.error;ngModel.$setValidity("tv4-"+result.error.code,false)}};scope.$on("schemaFormValidate",scope.validateArray);scope.hasSuccess=function(){if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return ngModel.$valid&&!ngModel.$pristine&&!ngModel.$isEmpty(ngModel.$modelValue)}else{return ngModel.$valid&&(!ngModel.$pristine||!ngModel.$isEmpty(ngModel.$modelValue))}};scope.hasError=function(){if(!scope.options||!scope.options.pristine||scope.options.pristine.errors!==false){return ngModel.$invalid}else{return ngModel.$invalid&&!ngModel.$pristine}};scope.schemaError=function(){return error}}once()})}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){return{require:"ngModel",restrict:"AC",scope:false,link:function link(scope,element,attrs,ctrl){var form=scope.$eval(attrs.sfChanged);if(form&&form.onChange){ctrl.$viewChangeListeners.push(function(){if(_angular2.default.isFunction(form.onChange)){form.onChange(ctrl.$modelValue,form)}else{scope.evalExpr(form.onChange,{modelValue:ctrl.$modelValue,form:form})}})}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($parse,$compile,$http,$templateCache,$interpolate,$q,sfErrorMessage,sfPath,sfSelect){return{restrict:"AE",replace:false,transclude:false,scope:true,require:"^sfSchema",link:{pre:function pre(scope,element,attrs,sfSchema){scope.$on("schemaFormPropagateNgModelController",function(event,ngModel){event.stopPropagation();event.preventDefault();scope.ngModel=ngModel});scope.form=sfSchema.lookup["f"+attrs.sfField]},post:function post(scope,element,attrs,sfSchema){scope.showTitle=function(){return scope.form&&scope.form.notitle!==true&&scope.form.title};scope.listToCheckboxValues=function(list){var values={};_angular2.default.forEach(list,function(v){values[v]=true});return values};scope.checkboxValuesToList=function(values){var lst=[];_angular2.default.forEach(values,function(v,k){if(v){lst.push(k)}});return lst};scope.buttonClick=function($event,form){if(_angular2.default.isFunction(form.onClick)){form.onClick($event,form)}else if(_angular2.default.isString(form.onClick)){if(sfSchema){sfSchema.evalInParentScope(form.onClick,{$event:$event,form:form})}else{scope.$eval(form.onClick,{$event:$event,form:form})}}};scope.evalExpr=function(expression,locals){if(sfSchema){return sfSchema.evalInParentScope(expression,locals)}return scope.$eval(expression,locals)};scope.evalInScope=function(expression,locals){if(expression){return scope.$eval(expression,locals)}};scope.interp=function(expression,locals){return expression&&$interpolate(expression)(locals)};scope.hasSuccess=function(){if(!scope.ngModel){return false}if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return scope.ngModel.$valid&&!scope.ngModel.$pristine&&!scope.ngModel.$isEmpty(scope.ngModel.$modelValue)}else{return scope.ngModel.$valid&&(!scope.ngModel.$pristine||!scope.ngModel.$isEmpty(scope.ngModel.$modelValue))}};scope.hasError=function(){if(!scope.ngModel){return false}if(!scope.options||!scope.options.pristine||scope.options.pristine.errors!==false){return scope.ngModel.$invalid}else{return scope.ngModel.$invalid&&!scope.ngModel.$pristine}};scope.errorMessage=function(schemaError){return sfErrorMessage.interpolate(schemaError&&schemaError.code+""||"default",scope.ngModel&&scope.ngModel.$modelValue||"",scope.ngModel&&scope.ngModel.$viewValue||"",scope.form,scope.options&&scope.options.validationMessage)};var form=scope.form;if(form.key){scope.$on("schemaForm.error."+form.key.join("."),function(event,error,validationMessage,validity,formName){formName=validity;if(validationMessage===true||validationMessage===false){validity=validationMessage;validationMessage=undefined}if(formName!=undefined&&scope.ngModel.$$parentForm.$name!==formName){return}if(scope.ngModel&&error){if(scope.ngModel.$setDirty){scope.ngModel.$setDirty()}else{scope.ngModel.$dirty=true;scope.ngModel.$pristine=false}if(validationMessage){if(!form.validationMessage){form.validationMessage={}}form.validationMessage[error]=validationMessage}scope.ngModel.$setValidity(error,validity===true);if(validity===true){scope.ngModel.$validate();scope.$broadcast("schemaFormValidate")}}});scope.$on("$destroy",function(){if(!scope.externalDestructionInProgress){var destroyStrategy=form.destroyStrategy||scope.options&&scope.options.destroyStrategy||"remove";if(form.key&&destroyStrategy!=="retain"){var obj=scope.model;if(form.key.length>1){obj=sfSelect(form.key.slice(0,form.key.length-1),obj)}if(obj===undefined){return}var type=form.schema&&form.schema.type||"";if(destroyStrategy==="empty"&&type.indexOf("string")!==-1){obj[form.key.slice(-1)]=""}else if(destroyStrategy==="empty"&&type.indexOf("object")!==-1){obj[form.key.slice(-1)]={}}else if(destroyStrategy==="empty"&&type.indexOf("array")!==-1){obj[form.key.slice(-1)]=[]}else if(destroyStrategy==="null"){obj[form.key.slice(-1)]=null}else{delete obj[form.key.slice(-1)]}}}})}}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($injector,sfErrorMessage){var $sanitize=$injector.has("$sanitize")?$injector.get("$sanitize"):function(html){return html};return{scope:false,restrict:"EA",link:function link(scope,element,attrs){var message="";if(attrs.sfMessage){scope.$watch(attrs.sfMessage,function(msg){if(msg){message=$sanitize(msg);update(!!scope.ngModel)}})}var currentMessage;var setMessage=function setMessage(msg){if(msg!==currentMessage){element.html(msg);currentMessage=msg}};var update=function update(checkForErrors){if(checkForErrors){if(!scope.hasError()){setMessage(message)}else{var errors=[];_angular2.default.forEach(scope.ngModel&&scope.ngModel.$error,function(status,code){if(status){errors.push(code)}});errors=errors.filter(function(e){return e!=="schemaForm"});var error=errors[0];if(error){setMessage(sfErrorMessage.interpolate(error,scope.ngModel.$modelValue,scope.ngModel.$viewValue,scope.form,scope.options&&scope.options.validationMessage))}else{setMessage(message)}}}else{setMessage(message)}};update();var once=scope.$watch("ngModel",function(ngModel){if(ngModel){ngModel.$parsers.push(function(val){update(true);return val});ngModel.$formatters.push(function(val){update(true);return val});once()}});scope.$watchCollection("ngModel.$error",function(){update(!!scope.ngModel)})}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sel,sfPath,schemaForm){return{scope:false,link:function link(scope,element,attrs){scope.min=0;scope.modelArray=scope.$eval(attrs.sfNewArray);var watchFn=function watchFn(){scope.modelArray=scope.$eval(attrs.sfNewArray);if(scope.ngModel&&scope.ngModel.$pristine&&scope.firstDigest&&(!scope.options||scope.options.validateOnRender!==true)){return}else if(scope.validateField){scope.validateField()}};var onChangeFn=function onChangeFn(){if(scope.form&&scope.form.onChange){if(_angular2.default.isFunction(scope.form.onChange)){scope.form.onChange(scope.modelArray,scope.form)}else{scope.evalExpr(scope.form.onChange,{modelValue:scope.modelArray,form:scope.form})}}};var getOrCreateModel=function getOrCreateModel(){var model=scope.modelArray;if(!model){var selection=sfPath.parse(attrs.sfNewArray);model=[];sel(selection,scope,model);scope.modelArray=model}return model};var once=scope.$watch("form",function(form){if(!form){return}if(!form.titleMap&&form.startEmpty!==true&&(!scope.modelArray||scope.modelArray.length===0)){scope.appendToArray()}if(scope.form&&scope.form.schema&&scope.form.schema.uniqueItems===true){scope.$watch(attrs.sfNewArray,watchFn,true);scope.$watch([attrs.sfNewArray,attrs.sfNewArray+".length"],onChangeFn)}else{if(scope.$watchGroup){
-scope.$watchGroup([attrs.sfNewArray,attrs.sfNewArray+".length"],function(){watchFn();onChangeFn()})}else{scope.$watch(attrs.sfNewArray,function(){watchFn();onChangeFn()});scope.$watch(attrs.sfNewArray+".length",function(){watchFn();onChangeFn()})}}if(form.titleMap&&form.titleMap.length>0){scope.titleMapValues=[];var updateTitleMapValues=function updateTitleMapValues(arr){scope.titleMapValues=[];arr=arr||[];form.titleMap.forEach(function(item){scope.titleMapValues.push(arr.indexOf(item.value)!==-1)})};updateTitleMapValues(scope.modelArray);scope.$watchCollection("modelArray",updateTitleMapValues);scope.$watchCollection("titleMapValues",function(vals,old){if(vals&&vals!==old){var arr=getOrCreateModel();form.titleMap.forEach(function(item,index){var arrIndex=arr.indexOf(item.value);if(arrIndex===-1&&vals[index])arr.push(item.value);if(arrIndex!==-1&&!vals[index])arr.splice(arrIndex,1)});if(scope.validateField){scope.validateField()}}})}once()});scope.appendToArray=function(){var empty;var model=getOrCreateModel();if(scope.form&&scope.form.schema&&scope.form.schema.items){var items=scope.form.schema.items;if(items.type&&items.type.indexOf("object")!==-1){empty={};if(!scope.options||scope.options.setSchemaDefaults!==false){empty=_angular2.default.isDefined(items["default"])?items["default"]:empty;if(empty){schemaForm.traverseSchema(items,function(prop,path){if(_angular2.default.isDefined(prop["default"])){sel(path,empty,prop["default"])}})}}}else if(items.type&&items.type.indexOf("array")!==-1){empty=[];if(!scope.options||scope.options.setSchemaDefaults!==false){empty=items["default"]||empty}}else{if(!scope.options||scope.options.setSchemaDefaults!==false){empty=items["default"]||empty}}}model.push(empty);return model};scope.deleteFromArray=function(index){var model=scope.modelArray;if(model){model.splice(index,1)}return model};var setIndex=function setIndex(index){return function(form){if(form.key){form.key[form.key.indexOf("")]=index}}};var formDefCache={};scope.copyWithIndex=function(index){var form=scope.form;if(!formDefCache[index]){var subForm=form.items[0];if(form.items.length>1){subForm={type:"section",items:form.items.map(function(item){item.ngModelOptions=form.ngModelOptions;if(_angular2.default.isUndefined(item.readonly)){item.readonly=form.readonly}return item})}}if(subForm){var copy=_angular2.default.copy(subForm);copy.arrayIndex=index;schemaForm.traverseForm(copy,setIndex(index));formDefCache[index]=copy}}return formDefCache[index]}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($compile,$http,$templateCache,$q,schemaForm,schemaFormDecorators,sfSelect,sfPath,sfBuilder){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function($scope){this.evalInParentScope=function(expr,locals){return $scope.$parent.$eval(expr,locals)};var that=this;$scope.lookup=function(lookup){if(lookup){that.lookup=lookup}return that.lookup}}],replace:false,restrict:"A",transclude:true,require:"?form",link:function link(scope,element,attrs,formCtrl,transclude){scope.formCtrl=formCtrl;var ignore={};transclude(scope,function(clone){clone.addClass("schema-form-ignore");element.prepend(clone);if(element[0].querySelectorAll){var models=element[0].querySelectorAll("[ng-model]");if(models){for(var i=0;i<models.length;i++){var key=models[i].getAttribute("ng-model");ignore[key.substring(key.indexOf(".")+1)]=true}}}});var lastDigest={};var childScope;var render=function render(schema,form){var asyncTemplates=[];var merged=schemaForm.merge(schema,form,ignore,scope.options,undefined,asyncTemplates);if(asyncTemplates.length>0){$q.all(asyncTemplates.map(function(form){return $http.get(form.templateUrl,{cache:$templateCache}).then(function(res){form.template=res.data})})).then(function(){internalRender(schema,form,merged)})}else{internalRender(schema,form,merged)}};var internalRender=function internalRender(schema,form,merged){if(childScope){scope.externalDestructionInProgress=true;childScope.$destroy();scope.externalDestructionInProgress=false}childScope=scope.$new();childScope.schemaForm={form:merged,schema:schema};element.children(":not(.schema-form-ignore)").remove();var slots={};var slotsFound=element[0].querySelectorAll("*[sf-insert-field]");for(var i=0;i<slotsFound.length;i++){slots[slotsFound[i].getAttribute("sf-insert-field")]=slotsFound[i]}var decorator=schemaFormDecorators.decorator(attrs.sfUseDecorator);var lookup=Object.create(null);scope.lookup(lookup);element[0].appendChild(sfBuilder.build(merged,decorator,slots,lookup));childScope.firstDigest=true;setTimeout(function(){childScope.firstDigest=false},0);$compile(element.children())(childScope);if(!scope.options||scope.options.setSchemaDefaults!==false){schemaForm.traverseSchema(schema,function(prop,path){if(_angular2.default.isDefined(prop["default"])){var val=sfSelect(path,scope.model);if(_angular2.default.isUndefined(val)){sfSelect(path,scope.model,prop["default"])}}})}scope.$emit("sf-render-finished",element)};var defaultForm=["*"];scope.$watch(function(){var schema=scope.schema;var form=scope.initialForm||defaultForm;if(form&&schema&&schema.type&&(lastDigest.form!==form||lastDigest.schema!==schema)&&Object.keys(schema.properties).length>0){lastDigest.schema=schema;lastDigest.form=form;render(schema,form)}});scope.$on("schemaFormRedraw",function(){var schema=scope.schema;var form=scope.initialForm?_angular2.default.copy(scope.initialForm):["*"];if(schema){render(schema,form)}});scope.$on("$destroy",function(){scope.externalDestructionInProgress=true});scope.evalExpr=function(expression,locals){return scope.$parent.$eval(expression,locals)}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfValidator,$parse,sfSelect){return{restrict:"A",scope:false,priority:500,require:"ngModel",link:function link(scope,element,attrs,ngModel){scope.$emit("schemaFormPropagateNgModelController",ngModel);var error=null;var form=scope.$eval(attrs.schemaValidate);if(form.copyValueTo){ngModel.$viewChangeListeners.push(function(){var paths=form.copyValueTo;_angular2.default.forEach(paths,function(path){sfSelect(path,scope.model,ngModel.$modelValue)})})}var validate=function validate(viewValue){if(!form){return viewValue}if(scope.options&&scope.options.tv4Validation===false){return viewValue}var result=sfValidator.validate(form,viewValue);Object.keys(ngModel.$error).filter(function(k){return k.indexOf("tv4-")===0}).forEach(function(k){ngModel.$setValidity(k,true)});if(!result.valid){ngModel.$setValidity("tv4-"+result.error.code,false);error=result.error;if(ngModel.$validators){return viewValue}return undefined}return viewValue};if(typeof form.ngModel==="function"){form.ngModel(ngModel)}["$parsers","$viewChangeListeners","$formatters"].forEach(function(attr){if(form[attr]&&ngModel[attr]){form[attr].forEach(function(fn){ngModel[attr].push(fn)})}});["$validators","$asyncValidators"].forEach(function(attr){if(form[attr]&&ngModel[attr]){_angular2.default.forEach(form[attr],function(fn,name){ngModel[attr][name]=fn})}});ngModel.$parsers.push(validate);if(ngModel.$validators){ngModel.$validators.schemaForm=function(){return!Object.keys(ngModel.$error).some(function(e){return e!=="schemaForm"})}}var schema=form.schema;scope.validateField=function(formName){if(formName!=undefined&&ngModel.$$parentForm.$name!==formName){return}if(schema&&schema.type.indexOf("array")!==-1){validate(ngModel.$modelValue)}if(ngModel.$setDirty){ngModel.$setDirty();ngModel.$setViewValue(ngModel.$viewValue);ngModel.$commitViewValue();if(form.type==="checkbox"){if(form.required&&ngModel.$modelValue===undefined){ngModel.$setValidity("tv4-302",false)}}else if(form.required&&ngModel.$isEmpty(ngModel.$modelValue)){ngModel.$setValidity("tv4-302",false)}}else{ngModel.$setViewValue(ngModel.$viewValue)}};var first=true;ngModel.$formatters.push(function(val){if(ngModel.$pristine&&first&&(!scope.options||scope.options.validateOnRender!==true)){first=false;return val}validate(ngModel.$modelValue);return val});scope.$on("schemaFormValidate",function(event,formName){scope.validateField(formName)});scope.schemaError=function(){return error}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}}])})},function(module,exports,__webpack_require__){var textareaTemplate=__webpack_require__(18);var fieldsetTemplate=__webpack_require__(8);var arrayTemplate=__webpack_require__(4);var tabarrayTemplate=__webpack_require__(16);var tabsTemplate=__webpack_require__(17);var sectionTemplate=__webpack_require__(13);var actionsTemplate=__webpack_require__(3);var selectTemplate=__webpack_require__(14);var checkboxTemplate=__webpack_require__(5);var checkboxesTemplate=__webpack_require__(6);var submitTemplate=__webpack_require__(15);var radiosTemplate=__webpack_require__(12);var radiosInlineTemplate=__webpack_require__(11);var radiobuttonsTemplate=__webpack_require__(10);var helpTemplate=__webpack_require__(9);var defaultTemplate=__webpack_require__(7);angular.module("schemaForm").config(bootstrapDecoratorConfig).filter("sfCamelKey",sfCamelKeyFilter);bootstrapDecoratorConfig.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"];function bootstrapDecoratorConfig(schemaFormProvider,decoratorsProvider,sfBuilderProvider,sfPathProvider,$injector){var base="decorators/bootstrap/";var simpleTransclusion=sfBuilderProvider.builders.simpleTransclusion;var ngModelOptions=sfBuilderProvider.builders.ngModelOptions;var ngModel=sfBuilderProvider.builders.ngModel;var sfField=sfBuilderProvider.builders.sfField;var condition=sfBuilderProvider.builders.condition;var array=sfBuilderProvider.builders.array;var numeric=sfBuilderProvider.builders.numeric;var tabs=function(args){if(args.form.tabs&&args.form.tabs.length>0){var tabLi=args.fieldFrag.querySelector("li");tabLi.setAttribute("ng-if","!tab.condition ? true : evalExpr(tab.condition, { model: model, arrayIndex: $index })");var tabContent=args.fieldFrag.querySelector(".tab-content");args.form.tabs.forEach(function(tab,index){var evalExpr="(evalExpr("+args.path+".tabs["+index+"]"+'.condition, { model: model, "arrayIndex": $index}))';var div=document.createElement("div");div.className="tab-pane";div.setAttribute("ng-disabled","form.readonly");div.setAttribute("ng-show","selected.tab === "+index);div.setAttribute("ng-class","{active: selected.tab === "+index+"}");if(!!tab.condition){div.setAttribute("ng-if",evalExpr)}var childFrag=args.build(tab.items,args.path+".tabs["+index+"].items",args.state);div.appendChild(childFrag);tabContent.appendChild(div)})}};var selectPlaceholder=function(args){if(args.form.placeholder){var selectBox=args.fieldFrag.querySelector("select");var option=document.createElement("option");option.setAttribute("value","");option.setAttribute("sf-field-model","replaceAll");if(angular.version.major===1&&angular.version.minor<4){option.setAttribute("ng-if","$$value$$ === undefined")}else{option.setAttribute("ng-show","$$value$$ === undefined")}option.textContent=args.form.placeholder;selectBox.appendChild(option)}};var defaults=[sfField,ngModel,ngModelOptions,condition];decoratorsProvider.defineDecorator("bootstrapDecorator",{textarea:{template:textareaTemplate,builder:defaults},fieldset:{template:fieldsetTemplate,builder:[sfField,simpleTransclusion,condition]},array:{template:arrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},tabarray:{template:tabarrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},tabs:{template:tabsTemplate,builder:[sfField,ngModelOptions,tabs,condition]},section:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},conditional:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},actions:{template:actionsTemplate,builder:defaults},select:{template:selectTemplate,builder:defaults.concat(selectPlaceholder)},checkbox:{template:checkboxTemplate,builder:defaults},checkboxes:{template:checkboxesTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},number:{template:defaultTemplate,builder:defaults.concat(numeric)},password:{template:defaultTemplate,builder:defaults},submit:{template:submitTemplate,builder:defaults},button:{template:submitTemplate,builder:defaults},radios:{template:radiosTemplate,builder:defaults},"radios-inline":{template:radiosInlineTemplate,builder:defaults},radiobuttons:{template:radiobuttonsTemplate,builder:defaults},help:{template:helpTemplate,builder:defaults},default:{template:defaultTemplate,builder:defaults}},[])}function sfCamelKeyFilter(){return function(formKey){if(!formKey){return""}var part,i,key;key=formKey.slice();for(i=0;i<key.length;i++){part=key[i].toLowerCase().split("");if(i&&part.length){part[0]=part[0].toUpperCase()}key[i]=part.join("")}return key.join("")}}},function(module,exports){var path="bootstrap/actions.html";var html='<div class="btn-group schema-form-actions {{form.htmlClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/array.html";var html='<div  class="schema-form-array {{form.htmlClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{form.fieldHtmlClass}}"\r\n        schema-form-array-items\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkbox.html";var html='<div class="checkbox schema-form-checkbox {{form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{form.fieldHtmlClass}}"\r\n           name="{{form.key.slice(-1)[0]}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkboxes.html";var html='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{form.key.slice(-1)[0]}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/default.html";var html='<div class="form-group {{form.htmlClass}}"\r\n     ng-class="{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="form.key"\r\n         type="{{form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{form.placeholder}}"\r\n         class="form-control {{form.fieldHtmlClass}}"\r\n         id="{{form.key.slice(-1)[0]}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{form.key.slice(-1)[0]}}"\r\n         aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="form.key"\r\n           type="{{form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{form.placeholder}}"\r\n           class="form-control {{form.fieldHtmlClass}}"\r\n           id="{{form.key.slice(-1)[0]}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{form.key.slice(-1)[0]}}"\r\n           aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{form.key.slice(-1)[0] + \'Status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/fieldset.html";var html='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{form.htmlClass}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/help.html";var html='<div class="helpvalue schema-form-helpvalue {{form.htmlClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radio-buttons.html";var html='<div class="form-group schema-form-radiobuttons {{form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: item.value === $$value$$ }"\r\n           ng-repeat="item in form.titleMap">\r\n      <input type="radio"\r\n             class="{{form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios-inline.html";var html='<div class="form-group schema-form-radios-inline {{form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="item in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios.html";var html='<div class="form-group schema-form-radios {{form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="item in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/section.html";var html='<div class="schema-form-section {{form.htmlClass}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/select.html";var html='<div class="form-group {{form.htmlClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{form.labelHtmlClass}}" ng-show="showTitle()">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{form.key.slice(-1)[0]}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/submit.html";var html='<div class="form-group schema-form-submit {{form.htmlClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabarray.html";var html='\r\n<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{form.htmlClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabs.html";var html='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{form.htmlClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/textarea.html";var html='<div class="form-group has-feedback {{form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{form.fieldHtmlClass}}"\r\n            id="{{form.key.slice(-1)[0]}}"\r\n            sf-changed="form"\r\n            placeholder="{{form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{form.key.slice(-1)[0]}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{form.fieldHtmlClass}}"\r\n              id="{{form.key.slice(-1)[0]}}"\r\n              sf-changed="form"\r\n              placeholder="{{form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{form.key.slice(-1)[0]}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';
-window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){module.exports=angular},function(module,exports){module.exports=tv4}])});
\ No newline at end of file
+(function webpackUniversalModuleDefinition(root,factory){if(typeof exports==="object"&&typeof module==="object")module.exports=factory();else if(typeof define==="function"&&define.amd)define([],factory);else{var a=factory();for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){"use strict";__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var textareaTemplate=__webpack_require__(17);var fieldsetTemplate=__webpack_require__(7);var arrayTemplate=__webpack_require__(3);var tabarrayTemplate=__webpack_require__(15);var tabsTemplate=__webpack_require__(16);var sectionTemplate=__webpack_require__(12);var actionsTemplate=__webpack_require__(2);var selectTemplate=__webpack_require__(13);var checkboxTemplate=__webpack_require__(4);var checkboxesTemplate=__webpack_require__(5);var submitTemplate=__webpack_require__(14);var radiosTemplate=__webpack_require__(11);var radiosInlineTemplate=__webpack_require__(10);var radiobuttonsTemplate=__webpack_require__(9);var helpTemplate=__webpack_require__(8);var defaultTemplate=__webpack_require__(6);angular.module("schemaForm").config(bootstrapDecoratorConfig).filter("sfCamelKey",sfCamelKeyFilter);bootstrapDecoratorConfig.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"];function bootstrapDecoratorConfig(schemaFormProvider,decoratorsProvider,sfBuilderProvider,sfPathProvider,$injector){var base="decorators/bootstrap/";var simpleTransclusion=sfBuilderProvider.builders.simpleTransclusion;var ngModelOptions=sfBuilderProvider.builders.ngModelOptions;var ngModel=sfBuilderProvider.builders.ngModel;var sfField=sfBuilderProvider.builders.sfField;var condition=sfBuilderProvider.builders.condition;var array=sfBuilderProvider.builders.array;var numeric=sfBuilderProvider.builders.numeric;var tabs=function tabs(args){if(args.form.tabs&&args.form.tabs.length>0){var tabContent=args.fieldFrag.querySelector(".tab-content");args.form.tabs.forEach(function(tab,index){var evalExpr="(evalExpr("+args.path+".tabs["+index+"]"+'.condition, { model: model, "arrayIndex": $index}))';var div=document.createElement("div");div.className="tab-pane";div.setAttribute("ng-disabled","form.readonly");div.setAttribute("ng-show","selected.tab === "+index);div.setAttribute("ng-class","{active: selected.tab === "+index+"}");if(!!tab.condition){div.setAttribute("ng-if",evalExpr)}var childFrag=args.build(tab.items,args.path+".tabs["+index+"].items",args.state);div.appendChild(childFrag);tabContent.appendChild(div)})}};var selectPlaceholder=function selectPlaceholder(args){if(args.form.placeholder){var selectBox=args.fieldFrag.querySelector("select");var option=document.createElement("option");option.setAttribute("value","");option.setAttribute("sf-field-model","replaceAll");if(angular.version.major===1&&angular.version.minor<4){option.setAttribute("ng-if","$$value$$ === undefined")}else{option.setAttribute("ng-show","$$value$$ === undefined")}option.textContent=args.form.placeholder;selectBox.appendChild(option)}};var defaults=[sfField,ngModel,ngModelOptions,condition];decoratorsProvider.defineDecorator("bootstrapDecorator",{actions:{template:actionsTemplate,builder:defaults},array:{template:arrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},button:{template:submitTemplate,builder:defaults},checkbox:{template:checkboxTemplate,builder:defaults},checkboxes:{template:checkboxesTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},conditional:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},"default":{template:defaultTemplate,builder:defaults},fieldset:{template:fieldsetTemplate,builder:[sfField,simpleTransclusion,condition]},help:{template:helpTemplate,builder:defaults},number:{template:defaultTemplate,builder:defaults.concat(numeric)},password:{template:defaultTemplate,builder:defaults},radios:{template:radiosTemplate,builder:defaults},"radios-inline":{template:radiosInlineTemplate,builder:defaults},radiobuttons:{template:radiobuttonsTemplate,builder:defaults},section:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},select:{template:selectTemplate,builder:defaults.concat(selectPlaceholder)},submit:{template:submitTemplate,builder:defaults},tabarray:{template:tabarrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},tabs:{template:tabsTemplate,builder:[sfField,ngModelOptions,tabs,condition]},textarea:{template:textareaTemplate,builder:defaults}},[])}function sfCamelKeyFilter(){return function(formKey){if(!formKey){return""}var part,i,key;key=formKey.slice();for(i=0;i<key.length;i++){part=key[i].toLowerCase().split("");if(i&&part.length){part[0]=part[0].toUpperCase()}key[i]=part.join("")}return key.join("")}}},function(module,exports){var path="bootstrap/actions.html";var html='<div class="btn-group schema-form-actions {{::form.htmlClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/array.html";var html='<div  class="schema-form-array {{::form.htmlClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkbox.html";var html='<div class="checkbox schema-form-checkbox {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{form.key.slice(-1)[0]}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkboxes.html";var html='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{form.key.slice(-1)[0]}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/default.html";var html='<div class="form-group {{::form.htmlClass}}"\r\n     ng-class="{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{form.key.slice(-1)[0]}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{form.key.slice(-1)[0]}}"\r\n         aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{form.key.slice(-1)[0]}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{form.key.slice(-1)[0]}}"\r\n           aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{form.key.slice(-1)[0] + \'Status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/fieldset.html";var html='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/help.html";var html='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radio-buttons.html";var html='<div class="form-group schema-form-radiobuttons {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: item.value === $$value$$ }"\r\n           ng-repeat="item in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios-inline.html";var html='<div class="form-group schema-form-radios-inline {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="item in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios.html";var html='<div class="form-group schema-form-radios {{::form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="item in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/section.html";var html='<div class="schema-form-section {{::form.htmlClass}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/select.html";var html='<div class="form-group {{::form.htmlClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{form.key.slice(-1)[0]}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/submit.html";var html='<div class="form-group schema-form-submit {{::form.htmlClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabarray.html";var html='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabs.html";var html='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/textarea.html";var html='<div class="form-group has-feedback {{::form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{form.key.slice(-1)[0]}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{form.key.slice(-1)[0]}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{form.key.slice(-1)[0]}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{form.key.slice(-1)[0]}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path}])});
\ No newline at end of file
diff --git a/package.json b/package.json
index bb4a338..1df3032 100644
--- a/package.json
+++ b/package.json
@@ -7,7 +7,7 @@
     "dist": "npm run build && npm run minify",
     "build": "webpack",
     "watch": "webpack --watch",
-    "minify": "uglifyjs dist/angular-schema-form-bootstrap.js --comments --output=dist/angular-schema-form-bootstrap.min.js",
+    "minify": "uglifyjs dist/angular-schema-form-bootstrap.js --comments --output=dist/angular-schema-form-bootstrap.min.js && uglifyjs dist/angular-schema-form-bootstrap-bundled.js --comments --output=dist/angular-schema-form-bootstrap-bundled.min.js",
     "test": "echo \"Error: no test specified\" && exit 1",
     "test-not-yet-done": "karma start --single-run --browsers PhantomJS karma.conf.js --log-level info"
   },
@@ -28,9 +28,10 @@
     "tv4": "~1.0.15"
   },
   "devDependencies": {
-    "babel-core": "^6.10.4",
+    "babel": "^6.5.2",
+    "babel-core": "^6.17.0",
     "babel-loader": "^6.2.5",
-    "babel-polyfill": "^6.9.1",
+    "babel-polyfill": "^6.16.0",
     "babel-preset-es2015": "^6.16.0",
     "chai": "^3.5.0",
     "coveralls": "^2.11.0",
diff --git a/src/bootstrap-decorator.js b/src/bootstrap-decorator.js
index 432631d..c9f49ad 100644
--- a/src/bootstrap-decorator.js
+++ b/src/bootstrap-decorator.js
@@ -96,7 +96,7 @@ function bootstrapDecoratorConfig(
     checkbox: {template: checkboxTemplate, builder: defaults},
     checkboxes: {template: checkboxesTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition]},
     conditional: {template: sectionTemplate, builder: [sfField, simpleTransclusion, condition]},
-    'default': {template: defaultTemplate, builder: defaults}
+    'default': {template: defaultTemplate, builder: defaults},
     fieldset: {template: fieldsetTemplate, builder: [sfField, simpleTransclusion, condition]},
     help: {template: helpTemplate, builder: defaults},
     number: {template: defaultTemplate, builder: defaults.concat(numeric)},
diff --git a/src/module-bundled.js b/src/module-bundled.js
new file mode 100644
index 0000000..3f82b33
--- /dev/null
+++ b/src/module-bundled.js
@@ -0,0 +1,2 @@
+require('../node_modules/angular-schema-form/dist/schema-form.js');
+require('bootstrap-decorator.js');
diff --git a/src/module.js b/src/module.js
index 3f82b33..bf1b1bd 100644
--- a/src/module.js
+++ b/src/module.js
@@ -1,2 +1 @@
-require('../node_modules/angular-schema-form/dist/schema-form.js');
 require('bootstrap-decorator.js');
diff --git a/webpack.config.js b/webpack.config.js
index a3d3b98..3d3cb12 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -3,26 +3,20 @@
 //const ExtractTextPlugin = require('extract-text-webpack-plugin');
 const webpack = require('webpack');
 const path = require('path');
-const HtmlWebpackPlugin = require('html-webpack-plugin');
+//const HtmlWebpackPlugin = require('html-webpack-plugin');
 const getPath = (pathToFile) => path.resolve(__dirname, pathToFile);
 const pjson = require('./package.json');
 console.log('Angular Schema Form Bootstrap v' + pjson.version);
 
 module.exports = {
-  entry: './src/module.js',
-  // entry: {
-  //   schema_form_decorators: [
-  //     getPath('./src/bootstrap-decorator.js'),
-  //   ]
-  //   // ,
-  //   // app: [
-  //   //   getPath('./src/app.js'),
-  //   //   getPath('./src/config/dev.config.js')
-  //   // ]
-  // },
+  // entry: './src/module.js',
+  entry: {
+    'angular-schema-form-bootstrap': getPath('./src/module.js'),
+    'angular-schema-form-bootstrap-bundled': getPath('./src/module-bundled.js'),
+  },
   output: {
     path: getPath('./dist'),
-    filename: 'angular-schema-form-bootstrap.js',
+    filename: '[name].js',
     sourceMapFilename: '[name].map',
     libraryTarget: 'umd'
   },

From 98e28f7a770f806652930aa45b28a9647cbe51ba Mon Sep 17 00:00:00 2001
From: mbennett <marcel@iamserious.com>
Date: Wed, 19 Oct 2016 18:02:27 +1100
Subject: [PATCH 28/50] Part of previous commit

---
 dist/angular-schema-form-bootstrap-bundled.js | 4222 +++++++++++++++++
 1 file changed, 4222 insertions(+)
 create mode 100644 dist/angular-schema-form-bootstrap-bundled.js

diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
new file mode 100644
index 0000000..b7068be
--- /dev/null
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -0,0 +1,4222 @@
+/*!
+ * angular-schema-form-bootstrap
+ * @version 1.0.0-alpha.1
+ * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
+ * @license MIT
+ * Copyright (c) 2016 JSON Schema Form
+ */
+(function webpackUniversalModuleDefinition(root, factory) {
+	if(typeof exports === 'object' && typeof module === 'object')
+		module.exports = factory(require("angular"), require("tv4"));
+	else if(typeof define === 'function' && define.amd)
+		define(["angular", "tv4"], factory);
+	else {
+		var a = typeof exports === 'object' ? factory(require("angular"), require("tv4")) : factory(root["angular"], root["tv4"]);
+		for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
+	}
+})(this, function(__WEBPACK_EXTERNAL_MODULE_19__, __WEBPACK_EXTERNAL_MODULE_20__) {
+return /******/ (function(modules) { // webpackBootstrap
+/******/ 	// The module cache
+/******/ 	var installedModules = {};
+
+/******/ 	// The require function
+/******/ 	function __webpack_require__(moduleId) {
+
+/******/ 		// Check if module is in cache
+/******/ 		if(installedModules[moduleId])
+/******/ 			return installedModules[moduleId].exports;
+
+/******/ 		// Create a new module (and put it into the cache)
+/******/ 		var module = installedModules[moduleId] = {
+/******/ 			exports: {},
+/******/ 			id: moduleId,
+/******/ 			loaded: false
+/******/ 		};
+
+/******/ 		// Execute the module function
+/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
+
+/******/ 		// Flag the module as loaded
+/******/ 		module.loaded = true;
+
+/******/ 		// Return the exports of the module
+/******/ 		return module.exports;
+/******/ 	}
+
+
+/******/ 	// expose the modules object (__webpack_modules__)
+/******/ 	__webpack_require__.m = modules;
+
+/******/ 	// expose the module cache
+/******/ 	__webpack_require__.c = installedModules;
+
+/******/ 	// __webpack_public_path__
+/******/ 	__webpack_require__.p = "";
+
+/******/ 	// Load entry module and return exports
+/******/ 	return __webpack_require__(0);
+/******/ })
+/************************************************************************/
+/******/ ([
+/* 0 */
+/***/ function(module, exports, __webpack_require__) {
+
+	'use strict';
+
+	__webpack_require__(18);
+	__webpack_require__(1);
+
+/***/ },
+/* 1 */
+/***/ function(module, exports, __webpack_require__) {
+
+	'use strict';
+
+	// angular-templatecache-loader
+	var textareaTemplate = __webpack_require__(17);
+	var fieldsetTemplate = __webpack_require__(7);
+	var arrayTemplate = __webpack_require__(3);
+	var tabarrayTemplate = __webpack_require__(15);
+	var tabsTemplate = __webpack_require__(16);
+	var sectionTemplate = __webpack_require__(12);
+	var actionsTemplate = __webpack_require__(2);
+	var selectTemplate = __webpack_require__(13);
+	var checkboxTemplate = __webpack_require__(4);
+	var checkboxesTemplate = __webpack_require__(5);
+	var submitTemplate = __webpack_require__(14);
+	var radiosTemplate = __webpack_require__(11);
+	var radiosInlineTemplate = __webpack_require__(10);
+	var radiobuttonsTemplate = __webpack_require__(9);
+	var helpTemplate = __webpack_require__(8);
+	var defaultTemplate = __webpack_require__(6);
+
+	angular.module('schemaForm').config(bootstrapDecoratorConfig).filter('sfCamelKey', sfCamelKeyFilter);
+
+	bootstrapDecoratorConfig.$inject = ['schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'];
+
+	function bootstrapDecoratorConfig(schemaFormProvider, decoratorsProvider, sfBuilderProvider, sfPathProvider, $injector) {
+	  var base = 'decorators/bootstrap/';
+
+	  var simpleTransclusion = sfBuilderProvider.builders.simpleTransclusion;
+	  var ngModelOptions = sfBuilderProvider.builders.ngModelOptions;
+	  var ngModel = sfBuilderProvider.builders.ngModel;
+	  var sfField = sfBuilderProvider.builders.sfField;
+	  var condition = sfBuilderProvider.builders.condition;
+	  var array = sfBuilderProvider.builders.array;
+	  var numeric = sfBuilderProvider.builders.numeric;
+
+	  // Tabs is so bootstrap specific that it stays here.
+	  var tabs = function tabs(args) {
+	    if (args.form.tabs && args.form.tabs.length > 0) {
+	      var tabContent = args.fieldFrag.querySelector('.tab-content');
+
+	      args.form.tabs.forEach(function (tab, index) {
+	        var evalExpr = '(evalExpr(' + args.path + '.tabs[' + index + ']' + '.condition, { model: model, "arrayIndex": $index}))';
+	        var div = document.createElement('div');
+	        div.className = 'tab-pane';
+	        div.setAttribute('ng-disabled', 'form.readonly');
+	        div.setAttribute('ng-show', 'selected.tab === ' + index);
+	        div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
+	        if (!!tab.condition) {
+	          div.setAttribute('ng-if', evalExpr);
+	        };
+
+	        var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
+	        div.appendChild(childFrag);
+	        tabContent.appendChild(div);
+	      });
+	    }
+	  };
+
+	  var selectPlaceholder = function selectPlaceholder(args) {
+	    if (args.form.placeholder) {
+	      var selectBox = args.fieldFrag.querySelector('select');
+	      var option = document.createElement('option');
+	      option.setAttribute('value', '');
+
+	      /* We only want the placeholder to show when we do not have a value on the model.
+	       * We make ngModel builder replace all so we can use $$value$$.
+	       */
+	      option.setAttribute('sf-field-model', 'replaceAll');
+
+	      /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
+	       * angular > 1.4 does a emptyOption.attr('selected', true)
+	       * which does not like the ng-if comment.
+	       */
+	      if (angular.version.major === 1 && angular.version.minor < 4) {
+	        option.setAttribute('ng-if', '$$value$$ === undefined');
+	      } else {
+	        option.setAttribute('ng-show', '$$value$$ === undefined');
+	      }
+
+	      option.textContent = args.form.placeholder;
+
+	      selectBox.appendChild(option);
+	    }
+	  };
+
+	  var defaults = [sfField, ngModel, ngModelOptions, condition];
+	  decoratorsProvider.defineDecorator('bootstrapDecorator', {
+	    actions: { template: actionsTemplate, builder: defaults },
+	    array: { template: arrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
+	    button: { template: submitTemplate, builder: defaults },
+	    checkbox: { template: checkboxTemplate, builder: defaults },
+	    checkboxes: { template: checkboxesTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
+	    conditional: { template: sectionTemplate, builder: [sfField, simpleTransclusion, condition] },
+	    'default': { template: defaultTemplate, builder: defaults },
+	    fieldset: { template: fieldsetTemplate, builder: [sfField, simpleTransclusion, condition] },
+	    help: { template: helpTemplate, builder: defaults },
+	    number: { template: defaultTemplate, builder: defaults.concat(numeric) },
+	    password: { template: defaultTemplate, builder: defaults },
+	    radios: { template: radiosTemplate, builder: defaults },
+	    'radios-inline': { template: radiosInlineTemplate, builder: defaults },
+	    radiobuttons: { template: radiobuttonsTemplate, builder: defaults },
+	    section: { template: sectionTemplate, builder: [sfField, simpleTransclusion, condition] },
+	    select: { template: selectTemplate, builder: defaults.concat(selectPlaceholder) },
+	    submit: { template: submitTemplate, builder: defaults },
+	    tabarray: { template: tabarrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
+	    tabs: { template: tabsTemplate, builder: [sfField, ngModelOptions, tabs, condition] },
+	    textarea: { template: textareaTemplate, builder: defaults }
+	  }, []);
+	};
+
+	/**
+	 * sfCamelKey Filter
+	 */
+	function sfCamelKeyFilter() {
+	  return function (formKey) {
+	    if (!formKey) {
+	      return '';
+	    };
+	    var part, i, key;
+	    key = formKey.slice();
+	    for (i = 0; i < key.length; i++) {
+	      part = key[i].toLowerCase().split('');
+	      if (i && part.length) {
+	        part[0] = part[0].toUpperCase();
+	      };
+	      key[i] = part.join('');
+	    };
+	    return key.join('');
+	  };
+	};
+
+/***/ },
+/* 2 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/actions.html';
+	var html = "<div class=\"btn-group schema-form-actions {{::form.htmlClass}}\">\r\n  <input ng-repeat-start=\"item in form.items\"\r\n         type=\"submit\"\r\n         class=\"btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}\"\r\n         value=\"{{item.title}}\"\r\n         ng-if=\"item.type === 'submit'\">\r\n  <button ng-repeat-end\r\n          class=\"btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}\"\r\n          type=\"button\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"item.type !== 'submit'\"\r\n          ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 3 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/array.html';
+	var html = "<div  class=\"schema-form-array {{::form.htmlClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $index\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 4 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/checkbox.html';
+	var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{form.key.slice(-1)[0]}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 5 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/checkboxes.html';
+	var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{form.key.slice(-1)[0]}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 6 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/default.html';
+	var html = "<div class=\"form-group {{::form.htmlClass}}\"\r\n     ng-class=\"{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{form.key.slice(-1)[0]}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{form.key.slice(-1)[0]}}\"\r\n         aria-describedby=\"{{form.key.slice(-1)[0] + 'Status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{form.key.slice(-1)[0]}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{form.key.slice(-1)[0]}}\"\r\n           aria-describedby=\"{{form.key.slice(-1)[0] + 'Status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{form.key.slice(-1)[0] + 'Status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 7 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/fieldset.html';
+	var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 8 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/help.html';
+	var html = "<div class=\"helpvalue schema-form-helpvalue {{::form.htmlClass}}\" ng-bind-html=\"form.helpvalue\"></div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 9 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/radio-buttons.html';
+	var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (item.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: item.value === $$value$$ }\"\r\n           ng-repeat=\"item in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 10 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/radios-inline.html';
+	var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"item in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 11 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/radios.html';
+	var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"item in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 12 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/section.html';
+	var html = "<div class=\"schema-form-section {{::form.htmlClass}}\"></div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 13 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/select.html';
+	var html = "<div class=\"form-group {{::form.htmlClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{form.key.slice(-1)[0]}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 14 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/submit.html';
+	var html = "<div class=\"form-group schema-form-submit {{::form.htmlClass}}\">\r\n  <input type=\"submit\"\r\n         class=\"btn {{ form.style || 'btn-primary' }} {{::form.fieldHtmlClass}}\"\r\n         value=\"{{form.title}}\"\r\n         ng-disabled=\"form.readonly\"\r\n         ng-if=\"form.type === 'submit'\">\r\n  <button class=\"btn {{ form.style || 'btn-default' }}\"\r\n          type=\"button\"\r\n          ng-click=\"buttonClick($event,form)\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"form.type !== 'submit'\">\r\n      <span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 15 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/tabarray.html';
+	var html = "<div ng-init=\"selected = { tab: 0 }\"\r\n     ng-model=\"modelArray\" schema-validate=\"form\"\r\n     sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{::form.htmlClass}}\">\r\n  <div ng-if=\"!form.tabType || form.tabType !== 'right'\"\r\n       ng-class=\"{'col-xs-3': !form.tabType || form.tabType === 'left'}\">\r\n    <ol class=\"nav nav-tabs\"\r\n        ng-class=\"{ 'tabs-left': !form.tabType || form.tabType === 'left'}\"\r\n        sf-field-model ui-sortable=\"form.sortOptions\">\r\n      <li sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class=\"{'col-xs-9': !form.tabType || form.tabType === 'left' || form.tabType === 'right'}\">\r\n    <div class=\"tab-content {{::form.fieldHtmlClass}}\">\r\n      <div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\"\r\n           sf-field-model=\"ng-repeat\"\r\n           ng-repeat=\"item in $$value$$ track by $index\"\r\n           ng-show=\"selected.tab === $index\"\r\n           ng-class=\"{active: selected.tab === $index}\">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n\r\n           <button ng-hide=\"form.readonly || form.remove === null\"\r\n                   ng-click=\"selected.tab = deleteFromArray($index).length - 1\"\r\n                   ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n                   type=\"button\"\r\n                   class=\"btn {{ form.style.remove || 'btn-default' }} pull-right\">\r\n             <i class=\"glyphicon glyphicon-trash\"></i>\r\n             {{ form.remove || 'Remove'}}\r\n           </button>\r\n      </div>\r\n      <div class=\"help-block\"\r\n           ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n           ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if=\"form.tabType === 'right'\" class=\"col-xs-3\">\r\n    <ul class=\"nav nav-tabs tabs-right\">\r\n      <li  sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 16 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/tabs.html';
+	var html = "<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{::form.htmlClass}}\">\r\n  <ul class=\"nav nav-tabs\">\r\n    <li ng-repeat=\"tab in form.tabs\"\r\n        ng-disabled=\"form.readonly\"\r\n        ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n        ng-class=\"{active: selected.tab === $index}\">\r\n        <a href=\"#\">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class=\"tab-content {{::form.fieldHtmlClass}}\">\r\n  </div>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 17 */
+/***/ function(module, exports) {
+
+	var path = 'bootstrap/textarea.html';
+	var html = "<div class=\"form-group has-feedback {{::form.htmlClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{form.key.slice(-1)[0]}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{form.key.slice(-1)[0]}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{form.key.slice(-1)[0]}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{form.key.slice(-1)[0]}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
+	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+	module.exports = path;
+
+/***/ },
+/* 18 */
+/***/ function(module, exports, __webpack_require__) {
+
+	/*!
+	 * angular-schema-form
+	 * @version 1.0.0-alpha.2
+	 * @link https://github.com/json-schema-form/angular-schema-form
+	 * @license MIT
+	 * Copyright (c) 2016 JSON Schema Form
+	 */
+	(function webpackUniversalModuleDefinition(root, factory) {
+		if(true)
+			module.exports = factory(__webpack_require__(19), __webpack_require__(20));
+		else if(typeof define === 'function' && define.amd)
+			define(["angular", "tv4"], factory);
+		else {
+			var a = typeof exports === 'object' ? factory(require("angular"), require("tv4")) : factory(root["angular"], root["tv4"]);
+			for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
+		}
+	})(this, function(__WEBPACK_EXTERNAL_MODULE_2__, __WEBPACK_EXTERNAL_MODULE_7__) {
+	return /******/ (function(modules) { // webpackBootstrap
+	/******/ 	// The module cache
+	/******/ 	var installedModules = {};
+
+	/******/ 	// The require function
+	/******/ 	function __webpack_require__(moduleId) {
+
+	/******/ 		// Check if module is in cache
+	/******/ 		if(installedModules[moduleId])
+	/******/ 			return installedModules[moduleId].exports;
+
+	/******/ 		// Create a new module (and put it into the cache)
+	/******/ 		var module = installedModules[moduleId] = {
+	/******/ 			exports: {},
+	/******/ 			id: moduleId,
+	/******/ 			loaded: false
+	/******/ 		};
+
+	/******/ 		// Execute the module function
+	/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
+
+	/******/ 		// Flag the module as loaded
+	/******/ 		module.loaded = true;
+
+	/******/ 		// Return the exports of the module
+	/******/ 		return module.exports;
+	/******/ 	}
+
+
+	/******/ 	// expose the modules object (__webpack_modules__)
+	/******/ 	__webpack_require__.m = modules;
+
+	/******/ 	// expose the module cache
+	/******/ 	__webpack_require__.c = installedModules;
+
+	/******/ 	// __webpack_public_path__
+	/******/ 	__webpack_require__.p = "";
+
+	/******/ 	// Load entry module and return exports
+	/******/ 	return __webpack_require__(0);
+	/******/ })
+	/************************************************************************/
+	/******/ ([
+	/* 0 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		module.exports = __webpack_require__(1);
+
+
+	/***/ },
+	/* 1 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		var _builder = __webpack_require__(3);
+
+		var _builder2 = _interopRequireDefault(_builder);
+
+		var _decorators = __webpack_require__(4);
+
+		var _decorators2 = _interopRequireDefault(_decorators);
+
+		var _schemaForm = __webpack_require__(5);
+
+		var _schemaForm2 = _interopRequireDefault(_schemaForm);
+
+		var _jsonSchemaFormCore = __webpack_require__(6);
+
+		var _validator = __webpack_require__(8);
+
+		var _validator2 = _interopRequireDefault(_validator);
+
+		var _errors = __webpack_require__(9);
+
+		var _errors2 = _interopRequireDefault(_errors);
+
+		var _sfPath = __webpack_require__(10);
+
+		var _sfPath2 = _interopRequireDefault(_sfPath);
+
+		var _array = __webpack_require__(11);
+
+		var _array2 = _interopRequireDefault(_array);
+
+		var _changed = __webpack_require__(12);
+
+		var _changed2 = _interopRequireDefault(_changed);
+
+		var _field = __webpack_require__(13);
+
+		var _field2 = _interopRequireDefault(_field);
+
+		var _message = __webpack_require__(14);
+
+		var _message2 = _interopRequireDefault(_message);
+
+		var _newArray = __webpack_require__(15);
+
+		var _newArray2 = _interopRequireDefault(_newArray);
+
+		var _keyController = __webpack_require__(16);
+
+		var _keyController2 = _interopRequireDefault(_keyController);
+
+		var _schemaForm3 = __webpack_require__(17);
+
+		var _schemaForm4 = _interopRequireDefault(_schemaForm3);
+
+		var _schemaValidate = __webpack_require__(18);
+
+		var _schemaValidate2 = _interopRequireDefault(_schemaValidate);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+		// Deps is sort of a problem for us, maybe in the future we will ask the user to depend
+		// on modules for add-ons
+
+		var deps = [];
+		try {
+		  //This throws an expection if module does not exist.
+		  _angular2.default.module('ngSanitize');
+		  deps.push('ngSanitize');
+		} catch (e) {}
+
+		try {
+		  //This throws an expection if module does not exist.
+		  _angular2.default.module('ui.sortable');
+		  deps.push('ui.sortable');
+		} catch (e) {}
+
+		try {
+		  //This throws an expection if module does not exist.
+		  _angular2.default.module('angularSpectrumColorpicker');
+		  deps.push('angularSpectrumColorpicker');
+		} catch (e) {}
+
+		_angular2.default.module('schemaForm', deps)
+		// Providers and services
+		.provider('sfPath', _sfPath2.default).provider('sfBuilder', ['sfPathProvider', _builder2.default]).provider('schemaFormDecorators', ['$compileProvider', 'sfPathProvider', _decorators2.default]).provider('sfErrorMessage', _errors2.default).provider('schemaForm', ['sfPathProvider', _schemaForm2.default]).factory('sfSelect', function () {
+		  return _jsonSchemaFormCore.select;
+		}).factory('sfValidator', _validator2.default)
+
+		// Directives
+		.directive('sfArray', ['sfSelect', 'schemaForm', 'sfValidator', 'sfPath', _array2.default]).directive('sfChanged', _changed2.default).directive('sfField', ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', _field2.default]).directive('sfMessage', ['$injector', 'sfErrorMessage', _message2.default]).directive('sfNewArray', ['sfSelect', 'sfPath', 'schemaForm', _newArray2.default]).directive('sfSchema', ['$compile', '$http', '$templateCache', '$q', 'schemaForm', 'schemaFormDecorators', 'sfSelect', 'sfPath', 'sfBuilder', _schemaForm4.default]).directive('schemaValidate', ['sfValidator', '$parse', 'sfSelect', _schemaValidate2.default]).directive('sfKeyController', ['schemaForm', 'sfPath', _keyController2.default]);
+
+	/***/ },
+	/* 2 */
+	/***/ function(module, exports) {
+
+		module.exports = angular;
+
+	/***/ },
+	/* 3 */
+	/***/ function(module, exports) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function (sfPathProvider) {
+
+		  var SNAKE_CASE_REGEXP = /[A-Z]/g;
+		  var snakeCase = function snakeCase(name, separator) {
+		    separator = separator || '_';
+		    return name.replace(SNAKE_CASE_REGEXP, function (letter, pos) {
+		      return (pos ? separator : '') + letter.toLowerCase();
+		    });
+		  };
+		  var formId = 0;
+
+		  var builders = {
+		    sfField: function sfField(args) {
+		      args.fieldFrag.firstChild.setAttribute('sf-field', formId);
+
+		      // We use a lookup table for easy access to our form.
+		      args.lookup['f' + formId] = args.form;
+		      formId++;
+		    },
+		    ngModel: function ngModel(args) {
+		      if (!args.form.key) {
+		        return;
+		      }
+		      var key = args.form.key;
+
+		      // Redact part of the key, used in arrays
+		      // KISS keyRedaction is a number.
+		      if (args.state.keyRedaction) {
+		        key = key.slice(args.state.keyRedaction);
+		      }
+
+		      // Stringify key.
+		      var modelValue;
+		      if (!args.state.modelValue) {
+		        var strKey = sfPathProvider.stringify(key).replace(/"/g, '&quot;');
+		        modelValue = args.state.modelName || 'model';
+
+		        if (strKey) {
+		          // Sometimes, like with arrays directly in arrays strKey is nothing.
+		          modelValue += (strKey[0] !== '[' ? '.' : '') + strKey;
+		        }
+		      } else {
+		        // Another builder, i.e. array has overriden the modelValue
+		        modelValue = args.state.modelValue;
+		      }
+
+		      // Find all sf-field-value attributes.
+		      // No value means a add a ng-model.
+		      // sf-field-value="replaceAll", loop over attributes and replace $$value$$ in each.
+		      // sf-field-value="attrName", replace or set value of that attribute.
+		      var nodes = args.fieldFrag.querySelectorAll('[sf-field-model]');
+		      for (var i = 0; i < nodes.length; i++) {
+		        var n = nodes[i];
+		        var conf = n.getAttribute('sf-field-model');
+		        if (!conf || conf === '') {
+		          n.setAttribute('ng-model', modelValue);
+		        } else if (conf === 'replaceAll') {
+		          var attributes = n.attributes;
+		          for (var j = 0; j < attributes.length; j++) {
+		            if (attributes[j].value && attributes[j].value.indexOf('$$value') !== -1) {
+		              attributes[j].value = attributes[j].value.replace(/\$\$value\$\$/g, modelValue);
+		            }
+		          }
+		        } else {
+		          var val = n.getAttribute(conf);
+		          if (val && val.indexOf('$$value$$')) {
+		            n.setAttribute(conf, val.replace(/\$\$value\$\$/g, modelValue));
+		          } else {
+		            n.setAttribute(conf, modelValue);
+		          }
+		        }
+		      }
+		    },
+		    simpleTransclusion: function simpleTransclusion(args) {
+		      var children = args.build(args.form.items, args.path + '.items', args.state);
+		      args.fieldFrag.firstChild.appendChild(children);
+		    },
+
+		    // Patch on ngModelOptions, since it doesn't like waiting for its value.
+		    ngModelOptions: function ngModelOptions(args) {
+		      if (args.form.ngModelOptions && Object.keys(args.form.ngModelOptions).length > 0) {
+		        args.fieldFrag.firstChild.setAttribute('ng-model-options', JSON.stringify(args.form.ngModelOptions));
+		      }
+		    },
+		    transclusion: function transclusion(args) {
+		      var transclusions = args.fieldFrag.querySelectorAll('[sf-field-transclude]');
+
+		      if (transclusions.length) {
+		        for (var i = 0; i < transclusions.length; i++) {
+		          var n = transclusions[i];
+
+		          // The sf-transclude attribute is not a directive,
+		          // but has the name of what we're supposed to
+		          // traverse. Default to `items`
+		          var sub = n.getAttribute('sf-field-transclude') || 'items';
+		          var items = args.form[sub];
+
+		          if (items) {
+		            var childFrag = args.build(items, args.path + '.' + sub, args.state);
+		            n.appendChild(childFrag);
+		          }
+		        }
+		      }
+		    },
+		    condition: function condition(args) {
+		      // Do we have a condition? Then we slap on an ng-if on all children,
+		      // but be nice to existing ng-if.
+		      if (args.form.condition) {
+		        var evalExpr = 'evalExpr(' + args.path + '.condition, { model: model, "arrayIndex": $index})';
+		        if (args.form.key) {
+		          var strKey = sfPathProvider.stringify(args.form.key);
+		          var arrayDepth = args.form.key.filter(function (e) {
+		            return e === '';
+		          }).length;
+		          var arrayIndices = arrayDepth > 1 ? Array(arrayDepth - 1).join('$parent.$parent.$parent.') + '$parent.$parent.$index,' : '';
+		          for (var i = arrayDepth; i > 2; i--) {
+		            arrayIndices += Array(i - 1).join('$parent.$parent.$parent.') + '$index,';
+		          }
+		          arrayIndices += '$index';
+
+		          evalExpr = 'evalExpr(' + args.path + '.condition,{ model: model, "arrayIndex": $index, ' + '"arrayIndices": [' + arrayIndices + '],' + '"modelValue": model' + (strKey[0] === '[' ? '' : '.') + strKey + '})';
+		        }
+
+		        var children = args.fieldFrag.children || args.fieldFrag.childNodes;
+		        for (var i = 0; i < children.length; i++) {
+		          var child = children[i];
+		          var ngIf = child.getAttribute('ng-if');
+		          child.setAttribute('ng-if', ngIf ? '(' + ngIf + ') || (' + evalExpr + ')' : evalExpr);
+		        }
+		      }
+		    },
+		    array: function array(args) {
+		      var items = args.fieldFrag.querySelector('[schema-form-array-items]');
+
+		      if (args.form.key) {
+		        var arrayDepth = args.form.key.filter(function (e) {
+		          return e === '';
+		        }).length;
+		      }
+
+		      if (items) {
+		        var state = angular.copy(args.state);
+		        state.keyRedaction = 0;
+		        state.keyRedaction += args.form.key.length + 1;
+
+		        // Special case, an array with just one item in it that is not an object.
+		        // So then we just override the modelValue
+		        if (args.form.schema && args.form.schema.items && args.form.schema.items.type && args.form.schema.items.type.indexOf('object') === -1 && args.form.schema.items.type.indexOf('array') === -1) {
+		          var strKey = sfPathProvider.stringify(args.form.key).replace(/"/g, '&quot;') + '[$index]';
+		          state.modelValue = 'modelArray[$index]';
+		        } else {
+		          state.modelName = 'item';
+		        }
+
+		        // Flag to the builder that where in an array.
+		        // This is needed for compatabiliy if a "old" add-on is used that
+		        // hasn't been transitioned to the new builder.
+		        state.arrayCompatFlag = true;
+
+		        var childFrag = args.build(args.form.items, args.path + '.items', state);
+		        items.appendChild(childFrag);
+		      }
+		    },
+		    numeric: function numeric(args) {
+		      var inputFrag = args.fieldFrag.querySelector('input');
+		      var maximum = args.form.maximum || false;
+		      var exclusiveMaximum = args.form.exclusiveMaximum || false;
+		      var minimum = args.form.minimum || false;
+		      var exclusiveMinimum = args.form.exclusiveMinimum || false;
+		      var multipleOf = args.form.multipleOf || false;
+		      if (inputFrag) {
+		        if (multipleOf !== false) {
+		          inputFrag.setAttribute('step', multipleOf);
+		        };
+
+		        if (maximum !== false) {
+		          if (exclusiveMaximum !== false && multipleOf !== false) {
+		            maximum = maximum - multipleOf;
+		          };
+		          inputFrag.setAttribute('max', maximum);
+		        };
+
+		        if (minimum !== false) {
+		          if (exclusiveMinimum !== false && multipleOf !== false) {
+		            minimum = minimum + multipleOf;
+		          };
+		          inputFrag.setAttribute('min', minimum);
+		        };
+		      };
+		    }
+		  };
+		  this.builders = builders;
+		  var stdBuilders = [builders.sfField, builders.ngModel, builders.ngModelOptions, builders.condition];
+		  this.stdBuilders = stdBuilders;
+
+		  this.$get = ['$templateCache', 'schemaFormDecorators', 'sfPath', function ($templateCache, schemaFormDecorators, sfPath) {
+		    var checkForSlot = function checkForSlot(form, slots) {
+		      // Finally append this field to the frag.
+		      // Check for slots
+		      if (form.key) {
+		        var slot = slots[sfPath.stringify(form.key)];
+		        if (slot) {
+		          while (slot.firstChild) {
+		            slot.removeChild(slot.firstChild);
+		          }
+		          return slot;
+		        }
+		      }
+		    };
+
+		    var _build = function _build(items, decorator, templateFn, slots, path, state, lookup) {
+		      state = state || {};
+		      state = state || {};
+		      lookup = lookup || Object.create(null);
+		      path = path || 'schemaForm.form';
+		      var container = document.createDocumentFragment();
+		      items.reduce(function (frag, f, index) {
+
+		        // Sanity check.
+		        if (!f.type) {
+		          return frag;
+		        }
+
+		        var field = decorator[f.type] || decorator['default'];
+		        if (!field.replace) {
+		          // Backwards compatability build
+		          var n = document.createElement(snakeCase(decorator.__name, '-'));
+		          if (state.arrayCompatFlag) {
+		            n.setAttribute('form', 'copyWithIndex($index)');
+		          } else {
+		            n.setAttribute('form', path + '[' + index + ']');
+		          }
+
+		          (checkForSlot(f, slots) || frag).appendChild(n);
+		        } else {
+		          var tmpl;
+
+		          // Reset arrayCompatFlag, it's only valid for direct children of the array.
+		          state.arrayCompatFlag = false;
+
+		          // TODO: Create a couple of testcases, small and large and
+		          //       measure optmization. A good start is probably a
+		          //       cache of DOM nodes for a particular template
+		          //       that can be cloned instead of using innerHTML
+		          var div = document.createElement('div');
+		          var template = templateFn(f, field) || templateFn(f, decorator['default']);
+		          div.innerHTML = template;
+
+		          // Move node to a document fragment, we don't want the div.
+		          tmpl = document.createDocumentFragment();
+		          while (div.childNodes.length > 0) {
+		            tmpl.appendChild(div.childNodes[0]);
+		          }
+
+		          // Possible builder, often a noop
+		          var args = {
+		            fieldFrag: tmpl,
+		            form: f,
+		            lookup: lookup,
+		            state: state,
+		            path: path + '[' + index + ']',
+
+		            // Recursive build fn
+		            build: function build(items, path, state) {
+		              return _build(items, decorator, templateFn, slots, path, state, lookup);
+		            }
+
+		          };
+
+		          // Let the form definiton override builders if it wants to.
+		          var builderFn = f.builder || field.builder;
+
+		          // Builders are either a function or a list of functions.
+		          if (typeof builderFn === 'function') {
+		            builderFn(args);
+		          } else {
+		            builderFn.forEach(function (fn) {
+		              fn(args);
+		            });
+		          }
+
+		          // Append
+		          (checkForSlot(f, slots) || frag).appendChild(tmpl);
+		        }
+		        return frag;
+		      }, container);
+
+		      return container;
+		    };
+
+		    return {
+		      /**
+		       * Builds a form from a canonical form definition
+		       */
+		      build: function build(form, decorator, slots, lookup) {
+		        return _build(form, decorator, function (form, field) {
+		          if (form.type === 'template') {
+		            return form.template;
+		          }
+		          return $templateCache.get(field.template);
+		        }, slots, undefined, undefined, lookup);
+		      },
+		      builder: builders,
+		      stdBuilders: stdBuilders,
+		      internalBuild: _build
+		    };
+		  }];
+		};
+
+	/***/ },
+	/* 4 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function ($compileProvider, sfPathProvider) {
+		  var defaultDecorator = '';
+		  var decorators = {};
+
+		  // Map template after decorator and type.
+		  var templateUrl = function templateUrl(name, form) {
+		    //schemaDecorator is alias for whatever is set as default
+		    if (name === 'sfDecorator') {
+		      name = defaultDecorator;
+		    }
+
+		    var decorator = decorators[name];
+		    if (decorator[form.type]) {
+		      return decorator[form.type].template;
+		    }
+
+		    //try default
+		    return decorator['default'].template;
+		  };
+
+		  /**************************************************
+		   * DEPRECATED                                     *
+		   * The new builder and sf-field is preferred, but *
+		   * we keep this in during a transitional period   *
+		   * so that add-ons that don't use the new builder *
+		   * works.                                         *
+		   **************************************************/
+		  //TODO: Move to a compatability extra script.
+		  var createDirective = function createDirective(name) {
+		    $compileProvider.directive(name, ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', function ($parse, $compile, $http, $templateCache, $interpolate, $q, sfErrorMessage, sfPath, sfSelect) {
+
+		      return {
+		        restrict: 'AE',
+		        replace: false,
+		        transclude: false,
+		        scope: true,
+		        require: ['^sfSchema', '?^form'],
+		        link: function link(scope, element, attrs, ctrl) {
+		          var sfSchema = ctrl[0];
+		          var formCtrl = ctrl[1];
+
+		          //The ngModelController is used in some templates and
+		          //is needed for error messages,
+		          scope.$on('schemaFormPropagateNgModelController', function (event, ngModel) {
+		            event.stopPropagation();
+		            event.preventDefault();
+		            scope.ngModel = ngModel;
+		          });
+
+		          //Keep error prone logic from the template
+		          scope.showTitle = function () {
+		            return scope.form && scope.form.notitle !== true && scope.form.title;
+		          };
+
+		          //Normalise names and ids
+		          scope.fieldId = function (prependFormName, omitArrayIndexes) {
+		            var key = scope.parentKey || [];
+		            if (scope.form.key) {
+		              if (typeof key[key.length - 1] === 'number') {
+		                var combinedKey = key.concat(scope.form.key.slice(-1));
+		                var formName = prependFormName && formCtrl && formCtrl.$name ? formCtrl.$name : undefined;
+		                return sfPath.name(combinedKey, '-', formName, omitArrayIndexes);
+		              } else {
+		                var formName = prependFormName && formCtrl && formCtrl.$name ? formCtrl.$name : undefined;
+		                return sfPath.name(scope.form.key, '-', formName, omitArrayIndexes);
+		              }
+		            } else {
+		              return '';
+		            }
+		          };
+
+		          scope.listToCheckboxValues = function (list) {
+		            var values = {};
+		            _angular2.default.forEach(list, function (v) {
+		              values[v] = true;
+		            });
+		            return values;
+		          };
+
+		          scope.checkboxValuesToList = function (values) {
+		            var lst = [];
+		            _angular2.default.forEach(values, function (v, k) {
+		              if (v) {
+		                lst.push(k);
+		              }
+		            });
+		            return lst;
+		          };
+
+		          scope.buttonClick = function ($event, form) {
+		            if (_angular2.default.isFunction(form.onClick)) {
+		              form.onClick($event, form);
+		            } else if (_angular2.default.isString(form.onClick)) {
+		              if (sfSchema) {
+		                //evaluating in scope outside of sfSchemas isolated scope
+		                sfSchema.evalInParentScope(form.onClick, { '$event': $event, form: form });
+		              } else {
+		                scope.$eval(form.onClick, { '$event': $event, form: form });
+		              };
+		            };
+		          };
+
+		          /**
+		           * Evaluate an expression, i.e. scope.$eval
+		           * but do it in sfSchemas parent scope sf-schema directive is used
+		           *
+		           * @param {string} expression
+		           * @param {Object} locals (optional)
+		           * @return {Any} the result of the expression
+		           */
+		          scope.evalExpr = function (expression, locals) {
+		            if (sfSchema) {
+		              //evaluating in scope outside of sfSchemas isolated scope
+		              return sfSchema.evalInParentScope(expression, locals);
+		            }
+
+		            return scope.$eval(expression, locals);
+		          };
+
+		          /**
+		           * Evaluate an expression, i.e. scope.$eval
+		           * in this decorators scope
+		           *
+		           * @param {string} expression
+		           * @param {Object} locals (optional)
+		           * @return {Any} the result of the expression
+		           */
+		          scope.evalInScope = function (expression, locals) {
+		            if (expression) {
+		              return scope.$eval(expression, locals);
+		            }
+		          };
+
+		          /**
+		           * Interpolate the expression.
+		           * Similar to `evalExpr()` and `evalInScope()`
+		           * but will not fail if the expression is
+		           * text that contains spaces.
+		           *
+		           * Use the Angular `{{ interpolation }}`
+		           * braces to access properties on `locals`.
+		           *
+		           * @param  {string} expression The string to interpolate.
+		           * @param  {Object} locals (optional) Properties that may be accessed in the
+		           *                         `expression` string.
+		           * @return {Any} The result of the expression or `undefined`.
+		           */
+		          scope.interp = function (expression, locals) {
+		            return expression && $interpolate(expression)(locals);
+		          };
+
+		          //This works since we ot the ngModel from the array or the schema-validate directive.
+		          scope.hasSuccess = function () {
+		            if (!scope.ngModel) {
+		              return false;
+		            }
+		            if (scope.options && scope.options.pristine && scope.options.pristine.success === false) {
+		              return scope.ngModel.$valid && !scope.ngModel.$pristine && !scope.ngModel.$isEmpty(scope.ngModel.$modelValue);
+		            } else {
+		              return scope.ngModel.$valid && (!scope.ngModel.$pristine || !scope.ngModel.$isEmpty(scope.ngModel.$modelValue));
+		            }
+		          };
+
+		          scope.hasError = function () {
+		            if (!scope.ngModel) {
+		              return false;
+		            }
+		            return scope.ngModel.$invalid && !scope.ngModel.$pristine;
+		          };
+
+		          /**
+		           * DEPRECATED: use sf-messages instead.
+		           * Error message handler
+		           * An error can either be a schema validation message or a angular js validtion
+		           * error (i.e. required)
+		           */
+		          scope.errorMessage = function (schemaError) {
+		            return sfErrorMessage.interpolate(schemaError && schemaError.code + '' || 'default', scope.ngModel && scope.ngModel.$modelValue || '', scope.ngModel && scope.ngModel.$viewValue || '', scope.form, scope.options && scope.options.validationMessage);
+		          };
+
+		          // Rebind our part of the form to the scope.
+		          var once = scope.$watch(attrs.form, function (form) {
+		            if (form) {
+		              // Workaround for 'updateOn' error from ngModelOptions
+		              // see https://github.com/Textalk/angular-schema-form/issues/255
+		              // and https://github.com/Textalk/angular-schema-form/issues/206
+		              form.ngModelOptions = form.ngModelOptions || {};
+		              scope.form = form;
+
+		              //ok let's replace that template!
+		              //We do this manually since we need to bind ng-model properly and also
+		              //for fieldsets to recurse properly.
+		              var templatePromise;
+
+		              // type: "template" is a special case. It can contain a template inline or an url.
+		              // otherwise we find out the url to the template and load them.
+		              if (form.type === 'template' && form.template) {
+		                templatePromise = $q.when(form.template);
+		              } else {
+		                var url = form.type === 'template' ? form.templateUrl : templateUrl(name, form);
+		                templatePromise = $http.get(url, { cache: $templateCache }).then(function (res) {
+		                  return res.data;
+		                });
+		              }
+
+		              templatePromise.then(function (template) {
+		                if (form.key) {
+		                  var key = form.key ? sfPathProvider.stringify(form.key).replace(/"/g, '&quot;') : '';
+		                  template = template.replace(/\$\$value\$\$/g, 'model' + (key[0] !== '[' ? '.' : '') + key);
+		                }
+		                element.html(template);
+
+		                // Do we have a condition? Then we slap on an ng-if on all children,
+		                // but be nice to existing ng-if.
+		                if (form.condition) {
+
+		                  var evalExpr = 'evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';
+		                  if (form.key) {
+		                    evalExpr = 'evalExpr(form.condition, {' + 'model: model, "arrayIndex": arrayIndex, "modelValue": model' + sfPath.stringify(form.key) + '})';
+		                  }
+
+		                  _angular2.default.forEach(element.children(), function (child) {
+		                    var ngIf = child.getAttribute('ng-if');
+		                    child.setAttribute('ng-if', ngIf ? '(' + ngIf + ') || (' + evalExpr + ')' : evalExpr);
+		                  });
+		                }
+		                $compile(element.contents())(scope);
+		              });
+
+		              // Where there is a key there is probably a ngModel
+		              if (form.key) {
+		                // It looks better with dot notation.
+		                scope.$on('schemaForm.error.' + form.key.join('.'), function (event, error, validationMessage, validity, formName) {
+		                  // validationMessage and validity are mutually exclusive
+		                  formName = validity;
+		                  if (validationMessage === true || validationMessage === false) {
+		                    validity = validationMessage;
+		                    validationMessage = undefined;
+		                  };
+
+		                  // If we have specified a form name, and this model is not within
+		                  // that form, then leave things be.
+		                  if (formName != undefined && scope.ngModel.$$parentForm.$name !== formName) {
+		                    return;
+		                  };
+
+		                  if (scope.ngModel && error) {
+		                    if (scope.ngModel.$setDirty) {
+		                      scope.ngModel.$setDirty();
+		                    } else {
+		                      // FIXME: Check that this actually works on 1.2
+		                      scope.ngModel.$dirty = true;
+		                      scope.ngModel.$pristine = false;
+		                    };
+
+		                    // Set the new validation message if one is supplied
+		                    // Does not work when validationMessage is just a string.
+		                    if (validationMessage) {
+		                      if (!form.validationMessage) {
+		                        form.validationMessage = {};
+		                      }
+		                      form.validationMessage[error] = validationMessage;
+		                    }
+
+		                    scope.ngModel.$setValidity(error, validity === true);
+
+		                    if (validity === true) {
+		                      // Re-trigger model validator, that model itself would be re-validated
+		                      scope.ngModel.$validate();
+
+		                      // Setting or removing a validity can change the field to believe its valid
+		                      // but its not. So lets trigger its validation as well.
+		                      scope.$broadcast('schemaFormValidate');
+		                    }
+		                  }
+		                });
+
+		                // Clean up the model when the corresponding form field is $destroy-ed.
+		                // Default behavior can be supplied as a globalOption, and behavior can be overridden
+		                // in the form definition.
+		                scope.$on('$destroy', function () {
+		                  // If the entire schema form is destroyed we don't touch the model
+		                  if (!scope.externalDestructionInProgress) {
+		                    var destroyStrategy = form.destroyStrategy || scope.options && scope.options.destroyStrategy || 'remove';
+		                    // No key no model, and we might have strategy 'retain'
+		                    if (form.key && destroyStrategy !== 'retain') {
+
+		                      // Get the object that has the property we wan't to clear.
+		                      var obj = scope.model;
+		                      if (form.key.length > 1) {
+		                        obj = sfSelect(form.key.slice(0, form.key.length - 1), obj);
+		                      }
+
+		                      // We can get undefined here if the form hasn't been filled out entirely
+		                      if (obj === undefined) {
+		                        return;
+		                      }
+
+		                      // Type can also be a list in JSON Schema
+		                      var type = form.schema && form.schema.type || '';
+
+		                      // Empty means '',{} and [] for appropriate types and undefined for the rest
+		                      if (destroyStrategy === 'empty' && type.indexOf('string') !== -1) {
+		                        obj[form.key.slice(-1)] = '';
+		                      } else if (destroyStrategy === 'empty' && type.indexOf('object') !== -1) {
+		                        obj[form.key.slice(-1)] = {};
+		                      } else if (destroyStrategy === 'empty' && type.indexOf('array') !== -1) {
+		                        obj[form.key.slice(-1)] = [];
+		                      } else if (destroyStrategy === 'null') {
+		                        obj[form.key.slice(-1)] = null;
+		                      } else {
+		                        delete obj[form.key.slice(-1)];
+		                      }
+		                    }
+		                  }
+		                });
+		              }
+
+		              once();
+		            }
+		          });
+		        }
+		      };
+		    }]);
+		  };
+
+		  var createManualDirective = function createManualDirective(type, templateUrl, transclude) {
+		    transclude = _angular2.default.isDefined(transclude) ? transclude : false;
+		    $compileProvider.directive('sf' + _angular2.default.uppercase(type[0]) + type.substr(1), function () {
+		      return {
+		        restrict: 'EAC',
+		        scope: true,
+		        replace: true,
+		        transclude: transclude,
+		        template: '<sf-decorator form="form"></sf-decorator>',
+		        link: function link(scope, element, attrs) {
+		          var watchThis = {
+		            'items': 'c',
+		            'titleMap': 'c',
+		            'schema': 'c'
+		          };
+		          var form = { type: type };
+		          var once = true;
+		          _angular2.default.forEach(attrs, function (value, name) {
+		            if (name[0] !== '$' && name.indexOf('ng') !== 0 && name !== 'sfField') {
+
+		              var updateForm = function updateForm(val) {
+		                if (_angular2.default.isDefined(val) && val !== form[name]) {
+		                  form[name] = val;
+
+		                  //when we have type, and if specified key we apply it on scope.
+		                  if (once && form.type && (form.key || _angular2.default.isUndefined(attrs.key))) {
+		                    scope.form = form;
+		                    once = false;
+		                  }
+		                }
+		              };
+
+		              if (name === 'model') {
+		                //"model" is bound to scope under the name "model" since this is what the decorators
+		                //know and love.
+		                scope.$watch(value, function (val) {
+		                  if (val && scope.model !== val) {
+		                    scope.model = val;
+		                  }
+		                });
+		              } else if (watchThis[name] === 'c') {
+		                //watch collection
+		                scope.$watchCollection(value, updateForm);
+		              } else {
+		                //$observe
+		                attrs.$observe(name, updateForm);
+		              }
+		            }
+		          });
+		        }
+		      };
+		    });
+		  };
+
+		  /**
+		   * DEPRECATED: use defineDecorator instead.
+		   * Create a decorator directive and its sibling "manual" use decorators.
+		   * The directive can be used to create form fields or other form entities.
+		   * It can be used in conjunction with <schema-form> directive in which case the decorator is
+		   * given it's configuration via a the "form" attribute.
+		   *
+		   * ex. Basic usage
+		   *   <sf-decorator form="myform"></sf-decorator>
+		   **
+		   * @param {string} name directive name (CamelCased)
+		   * @param {Object} templates, an object that maps "type" => "templateUrl"
+		   */
+		  this.createDecorator = function (name, templates) {
+		    //console.warn('schemaFormDecorators.createDecorator is DEPRECATED, use defineDecorator instead.');
+		    decorators[name] = { '__name': name };
+
+		    _angular2.default.forEach(templates, function (url, type) {
+		      decorators[name][type] = { template: url, replace: false, builder: [] };
+		    });
+
+		    if (!decorators[defaultDecorator]) {
+		      defaultDecorator = name;
+		    }
+		    createDirective(name);
+		  };
+
+		  /**
+		   * Define a decorator. A decorator is a set of form types with templates and builder functions
+		   * that help set up the form.
+		   *
+		   * @param {string} name directive name (CamelCased)
+		   * @param {Object} fields, an object that maps "type" => `{ template, builder, replace}`.
+		                     attributes `builder` and `replace` are optional, and replace defaults to true.
+		                       `template` should be the key of the template to load and it should be pre-loaded
+		                     in `$templateCache`.
+		                       `builder` can be a function or an array of functions. They will be called in
+		                     the order they are supplied.
+		                       `replace` (DEPRECATED) is for backwards compatability. If false the builder
+		                     will use the "old" way of building that form field using a <sf-decorator>
+		                     directive.
+		   */
+		  this.defineDecorator = function (name, fields) {
+		    decorators[name] = { '__name': name }; // TODO: this feels like a hack, come up with a better way.
+
+		    _angular2.default.forEach(fields, function (field, type) {
+		      field.builder = field.builder || [];
+		      field.replace = _angular2.default.isDefined(field.replace) ? field.replace : true;
+		      decorators[name][type] = field;
+		    });
+
+		    if (!decorators[defaultDecorator]) {
+		      defaultDecorator = name;
+		    }
+		    createDirective(name);
+		  };
+
+		  /**
+		   * DEPRECATED
+		   * Creates a directive of a decorator
+		   * Usable when you want to use the decorators without using <schema-form> directive.
+		   * Specifically when you need to reuse styling.
+		   *
+		   * ex. createDirective('text','...')
+		   *  <sf-text title="foobar" model="person" key="name" schema="schema"></sf-text>
+		   *
+		   * @param {string}  type The type of the directive, resulting directive will have sf- prefixed
+		   * @param {string}  templateUrl
+		   * @param {boolean} transclude (optional) sets transclude option of directive, defaults to false.
+		   */
+		  this.createDirective = createManualDirective;
+
+		  /**
+		   * DEPRECATED
+		   * Same as createDirective, but takes an object where key is 'type' and value is 'templateUrl'
+		   * Useful for batching.
+		   *
+		   * @param {Object} templates
+		   */
+		  this.createDirectives = function (templates) {
+		    _angular2.default.forEach(templates, function (url, type) {
+		      createManualDirective(type, url);
+		    });
+		  };
+
+		  /**
+		   * Getter for decorator settings
+		   *
+		   * @param {string} name (optional) defaults to defaultDecorator
+		   * @return {Object} rules and templates { rules: [],templates: {}}
+		   */
+		  this.decorator = function (name) {
+		    name = name || defaultDecorator;
+		    return decorators[name];
+		  };
+
+		  /**
+		   * DEPRECATED use defineAddOn() instead.
+		   * Adds a mapping to an existing decorator.
+		   *
+		   * @param {String} name Decorator name
+		   * @param {String} type Form type for the mapping
+		   * @param {String} url  The template url
+		   * @param {Function} builder (optional) builder function
+		   * @param {boolean} replace (optional) defaults to false. Replace decorator directive with template.
+		   */
+		  this.addMapping = function (name, type, url, builder, replace) {
+		    if (decorators[name]) {
+		      decorators[name][type] = {
+		        template: url,
+		        builder: builder,
+		        replace: !!replace
+		      };
+		    }
+		  };
+
+		  /**
+		   * Adds an add-on to an existing decorator.
+		   *
+		   * @param {String} name Decorator name
+		   * @param {String} type Form type for the mapping
+		   * @param {String} url  The template url
+		   * @param {Function|Array} builder (optional) builder function(s),
+		   */
+		  this.defineAddOn = function (name, type, url, builder) {
+		    if (decorators[name]) {
+		      decorators[name][type] = {
+		        template: url,
+		        builder: builder,
+		        replace: true
+		      };
+		    }
+		  };
+
+		  //Service is just a getter for directive templates and rules
+		  this.$get = function () {
+		    return {
+		      decorator: function decorator(name) {
+		        return decorators[name] || decorators[defaultDecorator];
+		      },
+		      defaultDecorator: defaultDecorator
+		    };
+		  };
+
+		  //Create a default directive
+		  createDirective('sfDecorator');
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+		;
+
+	/***/ },
+	/* 5 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function () {
+		  var postProcessFn = function postProcessFn(form) {
+		    return form;
+		  };
+		  var defaults = _jsonSchemaFormCore.schemaDefaults.createDefaults();
+
+		  /**
+		   * Provider API
+		   */
+		  this.defaults = defaults;
+		  this.stdFormObj = _jsonSchemaFormCore.schemaDefaults.stdFormObj;
+		  this.defaultFormDefinition = _jsonSchemaFormCore.schemaDefaults.defaultFormDefinition;
+
+		  /**
+		   * Register a post process function.
+		   * This function is called with the fully merged
+		   * form definition (i.e. after merging with schema)
+		   * and whatever it returns is used as form.
+		   */
+		  this.postProcess = function (fn) {
+		    postProcessFn = fn;
+		  };
+
+		  /**
+		   * Append default form rule
+		   *
+		   * @param {string}   type json schema type
+		   * @param {Function} rule a function(propertyName,propertySchema,options) that returns a form
+		   *                        definition or undefined
+		   */
+		  this.appendRule = function (type, rule) {
+		    if (!defaults[type]) {
+		      defaults[type] = [];
+		    }
+		    defaults[type].push(rule);
+		  };
+
+		  /**
+		   * Prepend default form rule
+		   *
+		   * @param {string}   type json schema type
+		   * @param {Function} rule a function(propertyName,propertySchema,options) that returns a form
+		   *                        definition or undefined
+		   */
+		  this.prependRule = function (type, rule) {
+		    if (!defaults[type]) {
+		      defaults[type] = [];
+		    }
+		    defaults[type].unshift(rule);
+		  };
+
+		  /**
+		   * Utility function to create a standard form object.
+		   * This does *not* set the type of the form but rather all shared attributes.
+		   * You probably want to start your rule with creating the form with this method
+		   * then setting type and any other values you need.
+		   * @param {Object} schema
+		   * @param {Object} options
+		   * @return {Object} a form field defintion
+		   */
+		  this.createStandardForm = _jsonSchemaFormCore.schemaDefaults.stdFormObj;
+		  /* End Provider API */
+
+		  this.$get = function () {
+
+		    var service = {};
+		    var typeDefault = this.defaults;
+
+		    service.merge = function (schema, form, ignore, options, readonly, asyncTemplates) {
+		      form = form || ['*'];
+		      options = options || {};
+
+		      // Get readonly from root object
+		      readonly = readonly || schema.readonly || schema.readOnly;
+
+		      var stdForm = _jsonSchemaFormCore.schemaDefaults.defaultForm(schema, typeDefault, ignore, options);
+
+		      //simple case, we have a "*", just put the stdForm there
+		      var idx = form.indexOf('*');
+		      if (idx !== -1) {
+		        form = form.slice(0, idx).concat(stdForm.form).concat(form.slice(idx + 1));
+		      }
+
+		      //ok let's merge!
+		      //We look at the supplied form and extend it with schema standards
+		      var canonical = (0, _jsonSchemaFormCore.merge)(stdForm.lookup, form, options, readonly, asyncTemplates);
+		      return postProcessFn(canonical);
+		    };
+
+		    /**
+		     * Create form defaults from schema
+		     */
+		    service.defaults = _jsonSchemaFormCore.schemaDefaults.defaultForm;
+
+		    //Utility functions
+		    /**
+		     * Form defaults for schema by type
+		     * As a form is generated from a schema these are the definitions of each json-schema type
+		     */
+		    service.typeDefault = typeDefault;
+
+		    /**
+		     * Traverse a schema, applying a function(schema,path) on every sub schema
+		     * i.e. every property of an object.
+		     */
+		    service.traverseSchema = _jsonSchemaFormCore.traverseSchema;
+
+		    service.traverseForm = _jsonSchemaFormCore.traverseForm;
+
+		    return service;
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		var _jsonSchemaFormCore = __webpack_require__(6);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 6 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		/*!
+		 * json-schema-form
+		 * @version 1.0.0-alpha.2
+		 * @link https://github.com/json-schema-form/json-schema-form-core
+		 * @license MIT
+		 * Copyright (c) 2016 JSON Schema Form
+		 */
+		(function webpackUniversalModuleDefinition(root, factory) {
+			if(true)
+				module.exports = factory(__webpack_require__(7));
+			else if(typeof define === 'function' && define.amd)
+				define(["tv4"], factory);
+			else {
+				var a = typeof exports === 'object' ? factory(require("tv4")) : factory(root["tv4"]);
+				for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
+			}
+		})(this, function(__WEBPACK_EXTERNAL_MODULE_10__) {
+		return /******/ (function(modules) { // webpackBootstrap
+		/******/ 	// The module cache
+		/******/ 	var installedModules = {};
+
+		/******/ 	// The require function
+		/******/ 	function __webpack_require__(moduleId) {
+
+		/******/ 		// Check if module is in cache
+		/******/ 		if(installedModules[moduleId])
+		/******/ 			return installedModules[moduleId].exports;
+
+		/******/ 		// Create a new module (and put it into the cache)
+		/******/ 		var module = installedModules[moduleId] = {
+		/******/ 			exports: {},
+		/******/ 			id: moduleId,
+		/******/ 			loaded: false
+		/******/ 		};
+
+		/******/ 		// Execute the module function
+		/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
+
+		/******/ 		// Flag the module as loaded
+		/******/ 		module.loaded = true;
+
+		/******/ 		// Return the exports of the module
+		/******/ 		return module.exports;
+		/******/ 	}
+
+
+		/******/ 	// expose the modules object (__webpack_modules__)
+		/******/ 	__webpack_require__.m = modules;
+
+		/******/ 	// expose the module cache
+		/******/ 	__webpack_require__.c = installedModules;
+
+		/******/ 	// __webpack_public_path__
+		/******/ 	__webpack_require__.p = "";
+
+		/******/ 	// Load entry module and return exports
+		/******/ 	return __webpack_require__(0);
+		/******/ })
+		/************************************************************************/
+		/******/ ([
+		/* 0 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			module.exports = __webpack_require__(1);
+
+
+		/***/ },
+		/* 1 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+			exports.canonicalTitleMap = exports.schemaDefaults = exports.sfPath = undefined;
+
+			var _merge = __webpack_require__(2);
+
+			Object.keys(_merge).forEach(function (key) {
+			  if (key === "default") return;
+			  Object.defineProperty(exports, key, {
+			    enumerable: true,
+			    get: function get() {
+			      return _merge[key];
+			    }
+			  });
+			});
+
+			var _select = __webpack_require__(7);
+
+			Object.keys(_select).forEach(function (key) {
+			  if (key === "default") return;
+			  Object.defineProperty(exports, key, {
+			    enumerable: true,
+			    get: function get() {
+			      return _select[key];
+			    }
+			  });
+			});
+
+			var _traverse = __webpack_require__(8);
+
+			Object.keys(_traverse).forEach(function (key) {
+			  if (key === "default") return;
+			  Object.defineProperty(exports, key, {
+			    enumerable: true,
+			    get: function get() {
+			      return _traverse[key];
+			    }
+			  });
+			});
+
+			var _validate = __webpack_require__(9);
+
+			Object.keys(_validate).forEach(function (key) {
+			  if (key === "default") return;
+			  Object.defineProperty(exports, key, {
+			    enumerable: true,
+			    get: function get() {
+			      return _validate[key];
+			    }
+			  });
+			});
+
+			var _schemaDefaults = __webpack_require__(11);
+
+			var schemaDefaultsImp = _interopRequireWildcard(_schemaDefaults);
+
+			var _sfPath = __webpack_require__(3);
+
+			var sfPathImp = _interopRequireWildcard(_sfPath);
+
+			var _canonicalTitleMap = __webpack_require__(6);
+
+			var _canonicalTitleMap2 = _interopRequireDefault(_canonicalTitleMap);
+
+			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+			function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
+
+			var sfPath = exports.sfPath = sfPathImp;
+			var schemaDefaults = exports.schemaDefaults = schemaDefaultsImp;
+			var canonicalTitleMap = exports.canonicalTitleMap = _canonicalTitleMap2.default;
+
+		/***/ },
+		/* 2 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+			exports.merge = merge;
+
+			var _sfPath = __webpack_require__(3);
+
+			var _canonicalTitleMap = __webpack_require__(6);
+
+			var _canonicalTitleMap2 = _interopRequireDefault(_canonicalTitleMap);
+
+			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+			//export function merge(schema, form, schemaDefaultTypes, ignore, options, readonly, asyncTemplates) {
+			function merge(lookup, form, options, readonly, asyncTemplates) {
+			  form = form || [];
+			  options = options || {};
+
+			  //ok let's merge!
+			  //We look at the supplied form and extend it with schema standards
+			  return form.map(function (obj) {
+
+			    //handle the shortcut with just a name
+			    if (typeof obj === 'string') {
+			      obj = { key: obj };
+			    }
+
+			    if (obj.key) {
+			      if (typeof obj.key === 'string') {
+			        obj.key = (0, _sfPath.parse)(obj.key);
+			      }
+			    }
+
+			    //If it has a titleMap make sure it's a list
+			    if (obj.titleMap) {
+			      obj.titleMap = (0, _canonicalTitleMap2.default)(obj.titleMap);
+			    }
+
+			    //extend with std form from schema.
+			    if (obj.key) {
+			      var strid = (0, _sfPath.stringify)(obj.key);
+			      if (lookup[strid]) {
+			        (function () {
+			          var schemaDefaults = lookup[strid];
+			          if (schemaDefaults) {
+			            Object.keys(schemaDefaults).forEach(function (attr) {
+			              if (obj[attr] === undefined) {
+			                obj[attr] = schemaDefaults[attr];
+			              }
+			            });
+			          }
+			        })();
+			      }
+			    }
+
+			    // Are we inheriting readonly?
+			    if (readonly === true) {
+			      // Inheriting false is not cool.
+			      obj.readonly = true;
+			    }
+
+			    //if it's a type with items, merge 'em!
+			    if (obj.items) {
+			      obj.items = merge(lookup, obj.items, options, obj.readonly, asyncTemplates);
+			    }
+
+			    //if its has tabs, merge them also!
+			    if (obj.tabs) {
+			      obj.tabs.forEach(function (tab) {
+			        if (tab.items) {
+			          tab.items = merge(lookup, tab.items, options, obj.readonly, asyncTemplates);
+			        }
+			      });
+			    }
+
+			    // Special case: checkbox
+			    // Since have to ternary state we need a default
+			    if (obj.type === 'checkbox' && obj.schema['default'] === undefined) {
+			      obj.schema['default'] = false;
+			    };
+
+			    // Special case: template type with tempplateUrl that's needs to be loaded before rendering
+			    // TODO: this is not a clean solution. Maybe something cleaner can be made when $ref support
+			    // is introduced since we need to go async then anyway
+			    if (asyncTemplates && obj.type === 'template' && !obj.template && obj.templateUrl) {
+			      asyncTemplates.push(obj);
+			    }
+
+			    return obj;
+			  });
+			}
+
+		/***/ },
+		/* 3 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+			exports.name = exports.normalize = exports.stringify = exports.parse = undefined;
+
+			var _objectpath = __webpack_require__(4);
+
+			var name = function name(key, separator, formName, omitNumbers) {
+			  if (key) {
+			    var fieldKey = key;
+			    var fieldSeparator = separator || '-';
+
+			    if (omitNumbers) {
+			      fieldKey = fieldKey.filter(function (key) {
+			        return typeof key !== 'number';
+			      });
+			    };
+
+			    return (formName ? formName + fieldSeparator : '') + fieldKey.join(fieldSeparator);
+			  };
+
+			  return '';
+			}; // This is of course a bit silly. And should be refactored.
+
+
+			exports.parse = _objectpath.parse;
+			exports.stringify = _objectpath.stringify;
+			exports.normalize = _objectpath.normalize;
+			exports.name = name;
+
+		/***/ },
+		/* 4 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			module.exports = __webpack_require__(5).ObjectPath;
+
+		/***/ },
+		/* 5 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			var __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
+
+			var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; };
+
+			;!function (undefined) {
+
+				var ObjectPath = {
+					parse: function parse(str) {
+						if (typeof str !== 'string') {
+							throw new TypeError('ObjectPath.parse must be passed a string');
+						}
+
+						var i = 0;
+						var parts = [];
+						var d, b, q, c;
+						while (i < str.length) {
+							d = str.indexOf('.', i);
+							b = str.indexOf('[', i);
+
+							// we've reached the end
+							if (d === -1 && b === -1) {
+								parts.push(str.slice(i, str.length));
+								i = str.length;
+							}
+
+							// dots
+							else if (b === -1 || d !== -1 && d < b) {
+									parts.push(str.slice(i, d));
+									i = d + 1;
+								}
+
+								// brackets
+								else {
+										if (b > i) {
+											parts.push(str.slice(i, b));
+											i = b;
+										}
+										q = str.slice(b + 1, b + 2);
+										if (q !== '"' && q !== '\'') {
+											c = str.indexOf(']', b);
+											if (c === -1) c = str.length;
+											parts.push(str.slice(i + 1, c));
+											i = str.slice(c + 1, c + 2) === '.' ? c + 2 : c + 1;
+										} else {
+											c = str.indexOf(q + ']', b);
+											if (c === -1) c = str.length;
+											while (str.slice(c - 1, c) === '\\' && b < str.length) {
+												b++;
+												c = str.indexOf(q + ']', b);
+											}
+											parts.push(str.slice(i + 2, c).replace(new RegExp('\\' + q, 'g'), q));
+											i = str.slice(c + 2, c + 3) === '.' ? c + 3 : c + 2;
+										}
+									}
+						}
+						return parts;
+					},
+
+					// root === true : auto calculate root; must be dot-notation friendly
+					// root String : the string to use as root
+					stringify: function stringify(arr, quote) {
+
+						if (!Array.isArray(arr)) arr = [arr.toString()];
+
+						quote = quote === '"' ? '"' : '\'';
+
+						return arr.map(function (n) {
+							return '[' + quote + n.toString().replace(new RegExp(quote, 'g'), '\\' + quote) + quote + ']';
+						}).join('');
+					},
+
+					normalize: function normalize(data, quote) {
+						return ObjectPath.stringify(Array.isArray(data) ? data : ObjectPath.parse(data), quote);
+					},
+
+					// Angular
+					registerModule: function registerModule(angular) {
+						angular.module('ObjectPath', []).provider('ObjectPath', function () {
+							this.parse = ObjectPath.parse;
+							this.stringify = ObjectPath.stringify;
+							this.normalize = ObjectPath.normalize;
+							this.$get = function () {
+								return ObjectPath;
+							};
+						});
+					}
+				};
+
+				// AMD
+				if (true) {
+					!(__WEBPACK_AMD_DEFINE_RESULT__ = function () {
+						return { ObjectPath: ObjectPath };
+					}.call(exports, __webpack_require__, exports, module), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
+				}
+
+				// CommonJS
+				else if ((typeof exports === 'undefined' ? 'undefined' : _typeof(exports)) === 'object') {
+						exports.ObjectPath = ObjectPath;
+					}
+
+					// Browser global
+					else {
+							window.ObjectPath = ObjectPath;
+						}
+			}();
+
+		/***/ },
+		/* 6 */
+		/***/ function(module, exports) {
+
+			"use strict";
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+
+			var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; }; // Takes a titleMap in either object or list format and returns one in
+			// in the list format.
+
+
+			exports.default = function (titleMap, originalEnum) {
+			  if (!Array.isArray(titleMap)) {
+			    var _ret = function () {
+			      var canonical = [];
+			      if (originalEnum) {
+			        originalEnum.forEach(function (value) {
+			          canonical.push({ name: titleMap[value], value: value });
+			        });
+			      } else {
+			        Object.keys(titleMap).forEach(function (value) {
+			          canonical.push({ name: titleMap[value], value: value });
+			        });
+			      }
+			      return {
+			        v: canonical
+			      };
+			    }();
+
+			    if ((typeof _ret === "undefined" ? "undefined" : _typeof(_ret)) === "object") return _ret.v;
+			  }
+			  return titleMap;
+			};
+
+		/***/ },
+		/* 7 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+			exports.select = select;
+
+			var _sfPath = __webpack_require__(3);
+
+			var _sfPath2 = _interopRequireDefault(_sfPath);
+
+			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+			var numRe = /^\d+$/;
+
+			/**
+			  * @description
+			  * Utility method to access deep properties without
+			  * throwing errors when things are not defined.
+			  * Can also set a value in a deep structure, creating objects when missing
+			  * ex.
+			  * var foo = Select('address.contact.name',obj)
+			  * Select('address.contact.name',obj,'Leeroy')
+			  *
+			  * @param {string} projection A dot path to the property you want to get/set
+			  * @param {object} obj   (optional) The object to project on, defaults to 'this'
+			  * @param {Any}    valueToSet (opional)  The value to set, if parts of the path of
+			  *                 the projection is missing empty objects will be created.
+			  * @returns {Any|undefined} returns the value at the end of the projection path
+			  *                          or undefined if there is none.
+			  */
+			function select(projection, obj, valueToSet) {
+			  if (!obj) {
+			    obj = this;
+			  }
+			  //Support [] array syntax
+			  var parts = typeof projection === 'string' ? _sfPath2.default.parse(projection) : projection;
+
+			  if (typeof valueToSet !== 'undefined' && parts.length === 1) {
+			    //special case, just setting one variable
+			    obj[parts[0]] = valueToSet;
+			    return obj;
+			  }
+
+			  if (typeof valueToSet !== 'undefined' && typeof obj[parts[0]] === 'undefined') {
+			    // We need to look ahead to check if array is appropriate
+			    obj[parts[0]] = parts.length > 2 && numRe.test(parts[1]) ? [] : {};
+			  }
+
+			  var value = obj[parts[0]];
+			  for (var i = 1; i < parts.length; i++) {
+			    // Special case: We allow JSON Form syntax for arrays using empty brackets
+			    // These will of course not work here so we exit if they are found.
+			    if (parts[i] === '') {
+			      return undefined;
+			    }
+			    if (typeof valueToSet !== 'undefined') {
+			      if (i === parts.length - 1) {
+			        //last step. Let's set the value
+			        value[parts[i]] = valueToSet;
+			        return valueToSet;
+			      } else {
+			        // Make sure to create new objects on the way if they are not there.
+			        // We need to look ahead to check if array is appropriate
+			        var tmp = value[parts[i]];
+			        if (typeof tmp === 'undefined' || tmp === null) {
+			          tmp = numRe.test(parts[i + 1]) ? [] : {};
+			          value[parts[i]] = tmp;
+			        }
+			        value = tmp;
+			      }
+			    } else if (value) {
+			      //Just get nex value.
+			      value = value[parts[i]];
+			    }
+			  }
+			  return value;
+			}
+
+		/***/ },
+		/* 8 */
+		/***/ function(module, exports) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+			exports.traverseSchema = traverseSchema;
+			exports.traverseForm = traverseForm;
+			/**
+			 * Traverse a schema, applying a function(schema,path) on every sub schema
+			 * i.e. every property of an object.
+			 */
+			function traverseSchema(schema, fn, path, ignoreArrays) {
+			  ignoreArrays = ignoreArrays === undefined ? true : ignoreArrays;
+
+			  path = path || [];
+
+			  var traverse = function traverse(schema, fn, path) {
+			    fn(schema, path);
+			    if (schema.properties) {
+			      Object.keys(schema.properties).forEach(function (name) {
+			        var currentPath = path.slice();
+			        currentPath.push(name);
+			        traverse(schema.properties[name], fn, currentPath);
+			      });
+			    }
+
+			    //Only support type "array" which have a schema as "items".
+			    if (!ignoreArrays && schema.items) {
+			      var arrPath = path.slice();arrPath.push('');
+			      traverse(schema.items, fn, arrPath);
+			    }
+			  };
+
+			  traverse(schema, fn, path || []);
+			}
+
+			function traverseForm(form, fn) {
+			  fn(form);
+			  if (form.items) {
+			    form.items.forEach(function (f) {
+			      traverseForm(f, fn);
+			    });
+			  }
+
+			  if (form.tabs) {
+			    form.tabs.forEach(function (tab) {
+			      if (tab.items) {
+			        tab.items.forEach(function (f) {
+			          traverseForm(f, fn);
+			        });
+			      }
+			    });
+			  }
+			}
+
+		/***/ },
+		/* 9 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+			exports.validate = validate;
+
+			var _tv = __webpack_require__(10);
+
+			var _tv2 = _interopRequireDefault(_tv);
+
+			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+			/**
+			 * Validate a value against its form definition and schema.
+			 * The value should either be of proper type or a string, some type
+			 * coercion is applied.
+			 *
+			 * @param {Object} form A merged form definition, i.e. one with a schema.
+			 * @param {Any} value the value to validate.
+			 * @return {Object} a tv4js result object.
+			 */
+			function validate(form, value) {
+			  if (!form) {
+			    return { valid: true };
+			  };
+
+			  var schema = form.schema;
+			  if (!schema) {
+			    return { valid: true };
+			  };
+
+			  // Input of type text and textareas will give us a viewValue of ''
+			  // when empty, this is a valid value in a schema and does not count as something
+			  // that breaks validation of 'required'. But for our own sanity an empty field should
+			  // not validate if it's required.
+			  if (value === '') {
+			    value = undefined;
+			  };
+
+			  // Numbers fields will give a null value, which also means empty field
+			  if (form.type === 'number' && value === null) {
+			    value = undefined;
+			  };
+
+			  // Version 4 of JSON Schema has the required property not on the
+			  // property itself but on the wrapping object. Since we like to test
+			  // only this property we wrap it in a fake object.
+			  var wrap = { type: 'object', 'properties': {} };
+			  var propName = form.key[form.key.length - 1];
+			  wrap.properties[propName] = schema;
+
+			  if (form.required) {
+			    wrap.required = [propName];
+			  };
+
+			  var valueWrap = {};
+			  if (!!value) {
+			    valueWrap[propName] = value;
+			  };
+
+			  return _tv2.default.validateResult(valueWrap, wrap);
+			} /*  Common code for validating a value against its form and schema definition */
+			;
+
+		/***/ },
+		/* 10 */
+		/***/ function(module, exports) {
+
+			module.exports = tv4;
+
+		/***/ },
+		/* 11 */
+		/***/ function(module, exports, __webpack_require__) {
+
+			'use strict';
+
+			Object.defineProperty(exports, "__esModule", {
+			  value: true
+			});
+
+			var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; };
+
+			exports.defaultFormDefinition = defaultFormDefinition;
+			exports.stdFormObj = stdFormObj;
+			exports.text = text;
+			exports.number = number;
+			exports.integer = integer;
+			exports.checkbox = checkbox;
+			exports.select = select;
+			exports.checkboxes = checkboxes;
+			exports.fieldset = fieldset;
+			exports.array = array;
+			exports.createDefaults = createDefaults;
+			exports.defaultForm = defaultForm;
+
+			var _sfPath = __webpack_require__(3);
+
+			var _canonicalTitleMap = __webpack_require__(6);
+
+			var _canonicalTitleMap2 = _interopRequireDefault(_canonicalTitleMap);
+
+			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+			/* Utils */
+			var stripNullType = function stripNullType(type) {
+			  if (Array.isArray(type) && type.length == 2) {
+			    if (type[0] === 'null') {
+			      return type[1];
+			    };
+			    if (type[1] === 'null') {
+			      return type[0];
+			    };
+			  };
+			  return type;
+			};
+
+			//Creates an default titleMap list from an enum, i.e. a list of strings.
+			var enumToTitleMap = function enumToTitleMap(enm) {
+			  var titleMap = []; //canonical titleMap format is a list.
+			  enm.forEach(function (name) {
+			    titleMap.push({ name: name, value: name });
+			  });
+			  return titleMap;
+			};
+
+			/**
+			 * Creates a default form definition from a schema.
+			 */
+			function defaultFormDefinition(schemaTypes, name, schema, options) {
+			  var rules = schemaTypes[stripNullType(schema.type)];
+			  if (rules) {
+			    var def = void 0;
+			    // We give each rule a possibility to recurse it's children.
+			    var innerDefaultFormDefinition = function innerDefaultFormDefinition(childName, childSchema, childOptions) {
+			      return defaultFormDefinition(schemaTypes, childName, childSchema, childOptions);
+			    };
+			    for (var i = 0; i < rules.length; i++) {
+			      def = rules[i](name, schema, options, innerDefaultFormDefinition);
+
+			      //first handler in list that actually returns something is our handler!
+			      if (def) {
+
+			        // Do we have form defaults in the schema under the x-schema-form-attribute?
+			        if (def.schema['x-schema-form']) {
+			          Object.assign(def, def.schema['x-schema-form']);
+			        }
+
+			        return def;
+			      }
+			    }
+			  }
+			}
+
+			/**
+			 * Creates a form object with all common properties
+			 */
+			function stdFormObj(name, schema, options) {
+			  options = options || {};
+
+			  // The Object.assign used to be a angular.copy. Should work though.
+			  var f = options.global && options.global.formDefaults ? Object.assign({}, options.global.formDefaults) : {};
+			  if (options.global && options.global.supressPropertyTitles === true) {
+			    f.title = schema.title;
+			  } else {
+			    f.title = schema.title || name;
+			  }
+
+			  if (schema.description) {
+			    f.description = schema.description;
+			  }
+			  if (options.required === true || schema.required === true) {
+			    f.required = true;
+			  }
+			  if (schema.maxLength) {
+			    f.maxlength = schema.maxLength;
+			  }
+			  if (schema.minLength) {
+			    f.minlength = schema.minLength;
+			  }
+			  if (schema.readOnly || schema.readonly) {
+			    f.readonly = true;
+			  }
+			  if (schema.minimum) {
+			    f.minimum = schema.minimum + (schema.exclusiveMinimum ? 1 : 0);
+			  }
+			  if (schema.maximum) {
+			    f.maximum = schema.maximum - (schema.exclusiveMaximum ? 1 : 0);
+			  }
+
+			  // Non standard attributes (DONT USE DEPRECATED)
+			  // If you must set stuff like this in the schema use the x-schema-form attribute
+			  if (schema.validationMessage) {
+			    f.validationMessage = schema.validationMessage;
+			  }
+			  if (schema.enumNames) {
+			    f.titleMap = (0, _canonicalTitleMap2.default)(schema.enumNames, schema['enum']);
+			  }
+			  f.schema = schema;
+
+			  // Ng model options doesn't play nice with undefined, might be defined
+			  // globally though
+			  f.ngModelOptions = f.ngModelOptions || {};
+
+			  return f;
+			};
+
+			/*** Schema types to form type mappings, with defaults ***/
+			function text(name, schema, options) {
+			  if (stripNullType(schema.type) === 'string' && !schema['enum']) {
+			    var f = stdFormObj(name, schema, options);
+			    f.key = options.path;
+			    f.type = 'text';
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+			    return f;
+			  }
+			}
+
+			//default in json form for number and integer is a text field
+			//input type="number" would be more suitable don't ya think?
+			function number(name, schema, options) {
+			  if (stripNullType(schema.type) === 'number') {
+			    var f = stdFormObj(name, schema, options);
+			    f.key = options.path;
+			    f.type = 'number';
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+			    return f;
+			  }
+			}
+
+			function integer(name, schema, options) {
+			  if (stripNullType(schema.type) === 'integer') {
+			    var f = stdFormObj(name, schema, options);
+			    f.key = options.path;
+			    f.type = 'number';
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+			    return f;
+			  }
+			}
+
+			function checkbox(name, schema, options) {
+			  if (stripNullType(schema.type) === 'boolean') {
+			    var f = stdFormObj(name, schema, options);
+			    f.key = options.path;
+			    f.type = 'checkbox';
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+			    return f;
+			  }
+			}
+
+			function select(name, schema, options) {
+			  if (stripNullType(schema.type) === 'string' && schema['enum']) {
+			    var f = stdFormObj(name, schema, options);
+			    f.key = options.path;
+			    f.type = 'select';
+			    if (!f.titleMap) {
+			      f.titleMap = enumToTitleMap(schema['enum']);
+			    }
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+			    return f;
+			  }
+			}
+
+			function checkboxes(name, schema, options) {
+			  if (stripNullType(schema.type) === 'array' && schema.items && schema.items['enum']) {
+			    var f = stdFormObj(name, schema, options);
+			    f.key = options.path;
+			    f.type = 'checkboxes';
+			    if (!f.titleMap) {
+			      f.titleMap = enumToTitleMap(schema.items['enum']);
+			    }
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+			    return f;
+			  }
+			}
+
+			function fieldset(name, schema, options, defaultFormDef) {
+			  if (stripNullType(schema.type) === 'object') {
+			    var _ret = function () {
+			      var f = stdFormObj(name, schema, options);
+			      f.type = 'fieldset';
+			      f.key = options.path;
+			      f.items = [];
+			      options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+
+			      //recurse down into properties
+			      if (schema.properties) {
+			        Object.keys(schema.properties).forEach(function (key) {
+			          var value = schema.properties[key];
+			          var path = options.path.slice();
+			          path.push(key);
+			          if (options.ignore[(0, _sfPath.stringify)(path)] !== true) {
+			            var required = schema.required && schema.required.indexOf(key) !== -1;
+
+			            var def = defaultFormDef(key, value, {
+			              path: path,
+			              required: required || false,
+			              lookup: options.lookup,
+			              ignore: options.ignore,
+			              global: options.global
+			            });
+			            if (def) {
+			              f.items.push(def);
+			            }
+			          }
+			        });
+			      }
+			      return {
+			        v: f
+			      };
+			    }();
+
+			    if ((typeof _ret === 'undefined' ? 'undefined' : _typeof(_ret)) === "object") return _ret.v;
+			  }
+			}
+
+			function array(name, schema, options, defaultFormDef) {
+			  if (stripNullType(schema.type) === 'array') {
+			    var f = stdFormObj(name, schema, options);
+			    f.type = 'array';
+			    f.key = options.path;
+			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
+
+			    var required = schema.required && schema.required.indexOf(options.path[options.path.length - 1]) !== -1;
+
+			    // The default is to always just create one child. This works since if the
+			    // schemas items declaration is of type: "object" then we get a fieldset.
+			    // We also follow json form notatation, adding empty brackets "[]" to
+			    // signify arrays.
+
+			    var arrPath = options.path.slice();
+			    arrPath.push('');
+
+			    f.items = [defaultFormDef(name, schema.items, {
+			      path: arrPath,
+			      required: required || false,
+			      lookup: options.lookup,
+			      ignore: options.ignore,
+			      global: options.global
+			    })];
+
+			    return f;
+			  }
+			}
+
+			function createDefaults() {
+			  //First sorted by schema type then a list.
+			  //Order has importance. First handler returning an form snippet will be used.
+			  return {
+			    string: [select, text],
+			    object: [fieldset],
+			    number: [number],
+			    integer: [integer],
+			    boolean: [checkbox],
+			    array: [checkboxes, array]
+			  };
+			};
+
+			/**
+			 * Create form defaults from schema
+			 */
+			function defaultForm(schema, defaultSchemaTypes, ignore, globalOptions) {
+			  var form = [];
+			  var lookup = {}; //Map path => form obj for fast lookup in merging
+			  ignore = ignore || {};
+			  globalOptions = globalOptions || {};
+			  defaultSchemaTypes = defaultSchemaTypes || createDefaults();
+
+			  if (schema.properties) {
+			    Object.keys(schema.properties).forEach(function (key) {
+			      if (ignore[key] !== true) {
+			        var required = schema.required && schema.required.indexOf(key) !== -1;
+			        var def = defaultFormDefinition(defaultSchemaTypes, key, schema.properties[key], {
+			          path: [key], // Path to this property in bracket notation.
+			          lookup: lookup, // Extra map to register with. Optimization for merger.
+			          ignore: ignore, // The ignore list of paths (sans root level name)
+			          required: required, // Is it required? (v4 json schema style)
+			          global: globalOptions // Global options, including form defaults
+			        });
+			        if (def) {
+			          form.push(def);
+			        }
+			      }
+			    });
+			  } else {
+			    throw new Error('Not implemented. Only type "object" allowed at root level of schema.');
+			  }
+			  return { form: form, lookup: lookup };
+			}
+
+		/***/ }
+		/******/ ])
+		});
+		;
+
+	/***/ },
+	/* 7 */
+	/***/ function(module, exports) {
+
+		module.exports = tv4;
+
+	/***/ },
+	/* 8 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function () {
+		  var validator = {};
+
+		  /**
+		   * Validate a value against its form definition and schema.
+		   * The value should either be of proper type or a string, some type
+		   * coercion is applied.
+		   *
+		   * @param {Object} form A merged form definition, i.e. one with a schema.
+		   * @param {Any} value the value to validate.
+		   * @return {Object} a tv4js result object.
+		   */
+		  validator.validate = function (form, value) {
+		    if (!form) {
+		      return { valid: true };
+		    };
+
+		    var schema = form.schema;
+		    if (!schema) {
+		      return { valid: true };
+		    };
+
+		    // Input of type text and textareas will give us a viewValue of ''
+		    // when empty, this is a valid value in a schema and does not count as something
+		    // that breaks validation of 'required'. But for our own sanity an empty field should
+		    // not validate if it's required.
+		    if (value === '') {
+		      value = undefined;
+		    };
+
+		    // Numbers fields will give a null value, which also means empty field
+		    if (form.type === 'number' && value === null) {
+		      value = undefined;
+		    };
+
+		    // Version 4 of JSON Schema has the required property not on the
+		    // property itself but on the wrapping object. Since we like to test
+		    // only this property we wrap it in a fake object.
+		    var wrap = { type: 'object', 'properties': {} };
+		    var propName = form.key[form.key.length - 1];
+		    wrap.properties[propName] = schema;
+
+		    if (form.required) {
+		      wrap.required = [propName];
+		    };
+
+		    var valueWrap = {};
+		    if (_angular2.default.isDefined(value)) {
+		      valueWrap[propName] = value;
+		    };
+
+		    return _tv2.default.validateResult(valueWrap, wrap);
+		  };
+
+		  return validator;
+		};
+
+		var _tv = __webpack_require__(7);
+
+		var _tv2 = _interopRequireDefault(_tv);
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 9 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function () {
+
+		  // The codes are tv4 error codes.
+		  // Not all of these can actually happen in a field, but for
+		  // we never know when one might pop up so it's best to cover them all.
+
+		  // TODO: Humanize these.
+		  var defaultMessages = {
+		    'default': 'Field does not validate',
+		    0: 'Invalid type, expected {{schema.type}}',
+		    1: 'No enum match for: {{viewValue}}',
+		    10: 'Data does not match any schemas from "anyOf"',
+		    11: 'Data does not match any schemas from "oneOf"',
+		    12: 'Data is valid against more than one schema from "oneOf"',
+		    13: 'Data matches schema from "not"',
+		    // Numeric errors
+		    100: 'Value is not a multiple of {{schema.multipleOf}}',
+		    101: '{{viewValue}} is less than the allowed minimum of {{schema.minimum}}',
+		    102: '{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}',
+		    103: '{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}',
+		    104: '{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}',
+		    105: 'Value is not a valid number',
+		    // String errors
+		    200: 'String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}',
+		    201: 'String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}',
+		    202: 'String does not match pattern: {{schema.pattern}}',
+		    // Object errors
+		    300: 'Too few properties defined, minimum {{schema.minProperties}}',
+		    301: 'Too many properties defined, maximum {{schema.maxProperties}}',
+		    302: 'Required',
+		    303: 'Additional properties not allowed',
+		    304: 'Dependency failed - key must exist',
+		    // Array errors
+		    400: 'Array is too short ({{value.length}}), minimum {{schema.minItems}}',
+		    401: 'Array is too long ({{value.length}}), maximum {{schema.maxItems}}',
+		    402: 'Array items are not unique',
+		    403: 'Additional items not allowed',
+		    // Format errors
+		    500: 'Format validation failed',
+		    501: 'Keyword failed: "{{title}}"',
+		    // Schema structure
+		    600: 'Circular $refs',
+		    // Non-standard validation options
+		    1000: 'Unknown property (not in schema)'
+		  };
+
+		  // In some cases we get hit with an angular validation error
+		  defaultMessages.number = defaultMessages[105];
+		  defaultMessages.required = defaultMessages[302];
+		  defaultMessages.min = defaultMessages[101];
+		  defaultMessages.max = defaultMessages[103];
+		  defaultMessages.maxlength = defaultMessages[201];
+		  defaultMessages.minlength = defaultMessages[200];
+		  defaultMessages.pattern = defaultMessages[202];
+
+		  this.setDefaultMessages = function (messages) {
+		    defaultMessages = messages;
+		  };
+
+		  this.getDefaultMessages = function () {
+		    return defaultMessages;
+		  };
+
+		  this.setDefaultMessage = function (error, msg) {
+		    defaultMessages[error] = msg;
+		  };
+
+		  this.$get = ['$interpolate', function ($interpolate) {
+
+		    var service = {};
+		    service.defaultMessages = defaultMessages;
+
+		    /**
+		     * Interpolate and return proper error for an eror code.
+		     * Validation message on form trumps global error messages.
+		     * and if the message is a function instead of a string that function will be called instead.
+		     *
+		     * @param {string} error the error code, i.e. tv4-xxx for tv4 errors, otherwise it's whats on
+		     *                       ngModel.$error for custom errors.
+		     * @param {Any} value the actual model value.
+		     * @param {Any} viewValue the viewValue
+		     * @param {Object} form a form definition object for this field
+		     * @param  {Object} global the global validation messages object (even though its called global
+		     *                         its actually just shared in one instance of sf-schema)
+		     * @return {string} The error message.
+		     */
+		    service.interpolate = function (error, value, viewValue, form, global) {
+		      global = global || {};
+		      var validationMessage = form.validationMessage || {};
+
+		      // Drop tv4 prefix so only the code is left.
+		      if (error.indexOf('tv4-') === 0) {
+		        error = error.substring(4);
+		      }
+
+		      // First find apropriate message or function
+		      var message = validationMessage['default'] || global['default'] || '';
+
+		      [validationMessage, global, defaultMessages].some(function (val) {
+		        if (_angular2.default.isString(val) || _angular2.default.isFunction(val)) {
+		          message = val;
+		          return true;
+		        }
+		        if (val && val[error]) {
+		          message = val[error];
+		          return true;
+		        }
+		      });
+
+		      var context = {
+		        error: error,
+		        value: value,
+		        viewValue: viewValue,
+		        form: form,
+		        schema: form.schema,
+		        title: form.title || form.schema && form.schema.title
+		      };
+		      if (_angular2.default.isFunction(message)) {
+		        return message(context);
+		      } else {
+		        return $interpolate(message)(context);
+		      }
+		    };
+
+		    return service;
+		  }];
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 10 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function () {
+		  // expose the methods in sfPathProvider
+		  this.parse = _jsonSchemaFormCore.sfPath.parse;
+		  this.stringify = _jsonSchemaFormCore.sfPath.stringify;
+		  this.normalize = _jsonSchemaFormCore.sfPath.normalize;
+
+		  this.$get = function () {
+		    return _jsonSchemaFormCore.sfPath;
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		var _jsonSchemaFormCore = __webpack_require__(6);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 11 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function (sfSelect, schemaForm, sfValidator, sfPath) {
+
+		  var setIndex = function setIndex(index) {
+		    return function (form) {
+		      if (form.key) {
+		        form.key[form.key.indexOf('')] = index;
+		      }
+		    };
+		  };
+
+		  return {
+		    restrict: 'A',
+		    scope: true,
+		    require: '?ngModel',
+		    link: function link(scope, element, attrs, ngModel) {
+		      var formDefCache = {};
+
+		      scope.validateArray = _angular2.default.noop;
+
+		      if (ngModel) {
+		        // We need the ngModelController on several places,
+		        // most notably for errors.
+		        // So we emit it up to the decorator directive so it can put it on scope.
+		        scope.$emit('schemaFormPropagateNgModelController', ngModel);
+		      };
+
+		      // Watch for the form definition and then rewrite it.
+		      // It's the (first) array part of the key, '[]' that needs a number
+		      // corresponding to an index of the form.
+		      var once = scope.$watch(attrs.sfArray, function (form) {
+		        if (!form) {
+		          return;
+		        };
+
+		        // An array model always needs a key so we know what part of the model
+		        // to look at. This makes us a bit incompatible with JSON Form, on the
+		        // other hand it enables two way binding.
+		        var list = sfSelect(form.key, scope.model);
+
+		        // We only modify the same array instance but someone might change the array from
+		        // the outside so let's watch for that. We use an ordinary watch since the only case
+		        // we're really interested in is if its a new instance.
+		        var key = sfPath.normalize(form.key);
+		        scope.$watch('model' + (key[0] !== '[' ? '.' : '') + key, function (value) {
+		          list = scope.modelArray = value;
+		        });
+
+		        // Since ng-model happily creates objects in a deep path when setting a
+		        // a value but not arrays we need to create the array.
+		        if (_angular2.default.isUndefined(list)) {
+		          list = [];
+		          sfSelect(form.key, scope.model, list);
+		        }
+		        scope.modelArray = list;
+
+		        // Arrays with titleMaps, i.e. checkboxes doesn't have items.
+		        if (form.items) {
+
+		          // To be more compatible with JSON Form we support an array of items
+		          // in the form definition of "array" (the schema just a value).
+		          // for the subforms code to work this means we wrap everything in a
+		          // section. Unless there is just one.
+		          var subForm = form.items[0];
+		          if (form.items.length > 1) {
+		            subForm = {
+		              type: 'section',
+		              items: form.items.map(function (item) {
+		                item.ngModelOptions = form.ngModelOptions;
+		                if (_angular2.default.isUndefined(item.readonly)) {
+		                  item.readonly = form.readonly;
+		                }
+		                return item;
+		              })
+		            };
+		          }
+		        }
+
+		        // We ceate copies of the form on demand, caching them for
+		        // later requests
+		        scope.copyWithIndex = function (index) {
+		          if (!formDefCache[index]) {
+		            if (subForm) {
+		              var copy = _angular2.default.copy(subForm);
+		              copy.arrayIndex = index;
+		              schemaForm.traverseForm(copy, setIndex(index));
+		              formDefCache[index] = copy;
+		            }
+		          }
+		          return formDefCache[index];
+		        };
+
+		        scope.appendToArray = function () {
+		          var len = list.length;
+		          var copy = scope.copyWithIndex(len);
+		          schemaForm.traverseForm(copy, function (part) {
+
+		            if (part.key) {
+		              var def;
+		              if (_angular2.default.isDefined(part['default'])) {
+		                def = part['default'];
+		              }
+		              if (_angular2.default.isDefined(part.schema) && _angular2.default.isDefined(part.schema['default'])) {
+		                def = part.schema['default'];
+		              }
+
+		              if (_angular2.default.isDefined(def)) {
+		                sfSelect(part.key, scope.model, def);
+		              }
+		            }
+		          });
+
+		          // If there are no defaults nothing is added so we need to initialize
+		          // the array. undefined for basic values, {} or [] for the others.
+		          if (len === list.length) {
+		            var type = sfSelect('schema.items.type', form);
+		            var dflt;
+		            if (type === 'object') {
+		              dflt = {};
+		            } else if (type === 'array') {
+		              dflt = [];
+		            }
+		            list.push(dflt);
+		          }
+
+		          // Trigger validation.
+		          scope.validateArray();
+		          return list;
+		        };
+
+		        scope.deleteFromArray = function (index) {
+		          list.splice(index, 1);
+
+		          // Trigger validation.
+		          scope.validateArray();
+
+		          // Angular 1.2 lacks setDirty
+		          if (ngModel && ngModel.$setDirty) {
+		            ngModel.$setDirty();
+		          }
+		          return list;
+		        };
+
+		        // Always start with one empty form unless configured otherwise.
+		        // Special case: don't do it if form has a titleMap
+		        if (!form.titleMap && form.startEmpty !== true && list.length === 0) {
+		          scope.appendToArray();
+		        }
+
+		        // Title Map handling
+		        // If form has a titleMap configured we'd like to enable looping over
+		        // titleMap instead of modelArray, this is used for intance in
+		        // checkboxes. So instead of variable number of things we like to create
+		        // a array value from a subset of values in the titleMap.
+		        // The problem here is that ng-model on a checkbox doesn't really map to
+		        // a list of values. This is here to fix that.
+		        if (form.titleMap && form.titleMap.length > 0) {
+		          scope.titleMapValues = [];
+
+		          // We watch the model for changes and the titleMapValues to reflect
+		          // the modelArray
+		          var updateTitleMapValues = function updateTitleMapValues(arr) {
+		            scope.titleMapValues = [];
+		            arr = arr || [];
+
+		            form.titleMap.forEach(function (item) {
+		              scope.titleMapValues.push(arr.indexOf(item.value) !== -1);
+		            });
+		          };
+		          //Catch default values
+		          updateTitleMapValues(scope.modelArray);
+		          scope.$watchCollection('modelArray', updateTitleMapValues);
+
+		          //To get two way binding we also watch our titleMapValues
+		          scope.$watchCollection('titleMapValues', function (vals, old) {
+		            if (vals && vals !== old) {
+		              var arr = scope.modelArray;
+
+		              // Apparently the fastest way to clear an array, readable too.
+		              // http://jsperf.com/array-destroy/32
+		              while (arr.length > 0) {
+		                arr.pop();
+		              }
+		              form.titleMap.forEach(function (item, index) {
+		                if (vals[index]) {
+		                  arr.push(item.value);
+		                }
+		              });
+
+		              // Time to validate the rebuilt array.
+		              scope.validateArray();
+		            }
+		          });
+		        }
+
+		        // If there is a ngModel present we need to validate when asked.
+		        if (ngModel) {
+		          var error;
+
+		          scope.validateArray = function () {
+		            // The actual content of the array is validated by each field
+		            // so we settle for checking validations specific to arrays
+
+		            // Since we prefill with empty arrays we can get the funny situation
+		            // where the array is required but empty in the gui but still validates.
+		            // Thats why we check the length.
+		            var result = sfValidator.validate(form, scope.modelArray.length > 0 ? scope.modelArray : undefined);
+
+		            // TODO: DRY this up, it has a lot of similarities with schema-validate
+		            // Since we might have different tv4 errors we must clear all
+		            // errors that start with tv4-
+		            Object.keys(ngModel.$error).filter(function (k) {
+		              return k.indexOf('tv4-') === 0;
+		            }).forEach(function (k) {
+		              ngModel.$setValidity(k, true);
+		            });
+
+		            if (result.valid === false && result.error && (result.error.dataPath === '' || result.error.dataPath === '/' + form.key[form.key.length - 1])) {
+
+		              // Set viewValue to trigger $dirty on field. If someone knows a
+		              // a better way to do it please tell.
+		              ngModel.$setViewValue(scope.modelArray);
+		              error = result.error;
+		              ngModel.$setValidity('tv4-' + result.error.code, false);
+		            }
+		          };
+
+		          scope.$on('schemaFormValidate', scope.validateArray);
+
+		          scope.hasSuccess = function () {
+		            if (scope.options && scope.options.pristine && scope.options.pristine.success === false) {
+		              return ngModel.$valid && !ngModel.$pristine && !ngModel.$isEmpty(ngModel.$modelValue);
+		            } else {
+		              return ngModel.$valid && (!ngModel.$pristine || !ngModel.$isEmpty(ngModel.$modelValue));
+		            }
+		          };
+
+		          scope.hasError = function () {
+		            if (!scope.options || !scope.options.pristine || scope.options.pristine.errors !== false) {
+		              // Show errors in pristine forms. The default.
+		              // Note that "validateOnRender" option defaults to *not* validate initial form.
+		              // so as a default there won't be any error anyway, but if the model is modified
+		              // from the outside the error will show even if the field is pristine.
+		              return ngModel.$invalid;
+		            } else {
+		              // Don't show errors in pristine forms.
+		              return ngModel.$invalid && !ngModel.$pristine;
+		            }
+		          };
+
+		          scope.schemaError = function () {
+		            return error;
+		          };
+		        }
+
+		        once();
+		      });
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 12 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function () {
+		  return {
+		    require: 'ngModel',
+		    restrict: 'AC',
+		    scope: false,
+		    link: function link(scope, element, attrs, ctrl) {
+		      var form = scope.$eval(attrs.sfChanged);
+		      //"form" is really guaranteed to be here since the decorator directive
+		      //waits for it. But best be sure.
+		      if (form && form.onChange) {
+		        ctrl.$viewChangeListeners.push(function () {
+		          if (_angular2.default.isFunction(form.onChange)) {
+		            form.onChange(ctrl.$modelValue, form);
+		          } else {
+		            scope.evalExpr(form.onChange, { 'modelValue': ctrl.$modelValue, form: form });
+		          }
+		        });
+		      }
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 13 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; };
+
+		exports.default = function ($parse, $compile, $http, $templateCache, $interpolate, $q, sfErrorMessage, sfPath, sfSelect) {
+
+		  var keyFormat = {
+		    COMPLETE: '*',
+		    PATH: 'string',
+		    INDICES: 'number'
+		  };
+
+		  return {
+		    restrict: 'AE',
+		    replace: false,
+		    transclude: false,
+		    scope: true,
+		    require: ['^sfSchema', '?^form', '?^^sfKeyController'],
+		    link: {
+		      pre: function pre(scope, element, attrs, ctrl) {
+		        var sfSchema = ctrl[0];
+		        var formCtrl = ctrl[1];
+		        var keyCtrl = ctrl[2];
+
+		        //The ngModelController is used in some templates and
+		        //is needed for error messages,
+		        scope.$on('schemaFormPropagateNgModelController', function (event, ngModel) {
+		          event.stopPropagation();
+		          event.preventDefault();
+		          scope.ngModel = ngModel;
+		        });
+
+		        // Fetch our form.
+		        scope.form = sfSchema.lookup['f' + attrs.sfField];
+		      },
+		      post: function post(scope, element, attrs, ctrl) {
+		        var sfSchema = ctrl[0];
+		        var formCtrl = ctrl[1];
+		        var keyCtrl = ctrl[2];
+
+		        //Keep error prone logic from the template
+		        scope.showTitle = function () {
+		          return scope.form && scope.form.notitle !== true && scope.form.title;
+		        };
+
+		        scope.getKey = function (requiredFormat) {
+		          var format = requiredFormat || keyFormat.COMPLETE;
+		          var key = scope.parentKey ? scope.parentKey.slice(0, scope.parentKey.length - 1) : [];
+
+		          if (typeof scope.$index === 'number') {
+		            key = key.concat(scope.$index);
+		          };
+
+		          if (scope.form.key && scope.form.key.length) {
+		            if (typeof key[key.length - 1] === 'number' && scope.form.key.length >= 1) {
+		              scope.completeKey = key.concat(scope.form.key.slice(-1));
+		            } else {
+		              scope.completeKey = scope.form.key.slice();
+		            };
+		          };
+
+		          if (!Array.isArray(scope.completeKey)) {
+		            return undefined;
+		          };
+
+		          if (format === keyFormat.COMPLETE) {
+		            return scope.completeKey;
+		          };
+
+		          return scope.completeKey.reduce(function (output, input, i) {
+		            if (-1 !== [format].indexOf(typeof input === 'undefined' ? 'undefined' : _typeof(input))) {
+		              return output.concat(input);
+		            }
+		            return output;
+		          }, []);
+		        };
+		        if (scope.form.key) scope.completeKey = scope.getKey();
+
+		        scope.path = function (modelPath) {
+		          var i = -1;
+		          modelPath = modelPath.replace(/\[\]/gi, function (matched) {
+		            i++;
+		            return scope.$i[i];
+		          });
+		          return scope.$eval(modelPath, scope);
+		        };
+
+		        //Normalise names and ids
+		        scope.fieldId = function (prependFormName, omitArrayIndexes) {
+		          var formName = prependFormName && formCtrl && formCtrl.$name ? formCtrl.$name : undefined;
+		          var key = scope.getKey();
+
+		          if (Array.isArray(key)) {
+		            return sfPath.name(key, '-', formName, omitArrayIndexes);
+		          } else {
+		            return '';
+		          };
+		        };
+
+		        scope.listToCheckboxValues = function (list) {
+		          var values = {};
+		          _angular2.default.forEach(list, function (v) {
+		            values[v] = true;
+		          });
+		          return values;
+		        };
+
+		        scope.checkboxValuesToList = function (values) {
+		          var lst = [];
+		          _angular2.default.forEach(values, function (v, k) {
+		            if (v) {
+		              lst.push(k);
+		            }
+		          });
+		          return lst;
+		        };
+
+		        scope.buttonClick = function ($event, form) {
+		          if (_angular2.default.isFunction(form.onClick)) {
+		            form.onClick($event, form);
+		          } else if (_angular2.default.isString(form.onClick)) {
+		            if (sfSchema) {
+		              //evaluating in scope outside of sfSchemas isolated scope
+		              sfSchema.evalInParentScope(form.onClick, { '$event': $event, form: form });
+		            } else {
+		              scope.$eval(form.onClick, { '$event': $event, form: form });
+		            }
+		          }
+		        };
+
+		        /**
+		         * Evaluate an expression, i.e. scope.$eval
+		         * but do it in sfSchemas parent scope sf-schema directive is used
+		         *
+		         * @param {string} expression
+		         * @param {Object} locals (optional)
+		         * @return {Any} the result of the expression
+		         */
+		        scope.evalExpr = function (expression, locals) {
+		          if (sfSchema) {
+		            //evaluating in scope outside of sfSchemas isolated scope
+		            return sfSchema.evalInParentScope(expression, locals);
+		          }
+
+		          return scope.$eval(expression, locals);
+		        };
+
+		        /**
+		         * Evaluate an expression, i.e. scope.$eval
+		         * in this decorators scope
+		         *
+		         * @param {string} expression
+		         * @param {Object} locals (optional)
+		         * @return {Any} the result of the expression
+		         */
+		        scope.evalInScope = function (expression, locals) {
+		          if (expression) {
+		            return scope.$eval(expression, locals);
+		          }
+		        };
+
+		        /**
+		         * Interpolate the expression.
+		         * Similar to `evalExpr()` and `evalInScope()`
+		         * but will not fail if the expression is
+		         * text that contains spaces.
+		         *
+		         * Use the Angular `{{ interpolation }}`
+		         * braces to access properties on `locals`.
+		         *
+		         * @param  {string} expression The string to interpolate.
+		         * @param  {Object} locals (optional) Properties that may be accessed in the
+		         *                         `expression` string.
+		         * @return {Any} The result of the expression or `undefined`.
+		         */
+		        scope.interp = function (expression, locals) {
+		          return expression && $interpolate(expression)(locals);
+		        };
+
+		        //This works since we get the ngModel from the array or the schema-validate directive.
+		        scope.hasSuccess = function () {
+		          if (!scope.ngModel) {
+		            return false;
+		          }
+		          if (scope.options && scope.options.pristine && scope.options.pristine.success === false) {
+		            return scope.ngModel.$valid && !scope.ngModel.$pristine && !scope.ngModel.$isEmpty(scope.ngModel.$modelValue);
+		          } else {
+		            return scope.ngModel.$valid && (!scope.ngModel.$pristine || !scope.ngModel.$isEmpty(scope.ngModel.$modelValue));
+		          }
+		        };
+
+		        scope.hasError = function () {
+		          if (!scope.ngModel) {
+		            return false;
+		          }
+		          if (!scope.options || !scope.options.pristine || scope.options.pristine.errors !== false) {
+		            // Show errors in pristine forms. The default.
+		            // Note that "validateOnRender" option defaults to *not* validate initial form.
+		            // so as a default there won't be any error anyway, but if the model is modified
+		            // from the outside the error will show even if the field is pristine.
+		            return scope.ngModel.$invalid;
+		          } else {
+		            // Don't show errors in pristine forms.
+		            return scope.ngModel.$invalid && !scope.ngModel.$pristine;
+		          }
+		        };
+
+		        /**
+		         * DEPRECATED: use sf-messages instead.
+		         * Error message handler
+		         * An error can either be a schema validation message or a angular js validtion
+		         * error (i.e. required)
+		         */
+		        scope.errorMessage = function (schemaError) {
+		          return sfErrorMessage.interpolate(schemaError && schemaError.code + '' || 'default', scope.ngModel && scope.ngModel.$modelValue || '', scope.ngModel && scope.ngModel.$viewValue || '', scope.form, scope.options && scope.options.validationMessage);
+		        };
+
+		        // append the field-id to the htmlClass
+		        scope.form.htmlClass = scope.form.htmlClass || '';
+		        scope.form.htmlClass += (scope.form.htmlClass ? ' ' : '') + scope.fieldId(false, true);
+
+		        var form = scope.form;
+
+		        // Where there is a key there is probably a ngModel
+		        if (form.key) {
+		          // It looks better with dot notation.
+		          scope.$on('schemaForm.error.' + form.key.join('.'), function (event, error, validationMessage, validity, formName) {
+		            // validationMessage and validity are mutually exclusive
+		            formName = validity;
+		            if (validationMessage === true || validationMessage === false) {
+		              validity = validationMessage;
+		              validationMessage = undefined;
+		            };
+
+		            // If we have specified a form name, and this model is not within
+		            // that form, then leave things be.
+		            if (formName != undefined && scope.ngModel.$$parentForm.$name !== formName) {
+		              return;
+		            };
+
+		            if (scope.ngModel && error) {
+		              if (scope.ngModel.$setDirty) {
+		                scope.ngModel.$setDirty();
+		              } else {
+		                // FIXME: Check that this actually works on 1.2
+		                scope.ngModel.$dirty = true;
+		                scope.ngModel.$pristine = false;
+		              }
+
+		              // Set the new validation message if one is supplied
+		              // Does not work when validationMessage is just a string.
+		              if (validationMessage) {
+		                if (!form.validationMessage) {
+		                  form.validationMessage = {};
+		                }
+		                form.validationMessage[error] = validationMessage;
+		              }
+
+		              scope.ngModel.$setValidity(error, validity === true);
+
+		              if (validity === true) {
+		                // Re-trigger model validator, that model itself would be re-validated
+		                scope.ngModel.$validate();
+
+		                // Setting or removing a validity can change the field to believe its valid
+		                // but its not. So lets trigger its validation as well.
+		                scope.$broadcast('schemaFormValidate');
+		              }
+		            }
+		          });
+
+		          // Clean up the model when the corresponding form field is $destroy-ed.
+		          // Default behavior can be supplied as a globalOption, and behavior can be overridden
+		          // in the form definition.
+		          scope.$on('$destroy', function () {
+		            var key = scope.getKey();
+
+		            // If the entire schema form is destroyed we don't touch the model
+		            if (!scope.externalDestructionInProgress) {
+		              var destroyStrategy = form.destroyStrategy || scope.options && scope.options.destroyStrategy || 'remove';
+		              // No key no model, and we might have strategy 'retain'
+		              if (key && destroyStrategy !== 'retain') {
+
+		                // Get the object that has the property we wan't to clear.
+		                var obj = scope.model;
+		                if (key.length > 1) {
+		                  obj = sfSelect(key.slice(0, key.length - 1), obj);
+		                }
+
+		                // We can get undefined here if the form hasn't been filled out entirely
+		                if (obj === undefined) {
+		                  return;
+		                }
+
+		                // Type can also be a list in JSON Schema
+		                var type = form.schema && form.schema.type || '';
+
+		                // Empty means '',{} and [] for appropriate types and undefined for the rest
+		                //console.log('destroy', destroyStrategy, key, type, obj);
+		                if (destroyStrategy === 'empty' && type.indexOf('string') !== -1) {
+		                  obj[key.slice(-1)] = '';
+		                } else if (destroyStrategy === 'empty' && type.indexOf('object') !== -1) {
+		                  obj[key.slice(-1)] = {};
+		                } else if (destroyStrategy === 'empty' && type.indexOf('array') !== -1) {
+		                  obj[key.slice(-1)] = [];
+		                } else if (destroyStrategy === 'null') {
+		                  obj[key.slice(-1)] = null;
+		                } else {
+		                  delete obj[key.slice(-1)];
+		                }
+		              }
+		            }
+		          });
+		        }
+		      }
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 14 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function ($injector, sfErrorMessage) {
+
+		  //Inject sanitizer if it exists
+		  var $sanitize = $injector.has('$sanitize') ? $injector.get('$sanitize') : function (html) {
+		    return html;
+		  };
+
+		  return {
+		    scope: false,
+		    restrict: 'EA',
+		    link: function link(scope, element, attrs) {
+
+		      var message = '';
+		      if (attrs.sfMessage) {
+		        scope.$watch(attrs.sfMessage, function (msg) {
+		          if (msg) {
+		            message = $sanitize(msg);
+		            update(!!scope.ngModel);
+		          }
+		        });
+		      }
+
+		      var currentMessage;
+		      // Only call html() if needed.
+		      var setMessage = function setMessage(msg) {
+		        if (msg !== currentMessage) {
+		          element.html(msg);
+		          currentMessage = msg;
+		        }
+		      };
+
+		      var update = function update(checkForErrors) {
+		        if (checkForErrors) {
+		          if (!scope.hasError()) {
+		            setMessage(message);
+		          } else {
+		            var errors = [];
+		            _angular2.default.forEach(scope.ngModel && scope.ngModel.$error, function (status, code) {
+		              if (status) {
+		                // if true then there is an error
+		                // Angular 1.3 removes properties, so we will always just have errors.
+		                // Angular 1.2 sets them to false.
+		                errors.push(code);
+		              }
+		            });
+
+		            // In Angular 1.3 we use one $validator to stop the model value from getting updated.
+		            // this means that we always end up with a 'schemaForm' error.
+		            errors = errors.filter(function (e) {
+		              return e !== 'schemaForm';
+		            });
+
+		            // We only show one error.
+		            // TODO: Make that optional
+		            var error = errors[0];
+
+		            if (error) {
+		              setMessage(sfErrorMessage.interpolate(error, scope.ngModel.$modelValue, scope.ngModel.$viewValue, scope.form, scope.options && scope.options.validationMessage));
+		            } else {
+		              setMessage(message);
+		            }
+		          }
+		        } else {
+		          setMessage(message);
+		        }
+		      };
+
+		      // Update once.
+		      update();
+
+		      var once = scope.$watch('ngModel', function (ngModel) {
+		        if (ngModel) {
+		          // We also listen to changes of the model via parsers and formatters.
+		          // This is since both the error message can change and given a pristine
+		          // option to not show errors the ngModel.$error might not have changed
+		          // but we're not pristine any more so we should change!
+		          ngModel.$parsers.push(function (val) {
+		            update(true);return val;
+		          });
+		          ngModel.$formatters.push(function (val) {
+		            update(true);return val;
+		          });
+		          once();
+		        }
+		      });
+
+		      // We watch for changes in $error
+		      scope.$watchCollection('ngModel.$error', function () {
+		        update(!!scope.ngModel);
+		      });
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 15 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function (sel, sfPath, schemaForm) {
+		  return {
+		    scope: true,
+		    controller: ['$scope', function SFArrayController($scope) {
+		      this.key = $scope.form && $scope.form.key ? $scope.form.key.splice(0, -2) : [];
+		    }],
+		    link: function link(scope, element, attrs) {
+		      scope.min = 0;
+
+		      scope.modelArray = scope.$eval(attrs.sfNewArray);
+
+		      // We need to have a ngModel to hook into validation. It doesn't really play well with
+		      // arrays though so we both need to trigger validation and onChange.
+		      // So we watch the value as well. But watching an array can be tricky. We wan't to know
+		      // when it changes so we can validate,
+		      var watchFn = function watchFn() {
+		        //scope.modelArray = modelArray;
+		        scope.modelArray = scope.$eval(attrs.sfNewArray);
+		        // validateField method is exported by schema-validate
+		        if (scope.ngModel && scope.ngModel.$pristine && scope.firstDigest && (!scope.options || scope.options.validateOnRender !== true)) {
+		          return;
+		        } else if (scope.validateField) {
+		          scope.validateField();
+		        }
+		      };
+
+		      var onChangeFn = function onChangeFn() {
+		        if (scope.form && scope.form.onChange) {
+		          if (_angular2.default.isFunction(scope.form.onChange)) {
+		            scope.form.onChange(scope.modelArray, scope.form);
+		          } else {
+		            scope.evalExpr(scope.form.onChange, { 'modelValue': scope.modelArray, form: scope.form });
+		          }
+		        }
+		      };
+
+		      // If model is undefined make sure it gets set.
+		      var getOrCreateModel = function getOrCreateModel() {
+		        var model = scope.modelArray;
+		        if (!model) {
+		          var selection = sfPath.parse(attrs.sfNewArray);
+		          model = [];
+		          sel(selection, scope, model);
+		          scope.modelArray = model;
+		        }
+		        return model;
+		      };
+
+		      // We need the form definition to make a decision on how we should listen.
+		      var once = scope.$watch('form', function (form) {
+		        if (!form) {
+		          return;
+		        }
+
+		        // Always start with one empty form unless configured otherwise.
+		        // Special case: don't do it if form has a titleMap
+		        if (!form.titleMap && form.startEmpty !== true && (!scope.modelArray || scope.modelArray.length === 0)) {
+		          scope.appendToArray();
+		        }
+
+		        // If we have "uniqueItems" set to true, we must deep watch for changes.
+		        if (scope.form && scope.form.schema && scope.form.schema.uniqueItems === true) {
+		          scope.$watch(attrs.sfNewArray, watchFn, true);
+
+		          // We still need to trigger onChange though.
+		          scope.$watch([attrs.sfNewArray, attrs.sfNewArray + '.length'], onChangeFn);
+		        } else {
+		          // Otherwise we like to check if the instance of the array has changed, or if something
+		          // has been added/removed.
+		          if (scope.$watchGroup) {
+		            scope.$watchGroup([attrs.sfNewArray, attrs.sfNewArray + '.length'], function () {
+		              watchFn();
+		              onChangeFn();
+		            });
+		          } else {
+		            // Angular 1.2 support
+		            scope.$watch(attrs.sfNewArray, function () {
+		              watchFn();
+		              onChangeFn();
+		            });
+		            scope.$watch(attrs.sfNewArray + '.length', function () {
+		              watchFn();
+		              onChangeFn();
+		            });
+		          }
+		        }
+
+		        // Title Map handling
+		        // If form has a titleMap configured we'd like to enable looping over
+		        // titleMap instead of modelArray, this is used for intance in
+		        // checkboxes. So instead of variable number of things we like to create
+		        // a array value from a subset of values in the titleMap.
+		        // The problem here is that ng-model on a checkbox doesn't really map to
+		        // a list of values. This is here to fix that.
+		        if (form.titleMap && form.titleMap.length > 0) {
+		          scope.titleMapValues = [];
+
+		          // We watch the model for changes and the titleMapValues to reflect
+		          // the modelArray
+		          var updateTitleMapValues = function updateTitleMapValues(arr) {
+		            scope.titleMapValues = [];
+		            arr = arr || [];
+
+		            form.titleMap.forEach(function (item) {
+		              scope.titleMapValues.push(arr.indexOf(item.value) !== -1);
+		            });
+		          };
+		          //Catch default values
+		          updateTitleMapValues(scope.modelArray);
+
+		          // TODO: Refactor and see if we can get rid of this watch by piggy backing on the
+		          // validation watch.
+		          scope.$watchCollection('modelArray', updateTitleMapValues);
+
+		          //To get two way binding we also watch our titleMapValues
+		          scope.$watchCollection('titleMapValues', function (vals, old) {
+		            if (vals && vals !== old) {
+		              var arr = getOrCreateModel();
+
+		              form.titleMap.forEach(function (item, index) {
+		                var arrIndex = arr.indexOf(item.value);
+		                if (arrIndex === -1 && vals[index]) {
+		                  arr.push(item.value);
+		                };
+
+		                if (arrIndex !== -1 && !vals[index]) {
+		                  arr.splice(arrIndex, 1);
+		                };
+		              });
+		              // Time to validate the rebuilt array.
+		              // validateField method is exported by schema-validate
+		              if (scope.validateField) {
+		                scope.validateField();
+		              }
+		            }
+		          });
+		        }
+
+		        once();
+		      });
+
+		      scope.appendToArray = function () {
+		        var empty;
+
+		        // Create and set an array if needed.
+		        var model = getOrCreateModel();
+
+		        // Same old add empty things to the array hack :(
+		        if (scope.form && scope.form.schema && scope.form.schema.items) {
+
+		          var items = scope.form.schema.items;
+		          if (items.type && items.type.indexOf('object') !== -1) {
+		            empty = {};
+
+		            // Check for possible defaults
+		            if (!scope.options || scope.options.setSchemaDefaults !== false) {
+		              empty = _angular2.default.isDefined(items['default']) ? items['default'] : empty;
+
+		              // Check for defaults further down in the schema.
+		              // If the default instance sets the new array item to something falsy, i.e. null
+		              // then there is no need to go further down.
+		              if (empty) {
+		                schemaForm.traverseSchema(items, function (prop, path) {
+		                  if (_angular2.default.isDefined(prop['default'])) {
+		                    sel(path, empty, prop['default']);
+		                  }
+		                });
+		              }
+		            }
+		          } else if (items.type && items.type.indexOf('array') !== -1) {
+		            empty = [];
+		            if (!scope.options || scope.options.setSchemaDefaults !== false) {
+		              empty = items['default'] || empty;
+		            }
+		          } else {
+		            // No type? could still have defaults.
+		            if (!scope.options || scope.options.setSchemaDefaults !== false) {
+		              empty = items['default'] || empty;
+		            }
+		          }
+		        }
+		        model.push(empty);
+
+		        return model;
+		      };
+
+		      scope.deleteFromArray = function (index) {
+		        var model = scope.modelArray;
+		        if (model) {
+		          model.splice(index, 1);
+		        }
+		        return model;
+		      };
+
+		      // For backwards compatability, i.e. when a bootstrap-decorator tag is used
+		      // as child to the array.
+		      var setIndex = function setIndex(index) {
+		        return function (form) {
+		          if (form.key) {
+		            form.key[form.key.indexOf('')] = index;
+		          }
+		        };
+		      };
+		      var formDefCache = {};
+		      scope.copyWithIndex = function (index) {
+		        var form = scope.form;
+		        if (!formDefCache[index]) {
+
+		          // To be more compatible with JSON Form we support an array of items
+		          // in the form definition of "array" (the schema just a value).
+		          // for the subforms code to work this means we wrap everything in a
+		          // section. Unless there is just one.
+		          var subForm = form.items[0];
+		          if (form.items.length > 1) {
+		            subForm = {
+		              type: 'section',
+		              items: form.items.map(function (item) {
+		                item.ngModelOptions = form.ngModelOptions;
+		                if (_angular2.default.isUndefined(item.readonly)) {
+		                  item.readonly = form.readonly;
+		                }
+		                return item;
+		              })
+		            };
+		          }
+
+		          if (subForm) {
+		            var copy = _angular2.default.copy(subForm);
+		            copy.arrayIndex = index;
+		            schemaForm.traverseForm(copy, setIndex(index));
+		            formDefCache[index] = copy;
+		          }
+		        }
+		        return formDefCache[index];
+		      };
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 16 */
+	/***/ function(module, exports) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function (schemaForm, sfPath) {
+		  return {
+		    scope: true,
+		    require: ['^^sfNewArray'],
+		    link: function link(scope, element, attrs, ctrl) {
+		      var currentKey = sfPath.parse(attrs.sfParentKey);
+		      if (currentKey.length > 1) currentKey = currentKey.splice(-1);
+
+		      scope.parentKey = scope.parentKey || [];
+		      scope.parentKey = scope.parentKey.concat(currentKey, Number(attrs.sfIndex));
+
+		      scope.arrayIndex = Number(attrs.sfIndex);
+		      scope.arrayIndices = scope.arrayIndices || [];
+		      scope.arrayIndices = scope.arrayIndices.concat(scope.arrayIndex);
+		      scope.$i = scope.arrayIndices;
+		    }
+		  };
+		};
+
+		; /**
+		   * Directive that handles keys and array indexes
+		   */
+
+	/***/ },
+	/* 17 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function ($compile, $http, $templateCache, $q, schemaForm, schemaFormDecorators, sfSelect, sfPath, sfBuilder) {
+
+		  return {
+		    scope: {
+		      schema: '=sfSchema',
+		      initialForm: '=sfForm',
+		      model: '=sfModel',
+		      options: '=sfOptions'
+		    },
+		    controller: ['$scope', function ($scope) {
+		      this.evalInParentScope = function (expr, locals) {
+		        return $scope.$parent.$eval(expr, locals);
+		      };
+
+		      // Set up form lookup map
+		      var that = this;
+		      $scope.lookup = function (lookup) {
+		        if (lookup) {
+		          that.lookup = lookup;
+		        }
+		        return that.lookup;
+		      };
+		    }],
+		    replace: false,
+		    restrict: 'A',
+		    transclude: true,
+		    require: '?form',
+		    link: function link(scope, element, attrs, formCtrl, transclude) {
+
+		      //expose form controller on scope so that we don't force authors to use name on form
+		      scope.formCtrl = formCtrl;
+
+		      //We'd like to handle existing markup,
+		      //besides using it in our template we also
+		      //check for ng-model and add that to an ignore list
+		      //i.e. even if form has a definition for it or form is ["*"]
+		      //we don't generate it.
+		      var ignore = {};
+		      transclude(scope, function (clone) {
+		        clone.addClass('schema-form-ignore');
+		        element.prepend(clone);
+
+		        if (element[0].querySelectorAll) {
+		          var models = element[0].querySelectorAll('[ng-model]');
+		          if (models) {
+		            for (var i = 0; i < models.length; i++) {
+		              var key = models[i].getAttribute('ng-model');
+		              //skip first part before .
+		              ignore[key.substring(key.indexOf('.') + 1)] = true;
+		            }
+		          }
+		        }
+		      });
+
+		      var lastDigest = {};
+		      var childScope;
+
+		      // Common renderer function, can either be triggered by a watch or by an event.
+		      var render = function render(schema, form) {
+		        var asyncTemplates = [];
+		        var merged = schemaForm.merge(schema, form, ignore, scope.options, undefined, asyncTemplates);
+
+		        if (asyncTemplates.length > 0) {
+		          // Pre load all async templates and put them on the form for the builder to use.
+		          $q.all(asyncTemplates.map(function (form) {
+		            return $http.get(form.templateUrl, { cache: $templateCache }).then(function (res) {
+		              form.template = res.data;
+		            });
+		          })).then(function () {
+		            internalRender(schema, form, merged);
+		          });
+		        } else {
+		          internalRender(schema, form, merged);
+		        };
+		      };
+
+		      var internalRender = function internalRender(schema, form, merged) {
+		        // Create a new form and destroy the old one.
+		        // Not doing keeps old form elements hanging around after
+		        // they have been removed from the DOM
+		        // https://github.com/Textalk/angular-schema-form/issues/200
+		        if (childScope) {
+		          // Destroy strategy should not be acted upon
+		          scope.externalDestructionInProgress = true;
+		          childScope.$destroy();
+		          scope.externalDestructionInProgress = false;
+		        };
+		        childScope = scope.$new();
+
+		        //make the form available to decorators
+		        childScope.schemaForm = { form: merged, schema: schema };
+
+		        //clean all but pre existing html.
+		        element.children(':not(.schema-form-ignore)').remove();
+
+		        // Find all slots.
+		        var slots = {};
+		        var slotsFound = element[0].querySelectorAll('*[sf-insert-field]');
+
+		        for (var i = 0; i < slotsFound.length; i++) {
+		          slots[slotsFound[i].getAttribute('sf-insert-field')] = slotsFound[i];
+		        }
+
+		        // if sfUseDecorator is undefined the default decorator is used.
+		        var decorator = schemaFormDecorators.decorator(attrs.sfUseDecorator);
+		        // Use the builder to build it and append the result
+		        var lookup = Object.create(null);
+		        scope.lookup(lookup); // give the new lookup to the controller.
+		        element[0].appendChild(sfBuilder.build(merged, decorator, slots, lookup));
+
+		        // We need to know if we're in the first digest looping
+		        // I.e. just rendered the form so we know not to validate
+		        // empty fields.
+		        childScope.firstDigest = true;
+		        // We use a ordinary timeout since we don't need a digest after this.
+		        setTimeout(function () {
+		          childScope.firstDigest = false;
+		        }, 0);
+
+		        //compile only children
+		        $compile(element.children())(childScope);
+
+		        //ok, now that that is done let's set any defaults
+		        if (!scope.options || scope.options.setSchemaDefaults !== false) {
+		          schemaForm.traverseSchema(schema, function (prop, path) {
+		            if (_angular2.default.isDefined(prop['default'])) {
+		              var val = sfSelect(path, scope.model);
+		              if (_angular2.default.isUndefined(val)) {
+		                sfSelect(path, scope.model, prop['default']);
+		              }
+		            }
+		          });
+		        }
+
+		        scope.$emit('sf-render-finished', element);
+		      };
+
+		      var defaultForm = ['*'];
+
+		      //Since we are dependant on up to three
+		      //attributes we'll do a common watch
+		      scope.$watch(function () {
+
+		        var schema = scope.schema;
+		        var form = scope.initialForm || defaultForm;
+
+		        //The check for schema.type is to ensure that schema is not {}
+		        if (form && schema && schema.type && (lastDigest.form !== form || lastDigest.schema !== schema) && Object.keys(schema.properties).length > 0) {
+		          lastDigest.schema = schema;
+		          lastDigest.form = form;
+
+		          render(schema, form);
+		        }
+		      });
+
+		      // We also listen to the event schemaFormRedraw so you can manually trigger a change if
+		      // part of the form or schema is chnaged without it being a new instance.
+		      scope.$on('schemaFormRedraw', function () {
+		        var schema = scope.schema;
+		        var form = scope.initialForm ? _angular2.default.copy(scope.initialForm) : ['*'];
+		        if (schema) {
+		          render(schema, form);
+		        }
+		      });
+
+		      scope.$on('$destroy', function () {
+		        // Each field listens to the $destroy event so that it can remove any value
+		        // from the model if that field is removed from the form. This is the default
+		        // destroy strategy. But if the entire form (or at least the part we're on)
+		        // gets removed, like when routing away to another page, then we definetly want to
+		        // keep the model intact. So therefore we set a flag to tell the others it's time to just
+		        // let it be.
+		        scope.externalDestructionInProgress = true;
+		      });
+
+		      /**
+		       * Evaluate an expression, i.e. scope.$eval
+		       * but do it in parent scope
+		       *
+		       * @param {String} expression
+		       * @param {Object} locals (optional)
+		       * @return {Any} the result of the expression
+		       */
+		      scope.evalExpr = function (expression, locals) {
+		        return scope.$parent.$eval(expression, locals);
+		      };
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ },
+	/* 18 */
+	/***/ function(module, exports, __webpack_require__) {
+
+		'use strict';
+
+		Object.defineProperty(exports, "__esModule", {
+		  value: true
+		});
+
+		exports.default = function (sfValidator, $parse, sfSelect) {
+
+		  return {
+		    restrict: 'A',
+		    scope: false,
+		    // We want the link function to be *after* the input directives link function so we get access
+		    // the parsed value, ex. a number instead of a string
+		    priority: 500,
+		    require: 'ngModel',
+		    link: function link(scope, element, attrs, ngModel) {
+		      // We need the ngModelController on several places,
+		      // most notably for errors.
+		      // So we emit it up to the decorator directive so it can put it on scope.
+		      scope.$emit('schemaFormPropagateNgModelController', ngModel);
+
+		      var error = null;
+		      var form = scope.$eval(attrs.schemaValidate);
+
+		      if (form.copyValueTo) {
+		        ngModel.$viewChangeListeners.push(function () {
+		          var paths = form.copyValueTo;
+		          _angular2.default.forEach(paths, function (path) {
+		            sfSelect(path, scope.model, ngModel.$modelValue);
+		          });
+		        });
+		      };
+
+		      // Validate against the schema.
+
+		      var validate = function validate(viewValue) {
+		        //console.log('validate called', viewValue)
+		        //Still might be undefined
+		        if (!form) {
+		          return viewValue;
+		        }
+
+		        // Omit TV4 validation
+		        if (scope.options && scope.options.tv4Validation === false) {
+		          return viewValue;
+		        }
+
+		        var result = sfValidator.validate(form, viewValue);
+		        //console.log('result is', result)
+		        // Since we might have different tv4 errors we must clear all
+		        // errors that start with tv4-
+		        Object.keys(ngModel.$error).filter(function (k) {
+		          return k.indexOf('tv4-') === 0;
+		        }).forEach(function (k) {
+		          ngModel.$setValidity(k, true);
+		        });
+
+		        if (!result.valid) {
+		          // it is invalid, return undefined (no model update)
+		          ngModel.$setValidity('tv4-' + result.error.code, false);
+		          error = result.error;
+
+		          // In Angular 1.3+ return the viewValue, otherwise we inadvertenly
+		          // will trigger a 'parse' error.
+		          // we will stop the model value from updating with our own $validator
+		          // later.
+		          if (ngModel.$validators) {
+		            return viewValue;
+		          }
+		          // Angular 1.2 on the other hand lacks $validators and don't add a 'parse' error.
+		          return undefined;
+		        }
+		        return viewValue;
+		      };
+
+		      // Custom validators, parsers, formatters etc
+		      if (typeof form.ngModel === 'function') {
+		        form.ngModel(ngModel);
+		      }
+
+		      ['$parsers', '$viewChangeListeners', '$formatters'].forEach(function (attr) {
+		        if (form[attr] && ngModel[attr]) {
+		          form[attr].forEach(function (fn) {
+		            ngModel[attr].push(fn);
+		          });
+		        }
+		      });
+
+		      ['$validators', '$asyncValidators'].forEach(function (attr) {
+		        // Check if our version of angular has validators, i.e. 1.3+
+		        if (form[attr] && ngModel[attr]) {
+		          _angular2.default.forEach(form[attr], function (fn, name) {
+		            ngModel[attr][name] = fn;
+		          });
+		        }
+		      });
+
+		      // Get in last of the parses so the parsed value has the correct type.
+		      // We don't use $validators since we like to set different errors depending tv4 error codes
+		      ngModel.$parsers.push(validate);
+
+		      // But we do use one custom validator in the case of Angular 1.3 to stop the model from
+		      // updating if we've found an error.
+		      if (ngModel.$validators) {
+		        ngModel.$validators.schemaForm = function () {
+		          //console.log('validators called.')
+		          // Any error and we're out of here!
+		          return !Object.keys(ngModel.$error).some(function (e) {
+		            return e !== 'schemaForm';
+		          });
+		        };
+		      }
+
+		      var schema = form.schema;
+
+		      // A bit ugly but useful.
+		      scope.validateField = function (formName) {
+		        // If we have specified a form name, and this model is not within
+		        // that form, then leave things be.
+		        if (formName != undefined && ngModel.$$parentForm.$name !== formName) {
+		          return;
+		        }
+
+		        // Special case: arrays
+		        // TODO: Can this be generalized in a way that works consistently?
+		        // Just setting the viewValue isn't enough to trigger validation
+		        // since it's the same value. This will be better when we drop
+		        // 1.2 support.
+		        if (schema && schema.type.indexOf('array') !== -1) {
+		          validate(ngModel.$modelValue);
+		        }
+
+		        // We set the viewValue to trigger parsers,
+		        // since modelValue might be empty and validating just that
+		        // might change an existing error to a "required" error message.
+		        if (ngModel.$setDirty) {
+
+		          // Angular 1.3+
+		          ngModel.$setDirty();
+		          ngModel.$setViewValue(ngModel.$viewValue);
+		          ngModel.$commitViewValue();
+
+		          // In Angular 1.3 setting undefined as a viewValue does not trigger parsers
+		          // so we need to do a special required check.
+
+		          // angulars checkbox directive isEmpty does not do the check we want.
+		          if (form.type === 'checkbox') {
+		            if (form.required && ngModel.$modelValue === undefined) {
+		              ngModel.$setValidity('tv4-302', false);
+		            }
+		          } else if (form.required && ngModel.$isEmpty(ngModel.$modelValue)) {
+		            ngModel.$setValidity('tv4-302', false);
+		          }
+		        } else {
+		          // Angular 1.2
+		          // In angular 1.2 setting a viewValue of undefined will trigger the parser.
+		          // hence required works.
+		          ngModel.$setViewValue(ngModel.$viewValue);
+		        }
+		      };
+
+		      var first = true;
+		      ngModel.$formatters.push(function (val) {
+		        // When a form first loads this will be called for each field.
+		        // we usually don't want that.
+		        if (ngModel.$pristine && first && (!scope.options || scope.options.validateOnRender !== true)) {
+		          first = false;
+		          return val;
+		        }
+		        validate(ngModel.$modelValue);
+		        return val;
+		      });
+
+		      // Listen to an event so we can validate the input on request
+		      scope.$on('schemaFormValidate', function (event, formName) {
+		        scope.validateField(formName);
+		      });
+
+		      scope.schemaError = function () {
+		        return error;
+		      };
+		    }
+		  };
+		};
+
+		var _angular = __webpack_require__(2);
+
+		var _angular2 = _interopRequireDefault(_angular);
+
+		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
+
+	/***/ }
+	/******/ ])
+	});
+	;
+
+/***/ },
+/* 19 */
+/***/ function(module, exports) {
+
+	module.exports = angular;
+
+/***/ },
+/* 20 */
+/***/ function(module, exports) {
+
+	module.exports = tv4;
+
+/***/ }
+/******/ ])
+});
+;
\ No newline at end of file

From 4d6748f86c7905bd5d76a770baee36ab382de32e Mon Sep 17 00:00:00 2001
From: mbennett <marcel@iamserious.com>
Date: Mon, 24 Oct 2016 10:05:37 +1100
Subject: [PATCH 29/50] One-time bindings

---
 src/bootstrap/checkbox.html      |  2 +-
 src/bootstrap/checkboxes.html    |  2 +-
 src/bootstrap/default.html       | 16 ++++++++--------
 src/bootstrap/radio-buttons.html |  2 +-
 src/bootstrap/radios-inline.html |  2 +-
 src/bootstrap/radios.html        |  2 +-
 src/bootstrap/select.html        |  5 +++--
 src/bootstrap/textarea.html      | 10 +++++-----
 8 files changed, 21 insertions(+), 20 deletions(-)

diff --git a/src/bootstrap/checkbox.html b/src/bootstrap/checkbox.html
index bba07ef..b37fb09 100644
--- a/src/bootstrap/checkbox.html
+++ b/src/bootstrap/checkbox.html
@@ -7,7 +7,7 @@
            sf-field-model
            schema-validate="form"
            class="{{::form.fieldHtmlClass}}"
-           name="{{form.key.slice(-1)[0]}}">
+           name="{{::fieldId(true, false)}}">
     <span ng-bind-html="form.title"></span>
   </label>
   <div class="help-block" sf-message="form.description"></div>
diff --git a/src/bootstrap/checkboxes.html b/src/bootstrap/checkboxes.html
index 1383ac7..064202d 100644
--- a/src/bootstrap/checkboxes.html
+++ b/src/bootstrap/checkboxes.html
@@ -14,7 +14,7 @@
              sf-changed="form"
              class="{{::form.fieldHtmlClass}}"
              ng-model="titleMapValues[$index]"
-             name="{{form.key.slice(-1)[0]}}">
+             name="{{::fieldId(true, false)}}">
       <span ng-bind-html="form.titleMap[$index].name"></span>
     </label>
 
diff --git a/src/bootstrap/default.html b/src/bootstrap/default.html
index 2cbb8c0..7a70367 100644
--- a/src/bootstrap/default.html
+++ b/src/bootstrap/default.html
@@ -1,6 +1,6 @@
 <div class="form-group {{::form.htmlClass}}"
      ng-class="{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }">
-  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>
+  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>
 
   <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"
          ng-show="::form.key"
@@ -9,12 +9,12 @@
          sf-changed="form"
          placeholder="{{::form.placeholder}}"
          class="form-control {{::form.fieldHtmlClass}}"
-         id="{{form.key.slice(-1)[0]}}"
+         id="{{::fieldId(true, false)}}"
          sf-field-model
          ng-disabled="form.readonly"
          schema-validate="form"
-         name="{{form.key.slice(-1)[0]}}"
-         aria-describedby="{{form.key.slice(-1)[0] + 'Status'}}">
+         name="{{::fieldId(true, false)}}"
+         aria-describedby="{{::fieldId(true, true) + '-status'}}">
 
   <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"
        ng-class="{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}">
@@ -27,12 +27,12 @@
            sf-changed="form"
            placeholder="{{::form.placeholder}}"
            class="form-control {{::form.fieldHtmlClass}}"
-           id="{{form.key.slice(-1)[0]}}"
+           id="{{::fieldId(true, false)}}"
            sf-field-model
            ng-disabled="form.readonly"
            schema-validate="form"
-           name="{{form.key.slice(-1)[0]}}"
-           aria-describedby="{{form.key.slice(-1)[0] + 'Status'}}">
+           name="{{::fieldId(true, false)}}"
+           aria-describedby="{{::fieldId(true, true) + '-status'}}">
 
     <span ng-if="form.fieldAddonRight"
           class="input-group-addon"
@@ -45,7 +45,7 @@
         aria-hidden="true"></span>
 
   <span ng-if="hasError() || hasSuccess()"
-        id="{{form.key.slice(-1)[0] + 'Status'}}"
+        id="{{::fieldId(true, true) + '-status'}}"
         class="sr-only">{{ hasSuccess() ? '(success)' : '(error)' }}</span>
 
   <div class="help-block" sf-message="form.description"></div>
diff --git a/src/bootstrap/radio-buttons.html b/src/bootstrap/radio-buttons.html
index 3530342..86e578e 100644
--- a/src/bootstrap/radio-buttons.html
+++ b/src/bootstrap/radio-buttons.html
@@ -15,7 +15,7 @@
              sf-field-model
              schema-validate="form"
              ng-value="item.value"
-             name="{{form.key.join('.')}}">
+             name="{{::fieldId(true)}}">
       <span ng-bind-html="item.name"></span>
     </label>
   </div>
diff --git a/src/bootstrap/radios-inline.html b/src/bootstrap/radios-inline.html
index 7b0df63..5f6f443 100644
--- a/src/bootstrap/radios-inline.html
+++ b/src/bootstrap/radios-inline.html
@@ -11,7 +11,7 @@
              ng-disabled="form.readonly"
              sf-field-model
              ng-value="item.value"
-             name="{{form.key.join('.')}}">
+             name="{{::fieldId(true)}}">
       <span ng-bind-html="item.name"></span>
     </label>
   </div>
diff --git a/src/bootstrap/radios.html b/src/bootstrap/radios.html
index 278715d..00d69da 100644
--- a/src/bootstrap/radios.html
+++ b/src/bootstrap/radios.html
@@ -10,7 +10,7 @@
              ng-disabled="form.readonly"
              sf-field-model
              ng-value="item.value"
-             name="{{form.key.join('.')}}">
+             name="{{::fieldId(true)}}">
       <span ng-bind-html="item.name"></span>
     </label>
   </div>
diff --git a/src/bootstrap/select.html b/src/bootstrap/select.html
index fb1e6dd..25de9be 100644
--- a/src/bootstrap/select.html
+++ b/src/bootstrap/select.html
@@ -1,15 +1,16 @@
 <div class="form-group {{::form.htmlClass}} schema-form-select"
      ng-class="{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}">
-  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">
+  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">
     {{form.title}}
   </label>
   <select sf-field-model
+          id="{{::fieldId(true, false)}}"
           ng-disabled="form.readonly"
           sf-changed="form"
           class="form-control {{::form.fieldHtmlClass}}"
           schema-validate="form"
           ng-options="item.value as item.name group by item.group for item in form.titleMap"
-          name="{{form.key.slice(-1)[0]}}">
+          name="{{::fieldId(true, false)}}">
   </select>
   <div class="help-block" sf-message="form.description"></div>
 </div>
diff --git a/src/bootstrap/textarea.html b/src/bootstrap/textarea.html
index 37f60de..66f56f0 100644
--- a/src/bootstrap/textarea.html
+++ b/src/bootstrap/textarea.html
@@ -1,15 +1,15 @@
 <div class="form-group has-feedback {{::form.htmlClass}} schema-form-textarea" ng-class="{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
-  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>
+  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>
 
   <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"
             class="form-control {{::form.fieldHtmlClass}}"
-            id="{{form.key.slice(-1)[0]}}"
+            id="{{::fieldId(true, false)}}"
             sf-changed="form"
             ng-attr-placeholder="{{::form.placeholder}}"
             ng-disabled="form.readonly"
             sf-field-model
             schema-validate="form"
-            name="{{form.key.slice(-1)[0]}}"></textarea>
+            name="{{::fieldId(true, false)}}"></textarea>
 
   <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"
        ng-class="{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}">
@@ -17,13 +17,13 @@
           class="input-group-addon"
           ng-bind-html="form.fieldAddonLeft"></span>
     <textarea class="form-control {{::form.fieldHtmlClass}}"
-              id="{{form.key.slice(-1)[0]}}"
+              id="{{::fieldId(true, false)}}"
               sf-changed="form"
               ng-attr-placeholder="{{::form.placeholder}}"
               ng-disabled="form.readonly"
               sf-field-model
               schema-validate="form"
-              name="{{form.key.slice(-1)[0]}}"></textarea>
+              name="{{::fieldId(true, false)}}"></textarea>
     <span ng-if="form.fieldAddonRight"
           class="input-group-addon"
           ng-bind-html="form.fieldAddonRight"></span>

From 65486579fa4aff530b74f22d47fd6f3bf47047a2 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Wed, 2 Nov 2016 01:25:29 +1100
Subject: [PATCH 30/50] Update templates to work better with arrays

---
 dist/angular-schema-form-bootstrap-bundled.js | 32 ++++++++++---------
 ...gular-schema-form-bootstrap-bundled.min.js |  8 ++---
 dist/angular-schema-form-bootstrap.js         | 10 +++---
 dist/angular-schema-form-bootstrap.min.js     |  2 +-
 examples/bootstrap-example.html               |  2 +-
 package.json                                  |  2 +-
 src/bootstrap/fieldset.html                   |  2 +-
 src/bootstrap/radio-buttons.html              | 12 +++----
 src/bootstrap/radios-inline.html              |  8 ++---
 src/bootstrap/radios.html                     |  8 ++---
 src/bootstrap/section.html                    |  2 +-
 11 files changed, 45 insertions(+), 43 deletions(-)

diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index b7068be..b4bae70 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -251,7 +251,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/fieldset.html';
-	var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
+	var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -269,7 +269,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/radio-buttons.html';
-	var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (item.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: item.value === $$value$$ }\"\r\n           ng-repeat=\"item in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (tm.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: tm.value === $$value$$ }\"\r\n           ng-repeat=\"tm in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -278,7 +278,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/radios-inline.html';
-	var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"item in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"tm in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -287,7 +287,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/radios.html';
-	var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"item in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"tm in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -296,7 +296,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/section.html';
-	var html = "<div class=\"schema-form-section {{::form.htmlClass}}\"></div>\r\n";
+	var html = "<div class=\"schema-form-section {{::form.htmlClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -686,7 +686,7 @@ return /******/ (function(modules) { // webpackBootstrap
 		          state.modelName = 'item';
 		        }
 
-		        // Flag to the builder that where in an array.
+		        // Flag to the builder that we're in an array.
 		        // This is needed for compatabiliy if a "old" add-on is used that
 		        // hasn't been transitioned to the new builder.
 		        state.arrayCompatFlag = true;
@@ -3779,17 +3779,19 @@ return /******/ (function(modules) { // webpackBootstrap
 		  return {
 		    scope: true,
 		    require: ['^^sfNewArray'],
-		    link: function link(scope, element, attrs, ctrl) {
-		      var currentKey = sfPath.parse(attrs.sfParentKey);
-		      if (currentKey.length > 1) currentKey = currentKey.splice(-1);
+		    link: {
+		      pre: function pre(scope, element, attrs, ctrl) {
+		        var currentKey = sfPath.parse(attrs.sfParentKey);
+		        if (currentKey.length > 1) currentKey = currentKey.splice(-1);
 
-		      scope.parentKey = scope.parentKey || [];
-		      scope.parentKey = scope.parentKey.concat(currentKey, Number(attrs.sfIndex));
+		        scope.parentKey = scope.parentKey || [];
+		        scope.parentKey = scope.parentKey.concat(currentKey, Number(attrs.sfIndex));
 
-		      scope.arrayIndex = Number(attrs.sfIndex);
-		      scope.arrayIndices = scope.arrayIndices || [];
-		      scope.arrayIndices = scope.arrayIndices.concat(scope.arrayIndex);
-		      scope.$i = scope.arrayIndices;
+		        scope.arrayIndex = Number(attrs.sfIndex);
+		        scope.arrayIndices = scope.arrayIndices || [];
+		        scope.arrayIndices = scope.arrayIndices.concat(scope.arrayIndex);
+		        scope.$i = scope.arrayIndices;
+		      }
 		    }
 		  };
 		};
diff --git a/dist/angular-schema-form-bootstrap-bundled.min.js b/dist/angular-schema-form-bootstrap-bundled.min.js
index 04d148b..c9f597f 100644
--- a/dist/angular-schema-form-bootstrap-bundled.min.js
+++ b/dist/angular-schema-form-bootstrap-bundled.min.js
@@ -5,19 +5,19 @@
  * @license MIT
  * Copyright (c) 2016 JSON Schema Form
  */
-(function webpackUniversalModuleDefinition(root,factory){if(typeof exports==="object"&&typeof module==="object")module.exports=factory(require("angular"),require("tv4"));else if(typeof define==="function"&&define.amd)define(["angular","tv4"],factory);else{var a=typeof exports==="object"?factory(require("angular"),require("tv4")):factory(root["angular"],root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_19__,__WEBPACK_EXTERNAL_MODULE_20__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){"use strict";__webpack_require__(18);__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var textareaTemplate=__webpack_require__(17);var fieldsetTemplate=__webpack_require__(7);var arrayTemplate=__webpack_require__(3);var tabarrayTemplate=__webpack_require__(15);var tabsTemplate=__webpack_require__(16);var sectionTemplate=__webpack_require__(12);var actionsTemplate=__webpack_require__(2);var selectTemplate=__webpack_require__(13);var checkboxTemplate=__webpack_require__(4);var checkboxesTemplate=__webpack_require__(5);var submitTemplate=__webpack_require__(14);var radiosTemplate=__webpack_require__(11);var radiosInlineTemplate=__webpack_require__(10);var radiobuttonsTemplate=__webpack_require__(9);var helpTemplate=__webpack_require__(8);var defaultTemplate=__webpack_require__(6);angular.module("schemaForm").config(bootstrapDecoratorConfig).filter("sfCamelKey",sfCamelKeyFilter);bootstrapDecoratorConfig.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"];function bootstrapDecoratorConfig(schemaFormProvider,decoratorsProvider,sfBuilderProvider,sfPathProvider,$injector){var base="decorators/bootstrap/";var simpleTransclusion=sfBuilderProvider.builders.simpleTransclusion;var ngModelOptions=sfBuilderProvider.builders.ngModelOptions;var ngModel=sfBuilderProvider.builders.ngModel;var sfField=sfBuilderProvider.builders.sfField;var condition=sfBuilderProvider.builders.condition;var array=sfBuilderProvider.builders.array;var numeric=sfBuilderProvider.builders.numeric;var tabs=function tabs(args){if(args.form.tabs&&args.form.tabs.length>0){var tabContent=args.fieldFrag.querySelector(".tab-content");args.form.tabs.forEach(function(tab,index){var evalExpr="(evalExpr("+args.path+".tabs["+index+"]"+'.condition, { model: model, "arrayIndex": $index}))';var div=document.createElement("div");div.className="tab-pane";div.setAttribute("ng-disabled","form.readonly");div.setAttribute("ng-show","selected.tab === "+index);div.setAttribute("ng-class","{active: selected.tab === "+index+"}");if(!!tab.condition){div.setAttribute("ng-if",evalExpr)}var childFrag=args.build(tab.items,args.path+".tabs["+index+"].items",args.state);div.appendChild(childFrag);tabContent.appendChild(div)})}};var selectPlaceholder=function selectPlaceholder(args){if(args.form.placeholder){var selectBox=args.fieldFrag.querySelector("select");var option=document.createElement("option");option.setAttribute("value","");option.setAttribute("sf-field-model","replaceAll");if(angular.version.major===1&&angular.version.minor<4){option.setAttribute("ng-if","$$value$$ === undefined")}else{option.setAttribute("ng-show","$$value$$ === undefined")}option.textContent=args.form.placeholder;selectBox.appendChild(option)}};var defaults=[sfField,ngModel,ngModelOptions,condition];decoratorsProvider.defineDecorator("bootstrapDecorator",{actions:{template:actionsTemplate,builder:defaults},array:{template:arrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},button:{template:submitTemplate,builder:defaults},checkbox:{template:checkboxTemplate,builder:defaults},checkboxes:{template:checkboxesTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},conditional:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},"default":{template:defaultTemplate,builder:defaults},fieldset:{template:fieldsetTemplate,builder:[sfField,simpleTransclusion,condition]},help:{template:helpTemplate,builder:defaults},number:{template:defaultTemplate,builder:defaults.concat(numeric)},password:{template:defaultTemplate,builder:defaults},radios:{template:radiosTemplate,builder:defaults},"radios-inline":{template:radiosInlineTemplate,builder:defaults},radiobuttons:{template:radiobuttonsTemplate,builder:defaults},section:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},select:{template:selectTemplate,builder:defaults.concat(selectPlaceholder)},submit:{template:submitTemplate,builder:defaults},tabarray:{template:tabarrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},tabs:{template:tabsTemplate,builder:[sfField,ngModelOptions,tabs,condition]},textarea:{template:textareaTemplate,builder:defaults}},[])}function sfCamelKeyFilter(){return function(formKey){if(!formKey){return""}var part,i,key;key=formKey.slice();for(i=0;i<key.length;i++){part=key[i].toLowerCase().split("");if(i&&part.length){part[0]=part[0].toUpperCase()}key[i]=part.join("")}return key.join("")}}},function(module,exports){var path="bootstrap/actions.html";var html='<div class="btn-group schema-form-actions {{::form.htmlClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/array.html";var html='<div  class="schema-form-array {{::form.htmlClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkbox.html";var html='<div class="checkbox schema-form-checkbox {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{form.key.slice(-1)[0]}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkboxes.html";var html='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{form.key.slice(-1)[0]}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/default.html";var html='<div class="form-group {{::form.htmlClass}}"\r\n     ng-class="{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{form.key.slice(-1)[0]}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{form.key.slice(-1)[0]}}"\r\n         aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{form.key.slice(-1)[0]}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{form.key.slice(-1)[0]}}"\r\n           aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{form.key.slice(-1)[0] + \'Status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/fieldset.html";var html='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/help.html";var html='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radio-buttons.html";var html='<div class="form-group schema-form-radiobuttons {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: item.value === $$value$$ }"\r\n           ng-repeat="item in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios-inline.html";var html='<div class="form-group schema-form-radios-inline {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="item in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios.html";var html='<div class="form-group schema-form-radios {{::form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="item in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/section.html";var html='<div class="schema-form-section {{::form.htmlClass}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/select.html";var html='<div class="form-group {{::form.htmlClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{form.key.slice(-1)[0]}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/submit.html";var html='<div class="form-group schema-form-submit {{::form.htmlClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabarray.html";var html='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabs.html";var html='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/textarea.html";var html='<div class="form-group has-feedback {{::form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{form.key.slice(-1)[0]}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{form.key.slice(-1)[0]}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{form.key.slice(-1)[0]}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{form.key.slice(-1)[0]}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports,__webpack_require__){/*!
+(function webpackUniversalModuleDefinition(root,factory){if(typeof exports==="object"&&typeof module==="object")module.exports=factory(require("angular"),require("tv4"));else if(typeof define==="function"&&define.amd)define(["angular","tv4"],factory);else{var a=typeof exports==="object"?factory(require("angular"),require("tv4")):factory(root["angular"],root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_19__,__WEBPACK_EXTERNAL_MODULE_20__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){"use strict";__webpack_require__(18);__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var textareaTemplate=__webpack_require__(17);var fieldsetTemplate=__webpack_require__(7);var arrayTemplate=__webpack_require__(3);var tabarrayTemplate=__webpack_require__(15);var tabsTemplate=__webpack_require__(16);var sectionTemplate=__webpack_require__(12);var actionsTemplate=__webpack_require__(2);var selectTemplate=__webpack_require__(13);var checkboxTemplate=__webpack_require__(4);var checkboxesTemplate=__webpack_require__(5);var submitTemplate=__webpack_require__(14);var radiosTemplate=__webpack_require__(11);var radiosInlineTemplate=__webpack_require__(10);var radiobuttonsTemplate=__webpack_require__(9);var helpTemplate=__webpack_require__(8);var defaultTemplate=__webpack_require__(6);angular.module("schemaForm").config(bootstrapDecoratorConfig).filter("sfCamelKey",sfCamelKeyFilter);bootstrapDecoratorConfig.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"];function bootstrapDecoratorConfig(schemaFormProvider,decoratorsProvider,sfBuilderProvider,sfPathProvider,$injector){var base="decorators/bootstrap/";var simpleTransclusion=sfBuilderProvider.builders.simpleTransclusion;var ngModelOptions=sfBuilderProvider.builders.ngModelOptions;var ngModel=sfBuilderProvider.builders.ngModel;var sfField=sfBuilderProvider.builders.sfField;var condition=sfBuilderProvider.builders.condition;var array=sfBuilderProvider.builders.array;var numeric=sfBuilderProvider.builders.numeric;var tabs=function tabs(args){if(args.form.tabs&&args.form.tabs.length>0){var tabContent=args.fieldFrag.querySelector(".tab-content");args.form.tabs.forEach(function(tab,index){var evalExpr="(evalExpr("+args.path+".tabs["+index+"]"+'.condition, { model: model, "arrayIndex": $index}))';var div=document.createElement("div");div.className="tab-pane";div.setAttribute("ng-disabled","form.readonly");div.setAttribute("ng-show","selected.tab === "+index);div.setAttribute("ng-class","{active: selected.tab === "+index+"}");if(!!tab.condition){div.setAttribute("ng-if",evalExpr)}var childFrag=args.build(tab.items,args.path+".tabs["+index+"].items",args.state);div.appendChild(childFrag);tabContent.appendChild(div)})}};var selectPlaceholder=function selectPlaceholder(args){if(args.form.placeholder){var selectBox=args.fieldFrag.querySelector("select");var option=document.createElement("option");option.setAttribute("value","");option.setAttribute("sf-field-model","replaceAll");if(angular.version.major===1&&angular.version.minor<4){option.setAttribute("ng-if","$$value$$ === undefined")}else{option.setAttribute("ng-show","$$value$$ === undefined")}option.textContent=args.form.placeholder;selectBox.appendChild(option)}};var defaults=[sfField,ngModel,ngModelOptions,condition];decoratorsProvider.defineDecorator("bootstrapDecorator",{actions:{template:actionsTemplate,builder:defaults},array:{template:arrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},button:{template:submitTemplate,builder:defaults},checkbox:{template:checkboxTemplate,builder:defaults},checkboxes:{template:checkboxesTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},conditional:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},default:{template:defaultTemplate,builder:defaults},fieldset:{template:fieldsetTemplate,builder:[sfField,simpleTransclusion,condition]},help:{template:helpTemplate,builder:defaults},number:{template:defaultTemplate,builder:defaults.concat(numeric)},password:{template:defaultTemplate,builder:defaults},radios:{template:radiosTemplate,builder:defaults},"radios-inline":{template:radiosInlineTemplate,builder:defaults},radiobuttons:{template:radiobuttonsTemplate,builder:defaults},section:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},select:{template:selectTemplate,builder:defaults.concat(selectPlaceholder)},submit:{template:submitTemplate,builder:defaults},tabarray:{template:tabarrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},tabs:{template:tabsTemplate,builder:[sfField,ngModelOptions,tabs,condition]},textarea:{template:textareaTemplate,builder:defaults}},[])}function sfCamelKeyFilter(){return function(formKey){if(!formKey){return""}var part,i,key;key=formKey.slice();for(i=0;i<key.length;i++){part=key[i].toLowerCase().split("");if(i&&part.length){part[0]=part[0].toUpperCase()}key[i]=part.join("")}return key.join("")}}},function(module,exports){var path="bootstrap/actions.html";var html='<div class="btn-group schema-form-actions {{::form.htmlClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/array.html";var html='<div  class="schema-form-array {{::form.htmlClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkbox.html";var html='<div class="checkbox schema-form-checkbox {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{form.key.slice(-1)[0]}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkboxes.html";var html='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{form.key.slice(-1)[0]}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/default.html";var html='<div class="form-group {{::form.htmlClass}}"\r\n     ng-class="{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{form.key.slice(-1)[0]}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{form.key.slice(-1)[0]}}"\r\n         aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{form.key.slice(-1)[0]}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{form.key.slice(-1)[0]}}"\r\n           aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{form.key.slice(-1)[0] + \'Status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/fieldset.html";var html='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/help.html";var html='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radio-buttons.html";var html='<div class="form-group schema-form-radiobuttons {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios-inline.html";var html='<div class="form-group schema-form-radios-inline {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios.html";var html='<div class="form-group schema-form-radios {{::form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/section.html";var html='<div class="schema-form-section {{::form.htmlClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/select.html";var html='<div class="form-group {{::form.htmlClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{form.key.slice(-1)[0]}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/submit.html";var html='<div class="form-group schema-form-submit {{::form.htmlClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabarray.html";var html='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabs.html";var html='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/textarea.html";var html='<div class="form-group has-feedback {{::form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{form.key.slice(-1)[0]}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{form.key.slice(-1)[0]}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{form.key.slice(-1)[0]}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{form.key.slice(-1)[0]}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports,__webpack_require__){/*!
 	 * angular-schema-form
 	 * @version 1.0.0-alpha.2
 	 * @link https://github.com/json-schema-form/angular-schema-form
 	 * @license MIT
 	 * Copyright (c) 2016 JSON Schema Form
 	 */
-(function webpackUniversalModuleDefinition(root,factory){if(true)module.exports=factory(__webpack_require__(19),__webpack_require__(20));else if(typeof define==="function"&&define.amd)define(["angular","tv4"],factory);else{var a=typeof exports==="object"?factory(require("angular"),require("tv4")):factory(root["angular"],root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_2__,__WEBPACK_EXTERNAL_MODULE_7__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){module.exports=__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _builder=__webpack_require__(3);var _builder2=_interopRequireDefault(_builder);var _decorators=__webpack_require__(4);var _decorators2=_interopRequireDefault(_decorators);var _schemaForm=__webpack_require__(5);var _schemaForm2=_interopRequireDefault(_schemaForm);var _jsonSchemaFormCore=__webpack_require__(6);var _validator=__webpack_require__(8);var _validator2=_interopRequireDefault(_validator);var _errors=__webpack_require__(9);var _errors2=_interopRequireDefault(_errors);var _sfPath=__webpack_require__(10);var _sfPath2=_interopRequireDefault(_sfPath);var _array=__webpack_require__(11);var _array2=_interopRequireDefault(_array);var _changed=__webpack_require__(12);var _changed2=_interopRequireDefault(_changed);var _field=__webpack_require__(13);var _field2=_interopRequireDefault(_field);var _message=__webpack_require__(14);var _message2=_interopRequireDefault(_message);var _newArray=__webpack_require__(15);var _newArray2=_interopRequireDefault(_newArray);var _keyController=__webpack_require__(16);var _keyController2=_interopRequireDefault(_keyController);var _schemaForm3=__webpack_require__(17);var _schemaForm4=_interopRequireDefault(_schemaForm3);var _schemaValidate=__webpack_require__(18);var _schemaValidate2=_interopRequireDefault(_schemaValidate);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}var deps=[];try{_angular2.default.module("ngSanitize");deps.push("ngSanitize")}catch(e){}try{_angular2.default.module("ui.sortable");deps.push("ui.sortable")}catch(e){}try{_angular2.default.module("angularSpectrumColorpicker");deps.push("angularSpectrumColorpicker")}catch(e){}_angular2.default.module("schemaForm",deps).provider("sfPath",_sfPath2.default).provider("sfBuilder",["sfPathProvider",_builder2.default]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",_decorators2.default]).provider("sfErrorMessage",_errors2.default).provider("schemaForm",["sfPathProvider",_schemaForm2.default]).factory("sfSelect",function(){return _jsonSchemaFormCore.select}).factory("sfValidator",_validator2.default).directive("sfArray",["sfSelect","schemaForm","sfValidator","sfPath",_array2.default]).directive("sfChanged",_changed2.default).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",_field2.default]).directive("sfMessage",["$injector","sfErrorMessage",_message2.default]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",_newArray2.default]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",_schemaForm4.default]).directive("schemaValidate",["sfValidator","$parse","sfSelect",_schemaValidate2.default]).directive("sfKeyController",["schemaForm","sfPath",_keyController2.default])},function(module,exports){module.exports=angular},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfPathProvider){var SNAKE_CASE_REGEXP=/[A-Z]/g;var snakeCase=function snakeCase(name,separator){separator=separator||"_";return name.replace(SNAKE_CASE_REGEXP,function(letter,pos){return(pos?separator:"")+letter.toLowerCase()})};var formId=0;var builders={sfField:function sfField(args){args.fieldFrag.firstChild.setAttribute("sf-field",formId);args.lookup["f"+formId]=args.form;formId++},ngModel:function ngModel(args){if(!args.form.key){return}var key=args.form.key;if(args.state.keyRedaction){key=key.slice(args.state.keyRedaction)}var modelValue;if(!args.state.modelValue){var strKey=sfPathProvider.stringify(key).replace(/"/g,"&quot;");modelValue=args.state.modelName||"model";if(strKey){modelValue+=(strKey[0]!=="["?".":"")+strKey}}else{modelValue=args.state.modelValue}var nodes=args.fieldFrag.querySelectorAll("[sf-field-model]");for(var i=0;i<nodes.length;i++){var n=nodes[i];var conf=n.getAttribute("sf-field-model");if(!conf||conf===""){n.setAttribute("ng-model",modelValue)}else if(conf==="replaceAll"){var attributes=n.attributes;for(var j=0;j<attributes.length;j++){if(attributes[j].value&&attributes[j].value.indexOf("$$value")!==-1){attributes[j].value=attributes[j].value.replace(/\$\$value\$\$/g,modelValue)}}}else{var val=n.getAttribute(conf);if(val&&val.indexOf("$$value$$")){n.setAttribute(conf,val.replace(/\$\$value\$\$/g,modelValue))}else{n.setAttribute(conf,modelValue)}}}},simpleTransclusion:function simpleTransclusion(args){var children=args.build(args.form.items,args.path+".items",args.state);args.fieldFrag.firstChild.appendChild(children)},ngModelOptions:function ngModelOptions(args){if(args.form.ngModelOptions&&Object.keys(args.form.ngModelOptions).length>0){args.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(args.form.ngModelOptions))}},transclusion:function transclusion(args){var transclusions=args.fieldFrag.querySelectorAll("[sf-field-transclude]");if(transclusions.length){for(var i=0;i<transclusions.length;i++){var n=transclusions[i];var sub=n.getAttribute("sf-field-transclude")||"items";var items=args.form[sub];if(items){var childFrag=args.build(items,args.path+"."+sub,args.state);n.appendChild(childFrag)}}}},condition:function condition(args){if(args.form.condition){var evalExpr="evalExpr("+args.path+'.condition, { model: model, "arrayIndex": $index})';if(args.form.key){var strKey=sfPathProvider.stringify(args.form.key);var arrayDepth=args.form.key.filter(function(e){return e===""}).length;var arrayIndices=arrayDepth>1?Array(arrayDepth-1).join("$parent.$parent.$parent.")+"$parent.$parent.$index,":"";for(var i=arrayDepth;i>2;i--){arrayIndices+=Array(i-1).join("$parent.$parent.$parent.")+"$index,"}arrayIndices+="$index";evalExpr="evalExpr("+args.path+'.condition,{ model: model, "arrayIndex": $index, '+'"arrayIndices": ['+arrayIndices+"],"+'"modelValue": model'+(strKey[0]==="["?"":".")+strKey+"})"}var children=args.fieldFrag.children||args.fieldFrag.childNodes;for(var i=0;i<children.length;i++){var child=children[i];var ngIf=child.getAttribute("ng-if");child.setAttribute("ng-if",ngIf?"("+ngIf+") || ("+evalExpr+")":evalExpr)}}},array:function array(args){var items=args.fieldFrag.querySelector("[schema-form-array-items]");if(args.form.key){var arrayDepth=args.form.key.filter(function(e){return e===""}).length}if(items){var state=angular.copy(args.state);state.keyRedaction=0;state.keyRedaction+=args.form.key.length+1;if(args.form.schema&&args.form.schema.items&&args.form.schema.items.type&&args.form.schema.items.type.indexOf("object")===-1&&args.form.schema.items.type.indexOf("array")===-1){var strKey=sfPathProvider.stringify(args.form.key).replace(/"/g,"&quot;")+"[$index]";state.modelValue="modelArray[$index]"}else{state.modelName="item"}state.arrayCompatFlag=true;var childFrag=args.build(args.form.items,args.path+".items",state);items.appendChild(childFrag)}},numeric:function numeric(args){var inputFrag=args.fieldFrag.querySelector("input");var maximum=args.form.maximum||false;var exclusiveMaximum=args.form.exclusiveMaximum||false;var minimum=args.form.minimum||false;var exclusiveMinimum=args.form.exclusiveMinimum||false;var multipleOf=args.form.multipleOf||false;if(inputFrag){if(multipleOf!==false){inputFrag.setAttribute("step",multipleOf)}if(maximum!==false){if(exclusiveMaximum!==false&&multipleOf!==false){maximum=maximum-multipleOf}inputFrag.setAttribute("max",maximum)}if(minimum!==false){if(exclusiveMinimum!==false&&multipleOf!==false){minimum=minimum+multipleOf}inputFrag.setAttribute("min",minimum)}}}};this.builders=builders;var stdBuilders=[builders.sfField,builders.ngModel,builders.ngModelOptions,builders.condition];this.stdBuilders=stdBuilders;this.$get=["$templateCache","schemaFormDecorators","sfPath",function($templateCache,schemaFormDecorators,sfPath){var checkForSlot=function checkForSlot(form,slots){if(form.key){var slot=slots[sfPath.stringify(form.key)];if(slot){while(slot.firstChild){slot.removeChild(slot.firstChild)}return slot}}};var _build=function _build(items,decorator,templateFn,slots,path,state,lookup){state=state||{};state=state||{};lookup=lookup||Object.create(null);path=path||"schemaForm.form";var container=document.createDocumentFragment();items.reduce(function(frag,f,index){if(!f.type){return frag}var field=decorator[f.type]||decorator["default"];if(!field.replace){var n=document.createElement(snakeCase(decorator.__name,"-"));if(state.arrayCompatFlag){n.setAttribute("form","copyWithIndex($index)")}else{n.setAttribute("form",path+"["+index+"]")}(checkForSlot(f,slots)||frag).appendChild(n)}else{var tmpl;state.arrayCompatFlag=false;var div=document.createElement("div");var template=templateFn(f,field)||templateFn(f,decorator["default"]);div.innerHTML=template;tmpl=document.createDocumentFragment();while(div.childNodes.length>0){tmpl.appendChild(div.childNodes[0])}var args={fieldFrag:tmpl,form:f,lookup:lookup,state:state,path:path+"["+index+"]",build:function build(items,path,state){return _build(items,decorator,templateFn,slots,path,state,lookup)}};var builderFn=f.builder||field.builder;if(typeof builderFn==="function"){builderFn(args)}else{builderFn.forEach(function(fn){fn(args)})}(checkForSlot(f,slots)||frag).appendChild(tmpl)}return frag},container);return container};return{build:function build(form,decorator,slots,lookup){return _build(form,decorator,function(form,field){if(form.type==="template"){return form.template}return $templateCache.get(field.template)},slots,undefined,undefined,lookup)},builder:builders,stdBuilders:stdBuilders,internalBuild:_build}}]}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($compileProvider,sfPathProvider){var defaultDecorator="";var decorators={};var templateUrl=function templateUrl(name,form){if(name==="sfDecorator"){name=defaultDecorator}var decorator=decorators[name];if(decorator[form.type]){return decorator[form.type].template}return decorator["default"].template};var createDirective=function createDirective(name){$compileProvider.directive(name,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function($parse,$compile,$http,$templateCache,$interpolate,$q,sfErrorMessage,sfPath,sfSelect){return{restrict:"AE",replace:false,transclude:false,scope:true,require:["^sfSchema","?^form"],link:function link(scope,element,attrs,ctrl){var sfSchema=ctrl[0];var formCtrl=ctrl[1];scope.$on("schemaFormPropagateNgModelController",function(event,ngModel){event.stopPropagation();event.preventDefault();scope.ngModel=ngModel});scope.showTitle=function(){return scope.form&&scope.form.notitle!==true&&scope.form.title};scope.fieldId=function(prependFormName,omitArrayIndexes){var key=scope.parentKey||[];if(scope.form.key){if(typeof key[key.length-1]==="number"){var combinedKey=key.concat(scope.form.key.slice(-1));var formName=prependFormName&&formCtrl&&formCtrl.$name?formCtrl.$name:undefined;return sfPath.name(combinedKey,"-",formName,omitArrayIndexes)}else{var formName=prependFormName&&formCtrl&&formCtrl.$name?formCtrl.$name:undefined;return sfPath.name(scope.form.key,"-",formName,omitArrayIndexes)}}else{return""}};scope.listToCheckboxValues=function(list){var values={};_angular2.default.forEach(list,function(v){values[v]=true});return values};scope.checkboxValuesToList=function(values){var lst=[];_angular2.default.forEach(values,function(v,k){if(v){lst.push(k)}});return lst};scope.buttonClick=function($event,form){if(_angular2.default.isFunction(form.onClick)){form.onClick($event,form)}else if(_angular2.default.isString(form.onClick)){if(sfSchema){sfSchema.evalInParentScope(form.onClick,{$event:$event,form:form})}else{scope.$eval(form.onClick,{$event:$event,form:form})}}};scope.evalExpr=function(expression,locals){if(sfSchema){return sfSchema.evalInParentScope(expression,locals)}return scope.$eval(expression,locals)};scope.evalInScope=function(expression,locals){if(expression){return scope.$eval(expression,locals)}};scope.interp=function(expression,locals){return expression&&$interpolate(expression)(locals)};scope.hasSuccess=function(){if(!scope.ngModel){return false}if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return scope.ngModel.$valid&&!scope.ngModel.$pristine&&!scope.ngModel.$isEmpty(scope.ngModel.$modelValue)}else{return scope.ngModel.$valid&&(!scope.ngModel.$pristine||!scope.ngModel.$isEmpty(scope.ngModel.$modelValue))}};scope.hasError=function(){if(!scope.ngModel){return false}return scope.ngModel.$invalid&&!scope.ngModel.$pristine};scope.errorMessage=function(schemaError){return sfErrorMessage.interpolate(schemaError&&schemaError.code+""||"default",scope.ngModel&&scope.ngModel.$modelValue||"",scope.ngModel&&scope.ngModel.$viewValue||"",scope.form,scope.options&&scope.options.validationMessage)};var once=scope.$watch(attrs.form,function(form){if(form){form.ngModelOptions=form.ngModelOptions||{};scope.form=form;var templatePromise;if(form.type==="template"&&form.template){templatePromise=$q.when(form.template)}else{var url=form.type==="template"?form.templateUrl:templateUrl(name,form);templatePromise=$http.get(url,{cache:$templateCache}).then(function(res){return res.data})}templatePromise.then(function(template){if(form.key){var key=form.key?sfPathProvider.stringify(form.key).replace(/"/g,"&quot;"):"";template=template.replace(/\$\$value\$\$/g,"model"+(key[0]!=="["?".":"")+key)}element.html(template);if(form.condition){var evalExpr='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';if(form.key){evalExpr="evalExpr(form.condition, {"+'model: model, "arrayIndex": arrayIndex, "modelValue": model'+sfPath.stringify(form.key)+"})"}_angular2.default.forEach(element.children(),function(child){var ngIf=child.getAttribute("ng-if");child.setAttribute("ng-if",ngIf?"("+ngIf+") || ("+evalExpr+")":evalExpr)})}$compile(element.contents())(scope)});if(form.key){scope.$on("schemaForm.error."+form.key.join("."),function(event,error,validationMessage,validity,formName){formName=validity;if(validationMessage===true||validationMessage===false){validity=validationMessage;validationMessage=undefined}if(formName!=undefined&&scope.ngModel.$$parentForm.$name!==formName){return}if(scope.ngModel&&error){if(scope.ngModel.$setDirty){scope.ngModel.$setDirty()}else{scope.ngModel.$dirty=true;scope.ngModel.$pristine=false}if(validationMessage){if(!form.validationMessage){form.validationMessage={}}form.validationMessage[error]=validationMessage}scope.ngModel.$setValidity(error,validity===true);if(validity===true){scope.ngModel.$validate();scope.$broadcast("schemaFormValidate")}}});scope.$on("$destroy",function(){if(!scope.externalDestructionInProgress){var destroyStrategy=form.destroyStrategy||scope.options&&scope.options.destroyStrategy||"remove";if(form.key&&destroyStrategy!=="retain"){var obj=scope.model;if(form.key.length>1){obj=sfSelect(form.key.slice(0,form.key.length-1),obj)}if(obj===undefined){return}var type=form.schema&&form.schema.type||"";if(destroyStrategy==="empty"&&type.indexOf("string")!==-1){obj[form.key.slice(-1)]=""}else if(destroyStrategy==="empty"&&type.indexOf("object")!==-1){obj[form.key.slice(-1)]={}}else if(destroyStrategy==="empty"&&type.indexOf("array")!==-1){obj[form.key.slice(-1)]=[]}else if(destroyStrategy==="null"){obj[form.key.slice(-1)]=null}else{delete obj[form.key.slice(-1)]}}}})}once()}})}}}])};var createManualDirective=function createManualDirective(type,templateUrl,transclude){transclude=_angular2.default.isDefined(transclude)?transclude:false;$compileProvider.directive("sf"+_angular2.default.uppercase(type[0])+type.substr(1),function(){return{restrict:"EAC",scope:true,replace:true,transclude:transclude,template:'<sf-decorator form="form"></sf-decorator>',link:function link(scope,element,attrs){var watchThis={items:"c",titleMap:"c",schema:"c"};var form={type:type};var once=true;_angular2.default.forEach(attrs,function(value,name){if(name[0]!=="$"&&name.indexOf("ng")!==0&&name!=="sfField"){var updateForm=function updateForm(val){if(_angular2.default.isDefined(val)&&val!==form[name]){form[name]=val;if(once&&form.type&&(form.key||_angular2.default.isUndefined(attrs.key))){scope.form=form;once=false}}};if(name==="model"){scope.$watch(value,function(val){if(val&&scope.model!==val){scope.model=val}})}else if(watchThis[name]==="c"){scope.$watchCollection(value,updateForm)}else{attrs.$observe(name,updateForm)}}})}}})};this.createDecorator=function(name,templates){decorators[name]={__name:name};_angular2.default.forEach(templates,function(url,type){decorators[name][type]={template:url,replace:false,builder:[]}});if(!decorators[defaultDecorator]){defaultDecorator=name}createDirective(name)};this.defineDecorator=function(name,fields){decorators[name]={__name:name};_angular2.default.forEach(fields,function(field,type){field.builder=field.builder||[];field.replace=_angular2.default.isDefined(field.replace)?field.replace:true;decorators[name][type]=field});if(!decorators[defaultDecorator]){defaultDecorator=name}createDirective(name)};this.createDirective=createManualDirective;this.createDirectives=function(templates){_angular2.default.forEach(templates,function(url,type){createManualDirective(type,url)})};this.decorator=function(name){name=name||defaultDecorator;return decorators[name]};this.addMapping=function(name,type,url,builder,replace){if(decorators[name]){decorators[name][type]={template:url,builder:builder,replace:!!replace}}};this.defineAddOn=function(name,type,url,builder){if(decorators[name]){decorators[name][type]={template:url,builder:builder,replace:true}}};this.$get=function(){return{decorator:function decorator(name){return decorators[name]||decorators[defaultDecorator]},defaultDecorator:defaultDecorator}};createDirective("sfDecorator")};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var postProcessFn=function postProcessFn(form){return form};var defaults=_jsonSchemaFormCore.schemaDefaults.createDefaults();this.defaults=defaults;this.stdFormObj=_jsonSchemaFormCore.schemaDefaults.stdFormObj;this.defaultFormDefinition=_jsonSchemaFormCore.schemaDefaults.defaultFormDefinition;this.postProcess=function(fn){postProcessFn=fn};this.appendRule=function(type,rule){if(!defaults[type]){defaults[type]=[]}defaults[type].push(rule)};this.prependRule=function(type,rule){if(!defaults[type]){defaults[type]=[]}defaults[type].unshift(rule)};this.createStandardForm=_jsonSchemaFormCore.schemaDefaults.stdFormObj;this.$get=function(){var service={};var typeDefault=this.defaults;service.merge=function(schema,form,ignore,options,readonly,asyncTemplates){form=form||["*"];options=options||{};readonly=readonly||schema.readonly||schema.readOnly;var stdForm=_jsonSchemaFormCore.schemaDefaults.defaultForm(schema,typeDefault,ignore,options);var idx=form.indexOf("*");if(idx!==-1){form=form.slice(0,idx).concat(stdForm.form).concat(form.slice(idx+1))}var canonical=(0,_jsonSchemaFormCore.merge)(stdForm.lookup,form,options,readonly,asyncTemplates);return postProcessFn(canonical)};service.defaults=_jsonSchemaFormCore.schemaDefaults.defaultForm;service.typeDefault=typeDefault;service.traverseSchema=_jsonSchemaFormCore.traverseSchema;service.traverseForm=_jsonSchemaFormCore.traverseForm;return service}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _jsonSchemaFormCore=__webpack_require__(6);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){/*!
+(function webpackUniversalModuleDefinition(root,factory){if(true)module.exports=factory(__webpack_require__(19),__webpack_require__(20));else if(typeof define==="function"&&define.amd)define(["angular","tv4"],factory);else{var a=typeof exports==="object"?factory(require("angular"),require("tv4")):factory(root["angular"],root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_2__,__WEBPACK_EXTERNAL_MODULE_7__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){module.exports=__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _builder=__webpack_require__(3);var _builder2=_interopRequireDefault(_builder);var _decorators=__webpack_require__(4);var _decorators2=_interopRequireDefault(_decorators);var _schemaForm=__webpack_require__(5);var _schemaForm2=_interopRequireDefault(_schemaForm);var _jsonSchemaFormCore=__webpack_require__(6);var _validator=__webpack_require__(8);var _validator2=_interopRequireDefault(_validator);var _errors=__webpack_require__(9);var _errors2=_interopRequireDefault(_errors);var _sfPath=__webpack_require__(10);var _sfPath2=_interopRequireDefault(_sfPath);var _array=__webpack_require__(11);var _array2=_interopRequireDefault(_array);var _changed=__webpack_require__(12);var _changed2=_interopRequireDefault(_changed);var _field=__webpack_require__(13);var _field2=_interopRequireDefault(_field);var _message=__webpack_require__(14);var _message2=_interopRequireDefault(_message);var _newArray=__webpack_require__(15);var _newArray2=_interopRequireDefault(_newArray);var _keyController=__webpack_require__(16);var _keyController2=_interopRequireDefault(_keyController);var _schemaForm3=__webpack_require__(17);var _schemaForm4=_interopRequireDefault(_schemaForm3);var _schemaValidate=__webpack_require__(18);var _schemaValidate2=_interopRequireDefault(_schemaValidate);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}var deps=[];try{_angular2.default.module("ngSanitize");deps.push("ngSanitize")}catch(e){}try{_angular2.default.module("ui.sortable");deps.push("ui.sortable")}catch(e){}try{_angular2.default.module("angularSpectrumColorpicker");deps.push("angularSpectrumColorpicker")}catch(e){}_angular2.default.module("schemaForm",deps).provider("sfPath",_sfPath2.default).provider("sfBuilder",["sfPathProvider",_builder2.default]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",_decorators2.default]).provider("sfErrorMessage",_errors2.default).provider("schemaForm",["sfPathProvider",_schemaForm2.default]).factory("sfSelect",function(){return _jsonSchemaFormCore.select}).factory("sfValidator",_validator2.default).directive("sfArray",["sfSelect","schemaForm","sfValidator","sfPath",_array2.default]).directive("sfChanged",_changed2.default).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",_field2.default]).directive("sfMessage",["$injector","sfErrorMessage",_message2.default]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",_newArray2.default]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",_schemaForm4.default]).directive("schemaValidate",["sfValidator","$parse","sfSelect",_schemaValidate2.default]).directive("sfKeyController",["schemaForm","sfPath",_keyController2.default])},function(module,exports){module.exports=angular},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfPathProvider){var SNAKE_CASE_REGEXP=/[A-Z]/g;var snakeCase=function snakeCase(name,separator){separator=separator||"_";return name.replace(SNAKE_CASE_REGEXP,function(letter,pos){return(pos?separator:"")+letter.toLowerCase()})};var formId=0;var builders={sfField:function sfField(args){args.fieldFrag.firstChild.setAttribute("sf-field",formId);args.lookup["f"+formId]=args.form;formId++},ngModel:function ngModel(args){if(!args.form.key){return}var key=args.form.key;if(args.state.keyRedaction){key=key.slice(args.state.keyRedaction)}var modelValue;if(!args.state.modelValue){var strKey=sfPathProvider.stringify(key).replace(/"/g,"&quot;");modelValue=args.state.modelName||"model";if(strKey){modelValue+=(strKey[0]!=="["?".":"")+strKey}}else{modelValue=args.state.modelValue}var nodes=args.fieldFrag.querySelectorAll("[sf-field-model]");for(var i=0;i<nodes.length;i++){var n=nodes[i];var conf=n.getAttribute("sf-field-model");if(!conf||conf===""){n.setAttribute("ng-model",modelValue)}else if(conf==="replaceAll"){var attributes=n.attributes;for(var j=0;j<attributes.length;j++){if(attributes[j].value&&attributes[j].value.indexOf("$$value")!==-1){attributes[j].value=attributes[j].value.replace(/\$\$value\$\$/g,modelValue)}}}else{var val=n.getAttribute(conf);if(val&&val.indexOf("$$value$$")){n.setAttribute(conf,val.replace(/\$\$value\$\$/g,modelValue))}else{n.setAttribute(conf,modelValue)}}}},simpleTransclusion:function simpleTransclusion(args){var children=args.build(args.form.items,args.path+".items",args.state);args.fieldFrag.firstChild.appendChild(children)},ngModelOptions:function ngModelOptions(args){if(args.form.ngModelOptions&&Object.keys(args.form.ngModelOptions).length>0){args.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(args.form.ngModelOptions))}},transclusion:function transclusion(args){var transclusions=args.fieldFrag.querySelectorAll("[sf-field-transclude]");if(transclusions.length){for(var i=0;i<transclusions.length;i++){var n=transclusions[i];var sub=n.getAttribute("sf-field-transclude")||"items";var items=args.form[sub];if(items){var childFrag=args.build(items,args.path+"."+sub,args.state);n.appendChild(childFrag)}}}},condition:function condition(args){if(args.form.condition){var evalExpr="evalExpr("+args.path+'.condition, { model: model, "arrayIndex": $index})';if(args.form.key){var strKey=sfPathProvider.stringify(args.form.key);var arrayDepth=args.form.key.filter(function(e){return e===""}).length;var arrayIndices=arrayDepth>1?Array(arrayDepth-1).join("$parent.$parent.$parent.")+"$parent.$parent.$index,":"";for(var i=arrayDepth;i>2;i--){arrayIndices+=Array(i-1).join("$parent.$parent.$parent.")+"$index,"}arrayIndices+="$index";evalExpr="evalExpr("+args.path+'.condition,{ model: model, "arrayIndex": $index, '+'"arrayIndices": ['+arrayIndices+"],"+'"modelValue": model'+(strKey[0]==="["?"":".")+strKey+"})"}var children=args.fieldFrag.children||args.fieldFrag.childNodes;for(var i=0;i<children.length;i++){var child=children[i];var ngIf=child.getAttribute("ng-if");child.setAttribute("ng-if",ngIf?"("+ngIf+") || ("+evalExpr+")":evalExpr)}}},array:function array(args){var items=args.fieldFrag.querySelector("[schema-form-array-items]");if(args.form.key){var arrayDepth=args.form.key.filter(function(e){return e===""}).length}if(items){var state=angular.copy(args.state);state.keyRedaction=0;state.keyRedaction+=args.form.key.length+1;if(args.form.schema&&args.form.schema.items&&args.form.schema.items.type&&args.form.schema.items.type.indexOf("object")===-1&&args.form.schema.items.type.indexOf("array")===-1){var strKey=sfPathProvider.stringify(args.form.key).replace(/"/g,"&quot;")+"[$index]";state.modelValue="modelArray[$index]"}else{state.modelName="item"}state.arrayCompatFlag=true;var childFrag=args.build(args.form.items,args.path+".items",state);items.appendChild(childFrag)}},numeric:function numeric(args){var inputFrag=args.fieldFrag.querySelector("input");var maximum=args.form.maximum||false;var exclusiveMaximum=args.form.exclusiveMaximum||false;var minimum=args.form.minimum||false;var exclusiveMinimum=args.form.exclusiveMinimum||false;var multipleOf=args.form.multipleOf||false;if(inputFrag){if(multipleOf!==false){inputFrag.setAttribute("step",multipleOf)}if(maximum!==false){if(exclusiveMaximum!==false&&multipleOf!==false){maximum=maximum-multipleOf}inputFrag.setAttribute("max",maximum)}if(minimum!==false){if(exclusiveMinimum!==false&&multipleOf!==false){minimum=minimum+multipleOf}inputFrag.setAttribute("min",minimum)}}}};this.builders=builders;var stdBuilders=[builders.sfField,builders.ngModel,builders.ngModelOptions,builders.condition];this.stdBuilders=stdBuilders;this.$get=["$templateCache","schemaFormDecorators","sfPath",function($templateCache,schemaFormDecorators,sfPath){var checkForSlot=function checkForSlot(form,slots){if(form.key){var slot=slots[sfPath.stringify(form.key)];if(slot){while(slot.firstChild){slot.removeChild(slot.firstChild)}return slot}}};var _build=function _build(items,decorator,templateFn,slots,path,state,lookup){state=state||{};state=state||{};lookup=lookup||Object.create(null);path=path||"schemaForm.form";var container=document.createDocumentFragment();items.reduce(function(frag,f,index){if(!f.type){return frag}var field=decorator[f.type]||decorator["default"];if(!field.replace){var n=document.createElement(snakeCase(decorator.__name,"-"));if(state.arrayCompatFlag){n.setAttribute("form","copyWithIndex($index)")}else{n.setAttribute("form",path+"["+index+"]")}(checkForSlot(f,slots)||frag).appendChild(n)}else{var tmpl;state.arrayCompatFlag=false;var div=document.createElement("div");var template=templateFn(f,field)||templateFn(f,decorator["default"]);div.innerHTML=template;tmpl=document.createDocumentFragment();while(div.childNodes.length>0){tmpl.appendChild(div.childNodes[0])}var args={fieldFrag:tmpl,form:f,lookup:lookup,state:state,path:path+"["+index+"]",build:function build(items,path,state){return _build(items,decorator,templateFn,slots,path,state,lookup)}};var builderFn=f.builder||field.builder;if(typeof builderFn==="function"){builderFn(args)}else{builderFn.forEach(function(fn){fn(args)})}(checkForSlot(f,slots)||frag).appendChild(tmpl)}return frag},container);return container};return{build:function build(form,decorator,slots,lookup){return _build(form,decorator,function(form,field){if(form.type==="template"){return form.template}return $templateCache.get(field.template)},slots,undefined,undefined,lookup)},builder:builders,stdBuilders:stdBuilders,internalBuild:_build}}]}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($compileProvider,sfPathProvider){var defaultDecorator="";var decorators={};var templateUrl=function templateUrl(name,form){if(name==="sfDecorator"){name=defaultDecorator}var decorator=decorators[name];if(decorator[form.type]){return decorator[form.type].template}return decorator["default"].template};var createDirective=function createDirective(name){$compileProvider.directive(name,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function($parse,$compile,$http,$templateCache,$interpolate,$q,sfErrorMessage,sfPath,sfSelect){return{restrict:"AE",replace:false,transclude:false,scope:true,require:["^sfSchema","?^form"],link:function link(scope,element,attrs,ctrl){var sfSchema=ctrl[0];var formCtrl=ctrl[1];scope.$on("schemaFormPropagateNgModelController",function(event,ngModel){event.stopPropagation();event.preventDefault();scope.ngModel=ngModel});scope.showTitle=function(){return scope.form&&scope.form.notitle!==true&&scope.form.title};scope.fieldId=function(prependFormName,omitArrayIndexes){var key=scope.parentKey||[];if(scope.form.key){if(typeof key[key.length-1]==="number"){var combinedKey=key.concat(scope.form.key.slice(-1));var formName=prependFormName&&formCtrl&&formCtrl.$name?formCtrl.$name:undefined;return sfPath.name(combinedKey,"-",formName,omitArrayIndexes)}else{var formName=prependFormName&&formCtrl&&formCtrl.$name?formCtrl.$name:undefined;return sfPath.name(scope.form.key,"-",formName,omitArrayIndexes)}}else{return""}};scope.listToCheckboxValues=function(list){var values={};_angular2.default.forEach(list,function(v){values[v]=true});return values};scope.checkboxValuesToList=function(values){var lst=[];_angular2.default.forEach(values,function(v,k){if(v){lst.push(k)}});return lst};scope.buttonClick=function($event,form){if(_angular2.default.isFunction(form.onClick)){form.onClick($event,form)}else if(_angular2.default.isString(form.onClick)){if(sfSchema){sfSchema.evalInParentScope(form.onClick,{$event:$event,form:form})}else{scope.$eval(form.onClick,{$event:$event,form:form})}}};scope.evalExpr=function(expression,locals){if(sfSchema){return sfSchema.evalInParentScope(expression,locals)}return scope.$eval(expression,locals)};scope.evalInScope=function(expression,locals){if(expression){return scope.$eval(expression,locals)}};scope.interp=function(expression,locals){return expression&&$interpolate(expression)(locals)};scope.hasSuccess=function(){if(!scope.ngModel){return false}if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return scope.ngModel.$valid&&!scope.ngModel.$pristine&&!scope.ngModel.$isEmpty(scope.ngModel.$modelValue)}else{return scope.ngModel.$valid&&(!scope.ngModel.$pristine||!scope.ngModel.$isEmpty(scope.ngModel.$modelValue))}};scope.hasError=function(){if(!scope.ngModel){return false}return scope.ngModel.$invalid&&!scope.ngModel.$pristine};scope.errorMessage=function(schemaError){return sfErrorMessage.interpolate(schemaError&&schemaError.code+""||"default",scope.ngModel&&scope.ngModel.$modelValue||"",scope.ngModel&&scope.ngModel.$viewValue||"",scope.form,scope.options&&scope.options.validationMessage)};var once=scope.$watch(attrs.form,function(form){if(form){form.ngModelOptions=form.ngModelOptions||{};scope.form=form;var templatePromise;if(form.type==="template"&&form.template){templatePromise=$q.when(form.template)}else{var url=form.type==="template"?form.templateUrl:templateUrl(name,form);templatePromise=$http.get(url,{cache:$templateCache}).then(function(res){return res.data})}templatePromise.then(function(template){if(form.key){var key=form.key?sfPathProvider.stringify(form.key).replace(/"/g,"&quot;"):"";template=template.replace(/\$\$value\$\$/g,"model"+(key[0]!=="["?".":"")+key)}element.html(template);if(form.condition){var evalExpr='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';if(form.key){evalExpr="evalExpr(form.condition, {"+'model: model, "arrayIndex": arrayIndex, "modelValue": model'+sfPath.stringify(form.key)+"})"}_angular2.default.forEach(element.children(),function(child){var ngIf=child.getAttribute("ng-if");child.setAttribute("ng-if",ngIf?"("+ngIf+") || ("+evalExpr+")":evalExpr)})}$compile(element.contents())(scope)});if(form.key){scope.$on("schemaForm.error."+form.key.join("."),function(event,error,validationMessage,validity,formName){formName=validity;if(validationMessage===true||validationMessage===false){validity=validationMessage;validationMessage=undefined}if(formName!=undefined&&scope.ngModel.$$parentForm.$name!==formName){return}if(scope.ngModel&&error){if(scope.ngModel.$setDirty){scope.ngModel.$setDirty()}else{scope.ngModel.$dirty=true;scope.ngModel.$pristine=false}if(validationMessage){if(!form.validationMessage){form.validationMessage={}}form.validationMessage[error]=validationMessage}scope.ngModel.$setValidity(error,validity===true);if(validity===true){scope.ngModel.$validate();scope.$broadcast("schemaFormValidate")}}});scope.$on("$destroy",function(){if(!scope.externalDestructionInProgress){var destroyStrategy=form.destroyStrategy||scope.options&&scope.options.destroyStrategy||"remove";if(form.key&&destroyStrategy!=="retain"){var obj=scope.model;if(form.key.length>1){obj=sfSelect(form.key.slice(0,form.key.length-1),obj)}if(obj===undefined){return}var type=form.schema&&form.schema.type||"";if(destroyStrategy==="empty"&&type.indexOf("string")!==-1){obj[form.key.slice(-1)]=""}else if(destroyStrategy==="empty"&&type.indexOf("object")!==-1){obj[form.key.slice(-1)]={}}else if(destroyStrategy==="empty"&&type.indexOf("array")!==-1){obj[form.key.slice(-1)]=[]}else if(destroyStrategy==="null"){obj[form.key.slice(-1)]=null}else{delete obj[form.key.slice(-1)]}}}})}once()}})}}}])};var createManualDirective=function createManualDirective(type,templateUrl,transclude){transclude=_angular2.default.isDefined(transclude)?transclude:false;$compileProvider.directive("sf"+_angular2.default.uppercase(type[0])+type.substr(1),function(){return{restrict:"EAC",scope:true,replace:true,transclude:transclude,template:'<sf-decorator form="form"></sf-decorator>',link:function link(scope,element,attrs){var watchThis={items:"c",titleMap:"c",schema:"c"};var form={type:type};var once=true;_angular2.default.forEach(attrs,function(value,name){if(name[0]!=="$"&&name.indexOf("ng")!==0&&name!=="sfField"){var updateForm=function updateForm(val){if(_angular2.default.isDefined(val)&&val!==form[name]){form[name]=val;if(once&&form.type&&(form.key||_angular2.default.isUndefined(attrs.key))){scope.form=form;once=false}}};if(name==="model"){scope.$watch(value,function(val){if(val&&scope.model!==val){scope.model=val}})}else if(watchThis[name]==="c"){scope.$watchCollection(value,updateForm)}else{attrs.$observe(name,updateForm)}}})}}})};this.createDecorator=function(name,templates){decorators[name]={__name:name};_angular2.default.forEach(templates,function(url,type){decorators[name][type]={template:url,replace:false,builder:[]}});if(!decorators[defaultDecorator]){defaultDecorator=name}createDirective(name)};this.defineDecorator=function(name,fields){decorators[name]={__name:name};_angular2.default.forEach(fields,function(field,type){field.builder=field.builder||[];field.replace=_angular2.default.isDefined(field.replace)?field.replace:true;decorators[name][type]=field});if(!decorators[defaultDecorator]){defaultDecorator=name}createDirective(name)};this.createDirective=createManualDirective;this.createDirectives=function(templates){_angular2.default.forEach(templates,function(url,type){createManualDirective(type,url)})};this.decorator=function(name){name=name||defaultDecorator;return decorators[name]};this.addMapping=function(name,type,url,builder,replace){if(decorators[name]){decorators[name][type]={template:url,builder:builder,replace:!!replace}}};this.defineAddOn=function(name,type,url,builder){if(decorators[name]){decorators[name][type]={template:url,builder:builder,replace:true}}};this.$get=function(){return{decorator:function decorator(name){return decorators[name]||decorators[defaultDecorator]},defaultDecorator:defaultDecorator}};createDirective("sfDecorator")};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var postProcessFn=function postProcessFn(form){return form};var defaults=_jsonSchemaFormCore.schemaDefaults.createDefaults();this.defaults=defaults;this.stdFormObj=_jsonSchemaFormCore.schemaDefaults.stdFormObj;this.defaultFormDefinition=_jsonSchemaFormCore.schemaDefaults.defaultFormDefinition;this.postProcess=function(fn){postProcessFn=fn};this.appendRule=function(type,rule){if(!defaults[type]){defaults[type]=[]}defaults[type].push(rule)};this.prependRule=function(type,rule){if(!defaults[type]){defaults[type]=[]}defaults[type].unshift(rule)};this.createStandardForm=_jsonSchemaFormCore.schemaDefaults.stdFormObj;this.$get=function(){var service={};var typeDefault=this.defaults;service.merge=function(schema,form,ignore,options,readonly,asyncTemplates){form=form||["*"];options=options||{};readonly=readonly||schema.readonly||schema.readOnly;var stdForm=_jsonSchemaFormCore.schemaDefaults.defaultForm(schema,typeDefault,ignore,options);var idx=form.indexOf("*");if(idx!==-1){form=form.slice(0,idx).concat(stdForm.form).concat(form.slice(idx+1))}var canonical=(0,_jsonSchemaFormCore.merge)(stdForm.lookup,form,options,readonly,asyncTemplates);return postProcessFn(canonical)};service.defaults=_jsonSchemaFormCore.schemaDefaults.defaultForm;service.typeDefault=typeDefault;service.traverseSchema=_jsonSchemaFormCore.traverseSchema;service.traverseForm=_jsonSchemaFormCore.traverseForm;return service}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _jsonSchemaFormCore=__webpack_require__(6);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){/*!
 		 * json-schema-form
 		 * @version 1.0.0-alpha.2
 		 * @link https://github.com/json-schema-form/json-schema-form-core
 		 * @license MIT
 		 * Copyright (c) 2016 JSON Schema Form
 		 */
-(function webpackUniversalModuleDefinition(root,factory){if(true)module.exports=factory(__webpack_require__(7));else if(typeof define==="function"&&define.amd)define(["tv4"],factory);else{var a=typeof exports==="object"?factory(require("tv4")):factory(root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_10__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){module.exports=__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.canonicalTitleMap=exports.schemaDefaults=exports.sfPath=undefined;var _merge=__webpack_require__(2);Object.keys(_merge).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _merge[key]}})});var _select=__webpack_require__(7);Object.keys(_select).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _select[key]}})});var _traverse=__webpack_require__(8);Object.keys(_traverse).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _traverse[key]}})});var _validate=__webpack_require__(9);Object.keys(_validate).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _validate[key]}})});var _schemaDefaults=__webpack_require__(11);var schemaDefaultsImp=_interopRequireWildcard(_schemaDefaults);var _sfPath=__webpack_require__(3);var sfPathImp=_interopRequireWildcard(_sfPath);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}function _interopRequireWildcard(obj){if(obj&&obj.__esModule){return obj}else{var newObj={};if(obj!=null){for(var key in obj){if(Object.prototype.hasOwnProperty.call(obj,key))newObj[key]=obj[key]}}newObj.default=obj;return newObj}}var sfPath=exports.sfPath=sfPathImp;var schemaDefaults=exports.schemaDefaults=schemaDefaultsImp;var canonicalTitleMap=exports.canonicalTitleMap=_canonicalTitleMap2.default},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.merge=merge;var _sfPath=__webpack_require__(3);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}function merge(lookup,form,options,readonly,asyncTemplates){form=form||[];options=options||{};return form.map(function(obj){if(typeof obj==="string"){obj={key:obj}}if(obj.key){if(typeof obj.key==="string"){obj.key=(0,_sfPath.parse)(obj.key)}}if(obj.titleMap){obj.titleMap=(0,_canonicalTitleMap2.default)(obj.titleMap)}if(obj.key){var strid=(0,_sfPath.stringify)(obj.key);if(lookup[strid]){(function(){var schemaDefaults=lookup[strid];if(schemaDefaults){Object.keys(schemaDefaults).forEach(function(attr){if(obj[attr]===undefined){obj[attr]=schemaDefaults[attr]}})}})()}}if(readonly===true){obj.readonly=true}if(obj.items){obj.items=merge(lookup,obj.items,options,obj.readonly,asyncTemplates)}if(obj.tabs){obj.tabs.forEach(function(tab){if(tab.items){tab.items=merge(lookup,tab.items,options,obj.readonly,asyncTemplates)}})}if(obj.type==="checkbox"&&obj.schema["default"]===undefined){obj.schema["default"]=false}if(asyncTemplates&&obj.type==="template"&&!obj.template&&obj.templateUrl){asyncTemplates.push(obj)}return obj})}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.name=exports.normalize=exports.stringify=exports.parse=undefined;var _objectpath=__webpack_require__(4);var name=function name(key,separator,formName,omitNumbers){if(key){var fieldKey=key;var fieldSeparator=separator||"-";if(omitNumbers){fieldKey=fieldKey.filter(function(key){return typeof key!=="number"})}return(formName?formName+fieldSeparator:"")+fieldKey.join(fieldSeparator)}return""};exports.parse=_objectpath.parse;exports.stringify=_objectpath.stringify;exports.normalize=_objectpath.normalize;exports.name=name},function(module,exports,__webpack_require__){"use strict";module.exports=__webpack_require__(5).ObjectPath},function(module,exports,__webpack_require__){var __WEBPACK_AMD_DEFINE_RESULT__;"use strict";var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};!function(undefined){var ObjectPath={parse:function parse(str){if(typeof str!=="string"){throw new TypeError("ObjectPath.parse must be passed a string")}var i=0;var parts=[];var d,b,q,c;while(i<str.length){d=str.indexOf(".",i);b=str.indexOf("[",i);if(d===-1&&b===-1){parts.push(str.slice(i,str.length));i=str.length}else if(b===-1||d!==-1&&d<b){parts.push(str.slice(i,d));i=d+1}else{if(b>i){parts.push(str.slice(i,b));i=b}q=str.slice(b+1,b+2);if(q!=='"'&&q!=="'"){c=str.indexOf("]",b);if(c===-1)c=str.length;parts.push(str.slice(i+1,c));i=str.slice(c+1,c+2)==="."?c+2:c+1}else{c=str.indexOf(q+"]",b);if(c===-1)c=str.length;while(str.slice(c-1,c)==="\\"&&b<str.length){b++;c=str.indexOf(q+"]",b)}parts.push(str.slice(i+2,c).replace(new RegExp("\\"+q,"g"),q));i=str.slice(c+2,c+3)==="."?c+3:c+2}}}return parts},stringify:function stringify(arr,quote){if(!Array.isArray(arr))arr=[arr.toString()];quote=quote==='"'?'"':"'";return arr.map(function(n){return"["+quote+n.toString().replace(new RegExp(quote,"g"),"\\"+quote)+quote+"]"}).join("")},normalize:function normalize(data,quote){return ObjectPath.stringify(Array.isArray(data)?data:ObjectPath.parse(data),quote)},registerModule:function registerModule(angular){angular.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=ObjectPath.parse;this.stringify=ObjectPath.stringify;this.normalize=ObjectPath.normalize;this.$get=function(){return ObjectPath}})}};if(true){!(__WEBPACK_AMD_DEFINE_RESULT__=function(){return{ObjectPath:ObjectPath}}.call(exports,__webpack_require__,exports,module),__WEBPACK_AMD_DEFINE_RESULT__!==undefined&&(module.exports=__WEBPACK_AMD_DEFINE_RESULT__))}else if((typeof exports==="undefined"?"undefined":_typeof(exports))==="object"){exports.ObjectPath=ObjectPath}else{window.ObjectPath=ObjectPath}}()},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.default=function(titleMap,originalEnum){if(!Array.isArray(titleMap)){var _ret=function(){var canonical=[];if(originalEnum){originalEnum.forEach(function(value){canonical.push({name:titleMap[value],value:value})})}else{Object.keys(titleMap).forEach(function(value){canonical.push({name:titleMap[value],value:value})})}return{v:canonical}}();if((typeof _ret==="undefined"?"undefined":_typeof(_ret))==="object")return _ret.v}return titleMap}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.select=select;var _sfPath=__webpack_require__(3);var _sfPath2=_interopRequireDefault(_sfPath);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}var numRe=/^\d+$/;function select(projection,obj,valueToSet){if(!obj){obj=this}var parts=typeof projection==="string"?_sfPath2.default.parse(projection):projection;if(typeof valueToSet!=="undefined"&&parts.length===1){obj[parts[0]]=valueToSet;return obj}if(typeof valueToSet!=="undefined"&&typeof obj[parts[0]]==="undefined"){obj[parts[0]]=parts.length>2&&numRe.test(parts[1])?[]:{}}var value=obj[parts[0]];for(var i=1;i<parts.length;i++){if(parts[i]===""){return undefined}if(typeof valueToSet!=="undefined"){if(i===parts.length-1){value[parts[i]]=valueToSet;return valueToSet}else{var tmp=value[parts[i]];if(typeof tmp==="undefined"||tmp===null){tmp=numRe.test(parts[i+1])?[]:{};value[parts[i]]=tmp}value=tmp}}else if(value){value=value[parts[i]]}}return value}},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.traverseSchema=traverseSchema;exports.traverseForm=traverseForm;function traverseSchema(schema,fn,path,ignoreArrays){ignoreArrays=ignoreArrays===undefined?true:ignoreArrays;path=path||[];var traverse=function traverse(schema,fn,path){fn(schema,path);if(schema.properties){Object.keys(schema.properties).forEach(function(name){var currentPath=path.slice();currentPath.push(name);traverse(schema.properties[name],fn,currentPath)})}if(!ignoreArrays&&schema.items){var arrPath=path.slice();arrPath.push("");traverse(schema.items,fn,arrPath)}};traverse(schema,fn,path||[])}function traverseForm(form,fn){fn(form);if(form.items){form.items.forEach(function(f){traverseForm(f,fn)})}if(form.tabs){form.tabs.forEach(function(tab){if(tab.items){tab.items.forEach(function(f){traverseForm(f,fn)})}})}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.validate=validate;var _tv=__webpack_require__(10);var _tv2=_interopRequireDefault(_tv);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}function validate(form,value){if(!form){return{valid:true}}var schema=form.schema;if(!schema){return{valid:true}}if(value===""){value=undefined}if(form.type==="number"&&value===null){value=undefined}var wrap={type:"object",properties:{}};var propName=form.key[form.key.length-1];wrap.properties[propName]=schema;if(form.required){wrap.required=[propName]}var valueWrap={};if(!!value){valueWrap[propName]=value}return _tv2.default.validateResult(valueWrap,wrap)}},function(module,exports){module.exports=tv4},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.defaultFormDefinition=defaultFormDefinition;exports.stdFormObj=stdFormObj;exports.text=text;exports.number=number;exports.integer=integer;exports.checkbox=checkbox;exports.select=select;exports.checkboxes=checkboxes;exports.fieldset=fieldset;exports.array=array;exports.createDefaults=createDefaults;exports.defaultForm=defaultForm;var _sfPath=__webpack_require__(3);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}var stripNullType=function stripNullType(type){if(Array.isArray(type)&&type.length==2){if(type[0]==="null"){return type[1]}if(type[1]==="null"){return type[0]}}return type};var enumToTitleMap=function enumToTitleMap(enm){var titleMap=[];enm.forEach(function(name){titleMap.push({name:name,value:name})});return titleMap};function defaultFormDefinition(schemaTypes,name,schema,options){var rules=schemaTypes[stripNullType(schema.type)];if(rules){var def=void 0;var innerDefaultFormDefinition=function innerDefaultFormDefinition(childName,childSchema,childOptions){return defaultFormDefinition(schemaTypes,childName,childSchema,childOptions)};for(var i=0;i<rules.length;i++){def=rules[i](name,schema,options,innerDefaultFormDefinition);if(def){if(def.schema["x-schema-form"]){Object.assign(def,def.schema["x-schema-form"])}return def}}}}function stdFormObj(name,schema,options){options=options||{};var f=options.global&&options.global.formDefaults?Object.assign({},options.global.formDefaults):{};if(options.global&&options.global.supressPropertyTitles===true){f.title=schema.title}else{f.title=schema.title||name}if(schema.description){f.description=schema.description}if(options.required===true||schema.required===true){f.required=true}if(schema.maxLength){f.maxlength=schema.maxLength}if(schema.minLength){f.minlength=schema.minLength}if(schema.readOnly||schema.readonly){f.readonly=true}if(schema.minimum){f.minimum=schema.minimum+(schema.exclusiveMinimum?1:0)}if(schema.maximum){f.maximum=schema.maximum-(schema.exclusiveMaximum?1:0)}if(schema.validationMessage){f.validationMessage=schema.validationMessage}if(schema.enumNames){f.titleMap=(0,_canonicalTitleMap2.default)(schema.enumNames,schema["enum"])}f.schema=schema;f.ngModelOptions=f.ngModelOptions||{};return f}function text(name,schema,options){if(stripNullType(schema.type)==="string"&&!schema["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="text";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function number(name,schema,options){if(stripNullType(schema.type)==="number"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="number";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function integer(name,schema,options){if(stripNullType(schema.type)==="integer"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="number";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function checkbox(name,schema,options){if(stripNullType(schema.type)==="boolean"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="checkbox";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function select(name,schema,options){if(stripNullType(schema.type)==="string"&&schema["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="select";if(!f.titleMap){f.titleMap=enumToTitleMap(schema["enum"])}options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function checkboxes(name,schema,options){if(stripNullType(schema.type)==="array"&&schema.items&&schema.items["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="checkboxes";if(!f.titleMap){f.titleMap=enumToTitleMap(schema.items["enum"])}options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function fieldset(name,schema,options,defaultFormDef){if(stripNullType(schema.type)==="object"){var _ret=function(){var f=stdFormObj(name,schema,options);f.type="fieldset";f.key=options.path;f.items=[];options.lookup[(0,_sfPath.stringify)(options.path)]=f;if(schema.properties){Object.keys(schema.properties).forEach(function(key){var value=schema.properties[key];var path=options.path.slice();path.push(key);if(options.ignore[(0,_sfPath.stringify)(path)]!==true){var required=schema.required&&schema.required.indexOf(key)!==-1;var def=defaultFormDef(key,value,{path:path,required:required||false,lookup:options.lookup,ignore:options.ignore,global:options.global});if(def){f.items.push(def)}}})}return{v:f}}();if((typeof _ret==="undefined"?"undefined":_typeof(_ret))==="object")return _ret.v}}function array(name,schema,options,defaultFormDef){if(stripNullType(schema.type)==="array"){var f=stdFormObj(name,schema,options);f.type="array";f.key=options.path;options.lookup[(0,_sfPath.stringify)(options.path)]=f;var required=schema.required&&schema.required.indexOf(options.path[options.path.length-1])!==-1;var arrPath=options.path.slice();arrPath.push("");f.items=[defaultFormDef(name,schema.items,{path:arrPath,required:required||false,lookup:options.lookup,ignore:options.ignore,global:options.global})];return f}}function createDefaults(){return{string:[select,text],object:[fieldset],number:[number],integer:[integer],"boolean":[checkbox],array:[checkboxes,array]}}function defaultForm(schema,defaultSchemaTypes,ignore,globalOptions){var form=[];var lookup={};ignore=ignore||{};globalOptions=globalOptions||{};defaultSchemaTypes=defaultSchemaTypes||createDefaults();if(schema.properties){Object.keys(schema.properties).forEach(function(key){if(ignore[key]!==true){var required=schema.required&&schema.required.indexOf(key)!==-1;var def=defaultFormDefinition(defaultSchemaTypes,key,schema.properties[key],{path:[key],lookup:lookup,ignore:ignore,required:required,global:globalOptions});if(def){form.push(def)}}})}else{throw new Error('Not implemented. Only type "object" allowed at root level of schema.')}return{form:form,lookup:lookup}}}])})},function(module,exports){module.exports=tv4},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var validator={};validator.validate=function(form,value){if(!form){return{valid:true}}var schema=form.schema;if(!schema){return{valid:true}}if(value===""){value=undefined}if(form.type==="number"&&value===null){value=undefined}var wrap={type:"object",properties:{}};var propName=form.key[form.key.length-1];wrap.properties[propName]=schema;if(form.required){wrap.required=[propName]}var valueWrap={};if(_angular2.default.isDefined(value)){valueWrap[propName]=value}return _tv2.default.validateResult(valueWrap,wrap)};return validator};var _tv=__webpack_require__(7);var _tv2=_interopRequireDefault(_tv);var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var defaultMessages={"default":"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};defaultMessages.number=defaultMessages[105];defaultMessages.required=defaultMessages[302];defaultMessages.min=defaultMessages[101];defaultMessages.max=defaultMessages[103];defaultMessages.maxlength=defaultMessages[201];defaultMessages.minlength=defaultMessages[200];defaultMessages.pattern=defaultMessages[202];this.setDefaultMessages=function(messages){defaultMessages=messages};this.getDefaultMessages=function(){return defaultMessages};this.setDefaultMessage=function(error,msg){defaultMessages[error]=msg};this.$get=["$interpolate",function($interpolate){var service={};service.defaultMessages=defaultMessages;service.interpolate=function(error,value,viewValue,form,global){global=global||{};var validationMessage=form.validationMessage||{};if(error.indexOf("tv4-")===0){error=error.substring(4)}var message=validationMessage["default"]||global["default"]||"";[validationMessage,global,defaultMessages].some(function(val){if(_angular2.default.isString(val)||_angular2.default.isFunction(val)){message=val;return true}if(val&&val[error]){message=val[error];return true}});var context={error:error,value:value,viewValue:viewValue,form:form,schema:form.schema,title:form.title||form.schema&&form.schema.title};if(_angular2.default.isFunction(message)){return message(context)}else{return $interpolate(message)(context)}};return service}]};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){this.parse=_jsonSchemaFormCore.sfPath.parse;this.stringify=_jsonSchemaFormCore.sfPath.stringify;this.normalize=_jsonSchemaFormCore.sfPath.normalize;this.$get=function(){return _jsonSchemaFormCore.sfPath}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _jsonSchemaFormCore=__webpack_require__(6);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfSelect,schemaForm,sfValidator,sfPath){var setIndex=function setIndex(index){return function(form){if(form.key){form.key[form.key.indexOf("")]=index}}};return{restrict:"A",scope:true,require:"?ngModel",link:function link(scope,element,attrs,ngModel){var formDefCache={};scope.validateArray=_angular2.default.noop;if(ngModel){scope.$emit("schemaFormPropagateNgModelController",ngModel)}var once=scope.$watch(attrs.sfArray,function(form){if(!form){return}var list=sfSelect(form.key,scope.model);var key=sfPath.normalize(form.key);scope.$watch("model"+(key[0]!=="["?".":"")+key,function(value){list=scope.modelArray=value});if(_angular2.default.isUndefined(list)){list=[];sfSelect(form.key,scope.model,list)}scope.modelArray=list;if(form.items){var subForm=form.items[0];if(form.items.length>1){subForm={type:"section",items:form.items.map(function(item){item.ngModelOptions=form.ngModelOptions;if(_angular2.default.isUndefined(item.readonly)){item.readonly=form.readonly}return item})}}}scope.copyWithIndex=function(index){if(!formDefCache[index]){if(subForm){var copy=_angular2.default.copy(subForm);copy.arrayIndex=index;schemaForm.traverseForm(copy,setIndex(index));formDefCache[index]=copy}}return formDefCache[index]};scope.appendToArray=function(){var len=list.length;var copy=scope.copyWithIndex(len);schemaForm.traverseForm(copy,function(part){if(part.key){var def;if(_angular2.default.isDefined(part["default"])){def=part["default"]}if(_angular2.default.isDefined(part.schema)&&_angular2.default.isDefined(part.schema["default"])){def=part.schema["default"]}if(_angular2.default.isDefined(def)){sfSelect(part.key,scope.model,def)}}});if(len===list.length){var type=sfSelect("schema.items.type",form);var dflt;if(type==="object"){dflt={}}else if(type==="array"){dflt=[]}list.push(dflt)}scope.validateArray();return list};scope.deleteFromArray=function(index){list.splice(index,1);scope.validateArray();if(ngModel&&ngModel.$setDirty){ngModel.$setDirty()}return list};if(!form.titleMap&&form.startEmpty!==true&&list.length===0){scope.appendToArray()}if(form.titleMap&&form.titleMap.length>0){scope.titleMapValues=[];var updateTitleMapValues=function updateTitleMapValues(arr){scope.titleMapValues=[];arr=arr||[];form.titleMap.forEach(function(item){scope.titleMapValues.push(arr.indexOf(item.value)!==-1)})};updateTitleMapValues(scope.modelArray);scope.$watchCollection("modelArray",updateTitleMapValues);scope.$watchCollection("titleMapValues",function(vals,old){if(vals&&vals!==old){var arr=scope.modelArray;while(arr.length>0){arr.pop()}form.titleMap.forEach(function(item,index){if(vals[index]){arr.push(item.value)}});scope.validateArray()}})}if(ngModel){var error;scope.validateArray=function(){var result=sfValidator.validate(form,scope.modelArray.length>0?scope.modelArray:undefined);Object.keys(ngModel.$error).filter(function(k){return k.indexOf("tv4-")===0}).forEach(function(k){ngModel.$setValidity(k,true)});if(result.valid===false&&result.error&&(result.error.dataPath===""||result.error.dataPath==="/"+form.key[form.key.length-1])){ngModel.$setViewValue(scope.modelArray);error=result.error;ngModel.$setValidity("tv4-"+result.error.code,false)}};scope.$on("schemaFormValidate",scope.validateArray);scope.hasSuccess=function(){if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return ngModel.$valid&&!ngModel.$pristine&&!ngModel.$isEmpty(ngModel.$modelValue)}else{return ngModel.$valid&&(!ngModel.$pristine||!ngModel.$isEmpty(ngModel.$modelValue))}};scope.hasError=function(){if(!scope.options||!scope.options.pristine||scope.options.pristine.errors!==false){return ngModel.$invalid}else{return ngModel.$invalid&&!ngModel.$pristine}};scope.schemaError=function(){return error}}once()})}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){return{require:"ngModel",restrict:"AC",scope:false,link:function link(scope,element,attrs,ctrl){var form=scope.$eval(attrs.sfChanged);if(form&&form.onChange){ctrl.$viewChangeListeners.push(function(){if(_angular2.default.isFunction(form.onChange)){form.onChange(ctrl.$modelValue,form)}else{scope.evalExpr(form.onChange,{modelValue:ctrl.$modelValue,form:form})}})}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.default=function($parse,$compile,$http,$templateCache,$interpolate,$q,sfErrorMessage,sfPath,sfSelect){var keyFormat={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:false,transclude:false,scope:true,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function pre(scope,element,attrs,ctrl){var sfSchema=ctrl[0];var formCtrl=ctrl[1];var keyCtrl=ctrl[2];scope.$on("schemaFormPropagateNgModelController",function(event,ngModel){event.stopPropagation();event.preventDefault();scope.ngModel=ngModel});scope.form=sfSchema.lookup["f"+attrs.sfField]},post:function post(scope,element,attrs,ctrl){var sfSchema=ctrl[0];var formCtrl=ctrl[1];var keyCtrl=ctrl[2];scope.showTitle=function(){return scope.form&&scope.form.notitle!==true&&scope.form.title};scope.getKey=function(requiredFormat){var format=requiredFormat||keyFormat.COMPLETE;var key=scope.parentKey?scope.parentKey.slice(0,scope.parentKey.length-1):[];if(typeof scope.$index==="number"){key=key.concat(scope.$index)}if(scope.form.key&&scope.form.key.length){if(typeof key[key.length-1]==="number"&&scope.form.key.length>=1){scope.completeKey=key.concat(scope.form.key.slice(-1))}else{scope.completeKey=scope.form.key.slice()}}if(!Array.isArray(scope.completeKey)){return undefined}if(format===keyFormat.COMPLETE){return scope.completeKey}return scope.completeKey.reduce(function(output,input,i){if(-1!==[format].indexOf(typeof input==="undefined"?"undefined":_typeof(input))){return output.concat(input)}return output},[])};if(scope.form.key)scope.completeKey=scope.getKey();scope.path=function(modelPath){var i=-1;modelPath=modelPath.replace(/\[\]/gi,function(matched){i++;return scope.$i[i]});return scope.$eval(modelPath,scope)};scope.fieldId=function(prependFormName,omitArrayIndexes){var formName=prependFormName&&formCtrl&&formCtrl.$name?formCtrl.$name:undefined;var key=scope.getKey();if(Array.isArray(key)){return sfPath.name(key,"-",formName,omitArrayIndexes)}else{return""}};scope.listToCheckboxValues=function(list){var values={};_angular2.default.forEach(list,function(v){values[v]=true});return values};scope.checkboxValuesToList=function(values){var lst=[];_angular2.default.forEach(values,function(v,k){if(v){lst.push(k)}});return lst};scope.buttonClick=function($event,form){if(_angular2.default.isFunction(form.onClick)){form.onClick($event,form)}else if(_angular2.default.isString(form.onClick)){if(sfSchema){sfSchema.evalInParentScope(form.onClick,{$event:$event,form:form})}else{scope.$eval(form.onClick,{$event:$event,form:form})}}};scope.evalExpr=function(expression,locals){if(sfSchema){return sfSchema.evalInParentScope(expression,locals)}return scope.$eval(expression,locals)};scope.evalInScope=function(expression,locals){if(expression){return scope.$eval(expression,locals)}};scope.interp=function(expression,locals){return expression&&$interpolate(expression)(locals)};scope.hasSuccess=function(){if(!scope.ngModel){return false}if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return scope.ngModel.$valid&&!scope.ngModel.$pristine&&!scope.ngModel.$isEmpty(scope.ngModel.$modelValue)}else{return scope.ngModel.$valid&&(!scope.ngModel.$pristine||!scope.ngModel.$isEmpty(scope.ngModel.$modelValue))}};scope.hasError=function(){if(!scope.ngModel){return false}if(!scope.options||!scope.options.pristine||scope.options.pristine.errors!==false){return scope.ngModel.$invalid}else{return scope.ngModel.$invalid&&!scope.ngModel.$pristine}};scope.errorMessage=function(schemaError){return sfErrorMessage.interpolate(schemaError&&schemaError.code+""||"default",scope.ngModel&&scope.ngModel.$modelValue||"",scope.ngModel&&scope.ngModel.$viewValue||"",scope.form,scope.options&&scope.options.validationMessage)};scope.form.htmlClass=scope.form.htmlClass||"";scope.form.htmlClass+=(scope.form.htmlClass?" ":"")+scope.fieldId(false,true);var form=scope.form;if(form.key){scope.$on("schemaForm.error."+form.key.join("."),function(event,error,validationMessage,validity,formName){formName=validity;if(validationMessage===true||validationMessage===false){validity=validationMessage;validationMessage=undefined}if(formName!=undefined&&scope.ngModel.$$parentForm.$name!==formName){return}if(scope.ngModel&&error){if(scope.ngModel.$setDirty){scope.ngModel.$setDirty()}else{scope.ngModel.$dirty=true;scope.ngModel.$pristine=false}if(validationMessage){if(!form.validationMessage){form.validationMessage={}}form.validationMessage[error]=validationMessage}scope.ngModel.$setValidity(error,validity===true);if(validity===true){scope.ngModel.$validate();scope.$broadcast("schemaFormValidate")}}});scope.$on("$destroy",function(){var key=scope.getKey();if(!scope.externalDestructionInProgress){var destroyStrategy=form.destroyStrategy||scope.options&&scope.options.destroyStrategy||"remove";if(key&&destroyStrategy!=="retain"){var obj=scope.model;if(key.length>1){obj=sfSelect(key.slice(0,key.length-1),obj)}if(obj===undefined){return}var type=form.schema&&form.schema.type||"";if(destroyStrategy==="empty"&&type.indexOf("string")!==-1){obj[key.slice(-1)]=""}else if(destroyStrategy==="empty"&&type.indexOf("object")!==-1){obj[key.slice(-1)]={}}else if(destroyStrategy==="empty"&&type.indexOf("array")!==-1){obj[key.slice(-1)]=[]}else if(destroyStrategy==="null"){obj[key.slice(-1)]=null}else{delete obj[key.slice(-1)]}}}})}}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){
-return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($injector,sfErrorMessage){var $sanitize=$injector.has("$sanitize")?$injector.get("$sanitize"):function(html){return html};return{scope:false,restrict:"EA",link:function link(scope,element,attrs){var message="";if(attrs.sfMessage){scope.$watch(attrs.sfMessage,function(msg){if(msg){message=$sanitize(msg);update(!!scope.ngModel)}})}var currentMessage;var setMessage=function setMessage(msg){if(msg!==currentMessage){element.html(msg);currentMessage=msg}};var update=function update(checkForErrors){if(checkForErrors){if(!scope.hasError()){setMessage(message)}else{var errors=[];_angular2.default.forEach(scope.ngModel&&scope.ngModel.$error,function(status,code){if(status){errors.push(code)}});errors=errors.filter(function(e){return e!=="schemaForm"});var error=errors[0];if(error){setMessage(sfErrorMessage.interpolate(error,scope.ngModel.$modelValue,scope.ngModel.$viewValue,scope.form,scope.options&&scope.options.validationMessage))}else{setMessage(message)}}}else{setMessage(message)}};update();var once=scope.$watch("ngModel",function(ngModel){if(ngModel){ngModel.$parsers.push(function(val){update(true);return val});ngModel.$formatters.push(function(val){update(true);return val});once()}});scope.$watchCollection("ngModel.$error",function(){update(!!scope.ngModel)})}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sel,sfPath,schemaForm){return{scope:true,controller:["$scope",function SFArrayController($scope){this.key=$scope.form&&$scope.form.key?$scope.form.key.splice(0,-2):[]}],link:function link(scope,element,attrs){scope.min=0;scope.modelArray=scope.$eval(attrs.sfNewArray);var watchFn=function watchFn(){scope.modelArray=scope.$eval(attrs.sfNewArray);if(scope.ngModel&&scope.ngModel.$pristine&&scope.firstDigest&&(!scope.options||scope.options.validateOnRender!==true)){return}else if(scope.validateField){scope.validateField()}};var onChangeFn=function onChangeFn(){if(scope.form&&scope.form.onChange){if(_angular2.default.isFunction(scope.form.onChange)){scope.form.onChange(scope.modelArray,scope.form)}else{scope.evalExpr(scope.form.onChange,{modelValue:scope.modelArray,form:scope.form})}}};var getOrCreateModel=function getOrCreateModel(){var model=scope.modelArray;if(!model){var selection=sfPath.parse(attrs.sfNewArray);model=[];sel(selection,scope,model);scope.modelArray=model}return model};var once=scope.$watch("form",function(form){if(!form){return}if(!form.titleMap&&form.startEmpty!==true&&(!scope.modelArray||scope.modelArray.length===0)){scope.appendToArray()}if(scope.form&&scope.form.schema&&scope.form.schema.uniqueItems===true){scope.$watch(attrs.sfNewArray,watchFn,true);scope.$watch([attrs.sfNewArray,attrs.sfNewArray+".length"],onChangeFn)}else{if(scope.$watchGroup){scope.$watchGroup([attrs.sfNewArray,attrs.sfNewArray+".length"],function(){watchFn();onChangeFn()})}else{scope.$watch(attrs.sfNewArray,function(){watchFn();onChangeFn()});scope.$watch(attrs.sfNewArray+".length",function(){watchFn();onChangeFn()})}}if(form.titleMap&&form.titleMap.length>0){scope.titleMapValues=[];var updateTitleMapValues=function updateTitleMapValues(arr){scope.titleMapValues=[];arr=arr||[];form.titleMap.forEach(function(item){scope.titleMapValues.push(arr.indexOf(item.value)!==-1)})};updateTitleMapValues(scope.modelArray);scope.$watchCollection("modelArray",updateTitleMapValues);scope.$watchCollection("titleMapValues",function(vals,old){if(vals&&vals!==old){var arr=getOrCreateModel();form.titleMap.forEach(function(item,index){var arrIndex=arr.indexOf(item.value);if(arrIndex===-1&&vals[index]){arr.push(item.value)}if(arrIndex!==-1&&!vals[index]){arr.splice(arrIndex,1)}});if(scope.validateField){scope.validateField()}}})}once()});scope.appendToArray=function(){var empty;var model=getOrCreateModel();if(scope.form&&scope.form.schema&&scope.form.schema.items){var items=scope.form.schema.items;if(items.type&&items.type.indexOf("object")!==-1){empty={};if(!scope.options||scope.options.setSchemaDefaults!==false){empty=_angular2.default.isDefined(items["default"])?items["default"]:empty;if(empty){schemaForm.traverseSchema(items,function(prop,path){if(_angular2.default.isDefined(prop["default"])){sel(path,empty,prop["default"])}})}}}else if(items.type&&items.type.indexOf("array")!==-1){empty=[];if(!scope.options||scope.options.setSchemaDefaults!==false){empty=items["default"]||empty}}else{if(!scope.options||scope.options.setSchemaDefaults!==false){empty=items["default"]||empty}}}model.push(empty);return model};scope.deleteFromArray=function(index){var model=scope.modelArray;if(model){model.splice(index,1)}return model};var setIndex=function setIndex(index){return function(form){if(form.key){form.key[form.key.indexOf("")]=index}}};var formDefCache={};scope.copyWithIndex=function(index){var form=scope.form;if(!formDefCache[index]){var subForm=form.items[0];if(form.items.length>1){subForm={type:"section",items:form.items.map(function(item){item.ngModelOptions=form.ngModelOptions;if(_angular2.default.isUndefined(item.readonly)){item.readonly=form.readonly}return item})}}if(subForm){var copy=_angular2.default.copy(subForm);copy.arrayIndex=index;schemaForm.traverseForm(copy,setIndex(index));formDefCache[index]=copy}}return formDefCache[index]}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(schemaForm,sfPath){return{scope:true,require:["^^sfNewArray"],link:function link(scope,element,attrs,ctrl){var currentKey=sfPath.parse(attrs.sfParentKey);if(currentKey.length>1)currentKey=currentKey.splice(-1);scope.parentKey=scope.parentKey||[];scope.parentKey=scope.parentKey.concat(currentKey,Number(attrs.sfIndex));scope.arrayIndex=Number(attrs.sfIndex);scope.arrayIndices=scope.arrayIndices||[];scope.arrayIndices=scope.arrayIndices.concat(scope.arrayIndex);scope.$i=scope.arrayIndices}}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($compile,$http,$templateCache,$q,schemaForm,schemaFormDecorators,sfSelect,sfPath,sfBuilder){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function($scope){this.evalInParentScope=function(expr,locals){return $scope.$parent.$eval(expr,locals)};var that=this;$scope.lookup=function(lookup){if(lookup){that.lookup=lookup}return that.lookup}}],replace:false,restrict:"A",transclude:true,require:"?form",link:function link(scope,element,attrs,formCtrl,transclude){scope.formCtrl=formCtrl;var ignore={};transclude(scope,function(clone){clone.addClass("schema-form-ignore");element.prepend(clone);if(element[0].querySelectorAll){var models=element[0].querySelectorAll("[ng-model]");if(models){for(var i=0;i<models.length;i++){var key=models[i].getAttribute("ng-model");ignore[key.substring(key.indexOf(".")+1)]=true}}}});var lastDigest={};var childScope;var render=function render(schema,form){var asyncTemplates=[];var merged=schemaForm.merge(schema,form,ignore,scope.options,undefined,asyncTemplates);if(asyncTemplates.length>0){$q.all(asyncTemplates.map(function(form){return $http.get(form.templateUrl,{cache:$templateCache}).then(function(res){form.template=res.data})})).then(function(){internalRender(schema,form,merged)})}else{internalRender(schema,form,merged)}};var internalRender=function internalRender(schema,form,merged){if(childScope){scope.externalDestructionInProgress=true;childScope.$destroy();scope.externalDestructionInProgress=false}childScope=scope.$new();childScope.schemaForm={form:merged,schema:schema};element.children(":not(.schema-form-ignore)").remove();var slots={};var slotsFound=element[0].querySelectorAll("*[sf-insert-field]");for(var i=0;i<slotsFound.length;i++){slots[slotsFound[i].getAttribute("sf-insert-field")]=slotsFound[i]}var decorator=schemaFormDecorators.decorator(attrs.sfUseDecorator);var lookup=Object.create(null);scope.lookup(lookup);element[0].appendChild(sfBuilder.build(merged,decorator,slots,lookup));childScope.firstDigest=true;setTimeout(function(){childScope.firstDigest=false},0);$compile(element.children())(childScope);if(!scope.options||scope.options.setSchemaDefaults!==false){schemaForm.traverseSchema(schema,function(prop,path){if(_angular2.default.isDefined(prop["default"])){var val=sfSelect(path,scope.model);if(_angular2.default.isUndefined(val)){sfSelect(path,scope.model,prop["default"])}}})}scope.$emit("sf-render-finished",element)};var defaultForm=["*"];scope.$watch(function(){var schema=scope.schema;var form=scope.initialForm||defaultForm;if(form&&schema&&schema.type&&(lastDigest.form!==form||lastDigest.schema!==schema)&&Object.keys(schema.properties).length>0){lastDigest.schema=schema;lastDigest.form=form;render(schema,form)}});scope.$on("schemaFormRedraw",function(){var schema=scope.schema;var form=scope.initialForm?_angular2.default.copy(scope.initialForm):["*"];if(schema){render(schema,form)}});scope.$on("$destroy",function(){scope.externalDestructionInProgress=true});scope.evalExpr=function(expression,locals){return scope.$parent.$eval(expression,locals)}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfValidator,$parse,sfSelect){return{restrict:"A",scope:false,priority:500,require:"ngModel",link:function link(scope,element,attrs,ngModel){scope.$emit("schemaFormPropagateNgModelController",ngModel);var error=null;var form=scope.$eval(attrs.schemaValidate);if(form.copyValueTo){ngModel.$viewChangeListeners.push(function(){var paths=form.copyValueTo;_angular2.default.forEach(paths,function(path){sfSelect(path,scope.model,ngModel.$modelValue)})})}var validate=function validate(viewValue){if(!form){return viewValue}if(scope.options&&scope.options.tv4Validation===false){return viewValue}var result=sfValidator.validate(form,viewValue);Object.keys(ngModel.$error).filter(function(k){return k.indexOf("tv4-")===0}).forEach(function(k){ngModel.$setValidity(k,true)});if(!result.valid){ngModel.$setValidity("tv4-"+result.error.code,false);error=result.error;if(ngModel.$validators){return viewValue}return undefined}return viewValue};if(typeof form.ngModel==="function"){form.ngModel(ngModel)}["$parsers","$viewChangeListeners","$formatters"].forEach(function(attr){if(form[attr]&&ngModel[attr]){form[attr].forEach(function(fn){ngModel[attr].push(fn)})}});["$validators","$asyncValidators"].forEach(function(attr){if(form[attr]&&ngModel[attr]){_angular2.default.forEach(form[attr],function(fn,name){ngModel[attr][name]=fn})}});ngModel.$parsers.push(validate);if(ngModel.$validators){ngModel.$validators.schemaForm=function(){return!Object.keys(ngModel.$error).some(function(e){return e!=="schemaForm"})}}var schema=form.schema;scope.validateField=function(formName){if(formName!=undefined&&ngModel.$$parentForm.$name!==formName){return}if(schema&&schema.type.indexOf("array")!==-1){validate(ngModel.$modelValue)}if(ngModel.$setDirty){ngModel.$setDirty();ngModel.$setViewValue(ngModel.$viewValue);ngModel.$commitViewValue();if(form.type==="checkbox"){if(form.required&&ngModel.$modelValue===undefined){ngModel.$setValidity("tv4-302",false)}}else if(form.required&&ngModel.$isEmpty(ngModel.$modelValue)){ngModel.$setValidity("tv4-302",false)}}else{ngModel.$setViewValue(ngModel.$viewValue)}};var first=true;ngModel.$formatters.push(function(val){if(ngModel.$pristine&&first&&(!scope.options||scope.options.validateOnRender!==true)){first=false;return val}validate(ngModel.$modelValue);return val});scope.$on("schemaFormValidate",function(event,formName){scope.validateField(formName)});scope.schemaError=function(){return error}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{"default":obj}}}])})},function(module,exports){module.exports=angular},function(module,exports){module.exports=tv4}])});
\ No newline at end of file
+(function webpackUniversalModuleDefinition(root,factory){if(true)module.exports=factory(__webpack_require__(7));else if(typeof define==="function"&&define.amd)define(["tv4"],factory);else{var a=typeof exports==="object"?factory(require("tv4")):factory(root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_10__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){module.exports=__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.canonicalTitleMap=exports.schemaDefaults=exports.sfPath=undefined;var _merge=__webpack_require__(2);Object.keys(_merge).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _merge[key]}})});var _select=__webpack_require__(7);Object.keys(_select).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _select[key]}})});var _traverse=__webpack_require__(8);Object.keys(_traverse).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _traverse[key]}})});var _validate=__webpack_require__(9);Object.keys(_validate).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _validate[key]}})});var _schemaDefaults=__webpack_require__(11);var schemaDefaultsImp=_interopRequireWildcard(_schemaDefaults);var _sfPath=__webpack_require__(3);var sfPathImp=_interopRequireWildcard(_sfPath);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _interopRequireWildcard(obj){if(obj&&obj.__esModule){return obj}else{var newObj={};if(obj!=null){for(var key in obj){if(Object.prototype.hasOwnProperty.call(obj,key))newObj[key]=obj[key]}}newObj.default=obj;return newObj}}var sfPath=exports.sfPath=sfPathImp;var schemaDefaults=exports.schemaDefaults=schemaDefaultsImp;var canonicalTitleMap=exports.canonicalTitleMap=_canonicalTitleMap2.default},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.merge=merge;var _sfPath=__webpack_require__(3);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function merge(lookup,form,options,readonly,asyncTemplates){form=form||[];options=options||{};return form.map(function(obj){if(typeof obj==="string"){obj={key:obj}}if(obj.key){if(typeof obj.key==="string"){obj.key=(0,_sfPath.parse)(obj.key)}}if(obj.titleMap){obj.titleMap=(0,_canonicalTitleMap2.default)(obj.titleMap)}if(obj.key){var strid=(0,_sfPath.stringify)(obj.key);if(lookup[strid]){(function(){var schemaDefaults=lookup[strid];if(schemaDefaults){Object.keys(schemaDefaults).forEach(function(attr){if(obj[attr]===undefined){obj[attr]=schemaDefaults[attr]}})}})()}}if(readonly===true){obj.readonly=true}if(obj.items){obj.items=merge(lookup,obj.items,options,obj.readonly,asyncTemplates)}if(obj.tabs){obj.tabs.forEach(function(tab){if(tab.items){tab.items=merge(lookup,tab.items,options,obj.readonly,asyncTemplates)}})}if(obj.type==="checkbox"&&obj.schema["default"]===undefined){obj.schema["default"]=false}if(asyncTemplates&&obj.type==="template"&&!obj.template&&obj.templateUrl){asyncTemplates.push(obj)}return obj})}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.name=exports.normalize=exports.stringify=exports.parse=undefined;var _objectpath=__webpack_require__(4);var name=function name(key,separator,formName,omitNumbers){if(key){var fieldKey=key;var fieldSeparator=separator||"-";if(omitNumbers){fieldKey=fieldKey.filter(function(key){return typeof key!=="number"})}return(formName?formName+fieldSeparator:"")+fieldKey.join(fieldSeparator)}return""};exports.parse=_objectpath.parse;exports.stringify=_objectpath.stringify;exports.normalize=_objectpath.normalize;exports.name=name},function(module,exports,__webpack_require__){"use strict";module.exports=__webpack_require__(5).ObjectPath},function(module,exports,__webpack_require__){var __WEBPACK_AMD_DEFINE_RESULT__;"use strict";var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};!function(undefined){var ObjectPath={parse:function parse(str){if(typeof str!=="string"){throw new TypeError("ObjectPath.parse must be passed a string")}var i=0;var parts=[];var d,b,q,c;while(i<str.length){d=str.indexOf(".",i);b=str.indexOf("[",i);if(d===-1&&b===-1){parts.push(str.slice(i,str.length));i=str.length}else if(b===-1||d!==-1&&d<b){parts.push(str.slice(i,d));i=d+1}else{if(b>i){parts.push(str.slice(i,b));i=b}q=str.slice(b+1,b+2);if(q!=='"'&&q!=="'"){c=str.indexOf("]",b);if(c===-1)c=str.length;parts.push(str.slice(i+1,c));i=str.slice(c+1,c+2)==="."?c+2:c+1}else{c=str.indexOf(q+"]",b);if(c===-1)c=str.length;while(str.slice(c-1,c)==="\\"&&b<str.length){b++;c=str.indexOf(q+"]",b)}parts.push(str.slice(i+2,c).replace(new RegExp("\\"+q,"g"),q));i=str.slice(c+2,c+3)==="."?c+3:c+2}}}return parts},stringify:function stringify(arr,quote){if(!Array.isArray(arr))arr=[arr.toString()];quote=quote==='"'?'"':"'";return arr.map(function(n){return"["+quote+n.toString().replace(new RegExp(quote,"g"),"\\"+quote)+quote+"]"}).join("")},normalize:function normalize(data,quote){return ObjectPath.stringify(Array.isArray(data)?data:ObjectPath.parse(data),quote)},registerModule:function registerModule(angular){angular.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=ObjectPath.parse;this.stringify=ObjectPath.stringify;this.normalize=ObjectPath.normalize;this.$get=function(){return ObjectPath}})}};if(true){!(__WEBPACK_AMD_DEFINE_RESULT__=function(){return{ObjectPath:ObjectPath}}.call(exports,__webpack_require__,exports,module),__WEBPACK_AMD_DEFINE_RESULT__!==undefined&&(module.exports=__WEBPACK_AMD_DEFINE_RESULT__))}else if((typeof exports==="undefined"?"undefined":_typeof(exports))==="object"){exports.ObjectPath=ObjectPath}else{window.ObjectPath=ObjectPath}}()},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.default=function(titleMap,originalEnum){if(!Array.isArray(titleMap)){var _ret=function(){var canonical=[];if(originalEnum){originalEnum.forEach(function(value){canonical.push({name:titleMap[value],value:value})})}else{Object.keys(titleMap).forEach(function(value){canonical.push({name:titleMap[value],value:value})})}return{v:canonical}}();if((typeof _ret==="undefined"?"undefined":_typeof(_ret))==="object")return _ret.v}return titleMap}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.select=select;var _sfPath=__webpack_require__(3);var _sfPath2=_interopRequireDefault(_sfPath);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}var numRe=/^\d+$/;function select(projection,obj,valueToSet){if(!obj){obj=this}var parts=typeof projection==="string"?_sfPath2.default.parse(projection):projection;if(typeof valueToSet!=="undefined"&&parts.length===1){obj[parts[0]]=valueToSet;return obj}if(typeof valueToSet!=="undefined"&&typeof obj[parts[0]]==="undefined"){obj[parts[0]]=parts.length>2&&numRe.test(parts[1])?[]:{}}var value=obj[parts[0]];for(var i=1;i<parts.length;i++){if(parts[i]===""){return undefined}if(typeof valueToSet!=="undefined"){if(i===parts.length-1){value[parts[i]]=valueToSet;return valueToSet}else{var tmp=value[parts[i]];if(typeof tmp==="undefined"||tmp===null){tmp=numRe.test(parts[i+1])?[]:{};value[parts[i]]=tmp}value=tmp}}else if(value){value=value[parts[i]]}}return value}},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.traverseSchema=traverseSchema;exports.traverseForm=traverseForm;function traverseSchema(schema,fn,path,ignoreArrays){ignoreArrays=ignoreArrays===undefined?true:ignoreArrays;path=path||[];var traverse=function traverse(schema,fn,path){fn(schema,path);if(schema.properties){Object.keys(schema.properties).forEach(function(name){var currentPath=path.slice();currentPath.push(name);traverse(schema.properties[name],fn,currentPath)})}if(!ignoreArrays&&schema.items){var arrPath=path.slice();arrPath.push("");traverse(schema.items,fn,arrPath)}};traverse(schema,fn,path||[])}function traverseForm(form,fn){fn(form);if(form.items){form.items.forEach(function(f){traverseForm(f,fn)})}if(form.tabs){form.tabs.forEach(function(tab){if(tab.items){tab.items.forEach(function(f){traverseForm(f,fn)})}})}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.validate=validate;var _tv=__webpack_require__(10);var _tv2=_interopRequireDefault(_tv);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function validate(form,value){if(!form){return{valid:true}}var schema=form.schema;if(!schema){return{valid:true}}if(value===""){value=undefined}if(form.type==="number"&&value===null){value=undefined}var wrap={type:"object",properties:{}};var propName=form.key[form.key.length-1];wrap.properties[propName]=schema;if(form.required){wrap.required=[propName]}var valueWrap={};if(!!value){valueWrap[propName]=value}return _tv2.default.validateResult(valueWrap,wrap)}},function(module,exports){module.exports=tv4},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.defaultFormDefinition=defaultFormDefinition;exports.stdFormObj=stdFormObj;exports.text=text;exports.number=number;exports.integer=integer;exports.checkbox=checkbox;exports.select=select;exports.checkboxes=checkboxes;exports.fieldset=fieldset;exports.array=array;exports.createDefaults=createDefaults;exports.defaultForm=defaultForm;var _sfPath=__webpack_require__(3);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}var stripNullType=function stripNullType(type){if(Array.isArray(type)&&type.length==2){if(type[0]==="null"){return type[1]}if(type[1]==="null"){return type[0]}}return type};var enumToTitleMap=function enumToTitleMap(enm){var titleMap=[];enm.forEach(function(name){titleMap.push({name:name,value:name})});return titleMap};function defaultFormDefinition(schemaTypes,name,schema,options){var rules=schemaTypes[stripNullType(schema.type)];if(rules){var def=void 0;var innerDefaultFormDefinition=function innerDefaultFormDefinition(childName,childSchema,childOptions){return defaultFormDefinition(schemaTypes,childName,childSchema,childOptions)};for(var i=0;i<rules.length;i++){def=rules[i](name,schema,options,innerDefaultFormDefinition);if(def){if(def.schema["x-schema-form"]){Object.assign(def,def.schema["x-schema-form"])}return def}}}}function stdFormObj(name,schema,options){options=options||{};var f=options.global&&options.global.formDefaults?Object.assign({},options.global.formDefaults):{};if(options.global&&options.global.supressPropertyTitles===true){f.title=schema.title}else{f.title=schema.title||name}if(schema.description){f.description=schema.description}if(options.required===true||schema.required===true){f.required=true}if(schema.maxLength){f.maxlength=schema.maxLength}if(schema.minLength){f.minlength=schema.minLength}if(schema.readOnly||schema.readonly){f.readonly=true}if(schema.minimum){f.minimum=schema.minimum+(schema.exclusiveMinimum?1:0)}if(schema.maximum){f.maximum=schema.maximum-(schema.exclusiveMaximum?1:0)}if(schema.validationMessage){f.validationMessage=schema.validationMessage}if(schema.enumNames){f.titleMap=(0,_canonicalTitleMap2.default)(schema.enumNames,schema["enum"])}f.schema=schema;f.ngModelOptions=f.ngModelOptions||{};return f}function text(name,schema,options){if(stripNullType(schema.type)==="string"&&!schema["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="text";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function number(name,schema,options){if(stripNullType(schema.type)==="number"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="number";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function integer(name,schema,options){if(stripNullType(schema.type)==="integer"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="number";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function checkbox(name,schema,options){if(stripNullType(schema.type)==="boolean"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="checkbox";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function select(name,schema,options){if(stripNullType(schema.type)==="string"&&schema["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="select";if(!f.titleMap){f.titleMap=enumToTitleMap(schema["enum"])}options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function checkboxes(name,schema,options){if(stripNullType(schema.type)==="array"&&schema.items&&schema.items["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="checkboxes";if(!f.titleMap){f.titleMap=enumToTitleMap(schema.items["enum"])}options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function fieldset(name,schema,options,defaultFormDef){if(stripNullType(schema.type)==="object"){var _ret=function(){var f=stdFormObj(name,schema,options);f.type="fieldset";f.key=options.path;f.items=[];options.lookup[(0,_sfPath.stringify)(options.path)]=f;if(schema.properties){Object.keys(schema.properties).forEach(function(key){var value=schema.properties[key];var path=options.path.slice();path.push(key);if(options.ignore[(0,_sfPath.stringify)(path)]!==true){var required=schema.required&&schema.required.indexOf(key)!==-1;var def=defaultFormDef(key,value,{path:path,required:required||false,lookup:options.lookup,ignore:options.ignore,global:options.global});if(def){f.items.push(def)}}})}return{v:f}}();if((typeof _ret==="undefined"?"undefined":_typeof(_ret))==="object")return _ret.v}}function array(name,schema,options,defaultFormDef){if(stripNullType(schema.type)==="array"){var f=stdFormObj(name,schema,options);f.type="array";f.key=options.path;options.lookup[(0,_sfPath.stringify)(options.path)]=f;var required=schema.required&&schema.required.indexOf(options.path[options.path.length-1])!==-1;var arrPath=options.path.slice();arrPath.push("");f.items=[defaultFormDef(name,schema.items,{path:arrPath,required:required||false,lookup:options.lookup,ignore:options.ignore,global:options.global})];return f}}function createDefaults(){return{string:[select,text],object:[fieldset],number:[number],integer:[integer],boolean:[checkbox],array:[checkboxes,array]}}function defaultForm(schema,defaultSchemaTypes,ignore,globalOptions){var form=[];var lookup={};ignore=ignore||{};globalOptions=globalOptions||{};defaultSchemaTypes=defaultSchemaTypes||createDefaults();if(schema.properties){Object.keys(schema.properties).forEach(function(key){if(ignore[key]!==true){var required=schema.required&&schema.required.indexOf(key)!==-1;var def=defaultFormDefinition(defaultSchemaTypes,key,schema.properties[key],{path:[key],lookup:lookup,ignore:ignore,required:required,global:globalOptions});if(def){form.push(def)}}})}else{throw new Error('Not implemented. Only type "object" allowed at root level of schema.')}return{form:form,lookup:lookup}}}])})},function(module,exports){module.exports=tv4},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var validator={};validator.validate=function(form,value){if(!form){return{valid:true}}var schema=form.schema;if(!schema){return{valid:true}}if(value===""){value=undefined}if(form.type==="number"&&value===null){value=undefined}var wrap={type:"object",properties:{}};var propName=form.key[form.key.length-1];wrap.properties[propName]=schema;if(form.required){wrap.required=[propName]}var valueWrap={};if(_angular2.default.isDefined(value)){valueWrap[propName]=value}return _tv2.default.validateResult(valueWrap,wrap)};return validator};var _tv=__webpack_require__(7);var _tv2=_interopRequireDefault(_tv);var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var defaultMessages={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};defaultMessages.number=defaultMessages[105];defaultMessages.required=defaultMessages[302];defaultMessages.min=defaultMessages[101];defaultMessages.max=defaultMessages[103];defaultMessages.maxlength=defaultMessages[201];defaultMessages.minlength=defaultMessages[200];defaultMessages.pattern=defaultMessages[202];this.setDefaultMessages=function(messages){defaultMessages=messages};this.getDefaultMessages=function(){return defaultMessages};this.setDefaultMessage=function(error,msg){defaultMessages[error]=msg};this.$get=["$interpolate",function($interpolate){var service={};service.defaultMessages=defaultMessages;service.interpolate=function(error,value,viewValue,form,global){global=global||{};var validationMessage=form.validationMessage||{};if(error.indexOf("tv4-")===0){error=error.substring(4)}var message=validationMessage["default"]||global["default"]||"";[validationMessage,global,defaultMessages].some(function(val){if(_angular2.default.isString(val)||_angular2.default.isFunction(val)){message=val;return true}if(val&&val[error]){message=val[error];return true}});var context={error:error,value:value,viewValue:viewValue,form:form,schema:form.schema,title:form.title||form.schema&&form.schema.title};if(_angular2.default.isFunction(message)){return message(context)}else{return $interpolate(message)(context)}};return service}]};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){this.parse=_jsonSchemaFormCore.sfPath.parse;this.stringify=_jsonSchemaFormCore.sfPath.stringify;this.normalize=_jsonSchemaFormCore.sfPath.normalize;this.$get=function(){return _jsonSchemaFormCore.sfPath}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _jsonSchemaFormCore=__webpack_require__(6);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfSelect,schemaForm,sfValidator,sfPath){var setIndex=function setIndex(index){return function(form){if(form.key){form.key[form.key.indexOf("")]=index}}};return{restrict:"A",scope:true,require:"?ngModel",link:function link(scope,element,attrs,ngModel){var formDefCache={};scope.validateArray=_angular2.default.noop;if(ngModel){scope.$emit("schemaFormPropagateNgModelController",ngModel)}var once=scope.$watch(attrs.sfArray,function(form){if(!form){return}var list=sfSelect(form.key,scope.model);var key=sfPath.normalize(form.key);scope.$watch("model"+(key[0]!=="["?".":"")+key,function(value){list=scope.modelArray=value});if(_angular2.default.isUndefined(list)){list=[];sfSelect(form.key,scope.model,list)}scope.modelArray=list;if(form.items){var subForm=form.items[0];if(form.items.length>1){subForm={type:"section",items:form.items.map(function(item){item.ngModelOptions=form.ngModelOptions;if(_angular2.default.isUndefined(item.readonly)){item.readonly=form.readonly}return item})}}}scope.copyWithIndex=function(index){if(!formDefCache[index]){if(subForm){var copy=_angular2.default.copy(subForm);copy.arrayIndex=index;schemaForm.traverseForm(copy,setIndex(index));formDefCache[index]=copy}}return formDefCache[index]};scope.appendToArray=function(){var len=list.length;var copy=scope.copyWithIndex(len);schemaForm.traverseForm(copy,function(part){if(part.key){var def;if(_angular2.default.isDefined(part["default"])){def=part["default"]}if(_angular2.default.isDefined(part.schema)&&_angular2.default.isDefined(part.schema["default"])){def=part.schema["default"]}if(_angular2.default.isDefined(def)){sfSelect(part.key,scope.model,def)}}});if(len===list.length){var type=sfSelect("schema.items.type",form);var dflt;if(type==="object"){dflt={}}else if(type==="array"){dflt=[]}list.push(dflt)}scope.validateArray();return list};scope.deleteFromArray=function(index){list.splice(index,1);scope.validateArray();if(ngModel&&ngModel.$setDirty){ngModel.$setDirty()}return list};if(!form.titleMap&&form.startEmpty!==true&&list.length===0){scope.appendToArray()}if(form.titleMap&&form.titleMap.length>0){scope.titleMapValues=[];var updateTitleMapValues=function updateTitleMapValues(arr){scope.titleMapValues=[];arr=arr||[];form.titleMap.forEach(function(item){scope.titleMapValues.push(arr.indexOf(item.value)!==-1)})};updateTitleMapValues(scope.modelArray);scope.$watchCollection("modelArray",updateTitleMapValues);scope.$watchCollection("titleMapValues",function(vals,old){if(vals&&vals!==old){var arr=scope.modelArray;while(arr.length>0){arr.pop()}form.titleMap.forEach(function(item,index){if(vals[index]){arr.push(item.value)}});scope.validateArray()}})}if(ngModel){var error;scope.validateArray=function(){var result=sfValidator.validate(form,scope.modelArray.length>0?scope.modelArray:undefined);Object.keys(ngModel.$error).filter(function(k){return k.indexOf("tv4-")===0}).forEach(function(k){ngModel.$setValidity(k,true)});if(result.valid===false&&result.error&&(result.error.dataPath===""||result.error.dataPath==="/"+form.key[form.key.length-1])){ngModel.$setViewValue(scope.modelArray);error=result.error;ngModel.$setValidity("tv4-"+result.error.code,false)}};scope.$on("schemaFormValidate",scope.validateArray);scope.hasSuccess=function(){if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return ngModel.$valid&&!ngModel.$pristine&&!ngModel.$isEmpty(ngModel.$modelValue)}else{return ngModel.$valid&&(!ngModel.$pristine||!ngModel.$isEmpty(ngModel.$modelValue))}};scope.hasError=function(){if(!scope.options||!scope.options.pristine||scope.options.pristine.errors!==false){return ngModel.$invalid}else{return ngModel.$invalid&&!ngModel.$pristine}};scope.schemaError=function(){return error}}once()})}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){return{require:"ngModel",restrict:"AC",scope:false,link:function link(scope,element,attrs,ctrl){var form=scope.$eval(attrs.sfChanged);if(form&&form.onChange){ctrl.$viewChangeListeners.push(function(){if(_angular2.default.isFunction(form.onChange)){form.onChange(ctrl.$modelValue,form)}else{scope.evalExpr(form.onChange,{modelValue:ctrl.$modelValue,form:form})}})}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.default=function($parse,$compile,$http,$templateCache,$interpolate,$q,sfErrorMessage,sfPath,sfSelect){var keyFormat={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:false,transclude:false,scope:true,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function pre(scope,element,attrs,ctrl){var sfSchema=ctrl[0];var formCtrl=ctrl[1];var keyCtrl=ctrl[2];scope.$on("schemaFormPropagateNgModelController",function(event,ngModel){event.stopPropagation();event.preventDefault();scope.ngModel=ngModel});scope.form=sfSchema.lookup["f"+attrs.sfField]},post:function post(scope,element,attrs,ctrl){var sfSchema=ctrl[0];var formCtrl=ctrl[1];var keyCtrl=ctrl[2];scope.showTitle=function(){return scope.form&&scope.form.notitle!==true&&scope.form.title};scope.getKey=function(requiredFormat){var format=requiredFormat||keyFormat.COMPLETE;var key=scope.parentKey?scope.parentKey.slice(0,scope.parentKey.length-1):[];if(typeof scope.$index==="number"){key=key.concat(scope.$index)}if(scope.form.key&&scope.form.key.length){if(typeof key[key.length-1]==="number"&&scope.form.key.length>=1){scope.completeKey=key.concat(scope.form.key.slice(-1))}else{scope.completeKey=scope.form.key.slice()}}if(!Array.isArray(scope.completeKey)){return undefined}if(format===keyFormat.COMPLETE){return scope.completeKey}return scope.completeKey.reduce(function(output,input,i){if(-1!==[format].indexOf(typeof input==="undefined"?"undefined":_typeof(input))){return output.concat(input)}return output},[])};if(scope.form.key)scope.completeKey=scope.getKey();scope.path=function(modelPath){var i=-1;modelPath=modelPath.replace(/\[\]/gi,function(matched){i++;return scope.$i[i]});return scope.$eval(modelPath,scope)};scope.fieldId=function(prependFormName,omitArrayIndexes){var formName=prependFormName&&formCtrl&&formCtrl.$name?formCtrl.$name:undefined;var key=scope.getKey();if(Array.isArray(key)){return sfPath.name(key,"-",formName,omitArrayIndexes)}else{return""}};scope.listToCheckboxValues=function(list){var values={};_angular2.default.forEach(list,function(v){values[v]=true});return values};scope.checkboxValuesToList=function(values){var lst=[];_angular2.default.forEach(values,function(v,k){if(v){lst.push(k)}});return lst};scope.buttonClick=function($event,form){if(_angular2.default.isFunction(form.onClick)){form.onClick($event,form)}else if(_angular2.default.isString(form.onClick)){if(sfSchema){sfSchema.evalInParentScope(form.onClick,{$event:$event,form:form})}else{scope.$eval(form.onClick,{$event:$event,form:form})}}};scope.evalExpr=function(expression,locals){if(sfSchema){return sfSchema.evalInParentScope(expression,locals)}return scope.$eval(expression,locals)};scope.evalInScope=function(expression,locals){if(expression){return scope.$eval(expression,locals)}};scope.interp=function(expression,locals){return expression&&$interpolate(expression)(locals)};scope.hasSuccess=function(){if(!scope.ngModel){return false}if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return scope.ngModel.$valid&&!scope.ngModel.$pristine&&!scope.ngModel.$isEmpty(scope.ngModel.$modelValue)}else{return scope.ngModel.$valid&&(!scope.ngModel.$pristine||!scope.ngModel.$isEmpty(scope.ngModel.$modelValue))}};scope.hasError=function(){if(!scope.ngModel){return false}if(!scope.options||!scope.options.pristine||scope.options.pristine.errors!==false){return scope.ngModel.$invalid}else{return scope.ngModel.$invalid&&!scope.ngModel.$pristine}};scope.errorMessage=function(schemaError){return sfErrorMessage.interpolate(schemaError&&schemaError.code+""||"default",scope.ngModel&&scope.ngModel.$modelValue||"",scope.ngModel&&scope.ngModel.$viewValue||"",scope.form,scope.options&&scope.options.validationMessage)};scope.form.htmlClass=scope.form.htmlClass||"";scope.form.htmlClass+=(scope.form.htmlClass?" ":"")+scope.fieldId(false,true);var form=scope.form;if(form.key){scope.$on("schemaForm.error."+form.key.join("."),function(event,error,validationMessage,validity,formName){formName=validity;if(validationMessage===true||validationMessage===false){validity=validationMessage;validationMessage=undefined}if(formName!=undefined&&scope.ngModel.$$parentForm.$name!==formName){return}if(scope.ngModel&&error){if(scope.ngModel.$setDirty){scope.ngModel.$setDirty()}else{scope.ngModel.$dirty=true;scope.ngModel.$pristine=false}if(validationMessage){if(!form.validationMessage){form.validationMessage={}}form.validationMessage[error]=validationMessage}scope.ngModel.$setValidity(error,validity===true);if(validity===true){scope.ngModel.$validate();scope.$broadcast("schemaFormValidate")}}});scope.$on("$destroy",function(){var key=scope.getKey();if(!scope.externalDestructionInProgress){var destroyStrategy=form.destroyStrategy||scope.options&&scope.options.destroyStrategy||"remove";if(key&&destroyStrategy!=="retain"){var obj=scope.model;if(key.length>1){obj=sfSelect(key.slice(0,key.length-1),obj)}if(obj===undefined){return}var type=form.schema&&form.schema.type||"";if(destroyStrategy==="empty"&&type.indexOf("string")!==-1){obj[key.slice(-1)]=""}else if(destroyStrategy==="empty"&&type.indexOf("object")!==-1){obj[key.slice(-1)]={}}else if(destroyStrategy==="empty"&&type.indexOf("array")!==-1){obj[key.slice(-1)]=[]}else if(destroyStrategy==="null"){obj[key.slice(-1)]=null}else{delete obj[key.slice(-1)]}}}})}}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{
+default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($injector,sfErrorMessage){var $sanitize=$injector.has("$sanitize")?$injector.get("$sanitize"):function(html){return html};return{scope:false,restrict:"EA",link:function link(scope,element,attrs){var message="";if(attrs.sfMessage){scope.$watch(attrs.sfMessage,function(msg){if(msg){message=$sanitize(msg);update(!!scope.ngModel)}})}var currentMessage;var setMessage=function setMessage(msg){if(msg!==currentMessage){element.html(msg);currentMessage=msg}};var update=function update(checkForErrors){if(checkForErrors){if(!scope.hasError()){setMessage(message)}else{var errors=[];_angular2.default.forEach(scope.ngModel&&scope.ngModel.$error,function(status,code){if(status){errors.push(code)}});errors=errors.filter(function(e){return e!=="schemaForm"});var error=errors[0];if(error){setMessage(sfErrorMessage.interpolate(error,scope.ngModel.$modelValue,scope.ngModel.$viewValue,scope.form,scope.options&&scope.options.validationMessage))}else{setMessage(message)}}}else{setMessage(message)}};update();var once=scope.$watch("ngModel",function(ngModel){if(ngModel){ngModel.$parsers.push(function(val){update(true);return val});ngModel.$formatters.push(function(val){update(true);return val});once()}});scope.$watchCollection("ngModel.$error",function(){update(!!scope.ngModel)})}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sel,sfPath,schemaForm){return{scope:true,controller:["$scope",function SFArrayController($scope){this.key=$scope.form&&$scope.form.key?$scope.form.key.splice(0,-2):[]}],link:function link(scope,element,attrs){scope.min=0;scope.modelArray=scope.$eval(attrs.sfNewArray);var watchFn=function watchFn(){scope.modelArray=scope.$eval(attrs.sfNewArray);if(scope.ngModel&&scope.ngModel.$pristine&&scope.firstDigest&&(!scope.options||scope.options.validateOnRender!==true)){return}else if(scope.validateField){scope.validateField()}};var onChangeFn=function onChangeFn(){if(scope.form&&scope.form.onChange){if(_angular2.default.isFunction(scope.form.onChange)){scope.form.onChange(scope.modelArray,scope.form)}else{scope.evalExpr(scope.form.onChange,{modelValue:scope.modelArray,form:scope.form})}}};var getOrCreateModel=function getOrCreateModel(){var model=scope.modelArray;if(!model){var selection=sfPath.parse(attrs.sfNewArray);model=[];sel(selection,scope,model);scope.modelArray=model}return model};var once=scope.$watch("form",function(form){if(!form){return}if(!form.titleMap&&form.startEmpty!==true&&(!scope.modelArray||scope.modelArray.length===0)){scope.appendToArray()}if(scope.form&&scope.form.schema&&scope.form.schema.uniqueItems===true){scope.$watch(attrs.sfNewArray,watchFn,true);scope.$watch([attrs.sfNewArray,attrs.sfNewArray+".length"],onChangeFn)}else{if(scope.$watchGroup){scope.$watchGroup([attrs.sfNewArray,attrs.sfNewArray+".length"],function(){watchFn();onChangeFn()})}else{scope.$watch(attrs.sfNewArray,function(){watchFn();onChangeFn()});scope.$watch(attrs.sfNewArray+".length",function(){watchFn();onChangeFn()})}}if(form.titleMap&&form.titleMap.length>0){scope.titleMapValues=[];var updateTitleMapValues=function updateTitleMapValues(arr){scope.titleMapValues=[];arr=arr||[];form.titleMap.forEach(function(item){scope.titleMapValues.push(arr.indexOf(item.value)!==-1)})};updateTitleMapValues(scope.modelArray);scope.$watchCollection("modelArray",updateTitleMapValues);scope.$watchCollection("titleMapValues",function(vals,old){if(vals&&vals!==old){var arr=getOrCreateModel();form.titleMap.forEach(function(item,index){var arrIndex=arr.indexOf(item.value);if(arrIndex===-1&&vals[index]){arr.push(item.value)}if(arrIndex!==-1&&!vals[index]){arr.splice(arrIndex,1)}});if(scope.validateField){scope.validateField()}}})}once()});scope.appendToArray=function(){var empty;var model=getOrCreateModel();if(scope.form&&scope.form.schema&&scope.form.schema.items){var items=scope.form.schema.items;if(items.type&&items.type.indexOf("object")!==-1){empty={};if(!scope.options||scope.options.setSchemaDefaults!==false){empty=_angular2.default.isDefined(items["default"])?items["default"]:empty;if(empty){schemaForm.traverseSchema(items,function(prop,path){if(_angular2.default.isDefined(prop["default"])){sel(path,empty,prop["default"])}})}}}else if(items.type&&items.type.indexOf("array")!==-1){empty=[];if(!scope.options||scope.options.setSchemaDefaults!==false){empty=items["default"]||empty}}else{if(!scope.options||scope.options.setSchemaDefaults!==false){empty=items["default"]||empty}}}model.push(empty);return model};scope.deleteFromArray=function(index){var model=scope.modelArray;if(model){model.splice(index,1)}return model};var setIndex=function setIndex(index){return function(form){if(form.key){form.key[form.key.indexOf("")]=index}}};var formDefCache={};scope.copyWithIndex=function(index){var form=scope.form;if(!formDefCache[index]){var subForm=form.items[0];if(form.items.length>1){subForm={type:"section",items:form.items.map(function(item){item.ngModelOptions=form.ngModelOptions;if(_angular2.default.isUndefined(item.readonly)){item.readonly=form.readonly}return item})}}if(subForm){var copy=_angular2.default.copy(subForm);copy.arrayIndex=index;schemaForm.traverseForm(copy,setIndex(index));formDefCache[index]=copy}}return formDefCache[index]}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(schemaForm,sfPath){return{scope:true,require:["^^sfNewArray"],link:{pre:function pre(scope,element,attrs,ctrl){var currentKey=sfPath.parse(attrs.sfParentKey);if(currentKey.length>1)currentKey=currentKey.splice(-1);scope.parentKey=scope.parentKey||[];scope.parentKey=scope.parentKey.concat(currentKey,Number(attrs.sfIndex));scope.arrayIndex=Number(attrs.sfIndex);scope.arrayIndices=scope.arrayIndices||[];scope.arrayIndices=scope.arrayIndices.concat(scope.arrayIndex);scope.$i=scope.arrayIndices}}}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($compile,$http,$templateCache,$q,schemaForm,schemaFormDecorators,sfSelect,sfPath,sfBuilder){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function($scope){this.evalInParentScope=function(expr,locals){return $scope.$parent.$eval(expr,locals)};var that=this;$scope.lookup=function(lookup){if(lookup){that.lookup=lookup}return that.lookup}}],replace:false,restrict:"A",transclude:true,require:"?form",link:function link(scope,element,attrs,formCtrl,transclude){scope.formCtrl=formCtrl;var ignore={};transclude(scope,function(clone){clone.addClass("schema-form-ignore");element.prepend(clone);if(element[0].querySelectorAll){var models=element[0].querySelectorAll("[ng-model]");if(models){for(var i=0;i<models.length;i++){var key=models[i].getAttribute("ng-model");ignore[key.substring(key.indexOf(".")+1)]=true}}}});var lastDigest={};var childScope;var render=function render(schema,form){var asyncTemplates=[];var merged=schemaForm.merge(schema,form,ignore,scope.options,undefined,asyncTemplates);if(asyncTemplates.length>0){$q.all(asyncTemplates.map(function(form){return $http.get(form.templateUrl,{cache:$templateCache}).then(function(res){form.template=res.data})})).then(function(){internalRender(schema,form,merged)})}else{internalRender(schema,form,merged)}};var internalRender=function internalRender(schema,form,merged){if(childScope){scope.externalDestructionInProgress=true;childScope.$destroy();scope.externalDestructionInProgress=false}childScope=scope.$new();childScope.schemaForm={form:merged,schema:schema};element.children(":not(.schema-form-ignore)").remove();var slots={};var slotsFound=element[0].querySelectorAll("*[sf-insert-field]");for(var i=0;i<slotsFound.length;i++){slots[slotsFound[i].getAttribute("sf-insert-field")]=slotsFound[i]}var decorator=schemaFormDecorators.decorator(attrs.sfUseDecorator);var lookup=Object.create(null);scope.lookup(lookup);element[0].appendChild(sfBuilder.build(merged,decorator,slots,lookup));childScope.firstDigest=true;setTimeout(function(){childScope.firstDigest=false},0);$compile(element.children())(childScope);if(!scope.options||scope.options.setSchemaDefaults!==false){schemaForm.traverseSchema(schema,function(prop,path){if(_angular2.default.isDefined(prop["default"])){var val=sfSelect(path,scope.model);if(_angular2.default.isUndefined(val)){sfSelect(path,scope.model,prop["default"])}}})}scope.$emit("sf-render-finished",element)};var defaultForm=["*"];scope.$watch(function(){var schema=scope.schema;var form=scope.initialForm||defaultForm;if(form&&schema&&schema.type&&(lastDigest.form!==form||lastDigest.schema!==schema)&&Object.keys(schema.properties).length>0){lastDigest.schema=schema;lastDigest.form=form;render(schema,form)}});scope.$on("schemaFormRedraw",function(){var schema=scope.schema;var form=scope.initialForm?_angular2.default.copy(scope.initialForm):["*"];if(schema){render(schema,form)}});scope.$on("$destroy",function(){scope.externalDestructionInProgress=true});scope.evalExpr=function(expression,locals){return scope.$parent.$eval(expression,locals)}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfValidator,$parse,sfSelect){return{restrict:"A",scope:false,priority:500,require:"ngModel",link:function link(scope,element,attrs,ngModel){scope.$emit("schemaFormPropagateNgModelController",ngModel);var error=null;var form=scope.$eval(attrs.schemaValidate);if(form.copyValueTo){ngModel.$viewChangeListeners.push(function(){var paths=form.copyValueTo;_angular2.default.forEach(paths,function(path){sfSelect(path,scope.model,ngModel.$modelValue)})})}var validate=function validate(viewValue){if(!form){return viewValue}if(scope.options&&scope.options.tv4Validation===false){return viewValue}var result=sfValidator.validate(form,viewValue);Object.keys(ngModel.$error).filter(function(k){return k.indexOf("tv4-")===0}).forEach(function(k){ngModel.$setValidity(k,true)});if(!result.valid){ngModel.$setValidity("tv4-"+result.error.code,false);error=result.error;if(ngModel.$validators){return viewValue}return undefined}return viewValue};if(typeof form.ngModel==="function"){form.ngModel(ngModel)}["$parsers","$viewChangeListeners","$formatters"].forEach(function(attr){if(form[attr]&&ngModel[attr]){form[attr].forEach(function(fn){ngModel[attr].push(fn)})}});["$validators","$asyncValidators"].forEach(function(attr){if(form[attr]&&ngModel[attr]){_angular2.default.forEach(form[attr],function(fn,name){ngModel[attr][name]=fn})}});ngModel.$parsers.push(validate);if(ngModel.$validators){ngModel.$validators.schemaForm=function(){return!Object.keys(ngModel.$error).some(function(e){return e!=="schemaForm"})}}var schema=form.schema;scope.validateField=function(formName){if(formName!=undefined&&ngModel.$$parentForm.$name!==formName){return}if(schema&&schema.type.indexOf("array")!==-1){validate(ngModel.$modelValue)}if(ngModel.$setDirty){ngModel.$setDirty();ngModel.$setViewValue(ngModel.$viewValue);ngModel.$commitViewValue();if(form.type==="checkbox"){if(form.required&&ngModel.$modelValue===undefined){ngModel.$setValidity("tv4-302",false)}}else if(form.required&&ngModel.$isEmpty(ngModel.$modelValue)){ngModel.$setValidity("tv4-302",false)}}else{ngModel.$setViewValue(ngModel.$viewValue)}};var first=true;ngModel.$formatters.push(function(val){if(ngModel.$pristine&&first&&(!scope.options||scope.options.validateOnRender!==true)){first=false;return val}validate(ngModel.$modelValue);return val});scope.$on("schemaFormValidate",function(event,formName){scope.validateField(formName)});scope.schemaError=function(){return error}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}}])})},function(module,exports){module.exports=angular},function(module,exports){module.exports=tv4}])});
\ No newline at end of file
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index 5548285..6b09d8f 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -250,7 +250,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/fieldset.html';
-	var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
+	var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -268,7 +268,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/radio-buttons.html';
-	var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (item.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: item.value === $$value$$ }\"\r\n           ng-repeat=\"item in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (tm.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: tm.value === $$value$$ }\"\r\n           ng-repeat=\"tm in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -277,7 +277,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/radios-inline.html';
-	var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"item in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"tm in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -286,7 +286,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/radios.html';
-	var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"item in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"item.value\"\r\n             name=\"{{form.key.join('.')}}\">\r\n      <span ng-bind-html=\"item.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"tm in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -295,7 +295,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/section.html';
-	var html = "<div class=\"schema-form-section {{::form.htmlClass}}\"></div>\r\n";
+	var html = "<div class=\"schema-form-section {{::form.htmlClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
diff --git a/dist/angular-schema-form-bootstrap.min.js b/dist/angular-schema-form-bootstrap.min.js
index 8aa67f6..796e330 100644
--- a/dist/angular-schema-form-bootstrap.min.js
+++ b/dist/angular-schema-form-bootstrap.min.js
@@ -5,4 +5,4 @@
  * @license MIT
  * Copyright (c) 2016 JSON Schema Form
  */
-(function webpackUniversalModuleDefinition(root,factory){if(typeof exports==="object"&&typeof module==="object")module.exports=factory();else if(typeof define==="function"&&define.amd)define([],factory);else{var a=factory();for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){"use strict";__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var textareaTemplate=__webpack_require__(17);var fieldsetTemplate=__webpack_require__(7);var arrayTemplate=__webpack_require__(3);var tabarrayTemplate=__webpack_require__(15);var tabsTemplate=__webpack_require__(16);var sectionTemplate=__webpack_require__(12);var actionsTemplate=__webpack_require__(2);var selectTemplate=__webpack_require__(13);var checkboxTemplate=__webpack_require__(4);var checkboxesTemplate=__webpack_require__(5);var submitTemplate=__webpack_require__(14);var radiosTemplate=__webpack_require__(11);var radiosInlineTemplate=__webpack_require__(10);var radiobuttonsTemplate=__webpack_require__(9);var helpTemplate=__webpack_require__(8);var defaultTemplate=__webpack_require__(6);angular.module("schemaForm").config(bootstrapDecoratorConfig).filter("sfCamelKey",sfCamelKeyFilter);bootstrapDecoratorConfig.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"];function bootstrapDecoratorConfig(schemaFormProvider,decoratorsProvider,sfBuilderProvider,sfPathProvider,$injector){var base="decorators/bootstrap/";var simpleTransclusion=sfBuilderProvider.builders.simpleTransclusion;var ngModelOptions=sfBuilderProvider.builders.ngModelOptions;var ngModel=sfBuilderProvider.builders.ngModel;var sfField=sfBuilderProvider.builders.sfField;var condition=sfBuilderProvider.builders.condition;var array=sfBuilderProvider.builders.array;var numeric=sfBuilderProvider.builders.numeric;var tabs=function tabs(args){if(args.form.tabs&&args.form.tabs.length>0){var tabContent=args.fieldFrag.querySelector(".tab-content");args.form.tabs.forEach(function(tab,index){var evalExpr="(evalExpr("+args.path+".tabs["+index+"]"+'.condition, { model: model, "arrayIndex": $index}))';var div=document.createElement("div");div.className="tab-pane";div.setAttribute("ng-disabled","form.readonly");div.setAttribute("ng-show","selected.tab === "+index);div.setAttribute("ng-class","{active: selected.tab === "+index+"}");if(!!tab.condition){div.setAttribute("ng-if",evalExpr)}var childFrag=args.build(tab.items,args.path+".tabs["+index+"].items",args.state);div.appendChild(childFrag);tabContent.appendChild(div)})}};var selectPlaceholder=function selectPlaceholder(args){if(args.form.placeholder){var selectBox=args.fieldFrag.querySelector("select");var option=document.createElement("option");option.setAttribute("value","");option.setAttribute("sf-field-model","replaceAll");if(angular.version.major===1&&angular.version.minor<4){option.setAttribute("ng-if","$$value$$ === undefined")}else{option.setAttribute("ng-show","$$value$$ === undefined")}option.textContent=args.form.placeholder;selectBox.appendChild(option)}};var defaults=[sfField,ngModel,ngModelOptions,condition];decoratorsProvider.defineDecorator("bootstrapDecorator",{actions:{template:actionsTemplate,builder:defaults},array:{template:arrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},button:{template:submitTemplate,builder:defaults},checkbox:{template:checkboxTemplate,builder:defaults},checkboxes:{template:checkboxesTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},conditional:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},"default":{template:defaultTemplate,builder:defaults},fieldset:{template:fieldsetTemplate,builder:[sfField,simpleTransclusion,condition]},help:{template:helpTemplate,builder:defaults},number:{template:defaultTemplate,builder:defaults.concat(numeric)},password:{template:defaultTemplate,builder:defaults},radios:{template:radiosTemplate,builder:defaults},"radios-inline":{template:radiosInlineTemplate,builder:defaults},radiobuttons:{template:radiobuttonsTemplate,builder:defaults},section:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},select:{template:selectTemplate,builder:defaults.concat(selectPlaceholder)},submit:{template:submitTemplate,builder:defaults},tabarray:{template:tabarrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},tabs:{template:tabsTemplate,builder:[sfField,ngModelOptions,tabs,condition]},textarea:{template:textareaTemplate,builder:defaults}},[])}function sfCamelKeyFilter(){return function(formKey){if(!formKey){return""}var part,i,key;key=formKey.slice();for(i=0;i<key.length;i++){part=key[i].toLowerCase().split("");if(i&&part.length){part[0]=part[0].toUpperCase()}key[i]=part.join("")}return key.join("")}}},function(module,exports){var path="bootstrap/actions.html";var html='<div class="btn-group schema-form-actions {{::form.htmlClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/array.html";var html='<div  class="schema-form-array {{::form.htmlClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkbox.html";var html='<div class="checkbox schema-form-checkbox {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{form.key.slice(-1)[0]}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkboxes.html";var html='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{form.key.slice(-1)[0]}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/default.html";var html='<div class="form-group {{::form.htmlClass}}"\r\n     ng-class="{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{form.key.slice(-1)[0]}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{form.key.slice(-1)[0]}}"\r\n         aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{form.key.slice(-1)[0]}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{form.key.slice(-1)[0]}}"\r\n           aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{form.key.slice(-1)[0] + \'Status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/fieldset.html";var html='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/help.html";var html='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radio-buttons.html";var html='<div class="form-group schema-form-radiobuttons {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (item.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: item.value === $$value$$ }"\r\n           ng-repeat="item in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios-inline.html";var html='<div class="form-group schema-form-radios-inline {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="item in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios.html";var html='<div class="form-group schema-form-radios {{::form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="item in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="item.value"\r\n             name="{{form.key.join(\'.\')}}">\r\n      <span ng-bind-html="item.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/section.html";var html='<div class="schema-form-section {{::form.htmlClass}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/select.html";var html='<div class="form-group {{::form.htmlClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{form.key.slice(-1)[0]}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/submit.html";var html='<div class="form-group schema-form-submit {{::form.htmlClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabarray.html";var html='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabs.html";var html='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/textarea.html";var html='<div class="form-group has-feedback {{::form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{form.key.slice(-1)[0]}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{form.key.slice(-1)[0]}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{form.key.slice(-1)[0]}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{form.key.slice(-1)[0]}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path}])});
\ No newline at end of file
+(function webpackUniversalModuleDefinition(root,factory){if(typeof exports==="object"&&typeof module==="object")module.exports=factory();else if(typeof define==="function"&&define.amd)define([],factory);else{var a=factory();for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){"use strict";__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var textareaTemplate=__webpack_require__(17);var fieldsetTemplate=__webpack_require__(7);var arrayTemplate=__webpack_require__(3);var tabarrayTemplate=__webpack_require__(15);var tabsTemplate=__webpack_require__(16);var sectionTemplate=__webpack_require__(12);var actionsTemplate=__webpack_require__(2);var selectTemplate=__webpack_require__(13);var checkboxTemplate=__webpack_require__(4);var checkboxesTemplate=__webpack_require__(5);var submitTemplate=__webpack_require__(14);var radiosTemplate=__webpack_require__(11);var radiosInlineTemplate=__webpack_require__(10);var radiobuttonsTemplate=__webpack_require__(9);var helpTemplate=__webpack_require__(8);var defaultTemplate=__webpack_require__(6);angular.module("schemaForm").config(bootstrapDecoratorConfig).filter("sfCamelKey",sfCamelKeyFilter);bootstrapDecoratorConfig.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"];function bootstrapDecoratorConfig(schemaFormProvider,decoratorsProvider,sfBuilderProvider,sfPathProvider,$injector){var base="decorators/bootstrap/";var simpleTransclusion=sfBuilderProvider.builders.simpleTransclusion;var ngModelOptions=sfBuilderProvider.builders.ngModelOptions;var ngModel=sfBuilderProvider.builders.ngModel;var sfField=sfBuilderProvider.builders.sfField;var condition=sfBuilderProvider.builders.condition;var array=sfBuilderProvider.builders.array;var numeric=sfBuilderProvider.builders.numeric;var tabs=function tabs(args){if(args.form.tabs&&args.form.tabs.length>0){var tabContent=args.fieldFrag.querySelector(".tab-content");args.form.tabs.forEach(function(tab,index){var evalExpr="(evalExpr("+args.path+".tabs["+index+"]"+'.condition, { model: model, "arrayIndex": $index}))';var div=document.createElement("div");div.className="tab-pane";div.setAttribute("ng-disabled","form.readonly");div.setAttribute("ng-show","selected.tab === "+index);div.setAttribute("ng-class","{active: selected.tab === "+index+"}");if(!!tab.condition){div.setAttribute("ng-if",evalExpr)}var childFrag=args.build(tab.items,args.path+".tabs["+index+"].items",args.state);div.appendChild(childFrag);tabContent.appendChild(div)})}};var selectPlaceholder=function selectPlaceholder(args){if(args.form.placeholder){var selectBox=args.fieldFrag.querySelector("select");var option=document.createElement("option");option.setAttribute("value","");option.setAttribute("sf-field-model","replaceAll");if(angular.version.major===1&&angular.version.minor<4){option.setAttribute("ng-if","$$value$$ === undefined")}else{option.setAttribute("ng-show","$$value$$ === undefined")}option.textContent=args.form.placeholder;selectBox.appendChild(option)}};var defaults=[sfField,ngModel,ngModelOptions,condition];decoratorsProvider.defineDecorator("bootstrapDecorator",{actions:{template:actionsTemplate,builder:defaults},array:{template:arrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},button:{template:submitTemplate,builder:defaults},checkbox:{template:checkboxTemplate,builder:defaults},checkboxes:{template:checkboxesTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},conditional:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},default:{template:defaultTemplate,builder:defaults},fieldset:{template:fieldsetTemplate,builder:[sfField,simpleTransclusion,condition]},help:{template:helpTemplate,builder:defaults},number:{template:defaultTemplate,builder:defaults.concat(numeric)},password:{template:defaultTemplate,builder:defaults},radios:{template:radiosTemplate,builder:defaults},"radios-inline":{template:radiosInlineTemplate,builder:defaults},radiobuttons:{template:radiobuttonsTemplate,builder:defaults},section:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},select:{template:selectTemplate,builder:defaults.concat(selectPlaceholder)},submit:{template:submitTemplate,builder:defaults},tabarray:{template:tabarrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},tabs:{template:tabsTemplate,builder:[sfField,ngModelOptions,tabs,condition]},textarea:{template:textareaTemplate,builder:defaults}},[])}function sfCamelKeyFilter(){return function(formKey){if(!formKey){return""}var part,i,key;key=formKey.slice();for(i=0;i<key.length;i++){part=key[i].toLowerCase().split("");if(i&&part.length){part[0]=part[0].toUpperCase()}key[i]=part.join("")}return key.join("")}}},function(module,exports){var path="bootstrap/actions.html";var html='<div class="btn-group schema-form-actions {{::form.htmlClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/array.html";var html='<div  class="schema-form-array {{::form.htmlClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkbox.html";var html='<div class="checkbox schema-form-checkbox {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{form.key.slice(-1)[0]}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkboxes.html";var html='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{form.key.slice(-1)[0]}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/default.html";var html='<div class="form-group {{::form.htmlClass}}"\r\n     ng-class="{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{form.key.slice(-1)[0]}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{form.key.slice(-1)[0]}}"\r\n         aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{form.key.slice(-1)[0]}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{form.key.slice(-1)[0]}}"\r\n           aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{form.key.slice(-1)[0] + \'Status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/fieldset.html";var html='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/help.html";var html='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radio-buttons.html";var html='<div class="form-group schema-form-radiobuttons {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios-inline.html";var html='<div class="form-group schema-form-radios-inline {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios.html";var html='<div class="form-group schema-form-radios {{::form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/section.html";var html='<div class="schema-form-section {{::form.htmlClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/select.html";var html='<div class="form-group {{::form.htmlClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{form.key.slice(-1)[0]}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/submit.html";var html='<div class="form-group schema-form-submit {{::form.htmlClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabarray.html";var html='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabs.html";var html='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/textarea.html";var html='<div class="form-group has-feedback {{::form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{form.key.slice(-1)[0]}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{form.key.slice(-1)[0]}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{form.key.slice(-1)[0]}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{form.key.slice(-1)[0]}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path}])});
\ No newline at end of file
diff --git a/examples/bootstrap-example.html b/examples/bootstrap-example.html
index 8c059f7..1ded14e 100644
--- a/examples/bootstrap-example.html
+++ b/examples/bootstrap-example.html
@@ -222,7 +222,7 @@ <h3>Schema</h3>
 
 <!-- These are the main files that you must include along with Angular-->
 <script type="text/javascript" src="../bower_components/tv4/tv4.js"></script>
-<script type="text/javascript" src="../dist/angular-schema-form-bootstrap.js"></script>
+<script type="text/javascript" src="../dist/angular-schema-form-bootstrap-bundled.js"></script>
 <!-- /These were the main files that you must include along with Angular-->
 
 <script type="text/javascript" src="../bower_components/angular-schema-form-datepicker/bootstrap-datepicker.min.js"></script>
diff --git a/package.json b/package.json
index 1df3032..6e28097 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
 {
   "name": "angular-schema-form-bootstrap",
-  "version": "1.0.0-alpha.1",
+  "version": "1.0.0-alpha.2",
   "description": "Bootstrap 3 decorator for Angular Schema Form",
   "main": "dist/bootstrap-decorator.js",
   "scripts": {
diff --git a/src/bootstrap/fieldset.html b/src/bootstrap/fieldset.html
index 5eeea33..f3b65f4 100644
--- a/src/bootstrap/fieldset.html
+++ b/src/bootstrap/fieldset.html
@@ -1,4 +1,4 @@
-<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass}}">
+<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass}}" sf-key-controller sf-parent-key="[{{form.key.join('][')}}]" sf-index="{{$index}}">
   <legend ng-class="{'sr-only': !showTitle() }">{{ form.title }}</legend>
   <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>
 </fieldset>
diff --git a/src/bootstrap/radio-buttons.html b/src/bootstrap/radio-buttons.html
index 3530342..b012876 100644
--- a/src/bootstrap/radio-buttons.html
+++ b/src/bootstrap/radio-buttons.html
@@ -4,9 +4,9 @@
     <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>
   </div>
   <div class="btn-group">
-    <label sf-field-model="replaceAll" class="btn {{ (item.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}"
-           ng-class="{ active: item.value === $$value$$ }"
-           ng-repeat="item in form.titleMap">
+    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}"
+           ng-class="{ active: tm.value === $$value$$ }"
+           ng-repeat="tm in form.titleMap">
       <input type="radio"
              class="{{::form.fieldHtmlClass}}"
              sf-changed="form"
@@ -14,9 +14,9 @@
              ng-disabled="form.readonly"
              sf-field-model
              schema-validate="form"
-             ng-value="item.value"
-             name="{{form.key.join('.')}}">
-      <span ng-bind-html="item.name"></span>
+             ng-value="tm.value"
+             name="{{::fieldId(true, false)}}">
+      <span ng-bind-html="tm.name"></span>
     </label>
   </div>
   <div class="help-block" sf-message="form.description"></div>
diff --git a/src/bootstrap/radios-inline.html b/src/bootstrap/radios-inline.html
index 7b0df63..463c7ed 100644
--- a/src/bootstrap/radios-inline.html
+++ b/src/bootstrap/radios-inline.html
@@ -4,15 +4,15 @@
         ng-show="showTitle()" sf-field-model
         schema-validate="form" >{{form.title}}</label>
   <div>
-      <label class="radio-inline" ng-repeat="item in form.titleMap" >
+      <label class="radio-inline" ng-repeat="tm in form.titleMap" >
       <input type="radio"
              class="{{::form.fieldHtmlClass}}"
              sf-changed="form"
              ng-disabled="form.readonly"
              sf-field-model
-             ng-value="item.value"
-             name="{{form.key.join('.')}}">
-      <span ng-bind-html="item.name"></span>
+             ng-value="tm.value"
+             name="{{::fieldId(true, false)}}">
+      <span ng-bind-html="tm.name"></span>
     </label>
   </div>
   <div class="help-block" sf-message="form.description"></div>
diff --git a/src/bootstrap/radios.html b/src/bootstrap/radios.html
index 278715d..17b6b2b 100644
--- a/src/bootstrap/radios.html
+++ b/src/bootstrap/radios.html
@@ -2,16 +2,16 @@
   <label class="control-label {{::form.labelHtmlClass}}"
          sf-field-model schema-validate="form"
          ng-show="showTitle()">{{form.title}}</label>
-  <div class="radio" ng-repeat="item in form.titleMap">
+  <div class="radio" ng-repeat="tm in form.titleMap">
     <label>
       <input type="radio"
              class="{{::form.fieldHtmlClass}}"
              sf-changed="form"
              ng-disabled="form.readonly"
              sf-field-model
-             ng-value="item.value"
-             name="{{form.key.join('.')}}">
-      <span ng-bind-html="item.name"></span>
+             ng-value="tm.value"
+             name="{{::fieldId(true, false)}}">
+      <span ng-bind-html="tm.name"></span>
     </label>
   </div>
   <div class="help-block" sf-message="form.description"></div>
diff --git a/src/bootstrap/section.html b/src/bootstrap/section.html
index ac37169..e06c96f 100644
--- a/src/bootstrap/section.html
+++ b/src/bootstrap/section.html
@@ -1 +1 @@
-<div class="schema-form-section {{::form.htmlClass}}"></div>
+<div class="schema-form-section {{::form.htmlClass}}" sf-key-controller sf-parent-key="[{{form.key.join('][')}}]" sf-index="{{$index}}"></div>

From 7b74047b4932b60f680544993a065ae94564e07d Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Sun, 18 Dec 2016 14:01:55 +1100
Subject: [PATCH 31/50] Update webpack build and fix default template

---
 dist/angular-schema-form-bootstrap-bundled.js | 12 ++++++------
 dist/angular-schema-form-bootstrap.js         | 12 ++++++------
 src/bootstrap/default.html                    |  4 ++--
 webpack.config.js                             | 19 ++++++++++---------
 4 files changed, 24 insertions(+), 23 deletions(-)

diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index b4bae70..dfe03c5 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -1,6 +1,6 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.1
+ * @version 1.0.0-alpha.2
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2016 JSON Schema Form
@@ -224,7 +224,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/checkbox.html';
-	var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{form.key.slice(-1)[0]}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{::fieldId(true, false)}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -233,7 +233,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/checkboxes.html';
-	var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{form.key.slice(-1)[0]}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -242,7 +242,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/default.html';
-	var html = "<div class=\"form-group {{::form.htmlClass}}\"\r\n     ng-class=\"{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{form.key.slice(-1)[0]}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{form.key.slice(-1)[0]}}\"\r\n         aria-describedby=\"{{form.key.slice(-1)[0] + 'Status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{form.key.slice(-1)[0]}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{form.key.slice(-1)[0]}}\"\r\n           aria-describedby=\"{{form.key.slice(-1)[0] + 'Status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{form.key.slice(-1)[0] + 'Status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group {{::form.htmlClass}}\"\r\n     ng-class=\"{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{::fieldId(true, false)}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{::fieldId(true, false)}}\"\r\n         aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{::fieldId(true, false)}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{::fieldId(true, false)}}\"\r\n           aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{::fieldId(true, true) + '-status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -305,7 +305,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/select.html';
-	var html = "<div class=\"form-group {{::form.htmlClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{form.key.slice(-1)[0]}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group {{::form.htmlClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\" for=\"{{::fieldId(true, false)}}\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id=\"{{::fieldId(true, false)}}\"\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{::fieldId(true, false)}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -341,7 +341,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/textarea.html';
-	var html = "<div class=\"form-group has-feedback {{::form.htmlClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{form.key.slice(-1)[0]}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{form.key.slice(-1)[0]}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{form.key.slice(-1)[0]}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{form.key.slice(-1)[0]}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
+	var html = "<div class=\"form-group has-feedback {{::form.htmlClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{::fieldId(true, false)}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{::fieldId(true, false)}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{::fieldId(true, false)}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{::fieldId(true, false)}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index 6b09d8f..6584bc4 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -1,6 +1,6 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.1
+ * @version 1.0.0-alpha.2
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2016 JSON Schema Form
@@ -223,7 +223,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/checkbox.html';
-	var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{form.key.slice(-1)[0]}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{::fieldId(true, false)}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -232,7 +232,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/checkboxes.html';
-	var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{form.key.slice(-1)[0]}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -241,7 +241,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/default.html';
-	var html = "<div class=\"form-group {{::form.htmlClass}}\"\r\n     ng-class=\"{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{form.key.slice(-1)[0]}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{form.key.slice(-1)[0]}}\"\r\n         aria-describedby=\"{{form.key.slice(-1)[0] + 'Status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{form.key.slice(-1)[0]}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{form.key.slice(-1)[0]}}\"\r\n           aria-describedby=\"{{form.key.slice(-1)[0] + 'Status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{form.key.slice(-1)[0] + 'Status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group {{::form.htmlClass}}\"\r\n     ng-class=\"{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{::fieldId(true, false)}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{::fieldId(true, false)}}\"\r\n         aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{::fieldId(true, false)}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{::fieldId(true, false)}}\"\r\n           aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{::fieldId(true, true) + '-status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -304,7 +304,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/select.html';
-	var html = "<div class=\"form-group {{::form.htmlClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{form.key.slice(-1)[0]}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+	var html = "<div class=\"form-group {{::form.htmlClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\" for=\"{{::fieldId(true, false)}}\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id=\"{{::fieldId(true, false)}}\"\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{::fieldId(true, false)}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
@@ -340,7 +340,7 @@ return /******/ (function(modules) { // webpackBootstrap
 /***/ function(module, exports) {
 
 	var path = 'bootstrap/textarea.html';
-	var html = "<div class=\"form-group has-feedback {{::form.htmlClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{form.key.slice(-1)[0]}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{form.key.slice(-1)[0]}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{form.key.slice(-1)[0]}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{form.key.slice(-1)[0]}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{form.key.slice(-1)[0]}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
+	var html = "<div class=\"form-group has-feedback {{::form.htmlClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{::fieldId(true, false)}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{::fieldId(true, false)}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{::fieldId(true, false)}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{::fieldId(true, false)}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
 	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 	module.exports = path;
 
diff --git a/src/bootstrap/default.html b/src/bootstrap/default.html
index 7a70367..56033df 100644
--- a/src/bootstrap/default.html
+++ b/src/bootstrap/default.html
@@ -1,5 +1,5 @@
-<div class="form-group {{::form.htmlClass}}"
-     ng-class="{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }">
+<div class="form-group {{::form.htmlClass + ' schema-form-' + form.type}}"
+     ng-class="{ 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }">
   <label class="control-label {{::form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>
 
   <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"
diff --git a/webpack.config.js b/webpack.config.js
index 3d3cb12..70f1261 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -9,20 +9,21 @@ const pjson = require('./package.json');
 console.log('Angular Schema Form Bootstrap v' + pjson.version);
 
 module.exports = {
-  // entry: './src/module.js',
   entry: {
-    'angular-schema-form-bootstrap': getPath('./src/module.js'),
-    'angular-schema-form-bootstrap-bundled': getPath('./src/module-bundled.js'),
+    'angular-schema-form-bootstrap': [ 'angular-schema-form', getPath('./src/module.js') ],
+    'angular-schema-form-bootstrap-bundled': [ 'angular-schema-form', getPath('./src/module-bundled.js') ],
   },
   output: {
     path: getPath('./dist'),
     filename: '[name].js',
-    sourceMapFilename: '[name].map',
-    libraryTarget: 'umd'
+    sourceMapFilename: '[name].map'
   },
   resolve: {
     modulesDirectories: [
-      'node_modules', 'src'
+      path.join(__dirname, "..", "angular-schema-form", "dist"),
+      path.join(__dirname, "src"),
+      path.join(__dirname, "src", "bootstrap"),
+      'node_modules',
     ],
     extensions: [ '', '.js', '.html' ]
   },
@@ -53,10 +54,10 @@ module.exports = {
     // }),
     new webpack.BannerPlugin(
       'angular-schema-form-bootstrap\n' +
-      '@version ' +
-      pjson.version + '\n' +
+      '@version ' + pjson.version + '\n' +
+      '@date ' + buildDate.toUTCString() + '\n' +
       '@link https://github.com/json-schema-form/angular-schema-form-bootstrap\n' +
       '@license MIT\n' +
-      'Copyright (c) 2016 JSON Schema Form')
+      'Copyright (c) 2014-' + buildDate.getFullYear() + ' JSON Schema Form')
   ]
 };

From a30a7cb2b27353f5baa79f41a440c138b1288291 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Sun, 1 Jan 2017 17:58:47 +1100
Subject: [PATCH 32/50] Deep array example

Still needs to mix tabs, tabarray and array to be more complete.
---
 examples/data/array-deep.json | 171 ++++++++++++++++++++++++++++++++++
 1 file changed, 171 insertions(+)
 create mode 100644 examples/data/array-deep.json

diff --git a/examples/data/array-deep.json b/examples/data/array-deep.json
new file mode 100644
index 0000000..1dd2a72
--- /dev/null
+++ b/examples/data/array-deep.json
@@ -0,0 +1,171 @@
+{
+  "schema": {
+    "type": "object",
+    "properties": {
+      "transportCategory": {
+        "type": "array",
+        "items": {
+          "type": "object",
+          "properties": {
+            "mode": { "type": "string", "enum": ["Car", "Motorbike", "Horse"] },
+            "transportOption": {
+              "type": "array",
+              "items": {
+                "type": "object",
+                "properties": {
+                  "name": { "type": "string" },
+                  "numberOfWheels": { "type": "number" },
+                  "forSale": { "type": "string", "enum": ["yes", "no"] },
+                  "price": { "type": "number" },
+                  "history": {
+                    "type": "object",
+                    "properties": {
+                      "historyKnown": { "type": "string", "enum": ["yes", "no"] },
+                      "previousOwners": {
+                        "type": "array",
+                        "items": {
+                          "type": "object",
+                          "properties": {
+                            "ownerName": { "type": "string" },
+                            "purchaseDate": { "type": "string" },
+                            "logBookProvided": { "type": "string", "enum": ["yes", "no"] },
+                            "logBookEntry": {
+                              "type": "array",
+                              "items": {
+                                "type": "object",
+                                "properties": {
+                                  "entryId": { "type": "number" },
+                                  "entryDate": { "type": "string" },
+                                  "entryNote": { "type": "string" }
+                                }
+                              }
+                            }
+                          }
+                        }
+                      }
+                    }
+                  }
+                }
+              }
+            }
+          }
+        }
+      }
+    }
+  },
+  "form": [
+    {
+      "key": "transportCategory",
+      "items": [
+        "transportCategory[].mode",
+        {
+          "key": "transportCategory[].transportOption",
+          "items": [
+            "transportCategory[].transportOption[].name",
+            {
+              "key": "transportCategory[].transportOption[].numberOfWheels",
+              "condition": "model.transportCategory[arrayIndices[0]].mode != 'Horse'"
+            },
+            "transportCategory[].transportOption[].forSale",
+            {
+              "key": "transportCategory[].transportOption[].price",
+              "condition": "model.transportCategory[arrayIndices[0]].transportOption[arrayIndices[1]].forSale == 'yes'"
+            },
+            "transportCategory[].transportOption[].history.historyKnown",
+            {
+              "key": "transportCategory[].transportOption[].history.previousOwners",
+              "condition": "model.transportCategory[arrayIndices[0]].transportOption[arrayIndices[1]].history.historyKnown == 'yes'",
+              "items": [
+                "transportCategory[].transportOption[].history.previousOwners[].ownerName",
+                {
+                  "key": "transportCategory[].transportOption[].history.previousOwners[].purchaseDate",
+                  "condition": "model.transportCategory[arrayIndices[0]].transportOption[arrayIndices[1]].history.previousOwners[arrayIndices[2]].ownerName.length > 2"
+                },
+                {
+                  "key": "transportCategory[].transportOption[].history.previousOwners[].logBookProvided",
+                  "condition": "model.transportCategory[arrayIndices[0]].mode != 'Horse' && model.transportCategory[arrayIndices[0]].transportOption[arrayIndices[1]].history.previousOwners[arrayIndices[2]].ownerName.length > 2"
+                },
+                {
+                  "key": "transportCategory[].transportOption[].history.previousOwners[].logBookEntry",
+                  "condition": "model.transportCategory[arrayIndices[0]].transportOption[arrayIndices[1]].history.previousOwners[arrayIndices[2]].logBookProvided == 'yes'",
+                  "items": [
+                    "transportCategory[].transportOption[].history.previousOwners[].logBookEntry[].entryId",
+                    "transportCategory[].transportOption[].history.previousOwners[].logBookEntry[].entryDate",
+                    {
+                      "key": "transportCategory[].transportOption[].history.previousOwners[].logBookEntry[].entryNote",
+                      "condition": "model.transportCategory[arrayIndices[0]].transportOption[arrayIndices[1]].history.previousOwners[arrayIndices[2]].logBookEntry[arrayIndices[3]].entryDate.length > 2"
+                    }
+                  ]
+                }
+              ]
+            }
+          ]
+        }
+      ]
+    }
+  ],
+  "model": {
+    "transportCategory": [
+      {
+        "mode": "Car",
+        "transportOption": [
+          {
+            "name": "Bertie",
+            "forSale": "yes",
+            "price": 100,
+            "history": {
+                "historyKnown": "no"
+            }
+          },
+          {
+            "name": "Lightning McQueen",
+            "forSale": "no",
+            "history": {
+              "historyKnown": "yes",
+              "previousOwners": [
+                {
+                  "ownerName": ""
+                },
+                {
+                  "ownerName": "Arlo",
+                  "logBookProvided": "yes",
+                  "logBookEntry": [
+                    {
+                      "entryId": 2,
+                      "entryDate": "2015-06-23"
+                    },
+                    {
+                      "entryId": 4
+                    }
+                  ]
+                }
+              ]
+            }
+          }
+        ]
+      },
+      {
+        "mode": "Horse",
+        "transportOption": [
+          {
+            "name": "Phar Lap",
+            "forSale": "no"
+          },
+          {
+            "name": "Greyhound",
+            "forSale": "yes",
+            "price": 1000,
+            "history": {
+              "historyKnown": "yes",
+              "previousOwners": [
+                {
+                  "ownerName": "Tom"
+                }
+              ]
+            }
+          }
+        ]
+      }
+    ]
+  }
+}

From 3cbcdac61e4fe714c4e4c55dbd523c81ff9138bb Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Mon, 2 Jan 2017 02:46:32 +1100
Subject: [PATCH 33/50] Add idClass and upgrade webpack to v2

---
 README.md                                     |    6 +-
 dist/angular-schema-form-bootstrap-bundled.js | 4360 ++---------------
 dist/angular-schema-form-bootstrap.js         |  493 +-
 examples/data/array-deep.json                 |    6 +
 .../{bootstrap-example.html => example.html}  |    2 +
 npm-debug.log                                 |   48 -
 package.json                                  |   24 +-
 src/bootstrap-decorator.js                    |   32 +-
 src/bootstrap/actions-trcl.html               |    2 +-
 src/bootstrap/actions.html                    |    2 +-
 src/bootstrap/array.html                      |    2 +-
 src/bootstrap/checkbox.html                   |    2 +-
 src/bootstrap/checkboxes.html                 |    2 +-
 src/bootstrap/default.html                    |    2 +-
 src/bootstrap/fieldset.html                   |    2 +-
 src/bootstrap/help.html                       |    2 +-
 src/bootstrap/radio-buttons.html              |    2 +-
 src/bootstrap/radios-inline.html              |    2 +-
 src/bootstrap/radios.html                     |    2 +-
 src/bootstrap/section.html                    |    2 +-
 src/bootstrap/select.html                     |    2 +-
 src/bootstrap/submit.html                     |    2 +-
 src/bootstrap/tabarray.html                   |    2 +-
 src/bootstrap/tabs.html                       |    2 +-
 src/bootstrap/textarea.html                   |    2 +-
 src/module-bundled.js                         |    2 -
 webpack.config.dist.js                        |   11 +
 webpack.config.js                             |   80 +-
 28 files changed, 656 insertions(+), 4442 deletions(-)
 rename examples/{bootstrap-example.html => example.html} (99%)
 delete mode 100644 npm-debug.log
 delete mode 100644 src/module-bundled.js
 create mode 100644 webpack.config.dist.js

diff --git a/README.md b/README.md
index 9593911..182291c 100644
--- a/README.md
+++ b/README.md
@@ -23,9 +23,9 @@ or
 ```sh
 npm install angular-schema-form-bootstrap
 ```
-And then include `angular-schema-form-bootstrap.min.js`. Note that angular-schema-form >= 1.0.0-alpha.1 is needed.
+And then include `angular-schema-form-bootstrap-bundled.min.js`. Note that angular-schema-form >= 1.0.0-alpha.1 is needed.
 
-You **DO NOT** need to include angular-schema-form with this version, it is now embedded within the above file.
+You **DO NOT** need to include angular-schema-form with this version, it is now embedded within the above file. If you wish to include the files separately you can still use `angular-schema-form-bootstrap.min.js`
 
 Future
 ------
@@ -33,8 +33,6 @@ Using the new builder opens up for a lot of optimization. Primarily we can get r
 watches by using build helpers. For instance, slapping on a `sf-changed` directive *only* if the
 form definition has an `onChange` option.
 
-We also intend to provide a version that can be added as just the decorator without including Angular Schema Form.
-
 Developer Install
 -----------------
 ```sh
diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index dfe03c5..5dd11fc 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -1,21 +1,12 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.2
+ * @version 1.0.0-alpha.5
+ * @date Sun, 01 Jan 2017 14:14:55 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
- * Copyright (c) 2016 JSON Schema Form
+ * Copyright (c) 2014-2017 JSON Schema Form
  */
-(function webpackUniversalModuleDefinition(root, factory) {
-	if(typeof exports === 'object' && typeof module === 'object')
-		module.exports = factory(require("angular"), require("tv4"));
-	else if(typeof define === 'function' && define.amd)
-		define(["angular", "tv4"], factory);
-	else {
-		var a = typeof exports === 'object' ? factory(require("angular"), require("tv4")) : factory(root["angular"], root["tv4"]);
-		for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
-	}
-})(this, function(__WEBPACK_EXTERNAL_MODULE_19__, __WEBPACK_EXTERNAL_MODULE_20__) {
-return /******/ (function(modules) { // webpackBootstrap
+/******/ (function(modules) { // webpackBootstrap
 /******/ 	// The module cache
 /******/ 	var installedModules = {};
 
@@ -28,16 +19,16 @@ return /******/ (function(modules) { // webpackBootstrap
 
 /******/ 		// Create a new module (and put it into the cache)
 /******/ 		var module = installedModules[moduleId] = {
-/******/ 			exports: {},
-/******/ 			id: moduleId,
-/******/ 			loaded: false
+/******/ 			i: moduleId,
+/******/ 			l: false,
+/******/ 			exports: {}
 /******/ 		};
 
 /******/ 		// Execute the module function
 /******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
 
 /******/ 		// Flag the module as loaded
-/******/ 		module.loaded = true;
+/******/ 		module.l = true;
 
 /******/ 		// Return the exports of the module
 /******/ 		return module.exports;
@@ -50,4175 +41,372 @@ return /******/ (function(modules) { // webpackBootstrap
 /******/ 	// expose the module cache
 /******/ 	__webpack_require__.c = installedModules;
 
+/******/ 	// identity function for calling harmory imports with the correct context
+/******/ 	__webpack_require__.i = function(value) { return value; };
+
+/******/ 	// define getter function for harmory exports
+/******/ 	__webpack_require__.d = function(exports, name, getter) {
+/******/ 		Object.defineProperty(exports, name, {
+/******/ 			configurable: false,
+/******/ 			enumerable: true,
+/******/ 			get: getter
+/******/ 		});
+/******/ 	};
+
+/******/ 	// getDefaultExport function for compatibility with non-harmony modules
+/******/ 	__webpack_require__.n = function(module) {
+/******/ 		var getter = module && module.__esModule ?
+/******/ 			function getDefault() { return module['default']; } :
+/******/ 			function getModuleExports() { return module; };
+/******/ 		__webpack_require__.d(getter, 'a', getter);
+/******/ 		return getter;
+/******/ 	};
+
+/******/ 	// Object.prototype.hasOwnProperty.call
+/******/ 	__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
+
 /******/ 	// __webpack_public_path__
 /******/ 	__webpack_require__.p = "";
 
 /******/ 	// Load entry module and return exports
-/******/ 	return __webpack_require__(0);
+/******/ 	return __webpack_require__(__webpack_require__.s = 20);
 /******/ })
 /************************************************************************/
 /******/ ([
 /* 0 */
 /***/ function(module, exports, __webpack_require__) {
 
-	'use strict';
+__webpack_require__(17);
 
-	__webpack_require__(18);
-	__webpack_require__(1);
 
 /***/ },
 /* 1 */
-/***/ function(module, exports, __webpack_require__) {
-
-	'use strict';
-
-	// angular-templatecache-loader
-	var textareaTemplate = __webpack_require__(17);
-	var fieldsetTemplate = __webpack_require__(7);
-	var arrayTemplate = __webpack_require__(3);
-	var tabarrayTemplate = __webpack_require__(15);
-	var tabsTemplate = __webpack_require__(16);
-	var sectionTemplate = __webpack_require__(12);
-	var actionsTemplate = __webpack_require__(2);
-	var selectTemplate = __webpack_require__(13);
-	var checkboxTemplate = __webpack_require__(4);
-	var checkboxesTemplate = __webpack_require__(5);
-	var submitTemplate = __webpack_require__(14);
-	var radiosTemplate = __webpack_require__(11);
-	var radiosInlineTemplate = __webpack_require__(10);
-	var radiobuttonsTemplate = __webpack_require__(9);
-	var helpTemplate = __webpack_require__(8);
-	var defaultTemplate = __webpack_require__(6);
-
-	angular.module('schemaForm').config(bootstrapDecoratorConfig).filter('sfCamelKey', sfCamelKeyFilter);
-
-	bootstrapDecoratorConfig.$inject = ['schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'];
-
-	function bootstrapDecoratorConfig(schemaFormProvider, decoratorsProvider, sfBuilderProvider, sfPathProvider, $injector) {
-	  var base = 'decorators/bootstrap/';
-
-	  var simpleTransclusion = sfBuilderProvider.builders.simpleTransclusion;
-	  var ngModelOptions = sfBuilderProvider.builders.ngModelOptions;
-	  var ngModel = sfBuilderProvider.builders.ngModel;
-	  var sfField = sfBuilderProvider.builders.sfField;
-	  var condition = sfBuilderProvider.builders.condition;
-	  var array = sfBuilderProvider.builders.array;
-	  var numeric = sfBuilderProvider.builders.numeric;
-
-	  // Tabs is so bootstrap specific that it stays here.
-	  var tabs = function tabs(args) {
-	    if (args.form.tabs && args.form.tabs.length > 0) {
-	      var tabContent = args.fieldFrag.querySelector('.tab-content');
-
-	      args.form.tabs.forEach(function (tab, index) {
-	        var evalExpr = '(evalExpr(' + args.path + '.tabs[' + index + ']' + '.condition, { model: model, "arrayIndex": $index}))';
-	        var div = document.createElement('div');
-	        div.className = 'tab-pane';
-	        div.setAttribute('ng-disabled', 'form.readonly');
-	        div.setAttribute('ng-show', 'selected.tab === ' + index);
-	        div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
-	        if (!!tab.condition) {
-	          div.setAttribute('ng-if', evalExpr);
-	        };
-
-	        var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
-	        div.appendChild(childFrag);
-	        tabContent.appendChild(div);
-	      });
-	    }
-	  };
-
-	  var selectPlaceholder = function selectPlaceholder(args) {
-	    if (args.form.placeholder) {
-	      var selectBox = args.fieldFrag.querySelector('select');
-	      var option = document.createElement('option');
-	      option.setAttribute('value', '');
-
-	      /* We only want the placeholder to show when we do not have a value on the model.
-	       * We make ngModel builder replace all so we can use $$value$$.
-	       */
-	      option.setAttribute('sf-field-model', 'replaceAll');
-
-	      /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
-	       * angular > 1.4 does a emptyOption.attr('selected', true)
-	       * which does not like the ng-if comment.
-	       */
-	      if (angular.version.major === 1 && angular.version.minor < 4) {
-	        option.setAttribute('ng-if', '$$value$$ === undefined');
-	      } else {
-	        option.setAttribute('ng-show', '$$value$$ === undefined');
-	      }
-
-	      option.textContent = args.form.placeholder;
-
-	      selectBox.appendChild(option);
-	    }
-	  };
-
-	  var defaults = [sfField, ngModel, ngModelOptions, condition];
-	  decoratorsProvider.defineDecorator('bootstrapDecorator', {
-	    actions: { template: actionsTemplate, builder: defaults },
-	    array: { template: arrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
-	    button: { template: submitTemplate, builder: defaults },
-	    checkbox: { template: checkboxTemplate, builder: defaults },
-	    checkboxes: { template: checkboxesTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
-	    conditional: { template: sectionTemplate, builder: [sfField, simpleTransclusion, condition] },
-	    'default': { template: defaultTemplate, builder: defaults },
-	    fieldset: { template: fieldsetTemplate, builder: [sfField, simpleTransclusion, condition] },
-	    help: { template: helpTemplate, builder: defaults },
-	    number: { template: defaultTemplate, builder: defaults.concat(numeric) },
-	    password: { template: defaultTemplate, builder: defaults },
-	    radios: { template: radiosTemplate, builder: defaults },
-	    'radios-inline': { template: radiosInlineTemplate, builder: defaults },
-	    radiobuttons: { template: radiobuttonsTemplate, builder: defaults },
-	    section: { template: sectionTemplate, builder: [sfField, simpleTransclusion, condition] },
-	    select: { template: selectTemplate, builder: defaults.concat(selectPlaceholder) },
-	    submit: { template: submitTemplate, builder: defaults },
-	    tabarray: { template: tabarrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
-	    tabs: { template: tabsTemplate, builder: [sfField, ngModelOptions, tabs, condition] },
-	    textarea: { template: textareaTemplate, builder: defaults }
-	  }, []);
-	};
+/***/ function(module, exports) {
 
-	/**
-	 * sfCamelKey Filter
-	 */
-	function sfCamelKeyFilter() {
-	  return function (formKey) {
-	    if (!formKey) {
-	      return '';
-	    };
-	    var part, i, key;
-	    key = formKey.slice();
-	    for (i = 0; i < key.length; i++) {
-	      part = key[i].toLowerCase().split('');
-	      if (i && part.length) {
-	        part[0] = part[0].toUpperCase();
-	      };
-	      key[i] = part.join('');
-	    };
-	    return key.join('');
-	  };
-	};
+var path = '/bootstrap/actions.html';
+var html = "<div class=\"btn-group schema-form-actions {{::form.htmlClass + ' ' + idClass}}\">\r\n  <input ng-repeat-start=\"item in form.items\"\r\n         type=\"submit\"\r\n         class=\"btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}\"\r\n         value=\"{{item.title}}\"\r\n         ng-if=\"item.type === 'submit'\">\r\n  <button ng-repeat-end\r\n          class=\"btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}\"\r\n          type=\"button\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"item.type !== 'submit'\"\r\n          ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 2 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/actions.html';
-	var html = "<div class=\"btn-group schema-form-actions {{::form.htmlClass}}\">\r\n  <input ng-repeat-start=\"item in form.items\"\r\n         type=\"submit\"\r\n         class=\"btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}\"\r\n         value=\"{{item.title}}\"\r\n         ng-if=\"item.type === 'submit'\">\r\n  <button ng-repeat-end\r\n          class=\"btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}\"\r\n          type=\"button\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"item.type !== 'submit'\"\r\n          ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/array.html';
+var html = "<div  class=\"schema-form-array {{::form.htmlClass + ' ' + idClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $index\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 3 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/array.html';
-	var html = "<div  class=\"schema-form-array {{::form.htmlClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $index\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/checkbox.html';
+var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{::fieldId(true, false)}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 4 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/checkbox.html';
-	var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{::fieldId(true, false)}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/checkboxes.html';
+var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 5 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/checkboxes.html';
-	var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/default.html';
+var html = "<div class=\"form-group {{::form.htmlClass + ' schema-form-' + form.type + ' ' + idClass}}\"\r\n     ng-class=\"{ 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{::fieldId(true, false)}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{::fieldId(true, false)}}\"\r\n         aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{::fieldId(true, false)}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{::fieldId(true, false)}}\"\r\n           aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{::fieldId(true, true) + '-status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 6 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/default.html';
-	var html = "<div class=\"form-group {{::form.htmlClass}}\"\r\n     ng-class=\"{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{::fieldId(true, false)}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{::fieldId(true, false)}}\"\r\n         aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{::fieldId(true, false)}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{::fieldId(true, false)}}\"\r\n           aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{::fieldId(true, true) + '-status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/fieldset.html';
+var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass + ' ' + idClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 7 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/fieldset.html';
-	var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/help.html';
+var html = "<div class=\"helpvalue schema-form-helpvalue {{::form.htmlClass + ' ' + idClass}}\" ng-bind-html=\"form.helpvalue\"></div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 8 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/help.html';
-	var html = "<div class=\"helpvalue schema-form-helpvalue {{::form.htmlClass}}\" ng-bind-html=\"form.helpvalue\"></div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/radio-buttons.html';
+var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (tm.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: tm.value === $$value$$ }\"\r\n           ng-repeat=\"tm in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 9 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/radio-buttons.html';
-	var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (tm.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: tm.value === $$value$$ }\"\r\n           ng-repeat=\"tm in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/radios-inline.html';
+var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"tm in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 10 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/radios-inline.html';
-	var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"tm in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/radios.html';
+var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass + ' ' + idClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"tm in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 11 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/radios.html';
-	var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"tm in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/section.html';
+var html = "<div class=\"schema-form-section {{::form.htmlClass + ' ' + idClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 12 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/section.html';
-	var html = "<div class=\"schema-form-section {{::form.htmlClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/select.html';
+var html = "<div class=\"form-group {{::form.htmlClass + ' ' + idClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\" for=\"{{::fieldId(true, false)}}\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id=\"{{::fieldId(true, false)}}\"\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{::fieldId(true, false)}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 13 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/select.html';
-	var html = "<div class=\"form-group {{::form.htmlClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\" for=\"{{::fieldId(true, false)}}\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id=\"{{::fieldId(true, false)}}\"\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{::fieldId(true, false)}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/submit.html';
+var html = "<div class=\"form-group schema-form-submit {{::form.htmlClass + ' ' + idClass}}\">\r\n  <input type=\"submit\"\r\n         class=\"btn {{ form.style || 'btn-primary' }} {{::form.fieldHtmlClass}}\"\r\n         value=\"{{form.title}}\"\r\n         ng-disabled=\"form.readonly\"\r\n         ng-if=\"form.type === 'submit'\">\r\n  <button class=\"btn {{ form.style || 'btn-default' }}\"\r\n          type=\"button\"\r\n          ng-click=\"buttonClick($event,form)\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"form.type !== 'submit'\">\r\n      <span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 14 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/submit.html';
-	var html = "<div class=\"form-group schema-form-submit {{::form.htmlClass}}\">\r\n  <input type=\"submit\"\r\n         class=\"btn {{ form.style || 'btn-primary' }} {{::form.fieldHtmlClass}}\"\r\n         value=\"{{form.title}}\"\r\n         ng-disabled=\"form.readonly\"\r\n         ng-if=\"form.type === 'submit'\">\r\n  <button class=\"btn {{ form.style || 'btn-default' }}\"\r\n          type=\"button\"\r\n          ng-click=\"buttonClick($event,form)\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"form.type !== 'submit'\">\r\n      <span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/tabarray.html';
+var html = "<div ng-init=\"selected = { tab: 0 }\"\r\n     ng-model=\"modelArray\" schema-validate=\"form\"\r\n     sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{::form.htmlClass + ' ' + idClass}}\">\r\n  <div ng-if=\"!form.tabType || form.tabType !== 'right'\"\r\n       ng-class=\"{'col-xs-3': !form.tabType || form.tabType === 'left'}\">\r\n    <ol class=\"nav nav-tabs\"\r\n        ng-class=\"{ 'tabs-left': !form.tabType || form.tabType === 'left'}\"\r\n        sf-field-model ui-sortable=\"form.sortOptions\">\r\n      <li sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class=\"{'col-xs-9': !form.tabType || form.tabType === 'left' || form.tabType === 'right'}\">\r\n    <div class=\"tab-content {{::form.fieldHtmlClass}}\">\r\n      <div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\"\r\n           sf-field-model=\"ng-repeat\"\r\n           ng-repeat=\"item in $$value$$ track by $index\"\r\n           ng-show=\"selected.tab === $index\"\r\n           ng-class=\"{active: selected.tab === $index}\">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n\r\n           <button ng-hide=\"form.readonly || form.remove === null\"\r\n                   ng-click=\"selected.tab = deleteFromArray($index).length - 1\"\r\n                   ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n                   type=\"button\"\r\n                   class=\"btn {{ form.style.remove || 'btn-default' }} pull-right\">\r\n             <i class=\"glyphicon glyphicon-trash\"></i>\r\n             {{ form.remove || 'Remove'}}\r\n           </button>\r\n      </div>\r\n      <div class=\"help-block\"\r\n           ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n           ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if=\"form.tabType === 'right'\" class=\"col-xs-3\">\r\n    <ul class=\"nav nav-tabs tabs-right\">\r\n      <li  sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 15 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/tabarray.html';
-	var html = "<div ng-init=\"selected = { tab: 0 }\"\r\n     ng-model=\"modelArray\" schema-validate=\"form\"\r\n     sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{::form.htmlClass}}\">\r\n  <div ng-if=\"!form.tabType || form.tabType !== 'right'\"\r\n       ng-class=\"{'col-xs-3': !form.tabType || form.tabType === 'left'}\">\r\n    <ol class=\"nav nav-tabs\"\r\n        ng-class=\"{ 'tabs-left': !form.tabType || form.tabType === 'left'}\"\r\n        sf-field-model ui-sortable=\"form.sortOptions\">\r\n      <li sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class=\"{'col-xs-9': !form.tabType || form.tabType === 'left' || form.tabType === 'right'}\">\r\n    <div class=\"tab-content {{::form.fieldHtmlClass}}\">\r\n      <div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\"\r\n           sf-field-model=\"ng-repeat\"\r\n           ng-repeat=\"item in $$value$$ track by $index\"\r\n           ng-show=\"selected.tab === $index\"\r\n           ng-class=\"{active: selected.tab === $index}\">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n\r\n           <button ng-hide=\"form.readonly || form.remove === null\"\r\n                   ng-click=\"selected.tab = deleteFromArray($index).length - 1\"\r\n                   ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n                   type=\"button\"\r\n                   class=\"btn {{ form.style.remove || 'btn-default' }} pull-right\">\r\n             <i class=\"glyphicon glyphicon-trash\"></i>\r\n             {{ form.remove || 'Remove'}}\r\n           </button>\r\n      </div>\r\n      <div class=\"help-block\"\r\n           ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n           ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if=\"form.tabType === 'right'\" class=\"col-xs-3\">\r\n    <ul class=\"nav nav-tabs tabs-right\">\r\n      <li  sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/tabs.html';
+var html = "<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{::form.htmlClass + ' ' + idClass}}\">\r\n  <ul class=\"nav nav-tabs\">\r\n    <li ng-repeat=\"tab in form.tabs\"\r\n        ng-disabled=\"form.readonly\"\r\n        ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n        ng-class=\"{active: selected.tab === $index}\">\r\n        <a href=\"#\">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class=\"tab-content {{::form.fieldHtmlClass}}\">\r\n  </div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 16 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/tabs.html';
-	var html = "<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{::form.htmlClass}}\">\r\n  <ul class=\"nav nav-tabs\">\r\n    <li ng-repeat=\"tab in form.tabs\"\r\n        ng-disabled=\"form.readonly\"\r\n        ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n        ng-class=\"{active: selected.tab === $index}\">\r\n        <a href=\"#\">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class=\"tab-content {{::form.fieldHtmlClass}}\">\r\n  </div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/textarea.html';
+var html = "<div class=\"form-group has-feedback {{::form.htmlClass + ' ' + idClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{::fieldId(true, false)}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{::fieldId(true, false)}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{::fieldId(true, false)}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{::fieldId(true, false)}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 17 */
-/***/ function(module, exports) {
-
-	var path = 'bootstrap/textarea.html';
-	var html = "<div class=\"form-group has-feedback {{::form.htmlClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{::fieldId(true, false)}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{::fieldId(true, false)}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{::fieldId(true, false)}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{::fieldId(true, false)}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
-
-/***/ },
-/* 18 */
 /***/ function(module, exports, __webpack_require__) {
 
-	/*!
-	 * angular-schema-form
-	 * @version 1.0.0-alpha.2
-	 * @link https://github.com/json-schema-form/angular-schema-form
-	 * @license MIT
-	 * Copyright (c) 2016 JSON Schema Form
-	 */
-	(function webpackUniversalModuleDefinition(root, factory) {
-		if(true)
-			module.exports = factory(__webpack_require__(19), __webpack_require__(20));
-		else if(typeof define === 'function' && define.amd)
-			define(["angular", "tv4"], factory);
-		else {
-			var a = typeof exports === 'object' ? factory(require("angular"), require("tv4")) : factory(root["angular"], root["tv4"]);
-			for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
-		}
-	})(this, function(__WEBPACK_EXTERNAL_MODULE_2__, __WEBPACK_EXTERNAL_MODULE_7__) {
-	return /******/ (function(modules) { // webpackBootstrap
-	/******/ 	// The module cache
-	/******/ 	var installedModules = {};
-
-	/******/ 	// The require function
-	/******/ 	function __webpack_require__(moduleId) {
-
-	/******/ 		// Check if module is in cache
-	/******/ 		if(installedModules[moduleId])
-	/******/ 			return installedModules[moduleId].exports;
-
-	/******/ 		// Create a new module (and put it into the cache)
-	/******/ 		var module = installedModules[moduleId] = {
-	/******/ 			exports: {},
-	/******/ 			id: moduleId,
-	/******/ 			loaded: false
-	/******/ 		};
-
-	/******/ 		// Execute the module function
-	/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
-
-	/******/ 		// Flag the module as loaded
-	/******/ 		module.loaded = true;
-
-	/******/ 		// Return the exports of the module
-	/******/ 		return module.exports;
-	/******/ 	}
-
-
-	/******/ 	// expose the modules object (__webpack_modules__)
-	/******/ 	__webpack_require__.m = modules;
-
-	/******/ 	// expose the module cache
-	/******/ 	__webpack_require__.c = installedModules;
-
-	/******/ 	// __webpack_public_path__
-	/******/ 	__webpack_require__.p = "";
-
-	/******/ 	// Load entry module and return exports
-	/******/ 	return __webpack_require__(0);
-	/******/ })
-	/************************************************************************/
-	/******/ ([
-	/* 0 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		module.exports = __webpack_require__(1);
-
-
-	/***/ },
-	/* 1 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		var _builder = __webpack_require__(3);
-
-		var _builder2 = _interopRequireDefault(_builder);
-
-		var _decorators = __webpack_require__(4);
-
-		var _decorators2 = _interopRequireDefault(_decorators);
-
-		var _schemaForm = __webpack_require__(5);
-
-		var _schemaForm2 = _interopRequireDefault(_schemaForm);
-
-		var _jsonSchemaFormCore = __webpack_require__(6);
-
-		var _validator = __webpack_require__(8);
-
-		var _validator2 = _interopRequireDefault(_validator);
-
-		var _errors = __webpack_require__(9);
-
-		var _errors2 = _interopRequireDefault(_errors);
-
-		var _sfPath = __webpack_require__(10);
-
-		var _sfPath2 = _interopRequireDefault(_sfPath);
-
-		var _array = __webpack_require__(11);
-
-		var _array2 = _interopRequireDefault(_array);
-
-		var _changed = __webpack_require__(12);
-
-		var _changed2 = _interopRequireDefault(_changed);
-
-		var _field = __webpack_require__(13);
-
-		var _field2 = _interopRequireDefault(_field);
-
-		var _message = __webpack_require__(14);
-
-		var _message2 = _interopRequireDefault(_message);
-
-		var _newArray = __webpack_require__(15);
-
-		var _newArray2 = _interopRequireDefault(_newArray);
-
-		var _keyController = __webpack_require__(16);
-
-		var _keyController2 = _interopRequireDefault(_keyController);
-
-		var _schemaForm3 = __webpack_require__(17);
-
-		var _schemaForm4 = _interopRequireDefault(_schemaForm3);
-
-		var _schemaValidate = __webpack_require__(18);
-
-		var _schemaValidate2 = _interopRequireDefault(_schemaValidate);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-		// Deps is sort of a problem for us, maybe in the future we will ask the user to depend
-		// on modules for add-ons
-
-		var deps = [];
-		try {
-		  //This throws an expection if module does not exist.
-		  _angular2.default.module('ngSanitize');
-		  deps.push('ngSanitize');
-		} catch (e) {}
-
-		try {
-		  //This throws an expection if module does not exist.
-		  _angular2.default.module('ui.sortable');
-		  deps.push('ui.sortable');
-		} catch (e) {}
-
-		try {
-		  //This throws an expection if module does not exist.
-		  _angular2.default.module('angularSpectrumColorpicker');
-		  deps.push('angularSpectrumColorpicker');
-		} catch (e) {}
-
-		_angular2.default.module('schemaForm', deps)
-		// Providers and services
-		.provider('sfPath', _sfPath2.default).provider('sfBuilder', ['sfPathProvider', _builder2.default]).provider('schemaFormDecorators', ['$compileProvider', 'sfPathProvider', _decorators2.default]).provider('sfErrorMessage', _errors2.default).provider('schemaForm', ['sfPathProvider', _schemaForm2.default]).factory('sfSelect', function () {
-		  return _jsonSchemaFormCore.select;
-		}).factory('sfValidator', _validator2.default)
-
-		// Directives
-		.directive('sfArray', ['sfSelect', 'schemaForm', 'sfValidator', 'sfPath', _array2.default]).directive('sfChanged', _changed2.default).directive('sfField', ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', _field2.default]).directive('sfMessage', ['$injector', 'sfErrorMessage', _message2.default]).directive('sfNewArray', ['sfSelect', 'sfPath', 'schemaForm', _newArray2.default]).directive('sfSchema', ['$compile', '$http', '$templateCache', '$q', 'schemaForm', 'schemaFormDecorators', 'sfSelect', 'sfPath', 'sfBuilder', _schemaForm4.default]).directive('schemaValidate', ['sfValidator', '$parse', 'sfSelect', _schemaValidate2.default]).directive('sfKeyController', ['schemaForm', 'sfPath', _keyController2.default]);
-
-	/***/ },
-	/* 2 */
-	/***/ function(module, exports) {
-
-		module.exports = angular;
-
-	/***/ },
-	/* 3 */
-	/***/ function(module, exports) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function (sfPathProvider) {
-
-		  var SNAKE_CASE_REGEXP = /[A-Z]/g;
-		  var snakeCase = function snakeCase(name, separator) {
-		    separator = separator || '_';
-		    return name.replace(SNAKE_CASE_REGEXP, function (letter, pos) {
-		      return (pos ? separator : '') + letter.toLowerCase();
-		    });
-		  };
-		  var formId = 0;
-
-		  var builders = {
-		    sfField: function sfField(args) {
-		      args.fieldFrag.firstChild.setAttribute('sf-field', formId);
-
-		      // We use a lookup table for easy access to our form.
-		      args.lookup['f' + formId] = args.form;
-		      formId++;
-		    },
-		    ngModel: function ngModel(args) {
-		      if (!args.form.key) {
-		        return;
-		      }
-		      var key = args.form.key;
-
-		      // Redact part of the key, used in arrays
-		      // KISS keyRedaction is a number.
-		      if (args.state.keyRedaction) {
-		        key = key.slice(args.state.keyRedaction);
-		      }
-
-		      // Stringify key.
-		      var modelValue;
-		      if (!args.state.modelValue) {
-		        var strKey = sfPathProvider.stringify(key).replace(/"/g, '&quot;');
-		        modelValue = args.state.modelName || 'model';
-
-		        if (strKey) {
-		          // Sometimes, like with arrays directly in arrays strKey is nothing.
-		          modelValue += (strKey[0] !== '[' ? '.' : '') + strKey;
-		        }
-		      } else {
-		        // Another builder, i.e. array has overriden the modelValue
-		        modelValue = args.state.modelValue;
-		      }
-
-		      // Find all sf-field-value attributes.
-		      // No value means a add a ng-model.
-		      // sf-field-value="replaceAll", loop over attributes and replace $$value$$ in each.
-		      // sf-field-value="attrName", replace or set value of that attribute.
-		      var nodes = args.fieldFrag.querySelectorAll('[sf-field-model]');
-		      for (var i = 0; i < nodes.length; i++) {
-		        var n = nodes[i];
-		        var conf = n.getAttribute('sf-field-model');
-		        if (!conf || conf === '') {
-		          n.setAttribute('ng-model', modelValue);
-		        } else if (conf === 'replaceAll') {
-		          var attributes = n.attributes;
-		          for (var j = 0; j < attributes.length; j++) {
-		            if (attributes[j].value && attributes[j].value.indexOf('$$value') !== -1) {
-		              attributes[j].value = attributes[j].value.replace(/\$\$value\$\$/g, modelValue);
-		            }
-		          }
-		        } else {
-		          var val = n.getAttribute(conf);
-		          if (val && val.indexOf('$$value$$')) {
-		            n.setAttribute(conf, val.replace(/\$\$value\$\$/g, modelValue));
-		          } else {
-		            n.setAttribute(conf, modelValue);
-		          }
-		        }
-		      }
-		    },
-		    simpleTransclusion: function simpleTransclusion(args) {
-		      var children = args.build(args.form.items, args.path + '.items', args.state);
-		      args.fieldFrag.firstChild.appendChild(children);
-		    },
-
-		    // Patch on ngModelOptions, since it doesn't like waiting for its value.
-		    ngModelOptions: function ngModelOptions(args) {
-		      if (args.form.ngModelOptions && Object.keys(args.form.ngModelOptions).length > 0) {
-		        args.fieldFrag.firstChild.setAttribute('ng-model-options', JSON.stringify(args.form.ngModelOptions));
-		      }
-		    },
-		    transclusion: function transclusion(args) {
-		      var transclusions = args.fieldFrag.querySelectorAll('[sf-field-transclude]');
-
-		      if (transclusions.length) {
-		        for (var i = 0; i < transclusions.length; i++) {
-		          var n = transclusions[i];
-
-		          // The sf-transclude attribute is not a directive,
-		          // but has the name of what we're supposed to
-		          // traverse. Default to `items`
-		          var sub = n.getAttribute('sf-field-transclude') || 'items';
-		          var items = args.form[sub];
-
-		          if (items) {
-		            var childFrag = args.build(items, args.path + '.' + sub, args.state);
-		            n.appendChild(childFrag);
-		          }
-		        }
-		      }
-		    },
-		    condition: function condition(args) {
-		      // Do we have a condition? Then we slap on an ng-if on all children,
-		      // but be nice to existing ng-if.
-		      if (args.form.condition) {
-		        var evalExpr = 'evalExpr(' + args.path + '.condition, { model: model, "arrayIndex": $index})';
-		        if (args.form.key) {
-		          var strKey = sfPathProvider.stringify(args.form.key);
-		          var arrayDepth = args.form.key.filter(function (e) {
-		            return e === '';
-		          }).length;
-		          var arrayIndices = arrayDepth > 1 ? Array(arrayDepth - 1).join('$parent.$parent.$parent.') + '$parent.$parent.$index,' : '';
-		          for (var i = arrayDepth; i > 2; i--) {
-		            arrayIndices += Array(i - 1).join('$parent.$parent.$parent.') + '$index,';
-		          }
-		          arrayIndices += '$index';
-
-		          evalExpr = 'evalExpr(' + args.path + '.condition,{ model: model, "arrayIndex": $index, ' + '"arrayIndices": [' + arrayIndices + '],' + '"modelValue": model' + (strKey[0] === '[' ? '' : '.') + strKey + '})';
-		        }
-
-		        var children = args.fieldFrag.children || args.fieldFrag.childNodes;
-		        for (var i = 0; i < children.length; i++) {
-		          var child = children[i];
-		          var ngIf = child.getAttribute('ng-if');
-		          child.setAttribute('ng-if', ngIf ? '(' + ngIf + ') || (' + evalExpr + ')' : evalExpr);
-		        }
-		      }
-		    },
-		    array: function array(args) {
-		      var items = args.fieldFrag.querySelector('[schema-form-array-items]');
-
-		      if (args.form.key) {
-		        var arrayDepth = args.form.key.filter(function (e) {
-		          return e === '';
-		        }).length;
-		      }
-
-		      if (items) {
-		        var state = angular.copy(args.state);
-		        state.keyRedaction = 0;
-		        state.keyRedaction += args.form.key.length + 1;
-
-		        // Special case, an array with just one item in it that is not an object.
-		        // So then we just override the modelValue
-		        if (args.form.schema && args.form.schema.items && args.form.schema.items.type && args.form.schema.items.type.indexOf('object') === -1 && args.form.schema.items.type.indexOf('array') === -1) {
-		          var strKey = sfPathProvider.stringify(args.form.key).replace(/"/g, '&quot;') + '[$index]';
-		          state.modelValue = 'modelArray[$index]';
-		        } else {
-		          state.modelName = 'item';
-		        }
-
-		        // Flag to the builder that we're in an array.
-		        // This is needed for compatabiliy if a "old" add-on is used that
-		        // hasn't been transitioned to the new builder.
-		        state.arrayCompatFlag = true;
-
-		        var childFrag = args.build(args.form.items, args.path + '.items', state);
-		        items.appendChild(childFrag);
-		      }
-		    },
-		    numeric: function numeric(args) {
-		      var inputFrag = args.fieldFrag.querySelector('input');
-		      var maximum = args.form.maximum || false;
-		      var exclusiveMaximum = args.form.exclusiveMaximum || false;
-		      var minimum = args.form.minimum || false;
-		      var exclusiveMinimum = args.form.exclusiveMinimum || false;
-		      var multipleOf = args.form.multipleOf || false;
-		      if (inputFrag) {
-		        if (multipleOf !== false) {
-		          inputFrag.setAttribute('step', multipleOf);
-		        };
-
-		        if (maximum !== false) {
-		          if (exclusiveMaximum !== false && multipleOf !== false) {
-		            maximum = maximum - multipleOf;
-		          };
-		          inputFrag.setAttribute('max', maximum);
-		        };
-
-		        if (minimum !== false) {
-		          if (exclusiveMinimum !== false && multipleOf !== false) {
-		            minimum = minimum + multipleOf;
-		          };
-		          inputFrag.setAttribute('min', minimum);
-		        };
-		      };
-		    }
-		  };
-		  this.builders = builders;
-		  var stdBuilders = [builders.sfField, builders.ngModel, builders.ngModelOptions, builders.condition];
-		  this.stdBuilders = stdBuilders;
-
-		  this.$get = ['$templateCache', 'schemaFormDecorators', 'sfPath', function ($templateCache, schemaFormDecorators, sfPath) {
-		    var checkForSlot = function checkForSlot(form, slots) {
-		      // Finally append this field to the frag.
-		      // Check for slots
-		      if (form.key) {
-		        var slot = slots[sfPath.stringify(form.key)];
-		        if (slot) {
-		          while (slot.firstChild) {
-		            slot.removeChild(slot.firstChild);
-		          }
-		          return slot;
-		        }
-		      }
-		    };
-
-		    var _build = function _build(items, decorator, templateFn, slots, path, state, lookup) {
-		      state = state || {};
-		      state = state || {};
-		      lookup = lookup || Object.create(null);
-		      path = path || 'schemaForm.form';
-		      var container = document.createDocumentFragment();
-		      items.reduce(function (frag, f, index) {
-
-		        // Sanity check.
-		        if (!f.type) {
-		          return frag;
-		        }
-
-		        var field = decorator[f.type] || decorator['default'];
-		        if (!field.replace) {
-		          // Backwards compatability build
-		          var n = document.createElement(snakeCase(decorator.__name, '-'));
-		          if (state.arrayCompatFlag) {
-		            n.setAttribute('form', 'copyWithIndex($index)');
-		          } else {
-		            n.setAttribute('form', path + '[' + index + ']');
-		          }
-
-		          (checkForSlot(f, slots) || frag).appendChild(n);
-		        } else {
-		          var tmpl;
-
-		          // Reset arrayCompatFlag, it's only valid for direct children of the array.
-		          state.arrayCompatFlag = false;
-
-		          // TODO: Create a couple of testcases, small and large and
-		          //       measure optmization. A good start is probably a
-		          //       cache of DOM nodes for a particular template
-		          //       that can be cloned instead of using innerHTML
-		          var div = document.createElement('div');
-		          var template = templateFn(f, field) || templateFn(f, decorator['default']);
-		          div.innerHTML = template;
-
-		          // Move node to a document fragment, we don't want the div.
-		          tmpl = document.createDocumentFragment();
-		          while (div.childNodes.length > 0) {
-		            tmpl.appendChild(div.childNodes[0]);
-		          }
-
-		          // Possible builder, often a noop
-		          var args = {
-		            fieldFrag: tmpl,
-		            form: f,
-		            lookup: lookup,
-		            state: state,
-		            path: path + '[' + index + ']',
-
-		            // Recursive build fn
-		            build: function build(items, path, state) {
-		              return _build(items, decorator, templateFn, slots, path, state, lookup);
-		            }
-
-		          };
-
-		          // Let the form definiton override builders if it wants to.
-		          var builderFn = f.builder || field.builder;
-
-		          // Builders are either a function or a list of functions.
-		          if (typeof builderFn === 'function') {
-		            builderFn(args);
-		          } else {
-		            builderFn.forEach(function (fn) {
-		              fn(args);
-		            });
-		          }
-
-		          // Append
-		          (checkForSlot(f, slots) || frag).appendChild(tmpl);
-		        }
-		        return frag;
-		      }, container);
-
-		      return container;
-		    };
-
-		    return {
-		      /**
-		       * Builds a form from a canonical form definition
-		       */
-		      build: function build(form, decorator, slots, lookup) {
-		        return _build(form, decorator, function (form, field) {
-		          if (form.type === 'template') {
-		            return form.template;
-		          }
-		          return $templateCache.get(field.template);
-		        }, slots, undefined, undefined, lookup);
-		      },
-		      builder: builders,
-		      stdBuilders: stdBuilders,
-		      internalBuild: _build
-		    };
-		  }];
-		};
-
-	/***/ },
-	/* 4 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function ($compileProvider, sfPathProvider) {
-		  var defaultDecorator = '';
-		  var decorators = {};
-
-		  // Map template after decorator and type.
-		  var templateUrl = function templateUrl(name, form) {
-		    //schemaDecorator is alias for whatever is set as default
-		    if (name === 'sfDecorator') {
-		      name = defaultDecorator;
-		    }
-
-		    var decorator = decorators[name];
-		    if (decorator[form.type]) {
-		      return decorator[form.type].template;
-		    }
-
-		    //try default
-		    return decorator['default'].template;
-		  };
-
-		  /**************************************************
-		   * DEPRECATED                                     *
-		   * The new builder and sf-field is preferred, but *
-		   * we keep this in during a transitional period   *
-		   * so that add-ons that don't use the new builder *
-		   * works.                                         *
-		   **************************************************/
-		  //TODO: Move to a compatability extra script.
-		  var createDirective = function createDirective(name) {
-		    $compileProvider.directive(name, ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', function ($parse, $compile, $http, $templateCache, $interpolate, $q, sfErrorMessage, sfPath, sfSelect) {
-
-		      return {
-		        restrict: 'AE',
-		        replace: false,
-		        transclude: false,
-		        scope: true,
-		        require: ['^sfSchema', '?^form'],
-		        link: function link(scope, element, attrs, ctrl) {
-		          var sfSchema = ctrl[0];
-		          var formCtrl = ctrl[1];
-
-		          //The ngModelController is used in some templates and
-		          //is needed for error messages,
-		          scope.$on('schemaFormPropagateNgModelController', function (event, ngModel) {
-		            event.stopPropagation();
-		            event.preventDefault();
-		            scope.ngModel = ngModel;
-		          });
-
-		          //Keep error prone logic from the template
-		          scope.showTitle = function () {
-		            return scope.form && scope.form.notitle !== true && scope.form.title;
-		          };
-
-		          //Normalise names and ids
-		          scope.fieldId = function (prependFormName, omitArrayIndexes) {
-		            var key = scope.parentKey || [];
-		            if (scope.form.key) {
-		              if (typeof key[key.length - 1] === 'number') {
-		                var combinedKey = key.concat(scope.form.key.slice(-1));
-		                var formName = prependFormName && formCtrl && formCtrl.$name ? formCtrl.$name : undefined;
-		                return sfPath.name(combinedKey, '-', formName, omitArrayIndexes);
-		              } else {
-		                var formName = prependFormName && formCtrl && formCtrl.$name ? formCtrl.$name : undefined;
-		                return sfPath.name(scope.form.key, '-', formName, omitArrayIndexes);
-		              }
-		            } else {
-		              return '';
-		            }
-		          };
-
-		          scope.listToCheckboxValues = function (list) {
-		            var values = {};
-		            _angular2.default.forEach(list, function (v) {
-		              values[v] = true;
-		            });
-		            return values;
-		          };
-
-		          scope.checkboxValuesToList = function (values) {
-		            var lst = [];
-		            _angular2.default.forEach(values, function (v, k) {
-		              if (v) {
-		                lst.push(k);
-		              }
-		            });
-		            return lst;
-		          };
-
-		          scope.buttonClick = function ($event, form) {
-		            if (_angular2.default.isFunction(form.onClick)) {
-		              form.onClick($event, form);
-		            } else if (_angular2.default.isString(form.onClick)) {
-		              if (sfSchema) {
-		                //evaluating in scope outside of sfSchemas isolated scope
-		                sfSchema.evalInParentScope(form.onClick, { '$event': $event, form: form });
-		              } else {
-		                scope.$eval(form.onClick, { '$event': $event, form: form });
-		              };
-		            };
-		          };
-
-		          /**
-		           * Evaluate an expression, i.e. scope.$eval
-		           * but do it in sfSchemas parent scope sf-schema directive is used
-		           *
-		           * @param {string} expression
-		           * @param {Object} locals (optional)
-		           * @return {Any} the result of the expression
-		           */
-		          scope.evalExpr = function (expression, locals) {
-		            if (sfSchema) {
-		              //evaluating in scope outside of sfSchemas isolated scope
-		              return sfSchema.evalInParentScope(expression, locals);
-		            }
-
-		            return scope.$eval(expression, locals);
-		          };
-
-		          /**
-		           * Evaluate an expression, i.e. scope.$eval
-		           * in this decorators scope
-		           *
-		           * @param {string} expression
-		           * @param {Object} locals (optional)
-		           * @return {Any} the result of the expression
-		           */
-		          scope.evalInScope = function (expression, locals) {
-		            if (expression) {
-		              return scope.$eval(expression, locals);
-		            }
-		          };
-
-		          /**
-		           * Interpolate the expression.
-		           * Similar to `evalExpr()` and `evalInScope()`
-		           * but will not fail if the expression is
-		           * text that contains spaces.
-		           *
-		           * Use the Angular `{{ interpolation }}`
-		           * braces to access properties on `locals`.
-		           *
-		           * @param  {string} expression The string to interpolate.
-		           * @param  {Object} locals (optional) Properties that may be accessed in the
-		           *                         `expression` string.
-		           * @return {Any} The result of the expression or `undefined`.
-		           */
-		          scope.interp = function (expression, locals) {
-		            return expression && $interpolate(expression)(locals);
-		          };
-
-		          //This works since we ot the ngModel from the array or the schema-validate directive.
-		          scope.hasSuccess = function () {
-		            if (!scope.ngModel) {
-		              return false;
-		            }
-		            if (scope.options && scope.options.pristine && scope.options.pristine.success === false) {
-		              return scope.ngModel.$valid && !scope.ngModel.$pristine && !scope.ngModel.$isEmpty(scope.ngModel.$modelValue);
-		            } else {
-		              return scope.ngModel.$valid && (!scope.ngModel.$pristine || !scope.ngModel.$isEmpty(scope.ngModel.$modelValue));
-		            }
-		          };
-
-		          scope.hasError = function () {
-		            if (!scope.ngModel) {
-		              return false;
-		            }
-		            return scope.ngModel.$invalid && !scope.ngModel.$pristine;
-		          };
-
-		          /**
-		           * DEPRECATED: use sf-messages instead.
-		           * Error message handler
-		           * An error can either be a schema validation message or a angular js validtion
-		           * error (i.e. required)
-		           */
-		          scope.errorMessage = function (schemaError) {
-		            return sfErrorMessage.interpolate(schemaError && schemaError.code + '' || 'default', scope.ngModel && scope.ngModel.$modelValue || '', scope.ngModel && scope.ngModel.$viewValue || '', scope.form, scope.options && scope.options.validationMessage);
-		          };
-
-		          // Rebind our part of the form to the scope.
-		          var once = scope.$watch(attrs.form, function (form) {
-		            if (form) {
-		              // Workaround for 'updateOn' error from ngModelOptions
-		              // see https://github.com/Textalk/angular-schema-form/issues/255
-		              // and https://github.com/Textalk/angular-schema-form/issues/206
-		              form.ngModelOptions = form.ngModelOptions || {};
-		              scope.form = form;
-
-		              //ok let's replace that template!
-		              //We do this manually since we need to bind ng-model properly and also
-		              //for fieldsets to recurse properly.
-		              var templatePromise;
-
-		              // type: "template" is a special case. It can contain a template inline or an url.
-		              // otherwise we find out the url to the template and load them.
-		              if (form.type === 'template' && form.template) {
-		                templatePromise = $q.when(form.template);
-		              } else {
-		                var url = form.type === 'template' ? form.templateUrl : templateUrl(name, form);
-		                templatePromise = $http.get(url, { cache: $templateCache }).then(function (res) {
-		                  return res.data;
-		                });
-		              }
-
-		              templatePromise.then(function (template) {
-		                if (form.key) {
-		                  var key = form.key ? sfPathProvider.stringify(form.key).replace(/"/g, '&quot;') : '';
-		                  template = template.replace(/\$\$value\$\$/g, 'model' + (key[0] !== '[' ? '.' : '') + key);
-		                }
-		                element.html(template);
-
-		                // Do we have a condition? Then we slap on an ng-if on all children,
-		                // but be nice to existing ng-if.
-		                if (form.condition) {
-
-		                  var evalExpr = 'evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';
-		                  if (form.key) {
-		                    evalExpr = 'evalExpr(form.condition, {' + 'model: model, "arrayIndex": arrayIndex, "modelValue": model' + sfPath.stringify(form.key) + '})';
-		                  }
-
-		                  _angular2.default.forEach(element.children(), function (child) {
-		                    var ngIf = child.getAttribute('ng-if');
-		                    child.setAttribute('ng-if', ngIf ? '(' + ngIf + ') || (' + evalExpr + ')' : evalExpr);
-		                  });
-		                }
-		                $compile(element.contents())(scope);
-		              });
-
-		              // Where there is a key there is probably a ngModel
-		              if (form.key) {
-		                // It looks better with dot notation.
-		                scope.$on('schemaForm.error.' + form.key.join('.'), function (event, error, validationMessage, validity, formName) {
-		                  // validationMessage and validity are mutually exclusive
-		                  formName = validity;
-		                  if (validationMessage === true || validationMessage === false) {
-		                    validity = validationMessage;
-		                    validationMessage = undefined;
-		                  };
-
-		                  // If we have specified a form name, and this model is not within
-		                  // that form, then leave things be.
-		                  if (formName != undefined && scope.ngModel.$$parentForm.$name !== formName) {
-		                    return;
-		                  };
-
-		                  if (scope.ngModel && error) {
-		                    if (scope.ngModel.$setDirty) {
-		                      scope.ngModel.$setDirty();
-		                    } else {
-		                      // FIXME: Check that this actually works on 1.2
-		                      scope.ngModel.$dirty = true;
-		                      scope.ngModel.$pristine = false;
-		                    };
-
-		                    // Set the new validation message if one is supplied
-		                    // Does not work when validationMessage is just a string.
-		                    if (validationMessage) {
-		                      if (!form.validationMessage) {
-		                        form.validationMessage = {};
-		                      }
-		                      form.validationMessage[error] = validationMessage;
-		                    }
-
-		                    scope.ngModel.$setValidity(error, validity === true);
-
-		                    if (validity === true) {
-		                      // Re-trigger model validator, that model itself would be re-validated
-		                      scope.ngModel.$validate();
-
-		                      // Setting or removing a validity can change the field to believe its valid
-		                      // but its not. So lets trigger its validation as well.
-		                      scope.$broadcast('schemaFormValidate');
-		                    }
-		                  }
-		                });
-
-		                // Clean up the model when the corresponding form field is $destroy-ed.
-		                // Default behavior can be supplied as a globalOption, and behavior can be overridden
-		                // in the form definition.
-		                scope.$on('$destroy', function () {
-		                  // If the entire schema form is destroyed we don't touch the model
-		                  if (!scope.externalDestructionInProgress) {
-		                    var destroyStrategy = form.destroyStrategy || scope.options && scope.options.destroyStrategy || 'remove';
-		                    // No key no model, and we might have strategy 'retain'
-		                    if (form.key && destroyStrategy !== 'retain') {
-
-		                      // Get the object that has the property we wan't to clear.
-		                      var obj = scope.model;
-		                      if (form.key.length > 1) {
-		                        obj = sfSelect(form.key.slice(0, form.key.length - 1), obj);
-		                      }
-
-		                      // We can get undefined here if the form hasn't been filled out entirely
-		                      if (obj === undefined) {
-		                        return;
-		                      }
-
-		                      // Type can also be a list in JSON Schema
-		                      var type = form.schema && form.schema.type || '';
-
-		                      // Empty means '',{} and [] for appropriate types and undefined for the rest
-		                      if (destroyStrategy === 'empty' && type.indexOf('string') !== -1) {
-		                        obj[form.key.slice(-1)] = '';
-		                      } else if (destroyStrategy === 'empty' && type.indexOf('object') !== -1) {
-		                        obj[form.key.slice(-1)] = {};
-		                      } else if (destroyStrategy === 'empty' && type.indexOf('array') !== -1) {
-		                        obj[form.key.slice(-1)] = [];
-		                      } else if (destroyStrategy === 'null') {
-		                        obj[form.key.slice(-1)] = null;
-		                      } else {
-		                        delete obj[form.key.slice(-1)];
-		                      }
-		                    }
-		                  }
-		                });
-		              }
-
-		              once();
-		            }
-		          });
-		        }
-		      };
-		    }]);
-		  };
-
-		  var createManualDirective = function createManualDirective(type, templateUrl, transclude) {
-		    transclude = _angular2.default.isDefined(transclude) ? transclude : false;
-		    $compileProvider.directive('sf' + _angular2.default.uppercase(type[0]) + type.substr(1), function () {
-		      return {
-		        restrict: 'EAC',
-		        scope: true,
-		        replace: true,
-		        transclude: transclude,
-		        template: '<sf-decorator form="form"></sf-decorator>',
-		        link: function link(scope, element, attrs) {
-		          var watchThis = {
-		            'items': 'c',
-		            'titleMap': 'c',
-		            'schema': 'c'
-		          };
-		          var form = { type: type };
-		          var once = true;
-		          _angular2.default.forEach(attrs, function (value, name) {
-		            if (name[0] !== '$' && name.indexOf('ng') !== 0 && name !== 'sfField') {
-
-		              var updateForm = function updateForm(val) {
-		                if (_angular2.default.isDefined(val) && val !== form[name]) {
-		                  form[name] = val;
-
-		                  //when we have type, and if specified key we apply it on scope.
-		                  if (once && form.type && (form.key || _angular2.default.isUndefined(attrs.key))) {
-		                    scope.form = form;
-		                    once = false;
-		                  }
-		                }
-		              };
-
-		              if (name === 'model') {
-		                //"model" is bound to scope under the name "model" since this is what the decorators
-		                //know and love.
-		                scope.$watch(value, function (val) {
-		                  if (val && scope.model !== val) {
-		                    scope.model = val;
-		                  }
-		                });
-		              } else if (watchThis[name] === 'c') {
-		                //watch collection
-		                scope.$watchCollection(value, updateForm);
-		              } else {
-		                //$observe
-		                attrs.$observe(name, updateForm);
-		              }
-		            }
-		          });
-		        }
-		      };
-		    });
-		  };
-
-		  /**
-		   * DEPRECATED: use defineDecorator instead.
-		   * Create a decorator directive and its sibling "manual" use decorators.
-		   * The directive can be used to create form fields or other form entities.
-		   * It can be used in conjunction with <schema-form> directive in which case the decorator is
-		   * given it's configuration via a the "form" attribute.
-		   *
-		   * ex. Basic usage
-		   *   <sf-decorator form="myform"></sf-decorator>
-		   **
-		   * @param {string} name directive name (CamelCased)
-		   * @param {Object} templates, an object that maps "type" => "templateUrl"
-		   */
-		  this.createDecorator = function (name, templates) {
-		    //console.warn('schemaFormDecorators.createDecorator is DEPRECATED, use defineDecorator instead.');
-		    decorators[name] = { '__name': name };
-
-		    _angular2.default.forEach(templates, function (url, type) {
-		      decorators[name][type] = { template: url, replace: false, builder: [] };
-		    });
-
-		    if (!decorators[defaultDecorator]) {
-		      defaultDecorator = name;
-		    }
-		    createDirective(name);
-		  };
-
-		  /**
-		   * Define a decorator. A decorator is a set of form types with templates and builder functions
-		   * that help set up the form.
-		   *
-		   * @param {string} name directive name (CamelCased)
-		   * @param {Object} fields, an object that maps "type" => `{ template, builder, replace}`.
-		                     attributes `builder` and `replace` are optional, and replace defaults to true.
-		                       `template` should be the key of the template to load and it should be pre-loaded
-		                     in `$templateCache`.
-		                       `builder` can be a function or an array of functions. They will be called in
-		                     the order they are supplied.
-		                       `replace` (DEPRECATED) is for backwards compatability. If false the builder
-		                     will use the "old" way of building that form field using a <sf-decorator>
-		                     directive.
-		   */
-		  this.defineDecorator = function (name, fields) {
-		    decorators[name] = { '__name': name }; // TODO: this feels like a hack, come up with a better way.
-
-		    _angular2.default.forEach(fields, function (field, type) {
-		      field.builder = field.builder || [];
-		      field.replace = _angular2.default.isDefined(field.replace) ? field.replace : true;
-		      decorators[name][type] = field;
-		    });
-
-		    if (!decorators[defaultDecorator]) {
-		      defaultDecorator = name;
-		    }
-		    createDirective(name);
-		  };
-
-		  /**
-		   * DEPRECATED
-		   * Creates a directive of a decorator
-		   * Usable when you want to use the decorators without using <schema-form> directive.
-		   * Specifically when you need to reuse styling.
-		   *
-		   * ex. createDirective('text','...')
-		   *  <sf-text title="foobar" model="person" key="name" schema="schema"></sf-text>
-		   *
-		   * @param {string}  type The type of the directive, resulting directive will have sf- prefixed
-		   * @param {string}  templateUrl
-		   * @param {boolean} transclude (optional) sets transclude option of directive, defaults to false.
-		   */
-		  this.createDirective = createManualDirective;
-
-		  /**
-		   * DEPRECATED
-		   * Same as createDirective, but takes an object where key is 'type' and value is 'templateUrl'
-		   * Useful for batching.
-		   *
-		   * @param {Object} templates
-		   */
-		  this.createDirectives = function (templates) {
-		    _angular2.default.forEach(templates, function (url, type) {
-		      createManualDirective(type, url);
-		    });
-		  };
-
-		  /**
-		   * Getter for decorator settings
-		   *
-		   * @param {string} name (optional) defaults to defaultDecorator
-		   * @return {Object} rules and templates { rules: [],templates: {}}
-		   */
-		  this.decorator = function (name) {
-		    name = name || defaultDecorator;
-		    return decorators[name];
-		  };
-
-		  /**
-		   * DEPRECATED use defineAddOn() instead.
-		   * Adds a mapping to an existing decorator.
-		   *
-		   * @param {String} name Decorator name
-		   * @param {String} type Form type for the mapping
-		   * @param {String} url  The template url
-		   * @param {Function} builder (optional) builder function
-		   * @param {boolean} replace (optional) defaults to false. Replace decorator directive with template.
-		   */
-		  this.addMapping = function (name, type, url, builder, replace) {
-		    if (decorators[name]) {
-		      decorators[name][type] = {
-		        template: url,
-		        builder: builder,
-		        replace: !!replace
-		      };
-		    }
-		  };
-
-		  /**
-		   * Adds an add-on to an existing decorator.
-		   *
-		   * @param {String} name Decorator name
-		   * @param {String} type Form type for the mapping
-		   * @param {String} url  The template url
-		   * @param {Function|Array} builder (optional) builder function(s),
-		   */
-		  this.defineAddOn = function (name, type, url, builder) {
-		    if (decorators[name]) {
-		      decorators[name][type] = {
-		        template: url,
-		        builder: builder,
-		        replace: true
-		      };
-		    }
-		  };
-
-		  //Service is just a getter for directive templates and rules
-		  this.$get = function () {
-		    return {
-		      decorator: function decorator(name) {
-		        return decorators[name] || decorators[defaultDecorator];
-		      },
-		      defaultDecorator: defaultDecorator
-		    };
-		  };
-
-		  //Create a default directive
-		  createDirective('sfDecorator');
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-		;
-
-	/***/ },
-	/* 5 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function () {
-		  var postProcessFn = function postProcessFn(form) {
-		    return form;
-		  };
-		  var defaults = _jsonSchemaFormCore.schemaDefaults.createDefaults();
-
-		  /**
-		   * Provider API
-		   */
-		  this.defaults = defaults;
-		  this.stdFormObj = _jsonSchemaFormCore.schemaDefaults.stdFormObj;
-		  this.defaultFormDefinition = _jsonSchemaFormCore.schemaDefaults.defaultFormDefinition;
-
-		  /**
-		   * Register a post process function.
-		   * This function is called with the fully merged
-		   * form definition (i.e. after merging with schema)
-		   * and whatever it returns is used as form.
-		   */
-		  this.postProcess = function (fn) {
-		    postProcessFn = fn;
-		  };
-
-		  /**
-		   * Append default form rule
-		   *
-		   * @param {string}   type json schema type
-		   * @param {Function} rule a function(propertyName,propertySchema,options) that returns a form
-		   *                        definition or undefined
-		   */
-		  this.appendRule = function (type, rule) {
-		    if (!defaults[type]) {
-		      defaults[type] = [];
-		    }
-		    defaults[type].push(rule);
-		  };
-
-		  /**
-		   * Prepend default form rule
-		   *
-		   * @param {string}   type json schema type
-		   * @param {Function} rule a function(propertyName,propertySchema,options) that returns a form
-		   *                        definition or undefined
-		   */
-		  this.prependRule = function (type, rule) {
-		    if (!defaults[type]) {
-		      defaults[type] = [];
-		    }
-		    defaults[type].unshift(rule);
-		  };
-
-		  /**
-		   * Utility function to create a standard form object.
-		   * This does *not* set the type of the form but rather all shared attributes.
-		   * You probably want to start your rule with creating the form with this method
-		   * then setting type and any other values you need.
-		   * @param {Object} schema
-		   * @param {Object} options
-		   * @return {Object} a form field defintion
-		   */
-		  this.createStandardForm = _jsonSchemaFormCore.schemaDefaults.stdFormObj;
-		  /* End Provider API */
-
-		  this.$get = function () {
-
-		    var service = {};
-		    var typeDefault = this.defaults;
-
-		    service.merge = function (schema, form, ignore, options, readonly, asyncTemplates) {
-		      form = form || ['*'];
-		      options = options || {};
-
-		      // Get readonly from root object
-		      readonly = readonly || schema.readonly || schema.readOnly;
-
-		      var stdForm = _jsonSchemaFormCore.schemaDefaults.defaultForm(schema, typeDefault, ignore, options);
-
-		      //simple case, we have a "*", just put the stdForm there
-		      var idx = form.indexOf('*');
-		      if (idx !== -1) {
-		        form = form.slice(0, idx).concat(stdForm.form).concat(form.slice(idx + 1));
-		      }
-
-		      //ok let's merge!
-		      //We look at the supplied form and extend it with schema standards
-		      var canonical = (0, _jsonSchemaFormCore.merge)(stdForm.lookup, form, options, readonly, asyncTemplates);
-		      return postProcessFn(canonical);
-		    };
-
-		    /**
-		     * Create form defaults from schema
-		     */
-		    service.defaults = _jsonSchemaFormCore.schemaDefaults.defaultForm;
-
-		    //Utility functions
-		    /**
-		     * Form defaults for schema by type
-		     * As a form is generated from a schema these are the definitions of each json-schema type
-		     */
-		    service.typeDefault = typeDefault;
-
-		    /**
-		     * Traverse a schema, applying a function(schema,path) on every sub schema
-		     * i.e. every property of an object.
-		     */
-		    service.traverseSchema = _jsonSchemaFormCore.traverseSchema;
-
-		    service.traverseForm = _jsonSchemaFormCore.traverseForm;
-
-		    return service;
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		var _jsonSchemaFormCore = __webpack_require__(6);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 6 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		/*!
-		 * json-schema-form
-		 * @version 1.0.0-alpha.2
-		 * @link https://github.com/json-schema-form/json-schema-form-core
-		 * @license MIT
-		 * Copyright (c) 2016 JSON Schema Form
-		 */
-		(function webpackUniversalModuleDefinition(root, factory) {
-			if(true)
-				module.exports = factory(__webpack_require__(7));
-			else if(typeof define === 'function' && define.amd)
-				define(["tv4"], factory);
-			else {
-				var a = typeof exports === 'object' ? factory(require("tv4")) : factory(root["tv4"]);
-				for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
-			}
-		})(this, function(__WEBPACK_EXTERNAL_MODULE_10__) {
-		return /******/ (function(modules) { // webpackBootstrap
-		/******/ 	// The module cache
-		/******/ 	var installedModules = {};
-
-		/******/ 	// The require function
-		/******/ 	function __webpack_require__(moduleId) {
-
-		/******/ 		// Check if module is in cache
-		/******/ 		if(installedModules[moduleId])
-		/******/ 			return installedModules[moduleId].exports;
-
-		/******/ 		// Create a new module (and put it into the cache)
-		/******/ 		var module = installedModules[moduleId] = {
-		/******/ 			exports: {},
-		/******/ 			id: moduleId,
-		/******/ 			loaded: false
-		/******/ 		};
-
-		/******/ 		// Execute the module function
-		/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
-
-		/******/ 		// Flag the module as loaded
-		/******/ 		module.loaded = true;
-
-		/******/ 		// Return the exports of the module
-		/******/ 		return module.exports;
-		/******/ 	}
-
-
-		/******/ 	// expose the modules object (__webpack_modules__)
-		/******/ 	__webpack_require__.m = modules;
-
-		/******/ 	// expose the module cache
-		/******/ 	__webpack_require__.c = installedModules;
-
-		/******/ 	// __webpack_public_path__
-		/******/ 	__webpack_require__.p = "";
-
-		/******/ 	// Load entry module and return exports
-		/******/ 	return __webpack_require__(0);
-		/******/ })
-		/************************************************************************/
-		/******/ ([
-		/* 0 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			module.exports = __webpack_require__(1);
-
-
-		/***/ },
-		/* 1 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-			exports.canonicalTitleMap = exports.schemaDefaults = exports.sfPath = undefined;
-
-			var _merge = __webpack_require__(2);
-
-			Object.keys(_merge).forEach(function (key) {
-			  if (key === "default") return;
-			  Object.defineProperty(exports, key, {
-			    enumerable: true,
-			    get: function get() {
-			      return _merge[key];
-			    }
-			  });
-			});
-
-			var _select = __webpack_require__(7);
-
-			Object.keys(_select).forEach(function (key) {
-			  if (key === "default") return;
-			  Object.defineProperty(exports, key, {
-			    enumerable: true,
-			    get: function get() {
-			      return _select[key];
-			    }
-			  });
-			});
-
-			var _traverse = __webpack_require__(8);
-
-			Object.keys(_traverse).forEach(function (key) {
-			  if (key === "default") return;
-			  Object.defineProperty(exports, key, {
-			    enumerable: true,
-			    get: function get() {
-			      return _traverse[key];
-			    }
-			  });
-			});
-
-			var _validate = __webpack_require__(9);
-
-			Object.keys(_validate).forEach(function (key) {
-			  if (key === "default") return;
-			  Object.defineProperty(exports, key, {
-			    enumerable: true,
-			    get: function get() {
-			      return _validate[key];
-			    }
-			  });
-			});
-
-			var _schemaDefaults = __webpack_require__(11);
-
-			var schemaDefaultsImp = _interopRequireWildcard(_schemaDefaults);
-
-			var _sfPath = __webpack_require__(3);
-
-			var sfPathImp = _interopRequireWildcard(_sfPath);
-
-			var _canonicalTitleMap = __webpack_require__(6);
-
-			var _canonicalTitleMap2 = _interopRequireDefault(_canonicalTitleMap);
-
-			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-			function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) newObj[key] = obj[key]; } } newObj.default = obj; return newObj; } }
-
-			var sfPath = exports.sfPath = sfPathImp;
-			var schemaDefaults = exports.schemaDefaults = schemaDefaultsImp;
-			var canonicalTitleMap = exports.canonicalTitleMap = _canonicalTitleMap2.default;
-
-		/***/ },
-		/* 2 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-			exports.merge = merge;
-
-			var _sfPath = __webpack_require__(3);
-
-			var _canonicalTitleMap = __webpack_require__(6);
-
-			var _canonicalTitleMap2 = _interopRequireDefault(_canonicalTitleMap);
-
-			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-			//export function merge(schema, form, schemaDefaultTypes, ignore, options, readonly, asyncTemplates) {
-			function merge(lookup, form, options, readonly, asyncTemplates) {
-			  form = form || [];
-			  options = options || {};
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html__ = __webpack_require__(16);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html__ = __webpack_require__(6);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html__ = __webpack_require__(2);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html__ = __webpack_require__(14);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html__ = __webpack_require__(15);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html__ = __webpack_require__(11);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html__ = __webpack_require__(1);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html__ = __webpack_require__(12);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html__ = __webpack_require__(3);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html__ = __webpack_require__(4);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html__ = __webpack_require__(13);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html__ = __webpack_require__(10);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html__ = __webpack_require__(9);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html__ = __webpack_require__(8);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html__ = __webpack_require__(7);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html__ = __webpack_require__(5);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html__);
+// angular-templatecache-loader
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+angular
+  .module('schemaForm')
+  .config(bootstrapDecoratorConfig)
+  .filter('sfCamelKey', sfCamelKeyFilter);
+
+bootstrapDecoratorConfig.$inject = [
+  'schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'
+];
+
+function bootstrapDecoratorConfig(
+    schemaFormProvider, decoratorsProvider, sfBuilderProvider, sfPathProvider, $injector) {
+  var base = 'decorators/bootstrap/';
+
+  var simpleTransclusion  = sfBuilderProvider.builders.simpleTransclusion;
+  var ngModelOptions      = sfBuilderProvider.builders.ngModelOptions;
+  var ngModel             = sfBuilderProvider.builders.ngModel;
+  var sfField             = sfBuilderProvider.builders.sfField;
+  var condition           = sfBuilderProvider.builders.condition;
+  var array               = sfBuilderProvider.builders.array;
+  var numeric             = sfBuilderProvider.builders.numeric;
+
+  // Tabs is so bootstrap specific that it stays here.
+  var tabs = function(args) {
+    if (args.form.tabs && args.form.tabs.length > 0) {
+      var tabContent = args.fieldFrag.querySelector('.tab-content');
+
+      args.form.tabs.forEach(function(tab, index) {
+        var evalExpr = '(evalExpr(' + args.path + '.tabs[' + index + ']' +
+                       '.condition, { model: model, "arrayIndex": $index}))';
+        var div = document.createElement('div');
+        div.className = 'tab-pane';
+        div.setAttribute('ng-disabled', 'form.readonly');
+        div.setAttribute('ng-show', 'selected.tab === ' + index);
+        div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
+        if(!!tab.condition) {
+          div.setAttribute('ng-if', evalExpr);
+        };
+
+        var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
+        div.appendChild(childFrag);
+        tabContent.appendChild(div);
+      });
+    }
+  };
+
+  var selectPlaceholder = function(args) {
+    if (args.form.placeholder) {
+      var selectBox = args.fieldFrag.querySelector('select');
+      var option = document.createElement('option');
+      option.setAttribute('value', '');
+
+      /* We only want the placeholder to show when we do not have a value on the model.
+       * We make ngModel builder replace all so we can use $$value$$.
+       */
+      option.setAttribute('sf-field-model', 'replaceAll');
+
+      /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
+       * angular > 1.4 does a emptyOption.attr('selected', true)
+       * which does not like the ng-if comment.
+       */
+      if (angular.version.major === 1 && angular.version.minor < 4) {
+        option.setAttribute('ng-if', '$$value$$ === undefined');
+      } else {
+        option.setAttribute('ng-show', '$$value$$ === undefined');
+      }
+
+      option.textContent = args.form.placeholder;
+
+      selectBox.appendChild(option);
+    }
+  };
+
+  var defaults = [sfField, ngModel, ngModelOptions, condition];
+  decoratorsProvider.defineDecorator('bootstrapDecorator', {
+    actions: {template: __WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html___default.a, builder: defaults},
+    array: {template: __WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    button: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html___default.a, builder: defaults},
+    checkbox: {template: __WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html___default.a, builder: defaults},
+    checkboxes: {template: __WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    conditional: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    'default': {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default.a, builder: defaults},
+    fieldset: {template: __WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    help: {template: __WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html___default.a, builder: defaults},
+    number: {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default.a, builder: defaults.concat(numeric)},
+    password: {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default.a, builder: defaults},
+    radios: {template: __WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html___default.a, builder: defaults},
+    'radios-inline': {template: __WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html___default.a, builder: defaults},
+    radiobuttons: {template: __WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html___default.a, builder: defaults},
+    section: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    select: {template: __WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html___default.a, builder: defaults.concat(selectPlaceholder)},
+    submit: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html___default.a, builder: defaults},
+    tabarray: {template: __WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    tabs: {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html___default.a, builder: [sfField, ngModelOptions, tabs, condition]},
+    textarea: {template: __WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html___default.a, builder: defaults},
+  }, []);
+};
+
+/**
+ * sfCamelKey Filter
+ */
+function sfCamelKeyFilter() {
+  return function(formKey) {
+    if (!formKey) { return ''; };
+    var part, i, key;
+    key = formKey.slice();
+    for (i = 0; i < key.length; i++) {
+      part = key[i].toLowerCase().split('');
+      if (i && part.length) { part[0] = part[0].toUpperCase(); };
+      key[i] = part.join('');
+    };
+    return key.join('');
+  };
+};
 
-			  //ok let's merge!
-			  //We look at the supplied form and extend it with schema standards
-			  return form.map(function (obj) {
 
-			    //handle the shortcut with just a name
-			    if (typeof obj === 'string') {
-			      obj = { key: obj };
-			    }
+/***/ },
+/* 18 */
+/***/ function(module, exports) {
 
-			    if (obj.key) {
-			      if (typeof obj.key === 'string') {
-			        obj.key = (0, _sfPath.parse)(obj.key);
-			      }
-			    }
+throw new Error("Module build failed: Error: ENOENT: no such file or directory, open 'C:\\Users\\Marcel\\Documents\\SERIOUS\\git\\angular-schema-form\\dist\\angular-schema-form.js'\n    at Error (native)");
 
-			    //If it has a titleMap make sure it's a list
-			    if (obj.titleMap) {
-			      obj.titleMap = (0, _canonicalTitleMap2.default)(obj.titleMap);
-			    }
+/***/ },
+/* 19 */,
+/* 20 */
+/***/ function(module, exports, __webpack_require__) {
 
-			    //extend with std form from schema.
-			    if (obj.key) {
-			      var strid = (0, _sfPath.stringify)(obj.key);
-			      if (lookup[strid]) {
-			        (function () {
-			          var schemaDefaults = lookup[strid];
-			          if (schemaDefaults) {
-			            Object.keys(schemaDefaults).forEach(function (attr) {
-			              if (obj[attr] === undefined) {
-			                obj[attr] = schemaDefaults[attr];
-			              }
-			            });
-			          }
-			        })();
-			      }
-			    }
-
-			    // Are we inheriting readonly?
-			    if (readonly === true) {
-			      // Inheriting false is not cool.
-			      obj.readonly = true;
-			    }
-
-			    //if it's a type with items, merge 'em!
-			    if (obj.items) {
-			      obj.items = merge(lookup, obj.items, options, obj.readonly, asyncTemplates);
-			    }
-
-			    //if its has tabs, merge them also!
-			    if (obj.tabs) {
-			      obj.tabs.forEach(function (tab) {
-			        if (tab.items) {
-			          tab.items = merge(lookup, tab.items, options, obj.readonly, asyncTemplates);
-			        }
-			      });
-			    }
-
-			    // Special case: checkbox
-			    // Since have to ternary state we need a default
-			    if (obj.type === 'checkbox' && obj.schema['default'] === undefined) {
-			      obj.schema['default'] = false;
-			    };
-
-			    // Special case: template type with tempplateUrl that's needs to be loaded before rendering
-			    // TODO: this is not a clean solution. Maybe something cleaner can be made when $ref support
-			    // is introduced since we need to go async then anyway
-			    if (asyncTemplates && obj.type === 'template' && !obj.template && obj.templateUrl) {
-			      asyncTemplates.push(obj);
-			    }
-
-			    return obj;
-			  });
-			}
-
-		/***/ },
-		/* 3 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-			exports.name = exports.normalize = exports.stringify = exports.parse = undefined;
-
-			var _objectpath = __webpack_require__(4);
-
-			var name = function name(key, separator, formName, omitNumbers) {
-			  if (key) {
-			    var fieldKey = key;
-			    var fieldSeparator = separator || '-';
-
-			    if (omitNumbers) {
-			      fieldKey = fieldKey.filter(function (key) {
-			        return typeof key !== 'number';
-			      });
-			    };
-
-			    return (formName ? formName + fieldSeparator : '') + fieldKey.join(fieldSeparator);
-			  };
-
-			  return '';
-			}; // This is of course a bit silly. And should be refactored.
-
-
-			exports.parse = _objectpath.parse;
-			exports.stringify = _objectpath.stringify;
-			exports.normalize = _objectpath.normalize;
-			exports.name = name;
-
-		/***/ },
-		/* 4 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			module.exports = __webpack_require__(5).ObjectPath;
-
-		/***/ },
-		/* 5 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			var __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
-
-			var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; };
-
-			;!function (undefined) {
-
-				var ObjectPath = {
-					parse: function parse(str) {
-						if (typeof str !== 'string') {
-							throw new TypeError('ObjectPath.parse must be passed a string');
-						}
-
-						var i = 0;
-						var parts = [];
-						var d, b, q, c;
-						while (i < str.length) {
-							d = str.indexOf('.', i);
-							b = str.indexOf('[', i);
-
-							// we've reached the end
-							if (d === -1 && b === -1) {
-								parts.push(str.slice(i, str.length));
-								i = str.length;
-							}
-
-							// dots
-							else if (b === -1 || d !== -1 && d < b) {
-									parts.push(str.slice(i, d));
-									i = d + 1;
-								}
-
-								// brackets
-								else {
-										if (b > i) {
-											parts.push(str.slice(i, b));
-											i = b;
-										}
-										q = str.slice(b + 1, b + 2);
-										if (q !== '"' && q !== '\'') {
-											c = str.indexOf(']', b);
-											if (c === -1) c = str.length;
-											parts.push(str.slice(i + 1, c));
-											i = str.slice(c + 1, c + 2) === '.' ? c + 2 : c + 1;
-										} else {
-											c = str.indexOf(q + ']', b);
-											if (c === -1) c = str.length;
-											while (str.slice(c - 1, c) === '\\' && b < str.length) {
-												b++;
-												c = str.indexOf(q + ']', b);
-											}
-											parts.push(str.slice(i + 2, c).replace(new RegExp('\\' + q, 'g'), q));
-											i = str.slice(c + 2, c + 3) === '.' ? c + 3 : c + 2;
-										}
-									}
-						}
-						return parts;
-					},
-
-					// root === true : auto calculate root; must be dot-notation friendly
-					// root String : the string to use as root
-					stringify: function stringify(arr, quote) {
-
-						if (!Array.isArray(arr)) arr = [arr.toString()];
-
-						quote = quote === '"' ? '"' : '\'';
-
-						return arr.map(function (n) {
-							return '[' + quote + n.toString().replace(new RegExp(quote, 'g'), '\\' + quote) + quote + ']';
-						}).join('');
-					},
-
-					normalize: function normalize(data, quote) {
-						return ObjectPath.stringify(Array.isArray(data) ? data : ObjectPath.parse(data), quote);
-					},
-
-					// Angular
-					registerModule: function registerModule(angular) {
-						angular.module('ObjectPath', []).provider('ObjectPath', function () {
-							this.parse = ObjectPath.parse;
-							this.stringify = ObjectPath.stringify;
-							this.normalize = ObjectPath.normalize;
-							this.$get = function () {
-								return ObjectPath;
-							};
-						});
-					}
-				};
-
-				// AMD
-				if (true) {
-					!(__WEBPACK_AMD_DEFINE_RESULT__ = function () {
-						return { ObjectPath: ObjectPath };
-					}.call(exports, __webpack_require__, exports, module), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
-				}
-
-				// CommonJS
-				else if ((typeof exports === 'undefined' ? 'undefined' : _typeof(exports)) === 'object') {
-						exports.ObjectPath = ObjectPath;
-					}
-
-					// Browser global
-					else {
-							window.ObjectPath = ObjectPath;
-						}
-			}();
-
-		/***/ },
-		/* 6 */
-		/***/ function(module, exports) {
-
-			"use strict";
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-
-			var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; }; // Takes a titleMap in either object or list format and returns one in
-			// in the list format.
-
-
-			exports.default = function (titleMap, originalEnum) {
-			  if (!Array.isArray(titleMap)) {
-			    var _ret = function () {
-			      var canonical = [];
-			      if (originalEnum) {
-			        originalEnum.forEach(function (value) {
-			          canonical.push({ name: titleMap[value], value: value });
-			        });
-			      } else {
-			        Object.keys(titleMap).forEach(function (value) {
-			          canonical.push({ name: titleMap[value], value: value });
-			        });
-			      }
-			      return {
-			        v: canonical
-			      };
-			    }();
-
-			    if ((typeof _ret === "undefined" ? "undefined" : _typeof(_ret)) === "object") return _ret.v;
-			  }
-			  return titleMap;
-			};
-
-		/***/ },
-		/* 7 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-			exports.select = select;
-
-			var _sfPath = __webpack_require__(3);
-
-			var _sfPath2 = _interopRequireDefault(_sfPath);
-
-			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-			var numRe = /^\d+$/;
-
-			/**
-			  * @description
-			  * Utility method to access deep properties without
-			  * throwing errors when things are not defined.
-			  * Can also set a value in a deep structure, creating objects when missing
-			  * ex.
-			  * var foo = Select('address.contact.name',obj)
-			  * Select('address.contact.name',obj,'Leeroy')
-			  *
-			  * @param {string} projection A dot path to the property you want to get/set
-			  * @param {object} obj   (optional) The object to project on, defaults to 'this'
-			  * @param {Any}    valueToSet (opional)  The value to set, if parts of the path of
-			  *                 the projection is missing empty objects will be created.
-			  * @returns {Any|undefined} returns the value at the end of the projection path
-			  *                          or undefined if there is none.
-			  */
-			function select(projection, obj, valueToSet) {
-			  if (!obj) {
-			    obj = this;
-			  }
-			  //Support [] array syntax
-			  var parts = typeof projection === 'string' ? _sfPath2.default.parse(projection) : projection;
-
-			  if (typeof valueToSet !== 'undefined' && parts.length === 1) {
-			    //special case, just setting one variable
-			    obj[parts[0]] = valueToSet;
-			    return obj;
-			  }
-
-			  if (typeof valueToSet !== 'undefined' && typeof obj[parts[0]] === 'undefined') {
-			    // We need to look ahead to check if array is appropriate
-			    obj[parts[0]] = parts.length > 2 && numRe.test(parts[1]) ? [] : {};
-			  }
-
-			  var value = obj[parts[0]];
-			  for (var i = 1; i < parts.length; i++) {
-			    // Special case: We allow JSON Form syntax for arrays using empty brackets
-			    // These will of course not work here so we exit if they are found.
-			    if (parts[i] === '') {
-			      return undefined;
-			    }
-			    if (typeof valueToSet !== 'undefined') {
-			      if (i === parts.length - 1) {
-			        //last step. Let's set the value
-			        value[parts[i]] = valueToSet;
-			        return valueToSet;
-			      } else {
-			        // Make sure to create new objects on the way if they are not there.
-			        // We need to look ahead to check if array is appropriate
-			        var tmp = value[parts[i]];
-			        if (typeof tmp === 'undefined' || tmp === null) {
-			          tmp = numRe.test(parts[i + 1]) ? [] : {};
-			          value[parts[i]] = tmp;
-			        }
-			        value = tmp;
-			      }
-			    } else if (value) {
-			      //Just get nex value.
-			      value = value[parts[i]];
-			    }
-			  }
-			  return value;
-			}
-
-		/***/ },
-		/* 8 */
-		/***/ function(module, exports) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-			exports.traverseSchema = traverseSchema;
-			exports.traverseForm = traverseForm;
-			/**
-			 * Traverse a schema, applying a function(schema,path) on every sub schema
-			 * i.e. every property of an object.
-			 */
-			function traverseSchema(schema, fn, path, ignoreArrays) {
-			  ignoreArrays = ignoreArrays === undefined ? true : ignoreArrays;
-
-			  path = path || [];
-
-			  var traverse = function traverse(schema, fn, path) {
-			    fn(schema, path);
-			    if (schema.properties) {
-			      Object.keys(schema.properties).forEach(function (name) {
-			        var currentPath = path.slice();
-			        currentPath.push(name);
-			        traverse(schema.properties[name], fn, currentPath);
-			      });
-			    }
-
-			    //Only support type "array" which have a schema as "items".
-			    if (!ignoreArrays && schema.items) {
-			      var arrPath = path.slice();arrPath.push('');
-			      traverse(schema.items, fn, arrPath);
-			    }
-			  };
-
-			  traverse(schema, fn, path || []);
-			}
-
-			function traverseForm(form, fn) {
-			  fn(form);
-			  if (form.items) {
-			    form.items.forEach(function (f) {
-			      traverseForm(f, fn);
-			    });
-			  }
-
-			  if (form.tabs) {
-			    form.tabs.forEach(function (tab) {
-			      if (tab.items) {
-			        tab.items.forEach(function (f) {
-			          traverseForm(f, fn);
-			        });
-			      }
-			    });
-			  }
-			}
-
-		/***/ },
-		/* 9 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-			exports.validate = validate;
-
-			var _tv = __webpack_require__(10);
-
-			var _tv2 = _interopRequireDefault(_tv);
-
-			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-			/**
-			 * Validate a value against its form definition and schema.
-			 * The value should either be of proper type or a string, some type
-			 * coercion is applied.
-			 *
-			 * @param {Object} form A merged form definition, i.e. one with a schema.
-			 * @param {Any} value the value to validate.
-			 * @return {Object} a tv4js result object.
-			 */
-			function validate(form, value) {
-			  if (!form) {
-			    return { valid: true };
-			  };
-
-			  var schema = form.schema;
-			  if (!schema) {
-			    return { valid: true };
-			  };
-
-			  // Input of type text and textareas will give us a viewValue of ''
-			  // when empty, this is a valid value in a schema and does not count as something
-			  // that breaks validation of 'required'. But for our own sanity an empty field should
-			  // not validate if it's required.
-			  if (value === '') {
-			    value = undefined;
-			  };
-
-			  // Numbers fields will give a null value, which also means empty field
-			  if (form.type === 'number' && value === null) {
-			    value = undefined;
-			  };
-
-			  // Version 4 of JSON Schema has the required property not on the
-			  // property itself but on the wrapping object. Since we like to test
-			  // only this property we wrap it in a fake object.
-			  var wrap = { type: 'object', 'properties': {} };
-			  var propName = form.key[form.key.length - 1];
-			  wrap.properties[propName] = schema;
-
-			  if (form.required) {
-			    wrap.required = [propName];
-			  };
-
-			  var valueWrap = {};
-			  if (!!value) {
-			    valueWrap[propName] = value;
-			  };
-
-			  return _tv2.default.validateResult(valueWrap, wrap);
-			} /*  Common code for validating a value against its form and schema definition */
-			;
-
-		/***/ },
-		/* 10 */
-		/***/ function(module, exports) {
-
-			module.exports = tv4;
-
-		/***/ },
-		/* 11 */
-		/***/ function(module, exports, __webpack_require__) {
-
-			'use strict';
-
-			Object.defineProperty(exports, "__esModule", {
-			  value: true
-			});
-
-			var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; };
-
-			exports.defaultFormDefinition = defaultFormDefinition;
-			exports.stdFormObj = stdFormObj;
-			exports.text = text;
-			exports.number = number;
-			exports.integer = integer;
-			exports.checkbox = checkbox;
-			exports.select = select;
-			exports.checkboxes = checkboxes;
-			exports.fieldset = fieldset;
-			exports.array = array;
-			exports.createDefaults = createDefaults;
-			exports.defaultForm = defaultForm;
-
-			var _sfPath = __webpack_require__(3);
-
-			var _canonicalTitleMap = __webpack_require__(6);
-
-			var _canonicalTitleMap2 = _interopRequireDefault(_canonicalTitleMap);
-
-			function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-			/* Utils */
-			var stripNullType = function stripNullType(type) {
-			  if (Array.isArray(type) && type.length == 2) {
-			    if (type[0] === 'null') {
-			      return type[1];
-			    };
-			    if (type[1] === 'null') {
-			      return type[0];
-			    };
-			  };
-			  return type;
-			};
-
-			//Creates an default titleMap list from an enum, i.e. a list of strings.
-			var enumToTitleMap = function enumToTitleMap(enm) {
-			  var titleMap = []; //canonical titleMap format is a list.
-			  enm.forEach(function (name) {
-			    titleMap.push({ name: name, value: name });
-			  });
-			  return titleMap;
-			};
-
-			/**
-			 * Creates a default form definition from a schema.
-			 */
-			function defaultFormDefinition(schemaTypes, name, schema, options) {
-			  var rules = schemaTypes[stripNullType(schema.type)];
-			  if (rules) {
-			    var def = void 0;
-			    // We give each rule a possibility to recurse it's children.
-			    var innerDefaultFormDefinition = function innerDefaultFormDefinition(childName, childSchema, childOptions) {
-			      return defaultFormDefinition(schemaTypes, childName, childSchema, childOptions);
-			    };
-			    for (var i = 0; i < rules.length; i++) {
-			      def = rules[i](name, schema, options, innerDefaultFormDefinition);
-
-			      //first handler in list that actually returns something is our handler!
-			      if (def) {
-
-			        // Do we have form defaults in the schema under the x-schema-form-attribute?
-			        if (def.schema['x-schema-form']) {
-			          Object.assign(def, def.schema['x-schema-form']);
-			        }
-
-			        return def;
-			      }
-			    }
-			  }
-			}
-
-			/**
-			 * Creates a form object with all common properties
-			 */
-			function stdFormObj(name, schema, options) {
-			  options = options || {};
-
-			  // The Object.assign used to be a angular.copy. Should work though.
-			  var f = options.global && options.global.formDefaults ? Object.assign({}, options.global.formDefaults) : {};
-			  if (options.global && options.global.supressPropertyTitles === true) {
-			    f.title = schema.title;
-			  } else {
-			    f.title = schema.title || name;
-			  }
-
-			  if (schema.description) {
-			    f.description = schema.description;
-			  }
-			  if (options.required === true || schema.required === true) {
-			    f.required = true;
-			  }
-			  if (schema.maxLength) {
-			    f.maxlength = schema.maxLength;
-			  }
-			  if (schema.minLength) {
-			    f.minlength = schema.minLength;
-			  }
-			  if (schema.readOnly || schema.readonly) {
-			    f.readonly = true;
-			  }
-			  if (schema.minimum) {
-			    f.minimum = schema.minimum + (schema.exclusiveMinimum ? 1 : 0);
-			  }
-			  if (schema.maximum) {
-			    f.maximum = schema.maximum - (schema.exclusiveMaximum ? 1 : 0);
-			  }
-
-			  // Non standard attributes (DONT USE DEPRECATED)
-			  // If you must set stuff like this in the schema use the x-schema-form attribute
-			  if (schema.validationMessage) {
-			    f.validationMessage = schema.validationMessage;
-			  }
-			  if (schema.enumNames) {
-			    f.titleMap = (0, _canonicalTitleMap2.default)(schema.enumNames, schema['enum']);
-			  }
-			  f.schema = schema;
-
-			  // Ng model options doesn't play nice with undefined, might be defined
-			  // globally though
-			  f.ngModelOptions = f.ngModelOptions || {};
-
-			  return f;
-			};
-
-			/*** Schema types to form type mappings, with defaults ***/
-			function text(name, schema, options) {
-			  if (stripNullType(schema.type) === 'string' && !schema['enum']) {
-			    var f = stdFormObj(name, schema, options);
-			    f.key = options.path;
-			    f.type = 'text';
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-			    return f;
-			  }
-			}
-
-			//default in json form for number and integer is a text field
-			//input type="number" would be more suitable don't ya think?
-			function number(name, schema, options) {
-			  if (stripNullType(schema.type) === 'number') {
-			    var f = stdFormObj(name, schema, options);
-			    f.key = options.path;
-			    f.type = 'number';
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-			    return f;
-			  }
-			}
-
-			function integer(name, schema, options) {
-			  if (stripNullType(schema.type) === 'integer') {
-			    var f = stdFormObj(name, schema, options);
-			    f.key = options.path;
-			    f.type = 'number';
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-			    return f;
-			  }
-			}
-
-			function checkbox(name, schema, options) {
-			  if (stripNullType(schema.type) === 'boolean') {
-			    var f = stdFormObj(name, schema, options);
-			    f.key = options.path;
-			    f.type = 'checkbox';
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-			    return f;
-			  }
-			}
-
-			function select(name, schema, options) {
-			  if (stripNullType(schema.type) === 'string' && schema['enum']) {
-			    var f = stdFormObj(name, schema, options);
-			    f.key = options.path;
-			    f.type = 'select';
-			    if (!f.titleMap) {
-			      f.titleMap = enumToTitleMap(schema['enum']);
-			    }
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-			    return f;
-			  }
-			}
-
-			function checkboxes(name, schema, options) {
-			  if (stripNullType(schema.type) === 'array' && schema.items && schema.items['enum']) {
-			    var f = stdFormObj(name, schema, options);
-			    f.key = options.path;
-			    f.type = 'checkboxes';
-			    if (!f.titleMap) {
-			      f.titleMap = enumToTitleMap(schema.items['enum']);
-			    }
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-			    return f;
-			  }
-			}
-
-			function fieldset(name, schema, options, defaultFormDef) {
-			  if (stripNullType(schema.type) === 'object') {
-			    var _ret = function () {
-			      var f = stdFormObj(name, schema, options);
-			      f.type = 'fieldset';
-			      f.key = options.path;
-			      f.items = [];
-			      options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-
-			      //recurse down into properties
-			      if (schema.properties) {
-			        Object.keys(schema.properties).forEach(function (key) {
-			          var value = schema.properties[key];
-			          var path = options.path.slice();
-			          path.push(key);
-			          if (options.ignore[(0, _sfPath.stringify)(path)] !== true) {
-			            var required = schema.required && schema.required.indexOf(key) !== -1;
-
-			            var def = defaultFormDef(key, value, {
-			              path: path,
-			              required: required || false,
-			              lookup: options.lookup,
-			              ignore: options.ignore,
-			              global: options.global
-			            });
-			            if (def) {
-			              f.items.push(def);
-			            }
-			          }
-			        });
-			      }
-			      return {
-			        v: f
-			      };
-			    }();
-
-			    if ((typeof _ret === 'undefined' ? 'undefined' : _typeof(_ret)) === "object") return _ret.v;
-			  }
-			}
-
-			function array(name, schema, options, defaultFormDef) {
-			  if (stripNullType(schema.type) === 'array') {
-			    var f = stdFormObj(name, schema, options);
-			    f.type = 'array';
-			    f.key = options.path;
-			    options.lookup[(0, _sfPath.stringify)(options.path)] = f;
-
-			    var required = schema.required && schema.required.indexOf(options.path[options.path.length - 1]) !== -1;
-
-			    // The default is to always just create one child. This works since if the
-			    // schemas items declaration is of type: "object" then we get a fieldset.
-			    // We also follow json form notatation, adding empty brackets "[]" to
-			    // signify arrays.
-
-			    var arrPath = options.path.slice();
-			    arrPath.push('');
-
-			    f.items = [defaultFormDef(name, schema.items, {
-			      path: arrPath,
-			      required: required || false,
-			      lookup: options.lookup,
-			      ignore: options.ignore,
-			      global: options.global
-			    })];
-
-			    return f;
-			  }
-			}
-
-			function createDefaults() {
-			  //First sorted by schema type then a list.
-			  //Order has importance. First handler returning an form snippet will be used.
-			  return {
-			    string: [select, text],
-			    object: [fieldset],
-			    number: [number],
-			    integer: [integer],
-			    boolean: [checkbox],
-			    array: [checkboxes, array]
-			  };
-			};
-
-			/**
-			 * Create form defaults from schema
-			 */
-			function defaultForm(schema, defaultSchemaTypes, ignore, globalOptions) {
-			  var form = [];
-			  var lookup = {}; //Map path => form obj for fast lookup in merging
-			  ignore = ignore || {};
-			  globalOptions = globalOptions || {};
-			  defaultSchemaTypes = defaultSchemaTypes || createDefaults();
-
-			  if (schema.properties) {
-			    Object.keys(schema.properties).forEach(function (key) {
-			      if (ignore[key] !== true) {
-			        var required = schema.required && schema.required.indexOf(key) !== -1;
-			        var def = defaultFormDefinition(defaultSchemaTypes, key, schema.properties[key], {
-			          path: [key], // Path to this property in bracket notation.
-			          lookup: lookup, // Extra map to register with. Optimization for merger.
-			          ignore: ignore, // The ignore list of paths (sans root level name)
-			          required: required, // Is it required? (v4 json schema style)
-			          global: globalOptions // Global options, including form defaults
-			        });
-			        if (def) {
-			          form.push(def);
-			        }
-			      }
-			    });
-			  } else {
-			    throw new Error('Not implemented. Only type "object" allowed at root level of schema.');
-			  }
-			  return { form: form, lookup: lookup };
-			}
-
-		/***/ }
-		/******/ ])
-		});
-		;
-
-	/***/ },
-	/* 7 */
-	/***/ function(module, exports) {
-
-		module.exports = tv4;
-
-	/***/ },
-	/* 8 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function () {
-		  var validator = {};
-
-		  /**
-		   * Validate a value against its form definition and schema.
-		   * The value should either be of proper type or a string, some type
-		   * coercion is applied.
-		   *
-		   * @param {Object} form A merged form definition, i.e. one with a schema.
-		   * @param {Any} value the value to validate.
-		   * @return {Object} a tv4js result object.
-		   */
-		  validator.validate = function (form, value) {
-		    if (!form) {
-		      return { valid: true };
-		    };
-
-		    var schema = form.schema;
-		    if (!schema) {
-		      return { valid: true };
-		    };
-
-		    // Input of type text and textareas will give us a viewValue of ''
-		    // when empty, this is a valid value in a schema and does not count as something
-		    // that breaks validation of 'required'. But for our own sanity an empty field should
-		    // not validate if it's required.
-		    if (value === '') {
-		      value = undefined;
-		    };
-
-		    // Numbers fields will give a null value, which also means empty field
-		    if (form.type === 'number' && value === null) {
-		      value = undefined;
-		    };
-
-		    // Version 4 of JSON Schema has the required property not on the
-		    // property itself but on the wrapping object. Since we like to test
-		    // only this property we wrap it in a fake object.
-		    var wrap = { type: 'object', 'properties': {} };
-		    var propName = form.key[form.key.length - 1];
-		    wrap.properties[propName] = schema;
-
-		    if (form.required) {
-		      wrap.required = [propName];
-		    };
-
-		    var valueWrap = {};
-		    if (_angular2.default.isDefined(value)) {
-		      valueWrap[propName] = value;
-		    };
-
-		    return _tv2.default.validateResult(valueWrap, wrap);
-		  };
-
-		  return validator;
-		};
-
-		var _tv = __webpack_require__(7);
-
-		var _tv2 = _interopRequireDefault(_tv);
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 9 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function () {
-
-		  // The codes are tv4 error codes.
-		  // Not all of these can actually happen in a field, but for
-		  // we never know when one might pop up so it's best to cover them all.
-
-		  // TODO: Humanize these.
-		  var defaultMessages = {
-		    'default': 'Field does not validate',
-		    0: 'Invalid type, expected {{schema.type}}',
-		    1: 'No enum match for: {{viewValue}}',
-		    10: 'Data does not match any schemas from "anyOf"',
-		    11: 'Data does not match any schemas from "oneOf"',
-		    12: 'Data is valid against more than one schema from "oneOf"',
-		    13: 'Data matches schema from "not"',
-		    // Numeric errors
-		    100: 'Value is not a multiple of {{schema.multipleOf}}',
-		    101: '{{viewValue}} is less than the allowed minimum of {{schema.minimum}}',
-		    102: '{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}',
-		    103: '{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}',
-		    104: '{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}',
-		    105: 'Value is not a valid number',
-		    // String errors
-		    200: 'String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}',
-		    201: 'String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}',
-		    202: 'String does not match pattern: {{schema.pattern}}',
-		    // Object errors
-		    300: 'Too few properties defined, minimum {{schema.minProperties}}',
-		    301: 'Too many properties defined, maximum {{schema.maxProperties}}',
-		    302: 'Required',
-		    303: 'Additional properties not allowed',
-		    304: 'Dependency failed - key must exist',
-		    // Array errors
-		    400: 'Array is too short ({{value.length}}), minimum {{schema.minItems}}',
-		    401: 'Array is too long ({{value.length}}), maximum {{schema.maxItems}}',
-		    402: 'Array items are not unique',
-		    403: 'Additional items not allowed',
-		    // Format errors
-		    500: 'Format validation failed',
-		    501: 'Keyword failed: "{{title}}"',
-		    // Schema structure
-		    600: 'Circular $refs',
-		    // Non-standard validation options
-		    1000: 'Unknown property (not in schema)'
-		  };
-
-		  // In some cases we get hit with an angular validation error
-		  defaultMessages.number = defaultMessages[105];
-		  defaultMessages.required = defaultMessages[302];
-		  defaultMessages.min = defaultMessages[101];
-		  defaultMessages.max = defaultMessages[103];
-		  defaultMessages.maxlength = defaultMessages[201];
-		  defaultMessages.minlength = defaultMessages[200];
-		  defaultMessages.pattern = defaultMessages[202];
-
-		  this.setDefaultMessages = function (messages) {
-		    defaultMessages = messages;
-		  };
-
-		  this.getDefaultMessages = function () {
-		    return defaultMessages;
-		  };
-
-		  this.setDefaultMessage = function (error, msg) {
-		    defaultMessages[error] = msg;
-		  };
-
-		  this.$get = ['$interpolate', function ($interpolate) {
-
-		    var service = {};
-		    service.defaultMessages = defaultMessages;
-
-		    /**
-		     * Interpolate and return proper error for an eror code.
-		     * Validation message on form trumps global error messages.
-		     * and if the message is a function instead of a string that function will be called instead.
-		     *
-		     * @param {string} error the error code, i.e. tv4-xxx for tv4 errors, otherwise it's whats on
-		     *                       ngModel.$error for custom errors.
-		     * @param {Any} value the actual model value.
-		     * @param {Any} viewValue the viewValue
-		     * @param {Object} form a form definition object for this field
-		     * @param  {Object} global the global validation messages object (even though its called global
-		     *                         its actually just shared in one instance of sf-schema)
-		     * @return {string} The error message.
-		     */
-		    service.interpolate = function (error, value, viewValue, form, global) {
-		      global = global || {};
-		      var validationMessage = form.validationMessage || {};
-
-		      // Drop tv4 prefix so only the code is left.
-		      if (error.indexOf('tv4-') === 0) {
-		        error = error.substring(4);
-		      }
-
-		      // First find apropriate message or function
-		      var message = validationMessage['default'] || global['default'] || '';
-
-		      [validationMessage, global, defaultMessages].some(function (val) {
-		        if (_angular2.default.isString(val) || _angular2.default.isFunction(val)) {
-		          message = val;
-		          return true;
-		        }
-		        if (val && val[error]) {
-		          message = val[error];
-		          return true;
-		        }
-		      });
-
-		      var context = {
-		        error: error,
-		        value: value,
-		        viewValue: viewValue,
-		        form: form,
-		        schema: form.schema,
-		        title: form.title || form.schema && form.schema.title
-		      };
-		      if (_angular2.default.isFunction(message)) {
-		        return message(context);
-		      } else {
-		        return $interpolate(message)(context);
-		      }
-		    };
-
-		    return service;
-		  }];
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 10 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function () {
-		  // expose the methods in sfPathProvider
-		  this.parse = _jsonSchemaFormCore.sfPath.parse;
-		  this.stringify = _jsonSchemaFormCore.sfPath.stringify;
-		  this.normalize = _jsonSchemaFormCore.sfPath.normalize;
-
-		  this.$get = function () {
-		    return _jsonSchemaFormCore.sfPath;
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		var _jsonSchemaFormCore = __webpack_require__(6);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 11 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function (sfSelect, schemaForm, sfValidator, sfPath) {
-
-		  var setIndex = function setIndex(index) {
-		    return function (form) {
-		      if (form.key) {
-		        form.key[form.key.indexOf('')] = index;
-		      }
-		    };
-		  };
-
-		  return {
-		    restrict: 'A',
-		    scope: true,
-		    require: '?ngModel',
-		    link: function link(scope, element, attrs, ngModel) {
-		      var formDefCache = {};
-
-		      scope.validateArray = _angular2.default.noop;
-
-		      if (ngModel) {
-		        // We need the ngModelController on several places,
-		        // most notably for errors.
-		        // So we emit it up to the decorator directive so it can put it on scope.
-		        scope.$emit('schemaFormPropagateNgModelController', ngModel);
-		      };
-
-		      // Watch for the form definition and then rewrite it.
-		      // It's the (first) array part of the key, '[]' that needs a number
-		      // corresponding to an index of the form.
-		      var once = scope.$watch(attrs.sfArray, function (form) {
-		        if (!form) {
-		          return;
-		        };
-
-		        // An array model always needs a key so we know what part of the model
-		        // to look at. This makes us a bit incompatible with JSON Form, on the
-		        // other hand it enables two way binding.
-		        var list = sfSelect(form.key, scope.model);
-
-		        // We only modify the same array instance but someone might change the array from
-		        // the outside so let's watch for that. We use an ordinary watch since the only case
-		        // we're really interested in is if its a new instance.
-		        var key = sfPath.normalize(form.key);
-		        scope.$watch('model' + (key[0] !== '[' ? '.' : '') + key, function (value) {
-		          list = scope.modelArray = value;
-		        });
-
-		        // Since ng-model happily creates objects in a deep path when setting a
-		        // a value but not arrays we need to create the array.
-		        if (_angular2.default.isUndefined(list)) {
-		          list = [];
-		          sfSelect(form.key, scope.model, list);
-		        }
-		        scope.modelArray = list;
-
-		        // Arrays with titleMaps, i.e. checkboxes doesn't have items.
-		        if (form.items) {
-
-		          // To be more compatible with JSON Form we support an array of items
-		          // in the form definition of "array" (the schema just a value).
-		          // for the subforms code to work this means we wrap everything in a
-		          // section. Unless there is just one.
-		          var subForm = form.items[0];
-		          if (form.items.length > 1) {
-		            subForm = {
-		              type: 'section',
-		              items: form.items.map(function (item) {
-		                item.ngModelOptions = form.ngModelOptions;
-		                if (_angular2.default.isUndefined(item.readonly)) {
-		                  item.readonly = form.readonly;
-		                }
-		                return item;
-		              })
-		            };
-		          }
-		        }
-
-		        // We ceate copies of the form on demand, caching them for
-		        // later requests
-		        scope.copyWithIndex = function (index) {
-		          if (!formDefCache[index]) {
-		            if (subForm) {
-		              var copy = _angular2.default.copy(subForm);
-		              copy.arrayIndex = index;
-		              schemaForm.traverseForm(copy, setIndex(index));
-		              formDefCache[index] = copy;
-		            }
-		          }
-		          return formDefCache[index];
-		        };
-
-		        scope.appendToArray = function () {
-		          var len = list.length;
-		          var copy = scope.copyWithIndex(len);
-		          schemaForm.traverseForm(copy, function (part) {
-
-		            if (part.key) {
-		              var def;
-		              if (_angular2.default.isDefined(part['default'])) {
-		                def = part['default'];
-		              }
-		              if (_angular2.default.isDefined(part.schema) && _angular2.default.isDefined(part.schema['default'])) {
-		                def = part.schema['default'];
-		              }
-
-		              if (_angular2.default.isDefined(def)) {
-		                sfSelect(part.key, scope.model, def);
-		              }
-		            }
-		          });
-
-		          // If there are no defaults nothing is added so we need to initialize
-		          // the array. undefined for basic values, {} or [] for the others.
-		          if (len === list.length) {
-		            var type = sfSelect('schema.items.type', form);
-		            var dflt;
-		            if (type === 'object') {
-		              dflt = {};
-		            } else if (type === 'array') {
-		              dflt = [];
-		            }
-		            list.push(dflt);
-		          }
-
-		          // Trigger validation.
-		          scope.validateArray();
-		          return list;
-		        };
-
-		        scope.deleteFromArray = function (index) {
-		          list.splice(index, 1);
-
-		          // Trigger validation.
-		          scope.validateArray();
-
-		          // Angular 1.2 lacks setDirty
-		          if (ngModel && ngModel.$setDirty) {
-		            ngModel.$setDirty();
-		          }
-		          return list;
-		        };
-
-		        // Always start with one empty form unless configured otherwise.
-		        // Special case: don't do it if form has a titleMap
-		        if (!form.titleMap && form.startEmpty !== true && list.length === 0) {
-		          scope.appendToArray();
-		        }
-
-		        // Title Map handling
-		        // If form has a titleMap configured we'd like to enable looping over
-		        // titleMap instead of modelArray, this is used for intance in
-		        // checkboxes. So instead of variable number of things we like to create
-		        // a array value from a subset of values in the titleMap.
-		        // The problem here is that ng-model on a checkbox doesn't really map to
-		        // a list of values. This is here to fix that.
-		        if (form.titleMap && form.titleMap.length > 0) {
-		          scope.titleMapValues = [];
-
-		          // We watch the model for changes and the titleMapValues to reflect
-		          // the modelArray
-		          var updateTitleMapValues = function updateTitleMapValues(arr) {
-		            scope.titleMapValues = [];
-		            arr = arr || [];
-
-		            form.titleMap.forEach(function (item) {
-		              scope.titleMapValues.push(arr.indexOf(item.value) !== -1);
-		            });
-		          };
-		          //Catch default values
-		          updateTitleMapValues(scope.modelArray);
-		          scope.$watchCollection('modelArray', updateTitleMapValues);
-
-		          //To get two way binding we also watch our titleMapValues
-		          scope.$watchCollection('titleMapValues', function (vals, old) {
-		            if (vals && vals !== old) {
-		              var arr = scope.modelArray;
-
-		              // Apparently the fastest way to clear an array, readable too.
-		              // http://jsperf.com/array-destroy/32
-		              while (arr.length > 0) {
-		                arr.pop();
-		              }
-		              form.titleMap.forEach(function (item, index) {
-		                if (vals[index]) {
-		                  arr.push(item.value);
-		                }
-		              });
-
-		              // Time to validate the rebuilt array.
-		              scope.validateArray();
-		            }
-		          });
-		        }
-
-		        // If there is a ngModel present we need to validate when asked.
-		        if (ngModel) {
-		          var error;
-
-		          scope.validateArray = function () {
-		            // The actual content of the array is validated by each field
-		            // so we settle for checking validations specific to arrays
-
-		            // Since we prefill with empty arrays we can get the funny situation
-		            // where the array is required but empty in the gui but still validates.
-		            // Thats why we check the length.
-		            var result = sfValidator.validate(form, scope.modelArray.length > 0 ? scope.modelArray : undefined);
-
-		            // TODO: DRY this up, it has a lot of similarities with schema-validate
-		            // Since we might have different tv4 errors we must clear all
-		            // errors that start with tv4-
-		            Object.keys(ngModel.$error).filter(function (k) {
-		              return k.indexOf('tv4-') === 0;
-		            }).forEach(function (k) {
-		              ngModel.$setValidity(k, true);
-		            });
-
-		            if (result.valid === false && result.error && (result.error.dataPath === '' || result.error.dataPath === '/' + form.key[form.key.length - 1])) {
-
-		              // Set viewValue to trigger $dirty on field. If someone knows a
-		              // a better way to do it please tell.
-		              ngModel.$setViewValue(scope.modelArray);
-		              error = result.error;
-		              ngModel.$setValidity('tv4-' + result.error.code, false);
-		            }
-		          };
-
-		          scope.$on('schemaFormValidate', scope.validateArray);
-
-		          scope.hasSuccess = function () {
-		            if (scope.options && scope.options.pristine && scope.options.pristine.success === false) {
-		              return ngModel.$valid && !ngModel.$pristine && !ngModel.$isEmpty(ngModel.$modelValue);
-		            } else {
-		              return ngModel.$valid && (!ngModel.$pristine || !ngModel.$isEmpty(ngModel.$modelValue));
-		            }
-		          };
-
-		          scope.hasError = function () {
-		            if (!scope.options || !scope.options.pristine || scope.options.pristine.errors !== false) {
-		              // Show errors in pristine forms. The default.
-		              // Note that "validateOnRender" option defaults to *not* validate initial form.
-		              // so as a default there won't be any error anyway, but if the model is modified
-		              // from the outside the error will show even if the field is pristine.
-		              return ngModel.$invalid;
-		            } else {
-		              // Don't show errors in pristine forms.
-		              return ngModel.$invalid && !ngModel.$pristine;
-		            }
-		          };
-
-		          scope.schemaError = function () {
-		            return error;
-		          };
-		        }
-
-		        once();
-		      });
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 12 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function () {
-		  return {
-		    require: 'ngModel',
-		    restrict: 'AC',
-		    scope: false,
-		    link: function link(scope, element, attrs, ctrl) {
-		      var form = scope.$eval(attrs.sfChanged);
-		      //"form" is really guaranteed to be here since the decorator directive
-		      //waits for it. But best be sure.
-		      if (form && form.onChange) {
-		        ctrl.$viewChangeListeners.push(function () {
-		          if (_angular2.default.isFunction(form.onChange)) {
-		            form.onChange(ctrl.$modelValue, form);
-		          } else {
-		            scope.evalExpr(form.onChange, { 'modelValue': ctrl.$modelValue, form: form });
-		          }
-		        });
-		      }
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 13 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol ? "symbol" : typeof obj; };
-
-		exports.default = function ($parse, $compile, $http, $templateCache, $interpolate, $q, sfErrorMessage, sfPath, sfSelect) {
-
-		  var keyFormat = {
-		    COMPLETE: '*',
-		    PATH: 'string',
-		    INDICES: 'number'
-		  };
-
-		  return {
-		    restrict: 'AE',
-		    replace: false,
-		    transclude: false,
-		    scope: true,
-		    require: ['^sfSchema', '?^form', '?^^sfKeyController'],
-		    link: {
-		      pre: function pre(scope, element, attrs, ctrl) {
-		        var sfSchema = ctrl[0];
-		        var formCtrl = ctrl[1];
-		        var keyCtrl = ctrl[2];
-
-		        //The ngModelController is used in some templates and
-		        //is needed for error messages,
-		        scope.$on('schemaFormPropagateNgModelController', function (event, ngModel) {
-		          event.stopPropagation();
-		          event.preventDefault();
-		          scope.ngModel = ngModel;
-		        });
-
-		        // Fetch our form.
-		        scope.form = sfSchema.lookup['f' + attrs.sfField];
-		      },
-		      post: function post(scope, element, attrs, ctrl) {
-		        var sfSchema = ctrl[0];
-		        var formCtrl = ctrl[1];
-		        var keyCtrl = ctrl[2];
-
-		        //Keep error prone logic from the template
-		        scope.showTitle = function () {
-		          return scope.form && scope.form.notitle !== true && scope.form.title;
-		        };
-
-		        scope.getKey = function (requiredFormat) {
-		          var format = requiredFormat || keyFormat.COMPLETE;
-		          var key = scope.parentKey ? scope.parentKey.slice(0, scope.parentKey.length - 1) : [];
-
-		          if (typeof scope.$index === 'number') {
-		            key = key.concat(scope.$index);
-		          };
-
-		          if (scope.form.key && scope.form.key.length) {
-		            if (typeof key[key.length - 1] === 'number' && scope.form.key.length >= 1) {
-		              scope.completeKey = key.concat(scope.form.key.slice(-1));
-		            } else {
-		              scope.completeKey = scope.form.key.slice();
-		            };
-		          };
-
-		          if (!Array.isArray(scope.completeKey)) {
-		            return undefined;
-		          };
-
-		          if (format === keyFormat.COMPLETE) {
-		            return scope.completeKey;
-		          };
-
-		          return scope.completeKey.reduce(function (output, input, i) {
-		            if (-1 !== [format].indexOf(typeof input === 'undefined' ? 'undefined' : _typeof(input))) {
-		              return output.concat(input);
-		            }
-		            return output;
-		          }, []);
-		        };
-		        if (scope.form.key) scope.completeKey = scope.getKey();
-
-		        scope.path = function (modelPath) {
-		          var i = -1;
-		          modelPath = modelPath.replace(/\[\]/gi, function (matched) {
-		            i++;
-		            return scope.$i[i];
-		          });
-		          return scope.$eval(modelPath, scope);
-		        };
-
-		        //Normalise names and ids
-		        scope.fieldId = function (prependFormName, omitArrayIndexes) {
-		          var formName = prependFormName && formCtrl && formCtrl.$name ? formCtrl.$name : undefined;
-		          var key = scope.getKey();
-
-		          if (Array.isArray(key)) {
-		            return sfPath.name(key, '-', formName, omitArrayIndexes);
-		          } else {
-		            return '';
-		          };
-		        };
-
-		        scope.listToCheckboxValues = function (list) {
-		          var values = {};
-		          _angular2.default.forEach(list, function (v) {
-		            values[v] = true;
-		          });
-		          return values;
-		        };
-
-		        scope.checkboxValuesToList = function (values) {
-		          var lst = [];
-		          _angular2.default.forEach(values, function (v, k) {
-		            if (v) {
-		              lst.push(k);
-		            }
-		          });
-		          return lst;
-		        };
-
-		        scope.buttonClick = function ($event, form) {
-		          if (_angular2.default.isFunction(form.onClick)) {
-		            form.onClick($event, form);
-		          } else if (_angular2.default.isString(form.onClick)) {
-		            if (sfSchema) {
-		              //evaluating in scope outside of sfSchemas isolated scope
-		              sfSchema.evalInParentScope(form.onClick, { '$event': $event, form: form });
-		            } else {
-		              scope.$eval(form.onClick, { '$event': $event, form: form });
-		            }
-		          }
-		        };
-
-		        /**
-		         * Evaluate an expression, i.e. scope.$eval
-		         * but do it in sfSchemas parent scope sf-schema directive is used
-		         *
-		         * @param {string} expression
-		         * @param {Object} locals (optional)
-		         * @return {Any} the result of the expression
-		         */
-		        scope.evalExpr = function (expression, locals) {
-		          if (sfSchema) {
-		            //evaluating in scope outside of sfSchemas isolated scope
-		            return sfSchema.evalInParentScope(expression, locals);
-		          }
-
-		          return scope.$eval(expression, locals);
-		        };
-
-		        /**
-		         * Evaluate an expression, i.e. scope.$eval
-		         * in this decorators scope
-		         *
-		         * @param {string} expression
-		         * @param {Object} locals (optional)
-		         * @return {Any} the result of the expression
-		         */
-		        scope.evalInScope = function (expression, locals) {
-		          if (expression) {
-		            return scope.$eval(expression, locals);
-		          }
-		        };
-
-		        /**
-		         * Interpolate the expression.
-		         * Similar to `evalExpr()` and `evalInScope()`
-		         * but will not fail if the expression is
-		         * text that contains spaces.
-		         *
-		         * Use the Angular `{{ interpolation }}`
-		         * braces to access properties on `locals`.
-		         *
-		         * @param  {string} expression The string to interpolate.
-		         * @param  {Object} locals (optional) Properties that may be accessed in the
-		         *                         `expression` string.
-		         * @return {Any} The result of the expression or `undefined`.
-		         */
-		        scope.interp = function (expression, locals) {
-		          return expression && $interpolate(expression)(locals);
-		        };
-
-		        //This works since we get the ngModel from the array or the schema-validate directive.
-		        scope.hasSuccess = function () {
-		          if (!scope.ngModel) {
-		            return false;
-		          }
-		          if (scope.options && scope.options.pristine && scope.options.pristine.success === false) {
-		            return scope.ngModel.$valid && !scope.ngModel.$pristine && !scope.ngModel.$isEmpty(scope.ngModel.$modelValue);
-		          } else {
-		            return scope.ngModel.$valid && (!scope.ngModel.$pristine || !scope.ngModel.$isEmpty(scope.ngModel.$modelValue));
-		          }
-		        };
-
-		        scope.hasError = function () {
-		          if (!scope.ngModel) {
-		            return false;
-		          }
-		          if (!scope.options || !scope.options.pristine || scope.options.pristine.errors !== false) {
-		            // Show errors in pristine forms. The default.
-		            // Note that "validateOnRender" option defaults to *not* validate initial form.
-		            // so as a default there won't be any error anyway, but if the model is modified
-		            // from the outside the error will show even if the field is pristine.
-		            return scope.ngModel.$invalid;
-		          } else {
-		            // Don't show errors in pristine forms.
-		            return scope.ngModel.$invalid && !scope.ngModel.$pristine;
-		          }
-		        };
-
-		        /**
-		         * DEPRECATED: use sf-messages instead.
-		         * Error message handler
-		         * An error can either be a schema validation message or a angular js validtion
-		         * error (i.e. required)
-		         */
-		        scope.errorMessage = function (schemaError) {
-		          return sfErrorMessage.interpolate(schemaError && schemaError.code + '' || 'default', scope.ngModel && scope.ngModel.$modelValue || '', scope.ngModel && scope.ngModel.$viewValue || '', scope.form, scope.options && scope.options.validationMessage);
-		        };
-
-		        // append the field-id to the htmlClass
-		        scope.form.htmlClass = scope.form.htmlClass || '';
-		        scope.form.htmlClass += (scope.form.htmlClass ? ' ' : '') + scope.fieldId(false, true);
-
-		        var form = scope.form;
-
-		        // Where there is a key there is probably a ngModel
-		        if (form.key) {
-		          // It looks better with dot notation.
-		          scope.$on('schemaForm.error.' + form.key.join('.'), function (event, error, validationMessage, validity, formName) {
-		            // validationMessage and validity are mutually exclusive
-		            formName = validity;
-		            if (validationMessage === true || validationMessage === false) {
-		              validity = validationMessage;
-		              validationMessage = undefined;
-		            };
-
-		            // If we have specified a form name, and this model is not within
-		            // that form, then leave things be.
-		            if (formName != undefined && scope.ngModel.$$parentForm.$name !== formName) {
-		              return;
-		            };
-
-		            if (scope.ngModel && error) {
-		              if (scope.ngModel.$setDirty) {
-		                scope.ngModel.$setDirty();
-		              } else {
-		                // FIXME: Check that this actually works on 1.2
-		                scope.ngModel.$dirty = true;
-		                scope.ngModel.$pristine = false;
-		              }
-
-		              // Set the new validation message if one is supplied
-		              // Does not work when validationMessage is just a string.
-		              if (validationMessage) {
-		                if (!form.validationMessage) {
-		                  form.validationMessage = {};
-		                }
-		                form.validationMessage[error] = validationMessage;
-		              }
-
-		              scope.ngModel.$setValidity(error, validity === true);
-
-		              if (validity === true) {
-		                // Re-trigger model validator, that model itself would be re-validated
-		                scope.ngModel.$validate();
-
-		                // Setting or removing a validity can change the field to believe its valid
-		                // but its not. So lets trigger its validation as well.
-		                scope.$broadcast('schemaFormValidate');
-		              }
-		            }
-		          });
-
-		          // Clean up the model when the corresponding form field is $destroy-ed.
-		          // Default behavior can be supplied as a globalOption, and behavior can be overridden
-		          // in the form definition.
-		          scope.$on('$destroy', function () {
-		            var key = scope.getKey();
-
-		            // If the entire schema form is destroyed we don't touch the model
-		            if (!scope.externalDestructionInProgress) {
-		              var destroyStrategy = form.destroyStrategy || scope.options && scope.options.destroyStrategy || 'remove';
-		              // No key no model, and we might have strategy 'retain'
-		              if (key && destroyStrategy !== 'retain') {
-
-		                // Get the object that has the property we wan't to clear.
-		                var obj = scope.model;
-		                if (key.length > 1) {
-		                  obj = sfSelect(key.slice(0, key.length - 1), obj);
-		                }
-
-		                // We can get undefined here if the form hasn't been filled out entirely
-		                if (obj === undefined) {
-		                  return;
-		                }
-
-		                // Type can also be a list in JSON Schema
-		                var type = form.schema && form.schema.type || '';
-
-		                // Empty means '',{} and [] for appropriate types and undefined for the rest
-		                //console.log('destroy', destroyStrategy, key, type, obj);
-		                if (destroyStrategy === 'empty' && type.indexOf('string') !== -1) {
-		                  obj[key.slice(-1)] = '';
-		                } else if (destroyStrategy === 'empty' && type.indexOf('object') !== -1) {
-		                  obj[key.slice(-1)] = {};
-		                } else if (destroyStrategy === 'empty' && type.indexOf('array') !== -1) {
-		                  obj[key.slice(-1)] = [];
-		                } else if (destroyStrategy === 'null') {
-		                  obj[key.slice(-1)] = null;
-		                } else {
-		                  delete obj[key.slice(-1)];
-		                }
-		              }
-		            }
-		          });
-		        }
-		      }
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 14 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function ($injector, sfErrorMessage) {
-
-		  //Inject sanitizer if it exists
-		  var $sanitize = $injector.has('$sanitize') ? $injector.get('$sanitize') : function (html) {
-		    return html;
-		  };
-
-		  return {
-		    scope: false,
-		    restrict: 'EA',
-		    link: function link(scope, element, attrs) {
-
-		      var message = '';
-		      if (attrs.sfMessage) {
-		        scope.$watch(attrs.sfMessage, function (msg) {
-		          if (msg) {
-		            message = $sanitize(msg);
-		            update(!!scope.ngModel);
-		          }
-		        });
-		      }
-
-		      var currentMessage;
-		      // Only call html() if needed.
-		      var setMessage = function setMessage(msg) {
-		        if (msg !== currentMessage) {
-		          element.html(msg);
-		          currentMessage = msg;
-		        }
-		      };
-
-		      var update = function update(checkForErrors) {
-		        if (checkForErrors) {
-		          if (!scope.hasError()) {
-		            setMessage(message);
-		          } else {
-		            var errors = [];
-		            _angular2.default.forEach(scope.ngModel && scope.ngModel.$error, function (status, code) {
-		              if (status) {
-		                // if true then there is an error
-		                // Angular 1.3 removes properties, so we will always just have errors.
-		                // Angular 1.2 sets them to false.
-		                errors.push(code);
-		              }
-		            });
-
-		            // In Angular 1.3 we use one $validator to stop the model value from getting updated.
-		            // this means that we always end up with a 'schemaForm' error.
-		            errors = errors.filter(function (e) {
-		              return e !== 'schemaForm';
-		            });
-
-		            // We only show one error.
-		            // TODO: Make that optional
-		            var error = errors[0];
-
-		            if (error) {
-		              setMessage(sfErrorMessage.interpolate(error, scope.ngModel.$modelValue, scope.ngModel.$viewValue, scope.form, scope.options && scope.options.validationMessage));
-		            } else {
-		              setMessage(message);
-		            }
-		          }
-		        } else {
-		          setMessage(message);
-		        }
-		      };
-
-		      // Update once.
-		      update();
-
-		      var once = scope.$watch('ngModel', function (ngModel) {
-		        if (ngModel) {
-		          // We also listen to changes of the model via parsers and formatters.
-		          // This is since both the error message can change and given a pristine
-		          // option to not show errors the ngModel.$error might not have changed
-		          // but we're not pristine any more so we should change!
-		          ngModel.$parsers.push(function (val) {
-		            update(true);return val;
-		          });
-		          ngModel.$formatters.push(function (val) {
-		            update(true);return val;
-		          });
-		          once();
-		        }
-		      });
-
-		      // We watch for changes in $error
-		      scope.$watchCollection('ngModel.$error', function () {
-		        update(!!scope.ngModel);
-		      });
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 15 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function (sel, sfPath, schemaForm) {
-		  return {
-		    scope: true,
-		    controller: ['$scope', function SFArrayController($scope) {
-		      this.key = $scope.form && $scope.form.key ? $scope.form.key.splice(0, -2) : [];
-		    }],
-		    link: function link(scope, element, attrs) {
-		      scope.min = 0;
-
-		      scope.modelArray = scope.$eval(attrs.sfNewArray);
-
-		      // We need to have a ngModel to hook into validation. It doesn't really play well with
-		      // arrays though so we both need to trigger validation and onChange.
-		      // So we watch the value as well. But watching an array can be tricky. We wan't to know
-		      // when it changes so we can validate,
-		      var watchFn = function watchFn() {
-		        //scope.modelArray = modelArray;
-		        scope.modelArray = scope.$eval(attrs.sfNewArray);
-		        // validateField method is exported by schema-validate
-		        if (scope.ngModel && scope.ngModel.$pristine && scope.firstDigest && (!scope.options || scope.options.validateOnRender !== true)) {
-		          return;
-		        } else if (scope.validateField) {
-		          scope.validateField();
-		        }
-		      };
-
-		      var onChangeFn = function onChangeFn() {
-		        if (scope.form && scope.form.onChange) {
-		          if (_angular2.default.isFunction(scope.form.onChange)) {
-		            scope.form.onChange(scope.modelArray, scope.form);
-		          } else {
-		            scope.evalExpr(scope.form.onChange, { 'modelValue': scope.modelArray, form: scope.form });
-		          }
-		        }
-		      };
-
-		      // If model is undefined make sure it gets set.
-		      var getOrCreateModel = function getOrCreateModel() {
-		        var model = scope.modelArray;
-		        if (!model) {
-		          var selection = sfPath.parse(attrs.sfNewArray);
-		          model = [];
-		          sel(selection, scope, model);
-		          scope.modelArray = model;
-		        }
-		        return model;
-		      };
-
-		      // We need the form definition to make a decision on how we should listen.
-		      var once = scope.$watch('form', function (form) {
-		        if (!form) {
-		          return;
-		        }
-
-		        // Always start with one empty form unless configured otherwise.
-		        // Special case: don't do it if form has a titleMap
-		        if (!form.titleMap && form.startEmpty !== true && (!scope.modelArray || scope.modelArray.length === 0)) {
-		          scope.appendToArray();
-		        }
-
-		        // If we have "uniqueItems" set to true, we must deep watch for changes.
-		        if (scope.form && scope.form.schema && scope.form.schema.uniqueItems === true) {
-		          scope.$watch(attrs.sfNewArray, watchFn, true);
-
-		          // We still need to trigger onChange though.
-		          scope.$watch([attrs.sfNewArray, attrs.sfNewArray + '.length'], onChangeFn);
-		        } else {
-		          // Otherwise we like to check if the instance of the array has changed, or if something
-		          // has been added/removed.
-		          if (scope.$watchGroup) {
-		            scope.$watchGroup([attrs.sfNewArray, attrs.sfNewArray + '.length'], function () {
-		              watchFn();
-		              onChangeFn();
-		            });
-		          } else {
-		            // Angular 1.2 support
-		            scope.$watch(attrs.sfNewArray, function () {
-		              watchFn();
-		              onChangeFn();
-		            });
-		            scope.$watch(attrs.sfNewArray + '.length', function () {
-		              watchFn();
-		              onChangeFn();
-		            });
-		          }
-		        }
-
-		        // Title Map handling
-		        // If form has a titleMap configured we'd like to enable looping over
-		        // titleMap instead of modelArray, this is used for intance in
-		        // checkboxes. So instead of variable number of things we like to create
-		        // a array value from a subset of values in the titleMap.
-		        // The problem here is that ng-model on a checkbox doesn't really map to
-		        // a list of values. This is here to fix that.
-		        if (form.titleMap && form.titleMap.length > 0) {
-		          scope.titleMapValues = [];
-
-		          // We watch the model for changes and the titleMapValues to reflect
-		          // the modelArray
-		          var updateTitleMapValues = function updateTitleMapValues(arr) {
-		            scope.titleMapValues = [];
-		            arr = arr || [];
-
-		            form.titleMap.forEach(function (item) {
-		              scope.titleMapValues.push(arr.indexOf(item.value) !== -1);
-		            });
-		          };
-		          //Catch default values
-		          updateTitleMapValues(scope.modelArray);
-
-		          // TODO: Refactor and see if we can get rid of this watch by piggy backing on the
-		          // validation watch.
-		          scope.$watchCollection('modelArray', updateTitleMapValues);
-
-		          //To get two way binding we also watch our titleMapValues
-		          scope.$watchCollection('titleMapValues', function (vals, old) {
-		            if (vals && vals !== old) {
-		              var arr = getOrCreateModel();
-
-		              form.titleMap.forEach(function (item, index) {
-		                var arrIndex = arr.indexOf(item.value);
-		                if (arrIndex === -1 && vals[index]) {
-		                  arr.push(item.value);
-		                };
-
-		                if (arrIndex !== -1 && !vals[index]) {
-		                  arr.splice(arrIndex, 1);
-		                };
-		              });
-		              // Time to validate the rebuilt array.
-		              // validateField method is exported by schema-validate
-		              if (scope.validateField) {
-		                scope.validateField();
-		              }
-		            }
-		          });
-		        }
-
-		        once();
-		      });
-
-		      scope.appendToArray = function () {
-		        var empty;
-
-		        // Create and set an array if needed.
-		        var model = getOrCreateModel();
-
-		        // Same old add empty things to the array hack :(
-		        if (scope.form && scope.form.schema && scope.form.schema.items) {
-
-		          var items = scope.form.schema.items;
-		          if (items.type && items.type.indexOf('object') !== -1) {
-		            empty = {};
-
-		            // Check for possible defaults
-		            if (!scope.options || scope.options.setSchemaDefaults !== false) {
-		              empty = _angular2.default.isDefined(items['default']) ? items['default'] : empty;
-
-		              // Check for defaults further down in the schema.
-		              // If the default instance sets the new array item to something falsy, i.e. null
-		              // then there is no need to go further down.
-		              if (empty) {
-		                schemaForm.traverseSchema(items, function (prop, path) {
-		                  if (_angular2.default.isDefined(prop['default'])) {
-		                    sel(path, empty, prop['default']);
-		                  }
-		                });
-		              }
-		            }
-		          } else if (items.type && items.type.indexOf('array') !== -1) {
-		            empty = [];
-		            if (!scope.options || scope.options.setSchemaDefaults !== false) {
-		              empty = items['default'] || empty;
-		            }
-		          } else {
-		            // No type? could still have defaults.
-		            if (!scope.options || scope.options.setSchemaDefaults !== false) {
-		              empty = items['default'] || empty;
-		            }
-		          }
-		        }
-		        model.push(empty);
-
-		        return model;
-		      };
-
-		      scope.deleteFromArray = function (index) {
-		        var model = scope.modelArray;
-		        if (model) {
-		          model.splice(index, 1);
-		        }
-		        return model;
-		      };
-
-		      // For backwards compatability, i.e. when a bootstrap-decorator tag is used
-		      // as child to the array.
-		      var setIndex = function setIndex(index) {
-		        return function (form) {
-		          if (form.key) {
-		            form.key[form.key.indexOf('')] = index;
-		          }
-		        };
-		      };
-		      var formDefCache = {};
-		      scope.copyWithIndex = function (index) {
-		        var form = scope.form;
-		        if (!formDefCache[index]) {
-
-		          // To be more compatible with JSON Form we support an array of items
-		          // in the form definition of "array" (the schema just a value).
-		          // for the subforms code to work this means we wrap everything in a
-		          // section. Unless there is just one.
-		          var subForm = form.items[0];
-		          if (form.items.length > 1) {
-		            subForm = {
-		              type: 'section',
-		              items: form.items.map(function (item) {
-		                item.ngModelOptions = form.ngModelOptions;
-		                if (_angular2.default.isUndefined(item.readonly)) {
-		                  item.readonly = form.readonly;
-		                }
-		                return item;
-		              })
-		            };
-		          }
-
-		          if (subForm) {
-		            var copy = _angular2.default.copy(subForm);
-		            copy.arrayIndex = index;
-		            schemaForm.traverseForm(copy, setIndex(index));
-		            formDefCache[index] = copy;
-		          }
-		        }
-		        return formDefCache[index];
-		      };
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 16 */
-	/***/ function(module, exports) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function (schemaForm, sfPath) {
-		  return {
-		    scope: true,
-		    require: ['^^sfNewArray'],
-		    link: {
-		      pre: function pre(scope, element, attrs, ctrl) {
-		        var currentKey = sfPath.parse(attrs.sfParentKey);
-		        if (currentKey.length > 1) currentKey = currentKey.splice(-1);
-
-		        scope.parentKey = scope.parentKey || [];
-		        scope.parentKey = scope.parentKey.concat(currentKey, Number(attrs.sfIndex));
-
-		        scope.arrayIndex = Number(attrs.sfIndex);
-		        scope.arrayIndices = scope.arrayIndices || [];
-		        scope.arrayIndices = scope.arrayIndices.concat(scope.arrayIndex);
-		        scope.$i = scope.arrayIndices;
-		      }
-		    }
-		  };
-		};
-
-		; /**
-		   * Directive that handles keys and array indexes
-		   */
-
-	/***/ },
-	/* 17 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function ($compile, $http, $templateCache, $q, schemaForm, schemaFormDecorators, sfSelect, sfPath, sfBuilder) {
-
-		  return {
-		    scope: {
-		      schema: '=sfSchema',
-		      initialForm: '=sfForm',
-		      model: '=sfModel',
-		      options: '=sfOptions'
-		    },
-		    controller: ['$scope', function ($scope) {
-		      this.evalInParentScope = function (expr, locals) {
-		        return $scope.$parent.$eval(expr, locals);
-		      };
-
-		      // Set up form lookup map
-		      var that = this;
-		      $scope.lookup = function (lookup) {
-		        if (lookup) {
-		          that.lookup = lookup;
-		        }
-		        return that.lookup;
-		      };
-		    }],
-		    replace: false,
-		    restrict: 'A',
-		    transclude: true,
-		    require: '?form',
-		    link: function link(scope, element, attrs, formCtrl, transclude) {
-
-		      //expose form controller on scope so that we don't force authors to use name on form
-		      scope.formCtrl = formCtrl;
-
-		      //We'd like to handle existing markup,
-		      //besides using it in our template we also
-		      //check for ng-model and add that to an ignore list
-		      //i.e. even if form has a definition for it or form is ["*"]
-		      //we don't generate it.
-		      var ignore = {};
-		      transclude(scope, function (clone) {
-		        clone.addClass('schema-form-ignore');
-		        element.prepend(clone);
-
-		        if (element[0].querySelectorAll) {
-		          var models = element[0].querySelectorAll('[ng-model]');
-		          if (models) {
-		            for (var i = 0; i < models.length; i++) {
-		              var key = models[i].getAttribute('ng-model');
-		              //skip first part before .
-		              ignore[key.substring(key.indexOf('.') + 1)] = true;
-		            }
-		          }
-		        }
-		      });
-
-		      var lastDigest = {};
-		      var childScope;
-
-		      // Common renderer function, can either be triggered by a watch or by an event.
-		      var render = function render(schema, form) {
-		        var asyncTemplates = [];
-		        var merged = schemaForm.merge(schema, form, ignore, scope.options, undefined, asyncTemplates);
-
-		        if (asyncTemplates.length > 0) {
-		          // Pre load all async templates and put them on the form for the builder to use.
-		          $q.all(asyncTemplates.map(function (form) {
-		            return $http.get(form.templateUrl, { cache: $templateCache }).then(function (res) {
-		              form.template = res.data;
-		            });
-		          })).then(function () {
-		            internalRender(schema, form, merged);
-		          });
-		        } else {
-		          internalRender(schema, form, merged);
-		        };
-		      };
-
-		      var internalRender = function internalRender(schema, form, merged) {
-		        // Create a new form and destroy the old one.
-		        // Not doing keeps old form elements hanging around after
-		        // they have been removed from the DOM
-		        // https://github.com/Textalk/angular-schema-form/issues/200
-		        if (childScope) {
-		          // Destroy strategy should not be acted upon
-		          scope.externalDestructionInProgress = true;
-		          childScope.$destroy();
-		          scope.externalDestructionInProgress = false;
-		        };
-		        childScope = scope.$new();
-
-		        //make the form available to decorators
-		        childScope.schemaForm = { form: merged, schema: schema };
-
-		        //clean all but pre existing html.
-		        element.children(':not(.schema-form-ignore)').remove();
-
-		        // Find all slots.
-		        var slots = {};
-		        var slotsFound = element[0].querySelectorAll('*[sf-insert-field]');
-
-		        for (var i = 0; i < slotsFound.length; i++) {
-		          slots[slotsFound[i].getAttribute('sf-insert-field')] = slotsFound[i];
-		        }
-
-		        // if sfUseDecorator is undefined the default decorator is used.
-		        var decorator = schemaFormDecorators.decorator(attrs.sfUseDecorator);
-		        // Use the builder to build it and append the result
-		        var lookup = Object.create(null);
-		        scope.lookup(lookup); // give the new lookup to the controller.
-		        element[0].appendChild(sfBuilder.build(merged, decorator, slots, lookup));
-
-		        // We need to know if we're in the first digest looping
-		        // I.e. just rendered the form so we know not to validate
-		        // empty fields.
-		        childScope.firstDigest = true;
-		        // We use a ordinary timeout since we don't need a digest after this.
-		        setTimeout(function () {
-		          childScope.firstDigest = false;
-		        }, 0);
-
-		        //compile only children
-		        $compile(element.children())(childScope);
-
-		        //ok, now that that is done let's set any defaults
-		        if (!scope.options || scope.options.setSchemaDefaults !== false) {
-		          schemaForm.traverseSchema(schema, function (prop, path) {
-		            if (_angular2.default.isDefined(prop['default'])) {
-		              var val = sfSelect(path, scope.model);
-		              if (_angular2.default.isUndefined(val)) {
-		                sfSelect(path, scope.model, prop['default']);
-		              }
-		            }
-		          });
-		        }
-
-		        scope.$emit('sf-render-finished', element);
-		      };
-
-		      var defaultForm = ['*'];
-
-		      //Since we are dependant on up to three
-		      //attributes we'll do a common watch
-		      scope.$watch(function () {
-
-		        var schema = scope.schema;
-		        var form = scope.initialForm || defaultForm;
-
-		        //The check for schema.type is to ensure that schema is not {}
-		        if (form && schema && schema.type && (lastDigest.form !== form || lastDigest.schema !== schema) && Object.keys(schema.properties).length > 0) {
-		          lastDigest.schema = schema;
-		          lastDigest.form = form;
-
-		          render(schema, form);
-		        }
-		      });
-
-		      // We also listen to the event schemaFormRedraw so you can manually trigger a change if
-		      // part of the form or schema is chnaged without it being a new instance.
-		      scope.$on('schemaFormRedraw', function () {
-		        var schema = scope.schema;
-		        var form = scope.initialForm ? _angular2.default.copy(scope.initialForm) : ['*'];
-		        if (schema) {
-		          render(schema, form);
-		        }
-		      });
-
-		      scope.$on('$destroy', function () {
-		        // Each field listens to the $destroy event so that it can remove any value
-		        // from the model if that field is removed from the form. This is the default
-		        // destroy strategy. But if the entire form (or at least the part we're on)
-		        // gets removed, like when routing away to another page, then we definetly want to
-		        // keep the model intact. So therefore we set a flag to tell the others it's time to just
-		        // let it be.
-		        scope.externalDestructionInProgress = true;
-		      });
-
-		      /**
-		       * Evaluate an expression, i.e. scope.$eval
-		       * but do it in parent scope
-		       *
-		       * @param {String} expression
-		       * @param {Object} locals (optional)
-		       * @return {Any} the result of the expression
-		       */
-		      scope.evalExpr = function (expression, locals) {
-		        return scope.$parent.$eval(expression, locals);
-		      };
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ },
-	/* 18 */
-	/***/ function(module, exports, __webpack_require__) {
-
-		'use strict';
-
-		Object.defineProperty(exports, "__esModule", {
-		  value: true
-		});
-
-		exports.default = function (sfValidator, $parse, sfSelect) {
-
-		  return {
-		    restrict: 'A',
-		    scope: false,
-		    // We want the link function to be *after* the input directives link function so we get access
-		    // the parsed value, ex. a number instead of a string
-		    priority: 500,
-		    require: 'ngModel',
-		    link: function link(scope, element, attrs, ngModel) {
-		      // We need the ngModelController on several places,
-		      // most notably for errors.
-		      // So we emit it up to the decorator directive so it can put it on scope.
-		      scope.$emit('schemaFormPropagateNgModelController', ngModel);
-
-		      var error = null;
-		      var form = scope.$eval(attrs.schemaValidate);
-
-		      if (form.copyValueTo) {
-		        ngModel.$viewChangeListeners.push(function () {
-		          var paths = form.copyValueTo;
-		          _angular2.default.forEach(paths, function (path) {
-		            sfSelect(path, scope.model, ngModel.$modelValue);
-		          });
-		        });
-		      };
-
-		      // Validate against the schema.
-
-		      var validate = function validate(viewValue) {
-		        //console.log('validate called', viewValue)
-		        //Still might be undefined
-		        if (!form) {
-		          return viewValue;
-		        }
-
-		        // Omit TV4 validation
-		        if (scope.options && scope.options.tv4Validation === false) {
-		          return viewValue;
-		        }
-
-		        var result = sfValidator.validate(form, viewValue);
-		        //console.log('result is', result)
-		        // Since we might have different tv4 errors we must clear all
-		        // errors that start with tv4-
-		        Object.keys(ngModel.$error).filter(function (k) {
-		          return k.indexOf('tv4-') === 0;
-		        }).forEach(function (k) {
-		          ngModel.$setValidity(k, true);
-		        });
-
-		        if (!result.valid) {
-		          // it is invalid, return undefined (no model update)
-		          ngModel.$setValidity('tv4-' + result.error.code, false);
-		          error = result.error;
-
-		          // In Angular 1.3+ return the viewValue, otherwise we inadvertenly
-		          // will trigger a 'parse' error.
-		          // we will stop the model value from updating with our own $validator
-		          // later.
-		          if (ngModel.$validators) {
-		            return viewValue;
-		          }
-		          // Angular 1.2 on the other hand lacks $validators and don't add a 'parse' error.
-		          return undefined;
-		        }
-		        return viewValue;
-		      };
-
-		      // Custom validators, parsers, formatters etc
-		      if (typeof form.ngModel === 'function') {
-		        form.ngModel(ngModel);
-		      }
-
-		      ['$parsers', '$viewChangeListeners', '$formatters'].forEach(function (attr) {
-		        if (form[attr] && ngModel[attr]) {
-		          form[attr].forEach(function (fn) {
-		            ngModel[attr].push(fn);
-		          });
-		        }
-		      });
-
-		      ['$validators', '$asyncValidators'].forEach(function (attr) {
-		        // Check if our version of angular has validators, i.e. 1.3+
-		        if (form[attr] && ngModel[attr]) {
-		          _angular2.default.forEach(form[attr], function (fn, name) {
-		            ngModel[attr][name] = fn;
-		          });
-		        }
-		      });
-
-		      // Get in last of the parses so the parsed value has the correct type.
-		      // We don't use $validators since we like to set different errors depending tv4 error codes
-		      ngModel.$parsers.push(validate);
-
-		      // But we do use one custom validator in the case of Angular 1.3 to stop the model from
-		      // updating if we've found an error.
-		      if (ngModel.$validators) {
-		        ngModel.$validators.schemaForm = function () {
-		          //console.log('validators called.')
-		          // Any error and we're out of here!
-		          return !Object.keys(ngModel.$error).some(function (e) {
-		            return e !== 'schemaForm';
-		          });
-		        };
-		      }
-
-		      var schema = form.schema;
-
-		      // A bit ugly but useful.
-		      scope.validateField = function (formName) {
-		        // If we have specified a form name, and this model is not within
-		        // that form, then leave things be.
-		        if (formName != undefined && ngModel.$$parentForm.$name !== formName) {
-		          return;
-		        }
-
-		        // Special case: arrays
-		        // TODO: Can this be generalized in a way that works consistently?
-		        // Just setting the viewValue isn't enough to trigger validation
-		        // since it's the same value. This will be better when we drop
-		        // 1.2 support.
-		        if (schema && schema.type.indexOf('array') !== -1) {
-		          validate(ngModel.$modelValue);
-		        }
-
-		        // We set the viewValue to trigger parsers,
-		        // since modelValue might be empty and validating just that
-		        // might change an existing error to a "required" error message.
-		        if (ngModel.$setDirty) {
-
-		          // Angular 1.3+
-		          ngModel.$setDirty();
-		          ngModel.$setViewValue(ngModel.$viewValue);
-		          ngModel.$commitViewValue();
-
-		          // In Angular 1.3 setting undefined as a viewValue does not trigger parsers
-		          // so we need to do a special required check.
-
-		          // angulars checkbox directive isEmpty does not do the check we want.
-		          if (form.type === 'checkbox') {
-		            if (form.required && ngModel.$modelValue === undefined) {
-		              ngModel.$setValidity('tv4-302', false);
-		            }
-		          } else if (form.required && ngModel.$isEmpty(ngModel.$modelValue)) {
-		            ngModel.$setValidity('tv4-302', false);
-		          }
-		        } else {
-		          // Angular 1.2
-		          // In angular 1.2 setting a viewValue of undefined will trigger the parser.
-		          // hence required works.
-		          ngModel.$setViewValue(ngModel.$viewValue);
-		        }
-		      };
-
-		      var first = true;
-		      ngModel.$formatters.push(function (val) {
-		        // When a form first loads this will be called for each field.
-		        // we usually don't want that.
-		        if (ngModel.$pristine && first && (!scope.options || scope.options.validateOnRender !== true)) {
-		          first = false;
-		          return val;
-		        }
-		        validate(ngModel.$modelValue);
-		        return val;
-		      });
-
-		      // Listen to an event so we can validate the input on request
-		      scope.$on('schemaFormValidate', function (event, formName) {
-		        scope.validateField(formName);
-		      });
-
-		      scope.schemaError = function () {
-		        return error;
-		      };
-		    }
-		  };
-		};
-
-		var _angular = __webpack_require__(2);
-
-		var _angular2 = _interopRequireDefault(_angular);
-
-		function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
-
-	/***/ }
-	/******/ ])
-	});
-	;
-
-/***/ },
-/* 19 */
-/***/ function(module, exports) {
-
-	module.exports = angular;
-
-/***/ },
-/* 20 */
-/***/ function(module, exports) {
+__webpack_require__(18);
+module.exports = __webpack_require__(0);
 
-	module.exports = tv4;
 
 /***/ }
-/******/ ])
-});
-;
\ No newline at end of file
+/******/ ]);
\ No newline at end of file
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index 6584bc4..bb5fedb 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -1,21 +1,12 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.2
+ * @version 1.0.0-alpha.5
+ * @date Sun, 01 Jan 2017 14:14:55 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
- * Copyright (c) 2016 JSON Schema Form
+ * Copyright (c) 2014-2017 JSON Schema Form
  */
-(function webpackUniversalModuleDefinition(root, factory) {
-	if(typeof exports === 'object' && typeof module === 'object')
-		module.exports = factory();
-	else if(typeof define === 'function' && define.amd)
-		define([], factory);
-	else {
-		var a = factory();
-		for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
-	}
-})(this, function() {
-return /******/ (function(modules) { // webpackBootstrap
+/******/ (function(modules) { // webpackBootstrap
 /******/ 	// The module cache
 /******/ 	var installedModules = {};
 
@@ -28,16 +19,16 @@ return /******/ (function(modules) { // webpackBootstrap
 
 /******/ 		// Create a new module (and put it into the cache)
 /******/ 		var module = installedModules[moduleId] = {
-/******/ 			exports: {},
-/******/ 			id: moduleId,
-/******/ 			loaded: false
+/******/ 			i: moduleId,
+/******/ 			l: false,
+/******/ 			exports: {}
 /******/ 		};
 
 /******/ 		// Execute the module function
 /******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
 
 /******/ 		// Flag the module as loaded
-/******/ 		module.loaded = true;
+/******/ 		module.l = true;
 
 /******/ 		// Return the exports of the module
 /******/ 		return module.exports;
@@ -50,301 +41,365 @@ return /******/ (function(modules) { // webpackBootstrap
 /******/ 	// expose the module cache
 /******/ 	__webpack_require__.c = installedModules;
 
+/******/ 	// identity function for calling harmory imports with the correct context
+/******/ 	__webpack_require__.i = function(value) { return value; };
+
+/******/ 	// define getter function for harmory exports
+/******/ 	__webpack_require__.d = function(exports, name, getter) {
+/******/ 		Object.defineProperty(exports, name, {
+/******/ 			configurable: false,
+/******/ 			enumerable: true,
+/******/ 			get: getter
+/******/ 		});
+/******/ 	};
+
+/******/ 	// getDefaultExport function for compatibility with non-harmony modules
+/******/ 	__webpack_require__.n = function(module) {
+/******/ 		var getter = module && module.__esModule ?
+/******/ 			function getDefault() { return module['default']; } :
+/******/ 			function getModuleExports() { return module; };
+/******/ 		__webpack_require__.d(getter, 'a', getter);
+/******/ 		return getter;
+/******/ 	};
+
+/******/ 	// Object.prototype.hasOwnProperty.call
+/******/ 	__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
+
 /******/ 	// __webpack_public_path__
 /******/ 	__webpack_require__.p = "";
 
 /******/ 	// Load entry module and return exports
-/******/ 	return __webpack_require__(0);
+/******/ 	return __webpack_require__(__webpack_require__.s = 19);
 /******/ })
 /************************************************************************/
 /******/ ([
 /* 0 */
 /***/ function(module, exports, __webpack_require__) {
 
-	'use strict';
+__webpack_require__(17);
 
-	__webpack_require__(1);
 
 /***/ },
 /* 1 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ function(module, exports) {
 
-	'use strict';
-
-	// angular-templatecache-loader
-	var textareaTemplate = __webpack_require__(17);
-	var fieldsetTemplate = __webpack_require__(7);
-	var arrayTemplate = __webpack_require__(3);
-	var tabarrayTemplate = __webpack_require__(15);
-	var tabsTemplate = __webpack_require__(16);
-	var sectionTemplate = __webpack_require__(12);
-	var actionsTemplate = __webpack_require__(2);
-	var selectTemplate = __webpack_require__(13);
-	var checkboxTemplate = __webpack_require__(4);
-	var checkboxesTemplate = __webpack_require__(5);
-	var submitTemplate = __webpack_require__(14);
-	var radiosTemplate = __webpack_require__(11);
-	var radiosInlineTemplate = __webpack_require__(10);
-	var radiobuttonsTemplate = __webpack_require__(9);
-	var helpTemplate = __webpack_require__(8);
-	var defaultTemplate = __webpack_require__(6);
-
-	angular.module('schemaForm').config(bootstrapDecoratorConfig).filter('sfCamelKey', sfCamelKeyFilter);
-
-	bootstrapDecoratorConfig.$inject = ['schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'];
-
-	function bootstrapDecoratorConfig(schemaFormProvider, decoratorsProvider, sfBuilderProvider, sfPathProvider, $injector) {
-	  var base = 'decorators/bootstrap/';
-
-	  var simpleTransclusion = sfBuilderProvider.builders.simpleTransclusion;
-	  var ngModelOptions = sfBuilderProvider.builders.ngModelOptions;
-	  var ngModel = sfBuilderProvider.builders.ngModel;
-	  var sfField = sfBuilderProvider.builders.sfField;
-	  var condition = sfBuilderProvider.builders.condition;
-	  var array = sfBuilderProvider.builders.array;
-	  var numeric = sfBuilderProvider.builders.numeric;
-
-	  // Tabs is so bootstrap specific that it stays here.
-	  var tabs = function tabs(args) {
-	    if (args.form.tabs && args.form.tabs.length > 0) {
-	      var tabContent = args.fieldFrag.querySelector('.tab-content');
-
-	      args.form.tabs.forEach(function (tab, index) {
-	        var evalExpr = '(evalExpr(' + args.path + '.tabs[' + index + ']' + '.condition, { model: model, "arrayIndex": $index}))';
-	        var div = document.createElement('div');
-	        div.className = 'tab-pane';
-	        div.setAttribute('ng-disabled', 'form.readonly');
-	        div.setAttribute('ng-show', 'selected.tab === ' + index);
-	        div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
-	        if (!!tab.condition) {
-	          div.setAttribute('ng-if', evalExpr);
-	        };
-
-	        var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
-	        div.appendChild(childFrag);
-	        tabContent.appendChild(div);
-	      });
-	    }
-	  };
-
-	  var selectPlaceholder = function selectPlaceholder(args) {
-	    if (args.form.placeholder) {
-	      var selectBox = args.fieldFrag.querySelector('select');
-	      var option = document.createElement('option');
-	      option.setAttribute('value', '');
-
-	      /* We only want the placeholder to show when we do not have a value on the model.
-	       * We make ngModel builder replace all so we can use $$value$$.
-	       */
-	      option.setAttribute('sf-field-model', 'replaceAll');
-
-	      /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
-	       * angular > 1.4 does a emptyOption.attr('selected', true)
-	       * which does not like the ng-if comment.
-	       */
-	      if (angular.version.major === 1 && angular.version.minor < 4) {
-	        option.setAttribute('ng-if', '$$value$$ === undefined');
-	      } else {
-	        option.setAttribute('ng-show', '$$value$$ === undefined');
-	      }
-
-	      option.textContent = args.form.placeholder;
-
-	      selectBox.appendChild(option);
-	    }
-	  };
-
-	  var defaults = [sfField, ngModel, ngModelOptions, condition];
-	  decoratorsProvider.defineDecorator('bootstrapDecorator', {
-	    actions: { template: actionsTemplate, builder: defaults },
-	    array: { template: arrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
-	    button: { template: submitTemplate, builder: defaults },
-	    checkbox: { template: checkboxTemplate, builder: defaults },
-	    checkboxes: { template: checkboxesTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
-	    conditional: { template: sectionTemplate, builder: [sfField, simpleTransclusion, condition] },
-	    'default': { template: defaultTemplate, builder: defaults },
-	    fieldset: { template: fieldsetTemplate, builder: [sfField, simpleTransclusion, condition] },
-	    help: { template: helpTemplate, builder: defaults },
-	    number: { template: defaultTemplate, builder: defaults.concat(numeric) },
-	    password: { template: defaultTemplate, builder: defaults },
-	    radios: { template: radiosTemplate, builder: defaults },
-	    'radios-inline': { template: radiosInlineTemplate, builder: defaults },
-	    radiobuttons: { template: radiobuttonsTemplate, builder: defaults },
-	    section: { template: sectionTemplate, builder: [sfField, simpleTransclusion, condition] },
-	    select: { template: selectTemplate, builder: defaults.concat(selectPlaceholder) },
-	    submit: { template: submitTemplate, builder: defaults },
-	    tabarray: { template: tabarrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition] },
-	    tabs: { template: tabsTemplate, builder: [sfField, ngModelOptions, tabs, condition] },
-	    textarea: { template: textareaTemplate, builder: defaults }
-	  }, []);
-	};
-
-	/**
-	 * sfCamelKey Filter
-	 */
-	function sfCamelKeyFilter() {
-	  return function (formKey) {
-	    if (!formKey) {
-	      return '';
-	    };
-	    var part, i, key;
-	    key = formKey.slice();
-	    for (i = 0; i < key.length; i++) {
-	      part = key[i].toLowerCase().split('');
-	      if (i && part.length) {
-	        part[0] = part[0].toUpperCase();
-	      };
-	      key[i] = part.join('');
-	    };
-	    return key.join('');
-	  };
-	};
+var path = '/bootstrap/actions.html';
+var html = "<div class=\"btn-group schema-form-actions {{::form.htmlClass + ' ' + idClass}}\">\r\n  <input ng-repeat-start=\"item in form.items\"\r\n         type=\"submit\"\r\n         class=\"btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}\"\r\n         value=\"{{item.title}}\"\r\n         ng-if=\"item.type === 'submit'\">\r\n  <button ng-repeat-end\r\n          class=\"btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}\"\r\n          type=\"button\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"item.type !== 'submit'\"\r\n          ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 2 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/actions.html';
-	var html = "<div class=\"btn-group schema-form-actions {{::form.htmlClass}}\">\r\n  <input ng-repeat-start=\"item in form.items\"\r\n         type=\"submit\"\r\n         class=\"btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}\"\r\n         value=\"{{item.title}}\"\r\n         ng-if=\"item.type === 'submit'\">\r\n  <button ng-repeat-end\r\n          class=\"btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}\"\r\n          type=\"button\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"item.type !== 'submit'\"\r\n          ng-click=\"buttonClick($event,item)\"><span ng-if=\"item.icon\" class=\"{{item.icon}}\"></span>{{item.title}}</button>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/array.html';
+var html = "<div  class=\"schema-form-array {{::form.htmlClass + ' ' + idClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $index\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 3 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/array.html';
-	var html = "<div  class=\"schema-form-array {{::form.htmlClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $index\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/checkbox.html';
+var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{::fieldId(true, false)}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 4 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/checkbox.html';
-	var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{::fieldId(true, false)}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/checkboxes.html';
+var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 5 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/checkboxes.html';
-	var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/default.html';
+var html = "<div class=\"form-group {{::form.htmlClass + ' schema-form-' + form.type + ' ' + idClass}}\"\r\n     ng-class=\"{ 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{::fieldId(true, false)}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{::fieldId(true, false)}}\"\r\n         aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{::fieldId(true, false)}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{::fieldId(true, false)}}\"\r\n           aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{::fieldId(true, true) + '-status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 6 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/default.html';
-	var html = "<div class=\"form-group {{::form.htmlClass}}\"\r\n     ng-class=\"{ '{{'schema-form-' + form.type}}': true, 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{::fieldId(true, false)}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{::fieldId(true, false)}}\"\r\n         aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{::fieldId(true, false)}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{::fieldId(true, false)}}\"\r\n           aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{::fieldId(true, true) + '-status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/fieldset.html';
+var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass + ' ' + idClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 7 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/fieldset.html';
-	var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/help.html';
+var html = "<div class=\"helpvalue schema-form-helpvalue {{::form.htmlClass + ' ' + idClass}}\" ng-bind-html=\"form.helpvalue\"></div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 8 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/help.html';
-	var html = "<div class=\"helpvalue schema-form-helpvalue {{::form.htmlClass}}\" ng-bind-html=\"form.helpvalue\"></div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/radio-buttons.html';
+var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (tm.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: tm.value === $$value$$ }\"\r\n           ng-repeat=\"tm in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 9 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/radio-buttons.html';
-	var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (tm.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: tm.value === $$value$$ }\"\r\n           ng-repeat=\"tm in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/radios-inline.html';
+var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"tm in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 10 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/radios-inline.html';
-	var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"tm in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/radios.html';
+var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass + ' ' + idClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"tm in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 11 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/radios.html';
-	var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"tm in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/section.html';
+var html = "<div class=\"schema-form-section {{::form.htmlClass + ' ' + idClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 12 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/section.html';
-	var html = "<div class=\"schema-form-section {{::form.htmlClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/select.html';
+var html = "<div class=\"form-group {{::form.htmlClass + ' ' + idClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\" for=\"{{::fieldId(true, false)}}\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id=\"{{::fieldId(true, false)}}\"\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{::fieldId(true, false)}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 13 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/select.html';
-	var html = "<div class=\"form-group {{::form.htmlClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\" for=\"{{::fieldId(true, false)}}\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id=\"{{::fieldId(true, false)}}\"\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{::fieldId(true, false)}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/submit.html';
+var html = "<div class=\"form-group schema-form-submit {{::form.htmlClass + ' ' + idClass}}\">\r\n  <input type=\"submit\"\r\n         class=\"btn {{ form.style || 'btn-primary' }} {{::form.fieldHtmlClass}}\"\r\n         value=\"{{form.title}}\"\r\n         ng-disabled=\"form.readonly\"\r\n         ng-if=\"form.type === 'submit'\">\r\n  <button class=\"btn {{ form.style || 'btn-default' }}\"\r\n          type=\"button\"\r\n          ng-click=\"buttonClick($event,form)\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"form.type !== 'submit'\">\r\n      <span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 14 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/submit.html';
-	var html = "<div class=\"form-group schema-form-submit {{::form.htmlClass}}\">\r\n  <input type=\"submit\"\r\n         class=\"btn {{ form.style || 'btn-primary' }} {{::form.fieldHtmlClass}}\"\r\n         value=\"{{form.title}}\"\r\n         ng-disabled=\"form.readonly\"\r\n         ng-if=\"form.type === 'submit'\">\r\n  <button class=\"btn {{ form.style || 'btn-default' }}\"\r\n          type=\"button\"\r\n          ng-click=\"buttonClick($event,form)\"\r\n          ng-disabled=\"form.readonly\"\r\n          ng-if=\"form.type !== 'submit'\">\r\n      <span ng-if=\"form.icon\" class=\"{{form.icon}}\"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/tabarray.html';
+var html = "<div ng-init=\"selected = { tab: 0 }\"\r\n     ng-model=\"modelArray\" schema-validate=\"form\"\r\n     sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{::form.htmlClass + ' ' + idClass}}\">\r\n  <div ng-if=\"!form.tabType || form.tabType !== 'right'\"\r\n       ng-class=\"{'col-xs-3': !form.tabType || form.tabType === 'left'}\">\r\n    <ol class=\"nav nav-tabs\"\r\n        ng-class=\"{ 'tabs-left': !form.tabType || form.tabType === 'left'}\"\r\n        sf-field-model ui-sortable=\"form.sortOptions\">\r\n      <li sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class=\"{'col-xs-9': !form.tabType || form.tabType === 'left' || form.tabType === 'right'}\">\r\n    <div class=\"tab-content {{::form.fieldHtmlClass}}\">\r\n      <div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\"\r\n           sf-field-model=\"ng-repeat\"\r\n           ng-repeat=\"item in $$value$$ track by $index\"\r\n           ng-show=\"selected.tab === $index\"\r\n           ng-class=\"{active: selected.tab === $index}\">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n\r\n           <button ng-hide=\"form.readonly || form.remove === null\"\r\n                   ng-click=\"selected.tab = deleteFromArray($index).length - 1\"\r\n                   ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n                   type=\"button\"\r\n                   class=\"btn {{ form.style.remove || 'btn-default' }} pull-right\">\r\n             <i class=\"glyphicon glyphicon-trash\"></i>\r\n             {{ form.remove || 'Remove'}}\r\n           </button>\r\n      </div>\r\n      <div class=\"help-block\"\r\n           ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n           ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if=\"form.tabType === 'right'\" class=\"col-xs-3\">\r\n    <ul class=\"nav nav-tabs tabs-right\">\r\n      <li  sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 15 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/tabarray.html';
-	var html = "<div ng-init=\"selected = { tab: 0 }\"\r\n     ng-model=\"modelArray\" schema-validate=\"form\"\r\n     sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{::form.htmlClass}}\">\r\n  <div ng-if=\"!form.tabType || form.tabType !== 'right'\"\r\n       ng-class=\"{'col-xs-3': !form.tabType || form.tabType === 'left'}\">\r\n    <ol class=\"nav nav-tabs\"\r\n        ng-class=\"{ 'tabs-left': !form.tabType || form.tabType === 'left'}\"\r\n        sf-field-model ui-sortable=\"form.sortOptions\">\r\n      <li sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class=\"{'col-xs-9': !form.tabType || form.tabType === 'left' || form.tabType === 'right'}\">\r\n    <div class=\"tab-content {{::form.fieldHtmlClass}}\">\r\n      <div class=\"tab-pane clearfix tab{{selected.tab}} index{{$index}}\"\r\n           sf-field-model=\"ng-repeat\"\r\n           ng-repeat=\"item in $$value$$ track by $index\"\r\n           ng-show=\"selected.tab === $index\"\r\n           ng-class=\"{active: selected.tab === $index}\">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n\r\n           <button ng-hide=\"form.readonly || form.remove === null\"\r\n                   ng-click=\"selected.tab = deleteFromArray($index).length - 1\"\r\n                   ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n                   type=\"button\"\r\n                   class=\"btn {{ form.style.remove || 'btn-default' }} pull-right\">\r\n             <i class=\"glyphicon glyphicon-trash\"></i>\r\n             {{ form.remove || 'Remove'}}\r\n           </button>\r\n      </div>\r\n      <div class=\"help-block\"\r\n           ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n           ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if=\"form.tabType === 'right'\" class=\"col-xs-3\">\r\n    <ul class=\"nav nav-tabs tabs-right\">\r\n      <li  sf-field-model=\"ng-repeat\"\r\n          ng-repeat=\"item in $$value$$ track by $index\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n          ng-class=\"{active: selected.tab === $index}\">\r\n          <a href=\"#\">{{interp(form.title,{'$index':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide=\"form.readonly || form.add === null\"\r\n          ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n          ng-click=\"$event.preventDefault() || (selected.tab = appendToArray().length - 1)\">\r\n        <a href=\"#\">\r\n          <i class=\"glyphicon glyphicon-plus\"></i>\r\n          {{ form.add || 'Add'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/tabs.html';
+var html = "<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{::form.htmlClass + ' ' + idClass}}\">\r\n  <ul class=\"nav nav-tabs\">\r\n    <li ng-repeat=\"tab in form.tabs\"\r\n        ng-disabled=\"form.readonly\"\r\n        ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n        ng-class=\"{active: selected.tab === $index}\">\r\n        <a href=\"#\">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class=\"tab-content {{::form.fieldHtmlClass}}\">\r\n  </div>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 16 */
 /***/ function(module, exports) {
 
-	var path = 'bootstrap/tabs.html';
-	var html = "<div ng-init=\"selected = { tab: 0 }\" class=\"schema-form-tabs {{::form.htmlClass}}\">\r\n  <ul class=\"nav nav-tabs\">\r\n    <li ng-repeat=\"tab in form.tabs\"\r\n        ng-disabled=\"form.readonly\"\r\n        ng-click=\"$event.preventDefault() || (selected.tab = $index)\"\r\n        ng-class=\"{active: selected.tab === $index}\">\r\n        <a href=\"#\">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class=\"tab-content {{::form.fieldHtmlClass}}\">\r\n  </div>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
+var path = '/bootstrap/textarea.html';
+var html = "<div class=\"form-group has-feedback {{::form.htmlClass + ' ' + idClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{::fieldId(true, false)}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{::fieldId(true, false)}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{::fieldId(true, false)}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{::fieldId(true, false)}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
+window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
+module.exports = path;
 
 /***/ },
 /* 17 */
-/***/ function(module, exports) {
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html__ = __webpack_require__(16);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html__ = __webpack_require__(6);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html__ = __webpack_require__(2);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html__ = __webpack_require__(14);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html__ = __webpack_require__(15);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html__ = __webpack_require__(11);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html__ = __webpack_require__(1);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html__ = __webpack_require__(12);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html__ = __webpack_require__(3);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html__ = __webpack_require__(4);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html__ = __webpack_require__(13);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html__ = __webpack_require__(10);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html__ = __webpack_require__(9);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html__ = __webpack_require__(8);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html__ = __webpack_require__(7);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html__ = __webpack_require__(5);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html__);
+// angular-templatecache-loader
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+angular
+  .module('schemaForm')
+  .config(bootstrapDecoratorConfig)
+  .filter('sfCamelKey', sfCamelKeyFilter);
+
+bootstrapDecoratorConfig.$inject = [
+  'schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'
+];
+
+function bootstrapDecoratorConfig(
+    schemaFormProvider, decoratorsProvider, sfBuilderProvider, sfPathProvider, $injector) {
+  var base = 'decorators/bootstrap/';
+
+  var simpleTransclusion  = sfBuilderProvider.builders.simpleTransclusion;
+  var ngModelOptions      = sfBuilderProvider.builders.ngModelOptions;
+  var ngModel             = sfBuilderProvider.builders.ngModel;
+  var sfField             = sfBuilderProvider.builders.sfField;
+  var condition           = sfBuilderProvider.builders.condition;
+  var array               = sfBuilderProvider.builders.array;
+  var numeric             = sfBuilderProvider.builders.numeric;
+
+  // Tabs is so bootstrap specific that it stays here.
+  var tabs = function(args) {
+    if (args.form.tabs && args.form.tabs.length > 0) {
+      var tabContent = args.fieldFrag.querySelector('.tab-content');
+
+      args.form.tabs.forEach(function(tab, index) {
+        var evalExpr = '(evalExpr(' + args.path + '.tabs[' + index + ']' +
+                       '.condition, { model: model, "arrayIndex": $index}))';
+        var div = document.createElement('div');
+        div.className = 'tab-pane';
+        div.setAttribute('ng-disabled', 'form.readonly');
+        div.setAttribute('ng-show', 'selected.tab === ' + index);
+        div.setAttribute('ng-class', '{active: selected.tab === ' + index + '}');
+        if(!!tab.condition) {
+          div.setAttribute('ng-if', evalExpr);
+        };
+
+        var childFrag = args.build(tab.items, args.path + '.tabs[' + index + '].items', args.state);
+        div.appendChild(childFrag);
+        tabContent.appendChild(div);
+      });
+    }
+  };
+
+  var selectPlaceholder = function(args) {
+    if (args.form.placeholder) {
+      var selectBox = args.fieldFrag.querySelector('select');
+      var option = document.createElement('option');
+      option.setAttribute('value', '');
+
+      /* We only want the placeholder to show when we do not have a value on the model.
+       * We make ngModel builder replace all so we can use $$value$$.
+       */
+      option.setAttribute('sf-field-model', 'replaceAll');
+
+      /* https://github.com/angular/angular.js/issues/12190#issuecomment-115277040
+       * angular > 1.4 does a emptyOption.attr('selected', true)
+       * which does not like the ng-if comment.
+       */
+      if (angular.version.major === 1 && angular.version.minor < 4) {
+        option.setAttribute('ng-if', '$$value$$ === undefined');
+      } else {
+        option.setAttribute('ng-show', '$$value$$ === undefined');
+      }
+
+      option.textContent = args.form.placeholder;
+
+      selectBox.appendChild(option);
+    }
+  };
+
+  var defaults = [sfField, ngModel, ngModelOptions, condition];
+  decoratorsProvider.defineDecorator('bootstrapDecorator', {
+    actions: {template: __WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html___default.a, builder: defaults},
+    array: {template: __WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    button: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html___default.a, builder: defaults},
+    checkbox: {template: __WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html___default.a, builder: defaults},
+    checkboxes: {template: __WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    conditional: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    'default': {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default.a, builder: defaults},
+    fieldset: {template: __WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    help: {template: __WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html___default.a, builder: defaults},
+    number: {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default.a, builder: defaults.concat(numeric)},
+    password: {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default.a, builder: defaults},
+    radios: {template: __WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html___default.a, builder: defaults},
+    'radios-inline': {template: __WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html___default.a, builder: defaults},
+    radiobuttons: {template: __WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html___default.a, builder: defaults},
+    section: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    select: {template: __WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html___default.a, builder: defaults.concat(selectPlaceholder)},
+    submit: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html___default.a, builder: defaults},
+    tabarray: {template: __WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    tabs: {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html___default.a, builder: [sfField, ngModelOptions, tabs, condition]},
+    textarea: {template: __WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html___default.a, builder: defaults},
+  }, []);
+};
+
+/**
+ * sfCamelKey Filter
+ */
+function sfCamelKeyFilter() {
+  return function(formKey) {
+    if (!formKey) { return ''; };
+    var part, i, key;
+    key = formKey.slice();
+    for (i = 0; i < key.length; i++) {
+      part = key[i].toLowerCase().split('');
+      if (i && part.length) { part[0] = part[0].toUpperCase(); };
+      key[i] = part.join('');
+    };
+    return key.join('');
+  };
+};
+
+
+/***/ },
+/* 18 */,
+/* 19 */
+/***/ function(module, exports, __webpack_require__) {
+
+module.exports = __webpack_require__(0);
 
-	var path = 'bootstrap/textarea.html';
-	var html = "<div class=\"form-group has-feedback {{::form.htmlClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{::fieldId(true, false)}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{::fieldId(true, false)}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{::fieldId(true, false)}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{::fieldId(true, false)}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
-	window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
-	module.exports = path;
 
 /***/ }
-/******/ ])
-});
-;
\ No newline at end of file
+/******/ ]);
\ No newline at end of file
diff --git a/examples/data/array-deep.json b/examples/data/array-deep.json
index 1dd2a72..d8f7843 100644
--- a/examples/data/array-deep.json
+++ b/examples/data/array-deep.json
@@ -56,6 +56,12 @@
   "form": [
     {
       "key": "transportCategory",
+      "type": "tabarray",
+      "add": "New",
+      "style": {
+        "add": "btn-success"
+      },
+      "title": "{{ 'Tab '+$index + ' ' + value.mode + ' ' || 'Tab' + $index }}",
       "items": [
         "transportCategory[].mode",
         {
diff --git a/examples/bootstrap-example.html b/examples/example.html
similarity index 99%
rename from examples/bootstrap-example.html
rename to examples/example.html
index 1ded14e..79aac94 100644
--- a/examples/bootstrap-example.html
+++ b/examples/example.html
@@ -241,10 +241,12 @@ <h3>Schema</h3>
 
   $scope.tests = [
     { name: "Simple", data: 'data/simple.json' },
+    { name: "Simple oneOf", data: 'data/simple-oneOf.json' },
     { name: "Basic JSON Schema Type", data: 'data/types.json' },
     { name: "Bootstrap Grid", data: 'data/grid.json' },
     { name: "Complex Key Support", data: 'data/complex-keys.json' },
     { name: "Array", data: 'data/array.json' },
+    { name: "Deep Array", data: 'data/array-deep.json' },
     { name: "Tab Array", data: 'data/tabarray.json' },
     { name: "TitleMap Examples", data: 'data/titlemaps.json' },
     { name: "Kitchen Sink", data: 'data/sink.json' },
diff --git a/npm-debug.log b/npm-debug.log
deleted file mode 100644
index b1668bc..0000000
--- a/npm-debug.log
+++ /dev/null
@@ -1,48 +0,0 @@
-0 info it worked if it ends with ok
-1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe',
-1 verbose cli   'C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js',
-1 verbose cli   'run',
-1 verbose cli   'dist' ]
-2 info using npm@3.8.3
-3 info using node@v5.10.1
-4 verbose run-script [ 'predist', 'dist', 'postdist' ]
-5 info lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~predist: angular-schema-form-bootstrap@1.0.0-alpha.1
-6 silly lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~predist: no script for predist, continuing
-7 info lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: angular-schema-form-bootstrap@1.0.0-alpha.1
-8 verbose lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: unsafe-perm in lifecycle true
-9 verbose lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: PATH: C:\Program Files\nodejs\node_modules\npm\bin\node-gyp-bin;C:\Users\Marcel\Documents\SERIOUS\git\angular-schema-form-bootstrap\node_modules\.bin;C:\Program Files\nodejs;C:\Program Files\ConEmu\ConEmu\Scripts;C:\Program Files\ConEmu\ConEmu\Scripts;C:\Program Files\ConEmu;C:\Program Files\ConEmu\ConEmu;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;c:\Program Files (x86)\Intel\iCLS Client\;c:\Program Files\Intel\iCLS Client\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\Program Files (x86)\Windows Live\Shared;C:\Program Files\NpackdCL-1;C:\Program Files\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\DAL;C:\Program Files (x86)\Intel\Intel(R) Management Engine Components\IPT;C:\Program Files\MSysGit\bin;C:\Program Files\TortoiseGit_64_bit\bin;C:\Program Files\TortoiseHg_64_bit\;C:\Program Files\Microsoft\Web Platform Installer\;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommon\;C:\Program Files\nodejs\;C:\Users\Marcel\AppData\Local\atom\bin;C:\Users\Marcel\AppData\Roaming\npm
-10 verbose lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: CWD: C:\Users\Marcel\Documents\SERIOUS\git\angular-schema-form-bootstrap
-11 silly lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: Args: [ '/d /s /c', 'npm run build && npm run minify' ]
-12 silly lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: Returned: code: 1  signal: null
-13 info lifecycle angular-schema-form-bootstrap@1.0.0-alpha.1~dist: Failed to exec dist script
-14 verbose stack Error: angular-schema-form-bootstrap@1.0.0-alpha.1 dist: `npm run build && npm run minify`
-14 verbose stack Exit status 1
-14 verbose stack     at EventEmitter.<anonymous> (C:\Program Files\nodejs\node_modules\npm\lib\utils\lifecycle.js:239:16)
-14 verbose stack     at emitTwo (events.js:100:13)
-14 verbose stack     at EventEmitter.emit (events.js:185:7)
-14 verbose stack     at ChildProcess.<anonymous> (C:\Program Files\nodejs\node_modules\npm\lib\utils\spawn.js:24:14)
-14 verbose stack     at emitTwo (events.js:100:13)
-14 verbose stack     at ChildProcess.emit (events.js:185:7)
-14 verbose stack     at maybeClose (internal/child_process.js:850:16)
-14 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:215:5)
-15 verbose pkgid angular-schema-form-bootstrap@1.0.0-alpha.1
-16 verbose cwd C:\Users\Marcel\Documents\SERIOUS\git\angular-schema-form-bootstrap
-17 error Windows_NT 10.0.10586
-18 error argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\bin\\npm-cli.js" "run" "dist"
-19 error node v5.10.1
-20 error npm  v3.8.3
-21 error code ELIFECYCLE
-22 error angular-schema-form-bootstrap@1.0.0-alpha.1 dist: `npm run build && npm run minify`
-22 error Exit status 1
-23 error Failed at the angular-schema-form-bootstrap@1.0.0-alpha.1 dist script 'npm run build && npm run minify'.
-23 error Make sure you have the latest version of node.js and npm installed.
-23 error If you do, this is most likely a problem with the angular-schema-form-bootstrap package,
-23 error not with npm itself.
-23 error Tell the author that this fails on your system:
-23 error     npm run build && npm run minify
-23 error You can get information on how to open an issue for this project with:
-23 error     npm bugs angular-schema-form-bootstrap
-23 error Or if that isn't available, you can get their info via:
-23 error     npm owner ls angular-schema-form-bootstrap
-23 error There is likely additional logging output above.
-24 verbose exit [ 1, true ]
diff --git a/package.json b/package.json
index 6e28097..eb95dac 100644
--- a/package.json
+++ b/package.json
@@ -1,15 +1,14 @@
 {
   "name": "angular-schema-form-bootstrap",
-  "version": "1.0.0-alpha.2",
+  "version": "1.0.0-alpha.5",
   "description": "Bootstrap 3 decorator for Angular Schema Form",
   "main": "dist/bootstrap-decorator.js",
   "scripts": {
-    "dist": "npm run build && npm run minify",
     "build": "webpack",
+    "dist": "webpack --config webpack.config.dist.js",
     "watch": "webpack --watch",
-    "minify": "uglifyjs dist/angular-schema-form-bootstrap.js --comments --output=dist/angular-schema-form-bootstrap.min.js && uglifyjs dist/angular-schema-form-bootstrap-bundled.js --comments --output=dist/angular-schema-form-bootstrap-bundled.min.js",
-    "test": "echo \"Error: no test specified\" && exit 1",
-    "test-not-yet-done": "karma start --single-run --browsers PhantomJS karma.conf.js --log-level info"
+    "test": "echo \"Error: test not currently available\" && exit 1",
+    "test-me": "karma start --log-level debug"
   },
   "keywords": [
     "angular-schema-form-decorator"
@@ -24,7 +23,6 @@
     "angular": ">= 1.2",
     "angular-messages": "^1.5.0",
     "angular-sanitize": ">= 1.2",
-    "angular-schema-form": "git://github.com/json-schema-form/angular-schema-form.git#feature/webpack-babel",
     "tv4": "~1.0.15"
   },
   "devDependencies": {
@@ -35,16 +33,6 @@
     "babel-preset-es2015": "^6.16.0",
     "chai": "^3.5.0",
     "coveralls": "^2.11.0",
-    "gulp": "^3.9.0",
-    "gulp-angular-templatecache": "^1.6.0",
-    "gulp-concat": "^2.5.2",
-    "gulp-jscs": "^3.0.2",
-    "gulp-minify-html": "^1.0.2",
-    "gulp-protractor": "^3.0.0",
-    "gulp-rename": "^1.2.2",
-    "gulp-uglify": "^1.2.0",
-    "gulp-watch": "^4.2.4",
-    "gulp-webserver": "^0.9.1",
     "html": "^1.0.0",
     "html-loader": "^0.4.4",
     "html-webpack-plugin": "^2.22.0",
@@ -64,7 +52,7 @@
     "sinon-chai": "^2.8.0",
     "streamqueue": "^0.1.3",
     "uglify-js": "^2.6.2",
-    "webpack": "^1.13.1",
-    "webpack-dev-server": "^1.14.1"
+    "webpack": "^2.1.0-beta.27",
+    "webpack-dev-server": "^2.1.0-beta.12"
   }
 }
diff --git a/src/bootstrap-decorator.js b/src/bootstrap-decorator.js
index c9f49ad..fb75a1a 100644
--- a/src/bootstrap-decorator.js
+++ b/src/bootstrap-decorator.js
@@ -1,20 +1,20 @@
 // angular-templatecache-loader
-let textareaTemplate = require('./bootstrap/textarea.html');
-let fieldsetTemplate = require('./bootstrap/fieldset.html');
-let arrayTemplate = require('./bootstrap/array.html');
-let tabarrayTemplate = require('./bootstrap/tabarray.html');
-let tabsTemplate = require('./bootstrap/tabs.html');
-let sectionTemplate = require('./bootstrap/section.html');
-let actionsTemplate = require('./bootstrap/actions.html');
-let selectTemplate = require('./bootstrap/select.html');
-let checkboxTemplate = require('./bootstrap/checkbox.html');
-let checkboxesTemplate = require('./bootstrap/checkboxes.html');
-let submitTemplate = require('./bootstrap/submit.html');
-let radiosTemplate = require('./bootstrap/radios.html');
-let radiosInlineTemplate = require('./bootstrap/radios-inline.html');
-let radiobuttonsTemplate = require('./bootstrap/radio-buttons.html');
-let helpTemplate = require('./bootstrap/help.html');
-let defaultTemplate = require('./bootstrap/default.html');
+import textareaTemplate from './bootstrap/textarea.html';
+import fieldsetTemplate from './bootstrap/fieldset.html';
+import arrayTemplate from './bootstrap/array.html';
+import tabarrayTemplate from './bootstrap/tabarray.html';
+import tabsTemplate from './bootstrap/tabs.html';
+import sectionTemplate from './bootstrap/section.html';
+import actionsTemplate from './bootstrap/actions.html';
+import selectTemplate from './bootstrap/select.html';
+import checkboxTemplate from './bootstrap/checkbox.html';
+import checkboxesTemplate from './bootstrap/checkboxes.html';
+import submitTemplate from './bootstrap/submit.html';
+import radiosTemplate from './bootstrap/radios.html';
+import radiosInlineTemplate from './bootstrap/radios-inline.html';
+import radiobuttonsTemplate from './bootstrap/radio-buttons.html';
+import helpTemplate from './bootstrap/help.html';
+import defaultTemplate from './bootstrap/default.html';
 
 angular
   .module('schemaForm')
diff --git a/src/bootstrap/actions-trcl.html b/src/bootstrap/actions-trcl.html
index de33f95..f4307df 100644
--- a/src/bootstrap/actions-trcl.html
+++ b/src/bootstrap/actions-trcl.html
@@ -1 +1 @@
-<div class="btn-group schema-form-actions {{::form.htmlClass}}" ng-transclude></div>
+<div class="btn-group schema-form-actions {{::form.htmlClass + ' ' + idClass}}" ng-transclude></div>
diff --git a/src/bootstrap/actions.html b/src/bootstrap/actions.html
index db0a9f3..582455b 100644
--- a/src/bootstrap/actions.html
+++ b/src/bootstrap/actions.html
@@ -1,4 +1,4 @@
-<div class="btn-group schema-form-actions {{::form.htmlClass}}">
+<div class="btn-group schema-form-actions {{::form.htmlClass + ' ' + idClass}}">
   <input ng-repeat-start="item in form.items"
          type="submit"
          class="btn {{ item.style || 'btn-default' }} {{::form.fieldHtmlClass}}"
diff --git a/src/bootstrap/array.html b/src/bootstrap/array.html
index 5d632fc..7e05004 100644
--- a/src/bootstrap/array.html
+++ b/src/bootstrap/array.html
@@ -1,4 +1,4 @@
-<div  class="schema-form-array {{::form.htmlClass}}"
+<div  class="schema-form-array {{::form.htmlClass + ' ' + idClass}}"
       sf-field-model="sf-new-array"
       sf-new-array>
   <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>
diff --git a/src/bootstrap/checkbox.html b/src/bootstrap/checkbox.html
index b37fb09..4e71876 100644
--- a/src/bootstrap/checkbox.html
+++ b/src/bootstrap/checkbox.html
@@ -1,4 +1,4 @@
-<div class="checkbox schema-form-checkbox {{::form.htmlClass}}"
+<div class="checkbox schema-form-checkbox {{::form.htmlClass + ' ' + idClass}}"
      ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
   <label class="{{::form.labelHtmlClass}}">
     <input type="checkbox"
diff --git a/src/bootstrap/checkboxes.html b/src/bootstrap/checkboxes.html
index 064202d..89856af 100644
--- a/src/bootstrap/checkboxes.html
+++ b/src/bootstrap/checkboxes.html
@@ -1,6 +1,6 @@
 <div sf-field-model="sf-new-array"
      sf-new-array
-     class="form-group schema-form-checkboxes {{::form.htmlClass}}"
+     class="form-group schema-form-checkboxes {{::form.htmlClass + ' ' + idClass}}"
      ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
   <label class="control-label {{::form.labelHtmlClass}}"
          sf-field-model
diff --git a/src/bootstrap/default.html b/src/bootstrap/default.html
index 56033df..f44cfa0 100644
--- a/src/bootstrap/default.html
+++ b/src/bootstrap/default.html
@@ -1,4 +1,4 @@
-<div class="form-group {{::form.htmlClass + ' schema-form-' + form.type}}"
+<div class="form-group {{::form.htmlClass + ' schema-form-' + form.type + ' ' + idClass}}"
      ng-class="{ 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }">
   <label class="control-label {{::form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>
 
diff --git a/src/bootstrap/fieldset.html b/src/bootstrap/fieldset.html
index f3b65f4..a833b5b 100644
--- a/src/bootstrap/fieldset.html
+++ b/src/bootstrap/fieldset.html
@@ -1,4 +1,4 @@
-<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass}}" sf-key-controller sf-parent-key="[{{form.key.join('][')}}]" sf-index="{{$index}}">
+<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + ' ' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join('][')}}]" sf-index="{{$index}}">
   <legend ng-class="{'sr-only': !showTitle() }">{{ form.title }}</legend>
   <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>
 </fieldset>
diff --git a/src/bootstrap/help.html b/src/bootstrap/help.html
index 74e54d0..65782c9 100644
--- a/src/bootstrap/help.html
+++ b/src/bootstrap/help.html
@@ -1 +1 @@
-<div class="helpvalue schema-form-helpvalue {{::form.htmlClass}}" ng-bind-html="form.helpvalue"></div>
+<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + ' ' + idClass}}" ng-bind-html="form.helpvalue"></div>
diff --git a/src/bootstrap/radio-buttons.html b/src/bootstrap/radio-buttons.html
index b012876..a3dd1f8 100644
--- a/src/bootstrap/radio-buttons.html
+++ b/src/bootstrap/radio-buttons.html
@@ -1,4 +1,4 @@
-<div class="form-group schema-form-radiobuttons {{::form.htmlClass}}"
+<div class="form-group schema-form-radiobuttons {{::form.htmlClass + ' ' + idClass}}"
      ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
   <div>
     <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>
diff --git a/src/bootstrap/radios-inline.html b/src/bootstrap/radios-inline.html
index 463c7ed..eb94523 100644
--- a/src/bootstrap/radios-inline.html
+++ b/src/bootstrap/radios-inline.html
@@ -1,4 +1,4 @@
-<div class="form-group schema-form-radios-inline {{::form.htmlClass}}"
+<div class="form-group schema-form-radios-inline {{::form.htmlClass + ' ' + idClass}}"
      ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}">
   <label class="control-label {{::form.labelHtmlClass}}"
         ng-show="showTitle()" sf-field-model
diff --git a/src/bootstrap/radios.html b/src/bootstrap/radios.html
index 17b6b2b..861250f 100644
--- a/src/bootstrap/radios.html
+++ b/src/bootstrap/radios.html
@@ -1,4 +1,4 @@
-<div class="form-group schema-form-radios {{::form.htmlClass}}" ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}">
+<div class="form-group schema-form-radios {{::form.htmlClass + ' ' + idClass}}" ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}">
   <label class="control-label {{::form.labelHtmlClass}}"
          sf-field-model schema-validate="form"
          ng-show="showTitle()">{{form.title}}</label>
diff --git a/src/bootstrap/section.html b/src/bootstrap/section.html
index e06c96f..606aae2 100644
--- a/src/bootstrap/section.html
+++ b/src/bootstrap/section.html
@@ -1 +1 @@
-<div class="schema-form-section {{::form.htmlClass}}" sf-key-controller sf-parent-key="[{{form.key.join('][')}}]" sf-index="{{$index}}"></div>
+<div class="schema-form-section {{::form.htmlClass + ' ' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join('][')}}]" sf-index="{{$index}}"></div>
diff --git a/src/bootstrap/select.html b/src/bootstrap/select.html
index 25de9be..0288717 100644
--- a/src/bootstrap/select.html
+++ b/src/bootstrap/select.html
@@ -1,4 +1,4 @@
-<div class="form-group {{::form.htmlClass}} schema-form-select"
+<div class="form-group {{::form.htmlClass + ' ' + idClass}} schema-form-select"
      ng-class="{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}">
   <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">
     {{form.title}}
diff --git a/src/bootstrap/submit.html b/src/bootstrap/submit.html
index 1a0b43b..0c77daf 100644
--- a/src/bootstrap/submit.html
+++ b/src/bootstrap/submit.html
@@ -1,4 +1,4 @@
-<div class="form-group schema-form-submit {{::form.htmlClass}}">
+<div class="form-group schema-form-submit {{::form.htmlClass + ' ' + idClass}}">
   <input type="submit"
          class="btn {{ form.style || 'btn-primary' }} {{::form.fieldHtmlClass}}"
          value="{{form.title}}"
diff --git a/src/bootstrap/tabarray.html b/src/bootstrap/tabarray.html
index 1d56088..a2a8a3a 100644
--- a/src/bootstrap/tabarray.html
+++ b/src/bootstrap/tabarray.html
@@ -2,7 +2,7 @@
      ng-model="modelArray" schema-validate="form"
      sf-field-model="sf-new-array"
      sf-new-array
-     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{::form.htmlClass}}">
+     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || 'left'}} {{::form.htmlClass + ' ' + idClass}}">
   <div ng-if="!form.tabType || form.tabType !== 'right'"
        ng-class="{'col-xs-3': !form.tabType || form.tabType === 'left'}">
     <ol class="nav nav-tabs"
diff --git a/src/bootstrap/tabs.html b/src/bootstrap/tabs.html
index 0ae9174..35188f1 100644
--- a/src/bootstrap/tabs.html
+++ b/src/bootstrap/tabs.html
@@ -1,4 +1,4 @@
-<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass}}">
+<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + ' ' + idClass}}">
   <ul class="nav nav-tabs">
     <li ng-repeat="tab in form.tabs"
         ng-disabled="form.readonly"
diff --git a/src/bootstrap/textarea.html b/src/bootstrap/textarea.html
index 66f56f0..3f43779 100644
--- a/src/bootstrap/textarea.html
+++ b/src/bootstrap/textarea.html
@@ -1,4 +1,4 @@
-<div class="form-group has-feedback {{::form.htmlClass}} schema-form-textarea" ng-class="{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
+<div class="form-group has-feedback {{::form.htmlClass + ' ' + idClass}} schema-form-textarea" ng-class="{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
   <label class="control-label {{::form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>
 
   <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"
diff --git a/src/module-bundled.js b/src/module-bundled.js
deleted file mode 100644
index 3f82b33..0000000
--- a/src/module-bundled.js
+++ /dev/null
@@ -1,2 +0,0 @@
-require('../node_modules/angular-schema-form/dist/schema-form.js');
-require('bootstrap-decorator.js');
diff --git a/webpack.config.dist.js b/webpack.config.dist.js
new file mode 100644
index 0000000..0da42b0
--- /dev/null
+++ b/webpack.config.dist.js
@@ -0,0 +1,11 @@
+const config = require('./webpack.config.js');
+const path = require('path');
+
+config.entry = {
+  'angular-schema-form-bootstrap': [ path.join(__dirname, 'src', 'module') ],
+  'angular-schema-form-bootstrap-bundled': [ 'angular-schema-form', path.join(__dirname, 'src', 'module') ],
+  'angular-schema-form-bootstrap.min': [ path.join(__dirname, 'src', 'module') ],
+  'angular-schema-form-bootstrap-bundled.min': [ 'angular-schema-form', path.join(__dirname, 'src', 'module') ],
+}
+
+module.exports = config;
diff --git a/webpack.config.js b/webpack.config.js
index 70f1261..981da41 100644
--- a/webpack.config.js
+++ b/webpack.config.js
@@ -1,63 +1,79 @@
 /* global __dirname */
-//const ngAnnotatePlugin = require('ng-annotate-webpack-plugin');
-//const ExtractTextPlugin = require('extract-text-webpack-plugin');
+/**
+* NOTE in order to build with angular-schema-form you must
+* have it cloned as a sibling directory to this one or npm
+* installed with the version you wish to build with.
+*/
 const webpack = require('webpack');
 const path = require('path');
-//const HtmlWebpackPlugin = require('html-webpack-plugin');
-const getPath = (pathToFile) => path.resolve(__dirname, pathToFile);
-const pjson = require('./package.json');
-console.log('Angular Schema Form Bootstrap v' + pjson.version);
+const package = require('./package.json');
+const buildDate = new Date();
+console.log('Angular Schema Form Bootstrap v' + package.version);
+const plugins = [
+  new webpack.BannerPlugin(
+    'angular-schema-form-bootstrap\n' +
+    '@version ' + package.version + '\n' +
+    '@date ' + buildDate.toUTCString() + '\n' +
+    '@link https://github.com/json-schema-form/angular-schema-form-bootstrap\n' +
+    '@license MIT\n' +
+    'Copyright (c) 2014-' + buildDate.getFullYear() + ' JSON Schema Form'),
+  /* Minification only occurs if the output is named .min */
+  new webpack.optimize.UglifyJsPlugin(
+    {
+      include: /\.min\.js$/,
+      minimize: true
+    })
+];
 
 module.exports = {
   entry: {
-    'angular-schema-form-bootstrap': [ 'angular-schema-form', getPath('./src/module.js') ],
-    'angular-schema-form-bootstrap-bundled': [ 'angular-schema-form', getPath('./src/module-bundled.js') ],
+    'angular-schema-form-bootstrap': [ path.join(__dirname, 'src', 'module') ],
+    'angular-schema-form-bootstrap-bundled': [ 'angular-schema-form', path.join(__dirname, 'src', 'module') ],
   },
   output: {
-    path: getPath('./dist'),
+    path: path.join(__dirname, 'dist'),
     filename: '[name].js',
     sourceMapFilename: '[name].map'
   },
   resolve: {
-    modulesDirectories: [
-      path.join(__dirname, "..", "angular-schema-form", "dist"),
+    modules: [
       path.join(__dirname, "src"),
       path.join(__dirname, "src", "bootstrap"),
+      path.join(__dirname, "..", "angular-schema-form", "dist"),
       'node_modules',
     ],
-    extensions: [ '', '.js', '.html' ]
+    extensions: [ '.js', '.html' ]
   },
   module: {
-    loaders: [
+    rules: [
       {
         test: /\.js$/,
-        include: [ path.join(__dirname, 'src') ],
-        exclude: /(node_modules)/,
-        loader: 'babel-loader',
+        use: [{
+          loader: 'babel-loader',
+          options: {
+            presets: [
+              [ "es2015", { "modules": false }]
+            ]
+          }
+        }],
+        exclude: /(node_modules|angular-schema-form)/
       },
       {
         test: /\.html$/,
-        loader: 'ngtemplate?relativeTo=' + path.join(__dirname, 'src') + '/!html',
+        use: [{
+          loader: 'ngtemplate-loader',
+          options: {
+            relativeTo: path.join(__dirname, 'src')
+          }
+        }, 'html-loader'],
         exclude: /(index)/
       }
-    ]
+    ] 
   },
   externals: {
     'angular': 'var angular',
     'tv4': 'var tv4',
+    'bundle!angular-schema-form': 'commonjs angular-schema-form'
   },
-  plugins: [
-    new webpack.optimize.AggressiveMergingPlugin({}),
-    new webpack.optimize.OccurenceOrderPlugin(true),
-    // new HtmlWebpackPlugin({
-    //   template: 'html!./src/index.html'
-    // }),
-    new webpack.BannerPlugin(
-      'angular-schema-form-bootstrap\n' +
-      '@version ' + pjson.version + '\n' +
-      '@date ' + buildDate.toUTCString() + '\n' +
-      '@link https://github.com/json-schema-form/angular-schema-form-bootstrap\n' +
-      '@license MIT\n' +
-      'Copyright (c) 2014-' + buildDate.getFullYear() + ' JSON Schema Form')
-  ]
+  plugins: plugins
 };

From 81a804c367ac6b97f8c486cac9a5979563ffb599 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Sun, 15 Jan 2017 04:13:46 +1100
Subject: [PATCH 34/50] Match ASF alpha release

---
 dist/angular-schema-form-bootstrap-bundled.js | 3537 ++++++++++++++++-
 ...gular-schema-form-bootstrap-bundled.min.js |   37 +-
 dist/angular-schema-form-bootstrap.js         |  110 +-
 dist/angular-schema-form-bootstrap.min.js     |    5 +-
 package.json                                  |    5 +-
 src/bootstrap-decorator.js                    |   24 +-
 6 files changed, 3573 insertions(+), 145 deletions(-)

diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index 5dd11fc..4a5e9e9 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.5
- * @date Sun, 01 Jan 2017 14:14:55 GMT
+ * @version 1.0.0-alpha.1
+ * @date Sat, 14 Jan 2017 17:11:45 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -228,39 +228,39 @@ module.exports = path;
 /***/ function(module, exports, __webpack_require__) {
 
 "use strict";
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html__ = __webpack_require__(16);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html__ = __webpack_require__(6);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html__ = __webpack_require__(2);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html__ = __webpack_require__(14);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html__ = __webpack_require__(15);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html__ = __webpack_require__(11);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html__ = __webpack_require__(1);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html__ = __webpack_require__(12);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html__ = __webpack_require__(3);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html__ = __webpack_require__(4);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html__ = __webpack_require__(13);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html__ = __webpack_require__(10);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html__ = __webpack_require__(9);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html__ = __webpack_require__(8);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html__ = __webpack_require__(7);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html__ = __webpack_require__(5);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html__);
-// angular-templatecache-loader
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html__ = __webpack_require__(1);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html__ = __webpack_require__(2);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html__ = __webpack_require__(3);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html__ = __webpack_require__(4);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html__ = __webpack_require__(5);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html__ = __webpack_require__(6);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html__ = __webpack_require__(7);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html__ = __webpack_require__(8);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html__ = __webpack_require__(10);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html__ = __webpack_require__(9);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html__ = __webpack_require__(11);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html__ = __webpack_require__(12);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html__ = __webpack_require__(13);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html__ = __webpack_require__(14);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html__ = __webpack_require__(15);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html__ = __webpack_require__(16);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html__);
+// ngtemplate-loader embeds the html on build
 
 
 
@@ -352,26 +352,26 @@ function bootstrapDecoratorConfig(
 
   var defaults = [sfField, ngModel, ngModelOptions, condition];
   decoratorsProvider.defineDecorator('bootstrapDecorator', {
-    actions: {template: __WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html___default.a, builder: defaults},
-    array: {template: __WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    button: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html___default.a, builder: defaults},
-    checkbox: {template: __WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html___default.a, builder: defaults},
-    checkboxes: {template: __WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    conditional: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
-    'default': {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default.a, builder: defaults},
-    fieldset: {template: __WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html___default.a, builder: [sfField, simpleTransclusion, condition]},
-    help: {template: __WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html___default.a, builder: defaults},
-    number: {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default.a, builder: defaults.concat(numeric)},
-    password: {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default.a, builder: defaults},
-    radios: {template: __WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html___default.a, builder: defaults},
-    'radios-inline': {template: __WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html___default.a, builder: defaults},
-    radiobuttons: {template: __WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html___default.a, builder: defaults},
-    section: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
-    select: {template: __WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html___default.a, builder: defaults.concat(selectPlaceholder)},
-    submit: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html___default.a, builder: defaults},
-    tabarray: {template: __WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    tabs: {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html___default.a, builder: [sfField, ngModelOptions, tabs, condition]},
-    textarea: {template: __WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html___default.a, builder: defaults},
+    actions: {template: __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html___default.a, builder: defaults},
+    array: {template: __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    button: {template: __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html___default.a, builder: defaults},
+    checkbox: {template: __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html___default.a, builder: defaults},
+    checkboxes: {template: __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    conditional: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    'default': {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default.a, builder: defaults},
+    fieldset: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    help: {template: __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html___default.a, builder: defaults},
+    number: {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default.a, builder: defaults.concat(numeric)},
+    password: {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default.a, builder: defaults},
+    radios: {template: __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html___default.a, builder: defaults},
+    'radios-inline': {template: __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html___default.a, builder: defaults},
+    radiobuttons: {template: __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html___default.a, builder: defaults},
+    section: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    select: {template: __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html___default.a, builder: defaults.concat(selectPlaceholder)},
+    submit: {template: __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html___default.a, builder: defaults},
+    tabarray: {template: __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    tabs: {template: __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html___default.a, builder: [sfField, ngModelOptions, tabs, condition]},
+    textarea: {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html___default.a, builder: defaults},
   }, []);
 };
 
@@ -397,7 +397,3432 @@ function sfCamelKeyFilter() {
 /* 18 */
 /***/ function(module, exports) {
 
-throw new Error("Module build failed: Error: ENOENT: no such file or directory, open 'C:\\Users\\Marcel\\Documents\\SERIOUS\\git\\angular-schema-form\\dist\\angular-schema-form.js'\n    at Error (native)");
+/*!
+ * angular-schema-form
+ * @version 1.0.0-alpha.1
+ * @date Sat, 14 Jan 2017 17:09:44 GMT
+ * @link https://github.com/json-schema-form/angular-schema-form
+ * @license MIT
+ * Copyright (c) 2014-2017 JSON Schema Form
+ */
+/******/ (function(modules) { // webpackBootstrap
+/******/ 	// The module cache
+/******/ 	var installedModules = {};
+
+/******/ 	// The require function
+/******/ 	function __webpack_require__(moduleId) {
+
+/******/ 		// Check if module is in cache
+/******/ 		if(installedModules[moduleId])
+/******/ 			return installedModules[moduleId].exports;
+
+/******/ 		// Create a new module (and put it into the cache)
+/******/ 		var module = installedModules[moduleId] = {
+/******/ 			i: moduleId,
+/******/ 			l: false,
+/******/ 			exports: {}
+/******/ 		};
+
+/******/ 		// Execute the module function
+/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
+
+/******/ 		// Flag the module as loaded
+/******/ 		module.l = true;
+
+/******/ 		// Return the exports of the module
+/******/ 		return module.exports;
+/******/ 	}
+
+
+/******/ 	// expose the modules object (__webpack_modules__)
+/******/ 	__webpack_require__.m = modules;
+
+/******/ 	// expose the module cache
+/******/ 	__webpack_require__.c = installedModules;
+
+/******/ 	// identity function for calling harmory imports with the correct context
+/******/ 	__webpack_require__.i = function(value) { return value; };
+
+/******/ 	// define getter function for harmory exports
+/******/ 	__webpack_require__.d = function(exports, name, getter) {
+/******/ 		Object.defineProperty(exports, name, {
+/******/ 			configurable: false,
+/******/ 			enumerable: true,
+/******/ 			get: getter
+/******/ 		});
+/******/ 	};
+
+/******/ 	// getDefaultExport function for compatibility with non-harmony modules
+/******/ 	__webpack_require__.n = function(module) {
+/******/ 		var getter = module && module.__esModule ?
+/******/ 			function getDefault() { return module['default']; } :
+/******/ 			function getModuleExports() { return module; };
+/******/ 		__webpack_require__.d(getter, 'a', getter);
+/******/ 		return getter;
+/******/ 	};
+
+/******/ 	// Object.prototype.hasOwnProperty.call
+/******/ 	__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
+
+/******/ 	// __webpack_public_path__
+/******/ 	__webpack_require__.p = "";
+
+/******/ 	// Load entry module and return exports
+/******/ 	return __webpack_require__(__webpack_require__.s = 16);
+/******/ })
+/************************************************************************/
+/******/ ([
+/* 0 */
+/***/ function(module, exports) {
+
+module.exports = angular;
+
+/***/ },
+/* 1 */
+/***/ function(module, exports) {
+
+/*!
+ * json-schema-form-core
+ * @version 1.0.0-alpha.1
+ * @date Sat, 14 Jan 2017 17:07:51 GMT
+ * @link https://github.com/json-schema-form/json-schema-form-core
+ * @license MIT
+ * Copyright (c) 2014-2017 JSON Schema Form
+ */
+module.exports =
+/******/ (function(modules) { // webpackBootstrap
+/******/ 	// The module cache
+/******/ 	var installedModules = {};
+/******/
+/******/ 	// The require function
+/******/ 	function __webpack_require__(moduleId) {
+/******/
+/******/ 		// Check if module is in cache
+/******/ 		if(installedModules[moduleId])
+/******/ 			return installedModules[moduleId].exports;
+/******/
+/******/ 		// Create a new module (and put it into the cache)
+/******/ 		var module = installedModules[moduleId] = {
+/******/ 			i: moduleId,
+/******/ 			l: false,
+/******/ 			exports: {}
+/******/ 		};
+/******/
+/******/ 		// Execute the module function
+/******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
+/******/
+/******/ 		// Flag the module as loaded
+/******/ 		module.l = true;
+/******/
+/******/ 		// Return the exports of the module
+/******/ 		return module.exports;
+/******/ 	}
+/******/
+/******/
+/******/ 	// expose the modules object (__webpack_modules__)
+/******/ 	__webpack_require__.m = modules;
+/******/
+/******/ 	// expose the module cache
+/******/ 	__webpack_require__.c = installedModules;
+/******/
+/******/ 	// identity function for calling harmory imports with the correct context
+/******/ 	__webpack_require__.i = function(value) { return value; };
+/******/
+/******/ 	// define getter function for harmory exports
+/******/ 	__webpack_require__.d = function(exports, name, getter) {
+/******/ 		Object.defineProperty(exports, name, {
+/******/ 			configurable: false,
+/******/ 			enumerable: true,
+/******/ 			get: getter
+/******/ 		});
+/******/ 	};
+/******/
+/******/ 	// getDefaultExport function for compatibility with non-harmony modules
+/******/ 	__webpack_require__.n = function(module) {
+/******/ 		var getter = module && module.__esModule ?
+/******/ 			function getDefault() { return module['default']; } :
+/******/ 			function getModuleExports() { return module; };
+/******/ 		__webpack_require__.d(getter, 'a', getter);
+/******/ 		return getter;
+/******/ 	};
+/******/
+/******/ 	// Object.prototype.hasOwnProperty.call
+/******/ 	__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
+/******/
+/******/ 	// __webpack_public_path__
+/******/ 	__webpack_require__.p = "";
+/******/
+/******/ 	// Load entry module and return exports
+/******/ 	return __webpack_require__(__webpack_require__.s = 11);
+/******/ })
+/************************************************************************/
+/******/ ([
+/* 0 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_objectpath__ = __webpack_require__(2);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_objectpath___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_objectpath__);
+/* harmony export (immutable) */ exports["name"] = name;
+/* harmony reexport (binding) */ if(__webpack_require__.o(__WEBPACK_IMPORTED_MODULE_0_objectpath__, "parse")) __webpack_require__.d(exports, "parse", function() { return __WEBPACK_IMPORTED_MODULE_0_objectpath__["parse"]; });
+/* harmony reexport (binding) */ if(__webpack_require__.o(__WEBPACK_IMPORTED_MODULE_0_objectpath__, "stringify")) __webpack_require__.d(exports, "stringify", function() { return __WEBPACK_IMPORTED_MODULE_0_objectpath__["stringify"]; });
+/* harmony reexport (binding) */ if(__webpack_require__.o(__WEBPACK_IMPORTED_MODULE_0_objectpath__, "normalize")) __webpack_require__.d(exports, "normalize", function() { return __WEBPACK_IMPORTED_MODULE_0_objectpath__["normalize"]; });
+
+
+
+
+/**
+ * I am a name formatter function for processing keys into names for classes or Id.
+ *
+ * @param  {Array<string>} key         I am the key array of a processed schema key
+ * @param  {string}        separator   I am the separator between the key items and optional form name
+ * @param  {string}        formName    I am an optional form name
+ * @param  {boolean}       omitNumbers I determine if numeric values should be included in the output or withheld
+ *
+ * @return {string}                    I am the formatted key
+ */
+function name(key, separator) {
+  var formName = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : '';
+  var omitNumbers = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;
+
+  if (key) {
+    var fieldKey = key.slice();
+    var fieldSeparator = separator || '-';
+
+    if (omitNumbers) {
+      fieldKey = fieldKey.filter(function (currentKey) {
+        return typeof currentKey !== 'number';
+      });
+    };
+
+    return (formName.length !== 0 ? formName + fieldSeparator : '') + fieldKey.join(fieldSeparator);
+  };
+
+  return '';
+};
+
+/***/ },
+/* 1 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
+
+// Takes a titleMap in either object or list format and returns one
+/* harmony default export */ exports["a"] = function (titleMap, originalEnum) {
+  if (!Array.isArray(titleMap)) {
+    var _ret = function () {
+      var canonical = [];
+      if (originalEnum) {
+        originalEnum.forEach(function (value) {
+          canonical.push({ name: titleMap[value], value: value });
+        });
+      } else {
+        Object.keys(titleMap).forEach(function (value) {
+          canonical.push({ name: titleMap[value], value: value });
+        });
+      }
+      return {
+        v: canonical
+      };
+    }();
+
+    if ((typeof _ret === "undefined" ? "undefined" : _typeof(_ret)) === "object") return _ret.v;
+  }
+  return titleMap;
+};
+
+/***/ },
+/* 2 */
+/***/ function(module, exports, __webpack_require__) {
+
+module.exports = __webpack_require__(9).ObjectPath;
+
+
+/***/ },
+/* 3 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__sf_path__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__canonical_title_map__ = __webpack_require__(1);
+/* harmony export (immutable) */ exports["defaultFormDefinition"] = defaultFormDefinition;
+/* harmony export (immutable) */ exports["stdFormObj"] = stdFormObj;
+/* harmony export (immutable) */ exports["text"] = text;
+/* harmony export (immutable) */ exports["number"] = number;
+/* harmony export (immutable) */ exports["integer"] = integer;
+/* harmony export (immutable) */ exports["checkbox"] = checkbox;
+/* harmony export (immutable) */ exports["select"] = select;
+/* harmony export (immutable) */ exports["checkboxes"] = checkboxes;
+/* harmony export (immutable) */ exports["fieldset"] = fieldset;
+/* harmony export (immutable) */ exports["array"] = array;
+/* harmony export (immutable) */ exports["createDefaults"] = createDefaults;
+/* harmony export (immutable) */ exports["defaultForm"] = defaultForm;
+var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
+
+
+
+
+/* Utils */
+var stripNullType = function stripNullType(type) {
+  if (Array.isArray(type) && type.length === 2) {
+    if (type[0] === 'null') {
+      return type[1];
+    };
+    if (type[1] === 'null') {
+      return type[0];
+    };
+  };
+  return type;
+};
+
+// Creates an default titleMap list from an enum, i.e. a list of strings.
+var enumToTitleMap = function enumToTitleMap(enm) {
+  var titleMap = []; // canonical titleMap format is a list.
+  enm.forEach(function (name) {
+    titleMap.push({ name: name, value: name });
+  });
+  return titleMap;
+};
+
+/**
+ * Creates a default form definition from a schema.
+ */
+function defaultFormDefinition(schemaTypes, name, schema, options) {
+  var rules = schemaTypes[stripNullType(schema.type)];
+  if (rules) {
+    var def = void 0;
+    // We give each rule a possibility to recurse it's children.
+    var innerDefaultFormDefinition = function innerDefaultFormDefinition(childName, childSchema, childOptions) {
+      return defaultFormDefinition(schemaTypes, childName, childSchema, childOptions);
+    };
+    for (var i = 0; i < rules.length; i++) {
+      def = rules[i](name, schema, options, innerDefaultFormDefinition);
+
+      // first handler in list that actually returns something is our handler!
+      if (def) {
+
+        // Do we have form defaults in the schema under the x-schema-form-attribute?
+        if (def.schema['x-schema-form']) {
+          Object.assign(def, def.schema['x-schema-form']);
+        }
+
+        return def;
+      }
+    }
+  }
+}
+
+/**
+ * Creates a form object with all common properties
+ */
+function stdFormObj(name, schema, options) {
+  options = options || {};
+
+  // The Object.assign used to be a angular.copy. Should work though.
+  var f = options.global && options.global.formDefaults ? Object.assign({}, options.global.formDefaults) : {};
+  if (options.global && options.global.supressPropertyTitles === true) {
+    f.title = schema.title;
+  } else {
+    f.title = schema.title || name;
+  }
+
+  if (schema.description) {
+    f.description = schema.description;
+  }
+  if (options.required === true || schema.required === true) {
+    f.required = true;
+  }
+  if (schema.maxLength) {
+    f.maxlength = schema.maxLength;
+  }
+  if (schema.minLength) {
+    f.minlength = schema.minLength;
+  }
+  if (schema.readOnly || schema.readonly) {
+    f.readonly = true;
+  }
+  if (schema.minimum) {
+    f.minimum = schema.minimum + (schema.exclusiveMinimum ? 1 : 0);
+  }
+  if (schema.maximum) {
+    f.maximum = schema.maximum - (schema.exclusiveMaximum ? 1 : 0);
+  }
+
+  // Non standard attributes (DONT USE DEPRECATED)
+  // If you must set stuff like this in the schema use the x-schema-form attribute
+  if (schema.validationMessage) {
+    f.validationMessage = schema.validationMessage;
+  }
+  if (schema.enumNames) {
+    f.titleMap = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__canonical_title_map__["a" /* default */])(schema.enumNames, schema['enum']);
+  }
+  f.schema = schema;
+
+  // Ng model options doesn't play nice with undefined, might be defined
+  // globally though
+  f.ngModelOptions = f.ngModelOptions || {};
+
+  return f;
+};
+
+/*** Schema types to form type mappings, with defaults ***/
+function text(name, schema, options) {
+  if (stripNullType(schema.type) === 'string' && !schema['enum']) {
+    var f = stdFormObj(name, schema, options);
+    f.key = options.path;
+    f.type = 'text';
+    options.lookup[__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0__sf_path__["stringify"])(options.path)] = f;
+    return f;
+  }
+}
+
+// default in json form for number and integer is a text field
+// input type="number" would be more suitable don't ya think?
+function number(name, schema, options) {
+  if (stripNullType(schema.type) === 'number') {
+    var f = stdFormObj(name, schema, options);
+    f.key = options.path;
+    f.type = 'number';
+    options.lookup[__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0__sf_path__["stringify"])(options.path)] = f;
+    return f;
+  }
+}
+
+function integer(name, schema, options) {
+  if (stripNullType(schema.type) === 'integer') {
+    var f = stdFormObj(name, schema, options);
+    f.key = options.path;
+    f.type = 'number';
+    options.lookup[__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0__sf_path__["stringify"])(options.path)] = f;
+    return f;
+  }
+}
+
+function checkbox(name, schema, options) {
+  if (stripNullType(schema.type) === 'boolean') {
+    var f = stdFormObj(name, schema, options);
+    f.key = options.path;
+    f.type = 'checkbox';
+    options.lookup[__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0__sf_path__["stringify"])(options.path)] = f;
+    return f;
+  }
+}
+
+function select(name, schema, options) {
+  if (stripNullType(schema.type) === 'string' && schema['enum']) {
+    var f = stdFormObj(name, schema, options);
+    f.key = options.path;
+    f.type = 'select';
+    if (!f.titleMap) {
+      f.titleMap = enumToTitleMap(schema['enum']);
+    }
+    options.lookup[__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0__sf_path__["stringify"])(options.path)] = f;
+    return f;
+  }
+}
+
+function checkboxes(name, schema, options) {
+  if (stripNullType(schema.type) === 'array' && schema.items && schema.items['enum']) {
+    var f = stdFormObj(name, schema, options);
+    f.key = options.path;
+    f.type = 'checkboxes';
+    if (!f.titleMap) {
+      f.titleMap = enumToTitleMap(schema.items['enum']);
+    }
+    options.lookup[__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0__sf_path__["stringify"])(options.path)] = f;
+    return f;
+  }
+}
+
+function fieldset(name, schema, options, defaultFormDef) {
+  if (stripNullType(schema.type) === 'object') {
+    var _ret = function () {
+      var f = stdFormObj(name, schema, options);
+      f.type = 'fieldset';
+      f.key = options.path;
+      f.items = [];
+      options.lookup[__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0__sf_path__["stringify"])(options.path)] = f;
+
+      // recurse down into properties
+      if (schema.properties) {
+        Object.keys(schema.properties).forEach(function (key) {
+          var value = schema.properties[key];
+          var path = options.path.slice();
+          path.push(key);
+          if (options.ignore[__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0__sf_path__["stringify"])(path)] !== true) {
+            var required = schema.required && schema.required.indexOf(key) !== -1;
+
+            var def = defaultFormDef(key, value, {
+              path: path,
+              required: required || false,
+              lookup: options.lookup,
+              ignore: options.ignore,
+              global: options.global
+            });
+            if (def) {
+              f.items.push(def);
+            }
+          }
+        });
+      }
+      return {
+        v: f
+      };
+    }();
+
+    if ((typeof _ret === 'undefined' ? 'undefined' : _typeof(_ret)) === "object") return _ret.v;
+  }
+}
+
+function array(name, schema, options, defaultFormDef) {
+  if (stripNullType(schema.type) === 'array') {
+    var f = stdFormObj(name, schema, options);
+    f.type = 'array';
+    f.key = options.path;
+    options.lookup[__webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0__sf_path__["stringify"])(options.path)] = f;
+
+    var required = schema.required && schema.required.indexOf(options.path[options.path.length - 1]) !== -1;
+
+    // The default is to always just create one child. This works since if the
+    // schemas items declaration is of type: "object" then we get a fieldset.
+    // We also follow json form notatation, adding empty brackets "[]" to
+    // signify arrays.
+
+    var arrPath = options.path.slice();
+    arrPath.push('');
+
+    f.items = [defaultFormDef(name, schema.items, {
+      path: arrPath,
+      required: required || false,
+      lookup: options.lookup,
+      ignore: options.ignore,
+      global: options.global
+    })];
+
+    return f;
+  }
+}
+
+function createDefaults() {
+  // First sorted by schema type then a list.
+  // Order has importance. First handler returning an form snippet will be used.
+  return {
+    string: [select, text],
+    object: [fieldset],
+    number: [number],
+    integer: [integer],
+    boolean: [checkbox],
+    array: [checkboxes, array]
+  };
+};
+
+/**
+ * Create form defaults from schema
+ */
+function defaultForm(schema, defaultSchemaTypes, ignore, globalOptions) {
+  var form = [];
+  var lookup = {}; // Map path => form obj for fast lookup in merging
+  ignore = ignore || {};
+  globalOptions = globalOptions || {};
+  defaultSchemaTypes = defaultSchemaTypes || createDefaults();
+
+  if (schema.properties) {
+    Object.keys(schema.properties).forEach(function (key) {
+      if (ignore[key] !== true) {
+        var required = schema.required && schema.required.indexOf(key) !== -1;
+        var def = defaultFormDefinition(defaultSchemaTypes, key, schema.properties[key], {
+          path: [key], // Path to this property in bracket notation.
+          lookup: lookup, // Extra map to register with. Optimization for merger.
+          ignore: ignore, // The ignore list of paths (sans root level name)
+          required: required, // Is it required? (v4 json schema style)
+          global: globalOptions // Global options, including form defaults
+        });
+        if (def) {
+          form.push(def);
+        }
+      }
+    });
+  } else {
+    throw new Error('Not implemented. Only type "object" allowed at root level of schema.');
+  }
+  return { form: form, lookup: lookup };
+}
+
+/***/ },
+/* 4 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__schema_defaults__ = __webpack_require__(3);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__sf_path__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__canonical_title_map__ = __webpack_require__(1);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__merge__ = __webpack_require__(5);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__select__ = __webpack_require__(6);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__traverse__ = __webpack_require__(7);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__validate__ = __webpack_require__(8);
+/* harmony export (binding) */ __webpack_require__.d(exports, "sfPath", function() { return sfPath; });
+/* harmony export (binding) */ __webpack_require__.d(exports, "schemaDefaults", function() { return schemaDefaults; });
+/* harmony export (binding) */ __webpack_require__.d(exports, "canonicalTitleMap", function() { return canonicalTitleMap; });
+/* harmony reexport (binding) */ __webpack_require__.d(exports, "merge", function() { return __WEBPACK_IMPORTED_MODULE_3__merge__["a"]; });
+/* harmony reexport (binding) */ __webpack_require__.d(exports, "select", function() { return __WEBPACK_IMPORTED_MODULE_4__select__["a"]; });
+/* harmony reexport (binding) */ __webpack_require__.d(exports, "traverseSchema", function() { return __WEBPACK_IMPORTED_MODULE_5__traverse__["a"]; });
+/* harmony reexport (binding) */ __webpack_require__.d(exports, "traverseForm", function() { return __WEBPACK_IMPORTED_MODULE_5__traverse__["b"]; });
+/* harmony reexport (binding) */ __webpack_require__.d(exports, "validate", function() { return __WEBPACK_IMPORTED_MODULE_6__validate__["a"]; });
+
+
+
+
+
+
+
+
+
+var sfPath = __WEBPACK_IMPORTED_MODULE_1__sf_path__;
+var schemaDefaults = __WEBPACK_IMPORTED_MODULE_0__schema_defaults__;
+var canonicalTitleMap = __WEBPACK_IMPORTED_MODULE_2__canonical_title_map__["a" /* default */];
+
+/***/ },
+/* 5 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__sf_path__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__schema_defaults__ = __webpack_require__(3);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__canonical_title_map__ = __webpack_require__(1);
+/* harmony export (immutable) */ exports["a"] = merge;
+var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
+
+
+
+
+
+// export function merge(schema, form, schemaDefaultTypes, ignore, options, readonly, asyncTemplates) {
+function merge(lookup, form, ignore, options, readonly, asyncTemplates) {
+  var formItems = [];
+  form = form || [];
+  var idx = form.indexOf('*');
+  options = options || {};
+
+  if ((typeof lookup === 'undefined' ? 'undefined' : _typeof(lookup)) === 'object' && lookup.hasOwnProperty('properties')) {
+    readonly = readonly || lookup.readonly || lookup.readOnly;
+    var stdForm = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__schema_defaults__["defaultForm"])(lookup, __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__schema_defaults__["createDefaults"])(), ignore, options);
+    var defaultFormLookup = stdForm.lookup;
+
+    lookup = defaultFormLookup || lookup;
+    formItems = formItems.concat(stdForm.form);
+  };
+
+  if (idx !== -1) {
+    form = form.slice(0, idx).concat(formItems).concat(form.slice(idx + 1));
+  };
+
+  // ok let's merge!
+  // We look at the supplied form and extend it with schema standards
+  return form.map(function (obj) {
+    // handle the shortcut with just a name
+    if (typeof obj === 'string') {
+      obj = { key: obj };
+    }
+
+    if (obj.key) {
+      if (typeof obj.key === 'string') {
+        obj.key = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0__sf_path__["parse"])(obj.key);
+      }
+    }
+
+    // If it has a titleMap make sure it's a list
+    if (obj.titleMap) {
+      obj.titleMap = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_2__canonical_title_map__["a" /* default */])(obj.titleMap);
+    }
+
+    // extend with std form from schema.
+    if (obj.key) {
+      var strid = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0__sf_path__["stringify"])(obj.key);
+      if (lookup[strid]) {
+        (function () {
+          var schemaDefaults = lookup[strid];
+          if (schemaDefaults) {
+            Object.keys(schemaDefaults).forEach(function (attr) {
+              if (obj[attr] === undefined) {
+                obj[attr] = schemaDefaults[attr];
+              }
+            });
+          }
+        })();
+      }
+    }
+
+    // Are we inheriting readonly?
+    if (readonly === true) {
+      // Inheriting false is not cool.
+      obj.readonly = true;
+    }
+
+    // if it's a type with items, merge 'em!
+    if (obj.items) {
+      obj.items = merge(lookup, obj.items, ignore, options, obj.readonly, asyncTemplates);
+    }
+
+    // if its has tabs, merge them also!
+    if (obj.tabs) {
+      obj.tabs.forEach(function (tab) {
+        if (tab.items) {
+          tab.items = merge(lookup, tab.items, ignore, options, obj.readonly, asyncTemplates);
+        }
+      });
+    }
+
+    // Special case: checkbox
+    // Since have to ternary state we need a default
+    if (obj.type === 'checkbox' && obj.schema['default'] === undefined) {
+      obj.schema['default'] = false;
+    };
+
+    // Special case: template type with tempplateUrl that's needs to be loaded before rendering
+    // TODO: this is not a clean solution. Maybe something cleaner can be made when $ref support
+    // is introduced since we need to go async then anyway
+    if (asyncTemplates && obj.type === 'template' && !obj.template && obj.templateUrl) {
+      asyncTemplates.push(obj);
+    }
+
+    return obj;
+  });
+}
+
+/***/ },
+/* 6 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__sf_path__ = __webpack_require__(0);
+/* harmony export (immutable) */ exports["a"] = select;
+
+
+var numRe = /^\d+$/;
+
+/**
+  * @description
+  * Utility method to access deep properties without
+  * throwing errors when things are not defined.
+  * Can also set a value in a deep structure, creating objects when missing
+  * ex.
+  * var foo = Select('address.contact.name',obj)
+  * Select('address.contact.name',obj,'Leeroy')
+  *
+  * @param {string} projection A dot path to the property you want to get/set
+  * @param {object} obj   (optional) The object to project on, defaults to 'this'
+  * @param {Any}    valueToSet (opional)  The value to set, if parts of the path of
+  *                 the projection is missing empty objects will be created.
+  * @returns {Any|undefined} returns the value at the end of the projection path
+  *                          or undefined if there is none.
+  */
+function select(projection, obj, valueToSet) {
+  if (!obj) {
+    obj = this;
+  };
+
+  // Support [] array syntax
+  var parts = typeof projection === 'string' ? __WEBPACK_IMPORTED_MODULE_0__sf_path__["parse"](projection) : projection;
+
+  if (typeof valueToSet !== 'undefined' && parts.length === 1) {
+    // special case, just setting one variable
+    obj[parts[0]] = valueToSet;
+    return obj;
+  };
+
+  if (typeof valueToSet !== 'undefined' && typeof obj[parts[0]] === 'undefined') {
+    // We need to look ahead to check if array is appropriate
+    obj[parts[0]] = parts.length > 2 && numRe.test(parts[1]) ? [] : {};
+  };
+
+  var value = obj[parts[0]];
+  for (var i = 1; i < parts.length; i++) {
+    // Special case: We allow JSON Form syntax for arrays using empty brackets
+    // These will of course not work here so we exit if they are found.
+    if (parts[i] === '') {
+      return undefined;
+    }
+    if (typeof valueToSet !== 'undefined') {
+      if (i === parts.length - 1) {
+        // last step. Let's set the value
+        value[parts[i]] = valueToSet;
+        return valueToSet;
+      } else {
+        // Make sure to create new objects on the way if they are not there.
+        // We need to look ahead to check if array is appropriate
+        var tmp = value[parts[i]];
+        if (typeof tmp === 'undefined' || tmp === null) {
+          tmp = numRe.test(parts[i + 1]) ? [] : {};
+          value[parts[i]] = tmp;
+        }
+        value = tmp;
+      }
+    } else if (value) {
+      // Just get nex value.
+      value = value[parts[i]];
+    }
+  }
+  return value;
+}
+
+/***/ },
+/* 7 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony export (immutable) */ exports["a"] = traverseSchema;
+/* harmony export (immutable) */ exports["b"] = traverseForm;
+/**
+ * Traverse a schema, applying a function(schema,path) on every sub schema
+ * i.e. every property of an object.
+ */
+function traverseSchema(schema, fn, path, ignoreArrays) {
+  ignoreArrays = ignoreArrays === undefined ? true : ignoreArrays;
+
+  path = path || [];
+
+  var traverse = function traverse(schemaObject, processorFunction, pathArray) {
+    processorFunction(schemaObject, pathArray);
+    if (schemaObject.properties) {
+      Object.keys(schemaObject.properties).forEach(function (name) {
+        var currentPath = pathArray.slice();
+        currentPath.push(name);
+        traverse(schemaObject.properties[name], processorFunction, currentPath);
+      });
+    }
+
+    // Only support type "array" which have a schemaObject as "items".
+    if (!ignoreArrays && schemaObject.items) {
+      var arrPath = pathArray.slice();arrPath.push('');
+      traverse(schemaObject.items, processorFunction, arrPath);
+    }
+  };
+
+  traverse(schema, fn, path || []);
+}
+
+function traverseForm(form, fn) {
+  fn(form);
+  if (form.items) {
+    form.items.forEach(function (f) {
+      traverseForm(f, fn);
+    });
+  }
+
+  if (form.tabs) {
+    form.tabs.forEach(function (tab) {
+      if (tab.items) {
+        tab.items.forEach(function (f) {
+          traverseForm(f, fn);
+        });
+      }
+    });
+  }
+}
+
+/***/ },
+/* 8 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tv4__ = __webpack_require__(10);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tv4___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_tv4__);
+/* harmony export (immutable) */ exports["a"] = validate;
+/*  Common code for validating a value against its form and schema definition */
+
+
+/**
+ * Validate a value against its form definition and schema.
+ * The value should either be of proper type or a string, some type
+ * coercion is applied.
+ *
+ * @param {Object} form A merged form definition, i.e. one with a schema.
+ * @param {Any} value the value to validate.
+ * @return {Object} a tv4js result object.
+ */
+function validate(form, value) {
+  if (!form) {
+    return { valid: true };
+  };
+
+  var schema = form.schema;
+  if (!schema) {
+    return { valid: true };
+  };
+
+  // Input of type text and textareas will give us a viewValue of ''
+  // when empty, this is a valid value in a schema and does not count as something
+  // that breaks validation of 'required'. But for our own sanity an empty field should
+  // not validate if it's required.
+  if (value === '') {
+    value = undefined;
+  };
+
+  // Numbers fields will give a null value, which also means empty field
+  if (form.type === 'number' && value === null) {
+    value = undefined;
+  };
+
+  // Version 4 of JSON Schema has the required property not on the
+  // property itself but on the wrapping object. Since we like to test
+  // only this property we wrap it in a fake object.
+  var wrap = { type: 'object', 'properties': {}, required: undefined };
+  var propName = form.key[form.key.length - 1];
+  wrap.properties[propName] = schema;
+
+  if (form.required) {
+    wrap.required = [propName];
+  };
+
+  var valueWrap = {};
+  if (!!value) {
+    valueWrap[propName] = value;
+  };
+
+  return __WEBPACK_IMPORTED_MODULE_0_tv4___default.a.validateResult(valueWrap, wrap);
+};
+
+/***/ },
+/* 9 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+var __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
+
+;!function(undefined) {
+
+	var ObjectPath = {
+		parse: function(str){
+			if(typeof str !== 'string'){
+				throw new TypeError('ObjectPath.parse must be passed a string');
+			}
+
+			var i = 0;
+			var parts = [];
+			var d, b, q, c;
+			while (i < str.length){
+				d = str.indexOf('.', i);
+				b = str.indexOf('[', i);
+
+				// we've reached the end
+				if (d === -1 && b === -1){
+					parts.push(str.slice(i, str.length));
+					i = str.length;
+				}
+
+				// dots
+				else if (b === -1 || (d !== -1 && d < b)) {
+					parts.push(str.slice(i, d));
+					i = d + 1;
+				}
+
+				// brackets
+				else {
+					if (b > i){
+						parts.push(str.slice(i, b));
+						i = b;
+					}
+					q = str.slice(b+1, b+2);
+					if (q !== '"' && q !=='\'') {
+						c = str.indexOf(']', b);
+						if (c === -1) c = str.length;
+						parts.push(str.slice(i + 1, c));
+						i = (str.slice(c + 1, c + 2) === '.') ? c + 2 : c + 1;
+					} else {
+						c = str.indexOf(q+']', b);
+						if (c === -1) c = str.length;
+						while (str.slice(c - 1, c) === '\\' && b < str.length){
+							b++;
+							c = str.indexOf(q+']', b);
+						}
+						parts.push(str.slice(i + 2, c).replace(new RegExp('\\'+q,'g'), q));
+						i = (str.slice(c + 2, c + 3) === '.') ? c + 3 : c + 2;
+					}
+				}
+			}
+			return parts;
+		},
+
+		// root === true : auto calculate root; must be dot-notation friendly
+		// root String : the string to use as root
+		stringify: function(arr, quote){
+
+			if(!Array.isArray(arr))
+				arr = [arr.toString()];
+
+			quote = quote === '"' ? '"' : '\'';
+
+			return arr.map(function(n){ return '[' + quote + (n.toString()).replace(new RegExp(quote, 'g'), '\\' + quote) + quote + ']'; }).join('');
+		},
+
+		normalize: function(data, quote){
+			return ObjectPath.stringify(Array.isArray(data) ? data : ObjectPath.parse(data), quote);
+		},
+
+		// Angular
+		registerModule: function(angular) {
+			angular.module('ObjectPath', []).provider('ObjectPath', function(){
+				this.parse = ObjectPath.parse;
+				this.stringify = ObjectPath.stringify;
+				this.normalize = ObjectPath.normalize;
+				this.$get = function(){
+					return ObjectPath;
+				};
+			});
+		}
+	};
+
+	// AMD
+	if (true) {
+		!(__WEBPACK_AMD_DEFINE_RESULT__ = function() {
+			return {ObjectPath: ObjectPath};
+		}.call(exports, __webpack_require__, exports, module), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
+	}
+
+	// CommonJS
+	else if (typeof exports === 'object') {
+		exports.ObjectPath = ObjectPath;
+	}
+
+	// Browser global
+	else {
+		window.ObjectPath = ObjectPath;
+	}
+	
+}();
+
+/***/ },
+/* 10 */
+/***/ function(module, exports) {
+
+module.exports = tv4;
+
+/***/ },
+/* 11 */
+/***/ function(module, exports, __webpack_require__) {
+
+module.exports = __webpack_require__(4);
+
+
+/***/ }
+/******/ ]);
+//# sourceMappingURL=json-schema-form-core.js.map
+
+/***/ },
+/* 2 */,
+/* 3 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__ = __webpack_require__(1);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_angular__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_angular__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_sf_builder_provider__ = __webpack_require__(13);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_schema_form_decorators_provider__ = __webpack_require__(11);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_schema_form_provider__ = __webpack_require__(12);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_sf_error_message_provider__ = __webpack_require__(14);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_sf_path_provider__ = __webpack_require__(15);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__ = __webpack_require__(6);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__ = __webpack_require__(7);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__ = __webpack_require__(9);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__ = __webpack_require__(5);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__ = __webpack_require__(8);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__ = __webpack_require__(10);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__ = __webpack_require__(4);
+
+
+
+// ./services/
+
+
+
+
+
+// ./directives/
+
+
+
+
+
+
+
+
+// Deps is sort of a problem for us, maybe in the future we will ask the user to depend
+// on modules for add-ons
+var deps = [];
+
+try {
+  //This throws an expection if module does not exist.
+  __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('ngSanitize');
+  deps.push('ngSanitize');
+} catch (e) {}
+
+try {
+  //This throws an expection if module does not exist.
+  __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('ui.sortable');
+  deps.push('ui.sortable');
+} catch (e) {}
+
+try {
+  //This throws an expection if module does not exist.
+  __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('angularSpectrumColorpicker');
+  deps.push('angularSpectrumColorpicker');
+} catch (e) {}
+
+__WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
+
+// Providers and services
+.provider('sfPath', __WEBPACK_IMPORTED_MODULE_6_sf_path_provider__["a" /* default */]).provider('sfBuilder', ['sfPathProvider', __WEBPACK_IMPORTED_MODULE_2_sf_builder_provider__["a" /* default */]]).provider('schemaFormDecorators', ['$compileProvider', 'sfPathProvider', __WEBPACK_IMPORTED_MODULE_3_schema_form_decorators_provider__["a" /* default */]]).provider('sfErrorMessage', __WEBPACK_IMPORTED_MODULE_5_sf_error_message_provider__["a" /* default */]).provider('schemaForm', ['sfPathProvider', __WEBPACK_IMPORTED_MODULE_4_schema_form_provider__["a" /* default */]]).factory('sfSelect', function () {
+  return __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core___default.a.select;
+}).factory('sfValidator', function () {
+  return __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core___default.a.validate;
+})
+
+// Directives
+.directive('sfChanged', __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__["a" /* default */]).directive('sfField', ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__["a" /* default */]]).directive('sfMessage', ['$injector', 'sfErrorMessage', __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__["a" /* default */]]).directive('sfNewArray', ['sfSelect', 'sfPath', 'schemaForm', __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__["a" /* default */]]).directive('sfSchema', ['$compile', '$http', '$templateCache', '$q', 'schemaForm', 'schemaFormDecorators', 'sfSelect', 'sfPath', 'sfBuilder', __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__["a" /* default */]]).directive('schemaValidate', ['sfValidator', '$parse', 'sfSelect', __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__["a" /* default */]]).directive('sfKeyController', ['schemaForm', 'sfPath', __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__["a" /* default */]]);
+
+/***/ },
+/* 4 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
+
+
+/* harmony default export */ exports["a"] = function (sfValidator, $parse, sfSelect) {
+  return {
+    restrict: 'A',
+    scope: false,
+    // We want the link function to be *after* the input directives link function so we get access
+    // the parsed value, ex. a number instead of a string
+    priority: 500,
+    require: 'ngModel',
+    link: function link(scope, element, attrs, ngModel) {
+      // We need the ngModelController on several places,
+      // most notably for errors.
+      // So we emit it up to the decorator directive so it can put it on scope.
+      scope.$emit('schemaFormPropagateNgModelController', ngModel);
+
+      var error = null;
+      var form = scope.$eval(attrs.schemaValidate);
+
+      if (form.copyValueTo) {
+        ngModel.$viewChangeListeners.push(function () {
+          var paths = form.copyValueTo;
+          __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(paths, function (path) {
+            sfSelect(path, scope.model, ngModel.$modelValue);
+          });
+        });
+      };
+
+      // Validate against the schema.
+
+      var validate = function validate(viewValue) {
+        //console.log('validate called', viewValue)
+        //Still might be undefined
+        if (!form) {
+          return viewValue;
+        }
+
+        // Omit TV4 validation
+        if (scope.options && scope.options.tv4Validation === false) {
+          return viewValue;
+        }
+
+        var result = sfValidator(form, viewValue);
+        //console.log('result is', result)
+        // Since we might have different tv4 errors we must clear all
+        // errors that start with tv4-
+        Object.keys(ngModel.$error).filter(function (k) {
+          return k.indexOf('tv4-') === 0;
+        }).forEach(function (k) {
+          ngModel.$setValidity(k, true);
+        });
+
+        if (!result.valid) {
+          // it is invalid, return undefined (no model update)
+          ngModel.$setValidity('tv4-' + result.error.code, false);
+          error = result.error;
+
+          // In Angular 1.3+ return the viewValue, otherwise we inadvertenly
+          // will trigger a 'parse' error.
+          // we will stop the model value from updating with our own $validator
+          // later.
+          if (ngModel.$validators) {
+            return viewValue;
+          }
+          // Angular 1.2 on the other hand lacks $validators and don't add a 'parse' error.
+          return undefined;
+        }
+        return viewValue;
+      };
+
+      // Custom validators, parsers, formatters etc
+      if (typeof form.ngModel === 'function') {
+        form.ngModel(ngModel);
+      }
+
+      ['$parsers', '$viewChangeListeners', '$formatters'].forEach(function (attr) {
+        if (form[attr] && ngModel[attr]) {
+          form[attr].forEach(function (fn) {
+            ngModel[attr].push(fn);
+          });
+        }
+      });
+
+      ['$validators', '$asyncValidators'].forEach(function (attr) {
+        // Check if our version of angular has validators, i.e. 1.3+
+        if (form[attr] && ngModel[attr]) {
+          __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(form[attr], function (fn, name) {
+            ngModel[attr][name] = fn;
+          });
+        }
+      });
+
+      // Get in last of the parses so the parsed value has the correct type.
+      // We don't use $validators since we like to set different errors depending tv4 error codes
+      ngModel.$parsers.push(validate);
+
+      // But we do use one custom validator in the case of Angular 1.3 to stop the model from
+      // updating if we've found an error.
+      if (ngModel.$validators) {
+        ngModel.$validators.schemaForm = function () {
+          //console.log('validators called.')
+          // Any error and we're out of here!
+          return !Object.keys(ngModel.$error).some(function (e) {
+            return e !== 'schemaForm';
+          });
+        };
+      }
+
+      var schema = form.schema;
+
+      // A bit ugly but useful.
+      scope.validateField = function (formName) {
+        // If we have specified a form name, and this model is not within
+        // that form, then leave things be.
+        if (formName != undefined && ngModel.$$parentForm.$name !== formName) {
+          return;
+        }
+
+        // Special case: arrays
+        // TODO: Can this be generalized in a way that works consistently?
+        // Just setting the viewValue isn't enough to trigger validation
+        // since it's the same value. This will be better when we drop
+        // 1.2 support.
+        if (schema && schema.type.indexOf('array') !== -1) {
+          validate(ngModel.$modelValue);
+        }
+
+        // We set the viewValue to trigger parsers,
+        // since modelValue might be empty and validating just that
+        // might change an existing error to a "required" error message.
+        if (ngModel.$setDirty) {
+
+          // Angular 1.3+
+          ngModel.$setDirty();
+          ngModel.$setViewValue(ngModel.$viewValue);
+          ngModel.$commitViewValue();
+
+          // In Angular 1.3 setting undefined as a viewValue does not trigger parsers
+          // so we need to do a special required check.
+
+          // angulars checkbox directive isEmpty does not do the check we want.
+          if (form.type === 'checkbox') {
+            if (form.required && ngModel.$modelValue === undefined) {
+              ngModel.$setValidity('tv4-302', false);
+            }
+          } else if (form.required && ngModel.$isEmpty(ngModel.$modelValue)) {
+            ngModel.$setValidity('tv4-302', false);
+          }
+        } else {
+          // Angular 1.2
+          // In angular 1.2 setting a viewValue of undefined will trigger the parser.
+          // hence required works.
+          ngModel.$setViewValue(ngModel.$viewValue);
+        }
+      };
+
+      var first = true;
+      ngModel.$formatters.push(function (val) {
+        // When a form first loads this will be called for each field.
+        // we usually don't want that.
+        if (ngModel.$pristine && first && (!scope.options || scope.options.validateOnRender !== true)) {
+          first = false;
+          return val;
+        }
+        validate(ngModel.$modelValue);
+        return val;
+      });
+
+      // Listen to an event so we can validate the input on request
+      scope.$on('schemaFormValidate', function (event, formName) {
+        scope.validateField(formName);
+      });
+
+      scope.schemaError = function () {
+        return error;
+      };
+    }
+  };
+};
+
+/***/ },
+/* 5 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
+
+
+/**
+ * Directive that handles the model arrays
+ */
+/* harmony default export */ exports["a"] = function (sel, sfPath, schemaForm) {
+  return {
+    scope: true,
+    controller: ['$scope', function SFArrayController($scope) {
+      this.key = $scope.form && $scope.form.key ? $scope.form.key.splice(0, -2) : [];
+    }],
+    link: function link(scope, element, attrs) {
+      scope.min = 0;
+
+      scope.modelArray = scope.$eval(attrs.sfNewArray);
+
+      // We need to have a ngModel to hook into validation. It doesn't really play well with
+      // arrays though so we both need to trigger validation and onChange.
+      // So we watch the value as well. But watching an array can be tricky. We wan't to know
+      // when it changes so we can validate,
+      var watchFn = function watchFn() {
+        //scope.modelArray = modelArray;
+        scope.modelArray = scope.$eval(attrs.sfNewArray);
+        // validateField method is exported by schema-validate
+        if (scope.ngModel && scope.ngModel.$pristine && scope.firstDigest && (!scope.options || scope.options.validateOnRender !== true)) {
+          return;
+        } else if (scope.validateField) {
+          scope.validateField();
+        }
+      };
+
+      var onChangeFn = function onChangeFn() {
+        if (scope.form && scope.form.onChange) {
+          if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isFunction(scope.form.onChange)) {
+            scope.form.onChange(scope.modelArray, scope.form);
+          } else {
+            scope.evalExpr(scope.form.onChange, { 'modelValue': scope.modelArray, form: scope.form });
+          }
+        }
+      };
+
+      // If model is undefined make sure it gets set.
+      var getOrCreateModel = function getOrCreateModel() {
+        var model = scope.modelArray;
+        if (!model) {
+          var selection = sfPath.parse(attrs.sfNewArray);
+          model = [];
+          sel(selection, scope, model);
+          scope.modelArray = model;
+        }
+        return model;
+      };
+
+      // We need the form definition to make a decision on how we should listen.
+      var once = scope.$watch('form', function (form) {
+        if (!form) {
+          return;
+        }
+
+        // Always start with one empty form unless configured otherwise.
+        // Special case: don't do it if form has a titleMap
+        if (!form.titleMap && form.startEmpty !== true && (!scope.modelArray || scope.modelArray.length === 0)) {
+          scope.appendToArray();
+        }
+
+        // If we have "uniqueItems" set to true, we must deep watch for changes.
+        if (scope.form && scope.form.schema && scope.form.schema.uniqueItems === true) {
+          scope.$watch(attrs.sfNewArray, watchFn, true);
+
+          // We still need to trigger onChange though.
+          scope.$watch([attrs.sfNewArray, attrs.sfNewArray + '.length'], onChangeFn);
+        } else {
+          // Otherwise we like to check if the instance of the array has changed, or if something
+          // has been added/removed.
+          if (scope.$watchGroup) {
+            scope.$watchGroup([attrs.sfNewArray, attrs.sfNewArray + '.length'], function () {
+              watchFn();
+              onChangeFn();
+            });
+          } else {
+            // Angular 1.2 support
+            scope.$watch(attrs.sfNewArray, function () {
+              watchFn();
+              onChangeFn();
+            });
+            scope.$watch(attrs.sfNewArray + '.length', function () {
+              watchFn();
+              onChangeFn();
+            });
+          }
+        }
+
+        // Title Map handling
+        // If form has a titleMap configured we'd like to enable looping over
+        // titleMap instead of modelArray, this is used for intance in
+        // checkboxes. So instead of variable number of things we like to create
+        // a array value from a subset of values in the titleMap.
+        // The problem here is that ng-model on a checkbox doesn't really map to
+        // a list of values. This is here to fix that.
+        if (form.titleMap && form.titleMap.length > 0) {
+          scope.titleMapValues = [];
+
+          // We watch the model for changes and the titleMapValues to reflect
+          // the modelArray
+          var updateTitleMapValues = function updateTitleMapValues(arr) {
+            scope.titleMapValues = [];
+            arr = arr || [];
+
+            form.titleMap.forEach(function (item) {
+              scope.titleMapValues.push(arr.indexOf(item.value) !== -1);
+            });
+          };
+          //Catch default values
+          updateTitleMapValues(scope.modelArray);
+
+          // TODO: Refactor and see if we can get rid of this watch by piggy backing on the
+          // validation watch.
+          scope.$watchCollection('modelArray', updateTitleMapValues);
+
+          //To get two way binding we also watch our titleMapValues
+          scope.$watchCollection('titleMapValues', function (vals, old) {
+            if (vals && vals !== old) {
+              var arr = getOrCreateModel();
+
+              form.titleMap.forEach(function (item, index) {
+                var arrIndex = arr.indexOf(item.value);
+                if (arrIndex === -1 && vals[index]) {
+                  arr.push(item.value);
+                };
+
+                if (arrIndex !== -1 && !vals[index]) {
+                  arr.splice(arrIndex, 1);
+                };
+              });
+              // Time to validate the rebuilt array.
+              // validateField method is exported by schema-validate
+              if (scope.validateField) {
+                scope.validateField();
+              }
+            }
+          });
+        }
+
+        once();
+      });
+
+      scope.appendToArray = function () {
+        var empty;
+
+        // Create and set an array if needed.
+        var model = getOrCreateModel();
+
+        // Same old add empty things to the array hack :(
+        if (scope.form && scope.form.schema && scope.form.schema.items) {
+
+          var items = scope.form.schema.items;
+          if (items.type && items.type.indexOf('object') !== -1) {
+            empty = {};
+
+            // Check for possible defaults
+            if (!scope.options || scope.options.setSchemaDefaults !== false) {
+              empty = __WEBPACK_IMPORTED_MODULE_0_angular___default.a.isDefined(items['default']) ? items['default'] : empty;
+
+              // Check for defaults further down in the schema.
+              // If the default instance sets the new array item to something falsy, i.e. null
+              // then there is no need to go further down.
+              if (empty) {
+                schemaForm.traverseSchema(items, function (prop, path) {
+                  if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isDefined(prop['default'])) {
+                    sel(path, empty, prop['default']);
+                  }
+                });
+              }
+            }
+          } else if (items.type && items.type.indexOf('array') !== -1) {
+            empty = [];
+            if (!scope.options || scope.options.setSchemaDefaults !== false) {
+              empty = items['default'] || empty;
+            }
+          } else {
+            // No type? could still have defaults.
+            if (!scope.options || scope.options.setSchemaDefaults !== false) {
+              empty = items['default'] || empty;
+            }
+          }
+        }
+        model.push(empty);
+
+        return model;
+      };
+
+      scope.deleteFromArray = function (index) {
+        var model = scope.modelArray;
+        if (model) {
+          model.splice(index, 1);
+        }
+        return model;
+      };
+
+      // For backwards compatability, i.e. when a bootstrap-decorator tag is used
+      // as child to the array.
+      var setIndex = function setIndex(index) {
+        return function (form) {
+          if (form.key) {
+            form.key[form.key.indexOf('')] = index;
+          }
+        };
+      };
+      var formDefCache = {};
+      scope.copyWithIndex = function (index) {
+        var form = scope.form;
+        if (!formDefCache[index]) {
+
+          // To be more compatible with JSON Form we support an array of items
+          // in the form definition of "array" (the schema just a value).
+          // for the subforms code to work this means we wrap everything in a
+          // section. Unless there is just one.
+          var subForm = form.items[0];
+          if (form.items.length > 1) {
+            subForm = {
+              type: 'section',
+              items: form.items.map(function (item) {
+                item.ngModelOptions = form.ngModelOptions;
+                if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isUndefined(item.readonly)) {
+                  item.readonly = form.readonly;
+                }
+                return item;
+              })
+            };
+          }
+
+          if (subForm) {
+            var copy = __WEBPACK_IMPORTED_MODULE_0_angular___default.a.copy(subForm);
+            copy.arrayIndex = index;
+            schemaForm.traverseForm(copy, setIndex(index));
+            formDefCache[index] = copy;
+          }
+        }
+        return formDefCache[index];
+      };
+    }
+  };
+};
+
+/***/ },
+/* 6 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
+
+
+/**
+ * A version of ng-changed that only listens if
+ * there is actually a onChange defined on the form
+ *
+ * Takes the form definition as argument.
+ * If the form definition has a "onChange" defined as either a function or
+ */
+/* harmony default export */ exports["a"] = function () {
+  return {
+    require: 'ngModel',
+    restrict: 'AC',
+    scope: false,
+    link: function link(scope, element, attrs, ctrl) {
+      var form = scope.$eval(attrs.sfChanged);
+      //"form" is really guaranteed to be here since the decorator directive
+      //waits for it. But best be sure.
+      if (form && form.onChange) {
+        ctrl.$viewChangeListeners.push(function () {
+          if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isFunction(form.onChange)) {
+            form.onChange(ctrl.$modelValue, form);
+          } else {
+            scope.evalExpr(form.onChange, {
+              "modelValue": ctrl.$modelValue,
+              "form": form,
+              "arrayIndex": scope.$index,
+              "arrayIndices": scope.arrayIndices,
+              "path": scope.path,
+              "$i": scope.$i,
+              "$index": scope.$index
+            });
+          }
+        });
+      }
+    }
+  };
+};
+
+/***/ },
+/* 7 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
+var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
+
+
+
+/* harmony default export */ exports["a"] = function ($parse, $compile, $http, $templateCache, $interpolate, $q, sfErrorMessage, sfPath, sfSelect) {
+
+  var keyFormat = {
+    COMPLETE: '*',
+    PATH: 'string',
+    INDICES: 'number'
+  };
+
+  return {
+    restrict: 'AE',
+    replace: false,
+    transclude: false,
+    scope: true,
+    require: ['^sfSchema', '?^form', '?^^sfKeyController'],
+    link: {
+      pre: function pre(scope, element, attrs, ctrl) {
+        var sfSchema = ctrl[0];
+        var formCtrl = ctrl[1];
+        var keyCtrl = ctrl[2];
+
+        //The ngModelController is used in some templates and
+        //is needed for error messages,
+        scope.$on('schemaFormPropagateNgModelController', function (event, ngModel) {
+          event.stopPropagation();
+          event.preventDefault();
+          scope.ngModel = ngModel;
+        });
+
+        // Fetch our form.
+        scope.initialForm = Object.assign({}, sfSchema.lookup['f' + attrs.sfField]);
+        scope.form = sfSchema.lookup['f' + attrs.sfField];
+      },
+      post: function post(scope, element, attrs, ctrl) {
+        var sfSchema = ctrl[0];
+        var formCtrl = ctrl[1];
+        var keyCtrl = ctrl[2];
+
+        scope.getKey = function (requiredFormat) {
+          var format = requiredFormat || keyFormat.COMPLETE;
+          var key = scope.parentKey ? scope.parentKey.slice(0, scope.parentKey.length - 1) : [];
+
+          // Only calculate completeKey if not already saved to form.key
+          if (scope.completeKey !== scope.form.key) {
+            if (typeof scope.$index === 'number') {
+              key = key.concat(scope.$index);
+            };
+
+            if (scope.form.key && scope.form.key.length) {
+              if (typeof key[key.length - 1] === 'number' && scope.form.key.length >= 1) {
+                var trim = scope.form.key.length - key.length;
+                scope.completeKey = key.concat(scope.form.key.slice(-trim));
+              } else {
+                scope.completeKey = scope.form.key.slice();
+              };
+            };
+          };
+
+          // If there is no key then there's nothing to return
+          if (!Array.isArray(scope.completeKey)) {
+            return undefined;
+          };
+
+          // return the full key if not omiting any types via reduce
+          if (format === keyFormat.COMPLETE) {
+            return scope.completeKey;
+          } else {
+            // else to clearly show that data must be ommited
+            return scope.completeKey.reduce(function (output, input, i) {
+              if (-1 !== [format].indexOf(typeof input === 'undefined' ? 'undefined' : _typeof(input))) {
+                return output.concat(input);
+              }
+              return output;
+            }, []);
+          };
+        };
+        // Now that getKey is defined, run it! ...if there's a key.
+        if (scope.form.key) {
+          scope.form.key = scope.completeKey = scope.getKey();
+        };
+
+        //Keep error prone logic from the template
+        scope.showTitle = function () {
+          return scope.form && scope.form.notitle !== true && scope.form.title;
+        };
+
+        //Normalise names and ids
+        scope.fieldId = function (prependFormName, omitArrayIndexes) {
+          var omit = omitArrayIndexes || false;
+          var formName = prependFormName && formCtrl && formCtrl.$name ? formCtrl.$name : undefined;
+          var key = scope.completeKey;
+
+          if (Array.isArray(key)) {
+            return sfPath.name(key, '-', formName, omit);
+          } else {
+            return '';
+          };
+        };
+
+        scope.listToCheckboxValues = function (list) {
+          var values = {};
+          __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(list, function (v) {
+            values[v] = true;
+          });
+          return values;
+        };
+
+        scope.checkboxValuesToList = function (values) {
+          var lst = [];
+          __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(values, function (v, k) {
+            if (v) {
+              lst.push(k);
+            }
+          });
+          return lst;
+        };
+
+        scope.buttonClick = function ($event, form) {
+          if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isFunction(form.onClick)) {
+            form.onClick($event, form);
+          } else if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isString(form.onClick)) {
+            if (sfSchema) {
+              //evaluating in scope outside of sfSchemas isolated scope
+              sfSchema.evalInParentScope(form.onClick, { '$event': $event, form: form });
+            } else {
+              scope.$eval(form.onClick, { '$event': $event, form: form });
+            }
+          }
+        };
+
+        /**
+         * Evaluate an expression, i.e. scope.$eval
+         * but do it in sfSchemas parent scope sf-schema directive is used
+         *
+         * @param {string} expression
+         * @param {Object} locals (optional)
+         * @return {Any} the result of the expression
+         */
+        scope.evalExpr = function (expression, locals) {
+          if (sfSchema) {
+            //evaluating in scope outside of sfSchemas isolated scope
+            return sfSchema.evalInParentScope(expression, locals);
+          }
+
+          return scope.$eval(expression, locals);
+        };
+
+        /**
+         * Evaluate an expression, i.e. scope.$eval
+         * in this decorators scope
+         *
+         * @param {string} expression
+         * @param {Object} locals (optional)
+         * @return {Any} the result of the expression
+         */
+        scope.evalInScope = function (expression, locals) {
+          if (expression) {
+            return scope.$eval(expression, locals);
+          }
+        };
+
+        /**
+         * Interpolate the expression.
+         * Similar to `evalExpr()` and `evalInScope()`
+         * but will not fail if the expression is
+         * text that contains spaces.
+         *
+         * Use the Angular `{{ interpolation }}`
+         * braces to access properties on `locals`.
+         *
+         * @param  {string} expression The string to interpolate.
+         * @param  {Object} locals (optional) Properties that may be accessed in the
+         *                         `expression` string.
+         * @return {Any} The result of the expression or `undefined`.
+         */
+        scope.interp = function (expression, locals) {
+          return expression && $interpolate(expression)(locals);
+        };
+
+        //This works since we get the ngModel from the array or the schema-validate directive.
+        scope.hasSuccess = function () {
+          if (!scope.ngModel) {
+            return false;
+          }
+          if (scope.options && scope.options.pristine && scope.options.pristine.success === false) {
+            return scope.ngModel.$valid && !scope.ngModel.$pristine && !scope.ngModel.$isEmpty(scope.ngModel.$modelValue);
+          } else {
+            return scope.ngModel.$valid && (!scope.ngModel.$pristine || !scope.ngModel.$isEmpty(scope.ngModel.$modelValue));
+          }
+        };
+
+        scope.hasError = function () {
+          if (!scope.ngModel) {
+            return false;
+          }
+          if (!scope.options || !scope.options.pristine || scope.options.pristine.errors !== false) {
+            // Show errors in pristine forms. The default.
+            // Note that "validateOnRender" option defaults to *not* validate initial form.
+            // so as a default there won't be any error anyway, but if the model is modified
+            // from the outside the error will show even if the field is pristine.
+            return scope.ngModel.$invalid;
+          } else {
+            // Don't show errors in pristine forms.
+            return scope.ngModel.$invalid && !scope.ngModel.$pristine;
+          }
+        };
+
+        /**
+         * DEPRECATED: use sf-messages instead.
+         * Error message handler
+         * An error can either be a schema validation message or a angular js validtion
+         * error (i.e. required)
+         */
+        scope.errorMessage = function (schemaError) {
+          return sfErrorMessage.interpolate(schemaError && schemaError.code + '' || 'default', scope.ngModel && scope.ngModel.$modelValue || '', scope.ngModel && scope.ngModel.$viewValue || '', scope.form, scope.options && scope.options.validationMessage);
+        };
+
+        // append the field-id to the htmlClass
+        scope.form.htmlClass = scope.form.htmlClass || '';
+        scope.idClass = scope.fieldId(false) + ' ' + scope.fieldId(false, true);
+
+        var form = scope.form;
+
+        // Where there is a key there is probably a ngModel
+        if (form.key) {
+          // It looks better with dot notation.
+          scope.$on('schemaForm.error.' + form.key.join('.'), function (event, error, validationMessage, validity, formName) {
+            // validationMessage and validity are mutually exclusive
+            formName = validity;
+            if (validationMessage === true || validationMessage === false) {
+              validity = validationMessage;
+              validationMessage = undefined;
+            };
+
+            // If we have specified a form name, and this model is not within
+            // that form, then leave things be.
+            if (formName != undefined && scope.ngModel.$$parentForm.$name !== formName) {
+              return;
+            };
+
+            if (scope.ngModel && error) {
+              if (scope.ngModel.$setDirty) {
+                scope.ngModel.$setDirty();
+              } else {
+                // FIXME: Check that this actually works on 1.2
+                scope.ngModel.$dirty = true;
+                scope.ngModel.$pristine = false;
+              }
+
+              // Set the new validation message if one is supplied
+              // Does not work when validationMessage is just a string.
+              if (validationMessage) {
+                if (!form.validationMessage) {
+                  form.validationMessage = {};
+                }
+                form.validationMessage[error] = validationMessage;
+              }
+
+              scope.ngModel.$setValidity(error, validity === true);
+
+              if (validity === true) {
+                // Re-trigger model validator, that model itself would be re-validated
+                scope.ngModel.$validate();
+
+                // Setting or removing a validity can change the field to believe its valid
+                // but its not. So lets trigger its validation as well.
+                scope.$broadcast('schemaFormValidate');
+              }
+            }
+          });
+
+          // Clean up the model when the corresponding form field is $destroy-ed.
+          // Default behavior can be supplied as a globalOption, and behavior can be overridden
+          // in the form definition.
+          scope.$on('$destroy', function () {
+            var key = scope.getKey();
+
+            // If the entire schema form is destroyed we don't touch the model
+            if (!scope.externalDestructionInProgress) {
+              var destroyStrategy = form.destroyStrategy || scope.options && scope.options.destroyStrategy || 'remove';
+              // No key no model, and we might have strategy 'retain'
+              if (key && destroyStrategy !== 'retain') {
+
+                // Get the object that has the property we wan't to clear.
+                var obj = scope.model;
+                if (key.length > 1) {
+                  obj = sfSelect(key.slice(0, key.length - 1), obj);
+                }
+
+                // We can get undefined here if the form hasn't been filled out entirely
+                if (obj === undefined) {
+                  return;
+                }
+
+                // Type can also be a list in JSON Schema
+                var type = form.schema && form.schema.type || '';
+
+                // Empty means '',{} and [] for appropriate types and undefined for the rest
+                //console.log('destroy', destroyStrategy, key, type, obj);
+                if (destroyStrategy === 'empty' && type.indexOf('string') !== -1) {
+                  obj[key.slice(-1)] = '';
+                } else if (destroyStrategy === 'empty' && type.indexOf('object') !== -1) {
+                  obj[key.slice(-1)] = {};
+                } else if (destroyStrategy === 'empty' && type.indexOf('array') !== -1) {
+                  obj[key.slice(-1)] = [];
+                } else if (destroyStrategy === 'null') {
+                  obj[key.slice(-1)] = null;
+                } else {
+                  delete obj[key.slice(-1)];
+                }
+              }
+            }
+          });
+        }
+      }
+    }
+  };
+};
+
+/***/ },
+/* 8 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/**
+ * Directive that handles keys and array indexes
+ */
+/* harmony default export */ exports["a"] = function (schemaForm, sfPath) {
+  return {
+    scope: true,
+    require: ['?^^sfNewArray'],
+    link: {
+      pre: function pre(scope, element, attrs, ctrl) {
+        scope.parentKey = scope.parentKey || [];
+
+        var currentKey = sfPath.parse(attrs.sfParentKey);
+        var trim = currentKey.length - scope.parentKey.length;
+
+        if (currentKey.length > 1) currentKey = currentKey.splice(-trim);
+
+        scope.parentKey = scope.parentKey.concat(currentKey, Number(attrs.sfIndex));
+        scope.arrayIndex = Number(attrs.sfIndex);
+        scope.arrayIndices = scope.arrayIndices || [];
+        scope.arrayIndices = scope.arrayIndices.concat(scope.arrayIndex);
+        scope.$i = scope.arrayIndices;
+        scope.path = function (modelPath) {
+          var i = -1;
+          modelPath = modelPath.replace(/\[\]/gi, function (matched) {
+            i++;
+            return '[' + scope.$i[i] + ']';
+          });
+          return scope.evalExpr(modelPath, scope);
+        };
+      }
+    }
+  };
+};;
+
+/***/ },
+/* 9 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
+
+
+/* harmony default export */ exports["a"] = function ($injector, sfErrorMessage) {
+
+  //Inject sanitizer if it exists
+  var $sanitize = $injector.has('$sanitize') ? $injector.get('$sanitize') : function (html) {
+    return html;
+  };
+
+  return {
+    scope: false,
+    restrict: 'EA',
+    link: function link(scope, element, attrs) {
+
+      var message = '';
+      if (attrs.sfMessage) {
+
+        scope.$watch(attrs.sfMessage, function (msg) {
+          if (msg) {
+            message = $sanitize(msg);
+            update(!!scope.ngModel);
+          }
+        });
+      }
+
+      var currentMessage;
+      // Only call html() if needed.
+      var setMessage = function setMessage(msg) {
+        if (msg !== currentMessage) {
+          element.html(msg);
+          currentMessage = msg;
+        }
+      };
+
+      var update = function update(checkForErrors) {
+        if (checkForErrors) {
+          if (!scope.hasError()) {
+            setMessage(message);
+          } else {
+            var errors = [];
+            __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(scope.ngModel && scope.ngModel.$error, function (status, code) {
+              if (status) {
+                // if true then there is an error
+                // Angular 1.3 removes properties, so we will always just have errors.
+                // Angular 1.2 sets them to false.
+                errors.push(code);
+              }
+            });
+
+            // In Angular 1.3 we use one $validator to stop the model value from getting updated.
+            // this means that we always end up with a 'schemaForm' error.
+            errors = errors.filter(function (e) {
+              return e !== 'schemaForm';
+            });
+
+            // We only show one error.
+            // TODO: Make that optional
+            var error = errors[0];
+
+            if (error) {
+              setMessage(sfErrorMessage.interpolate(error, scope.ngModel.$modelValue, scope.ngModel.$viewValue, scope.form, scope.options && scope.options.validationMessage));
+            } else {
+              setMessage(message);
+            }
+          }
+        } else {
+          setMessage(message);
+        }
+      };
+
+      // Update once.
+      update();
+
+      var once = scope.$watch('ngModel', function (ngModel) {
+        if (ngModel) {
+          // We also listen to changes of the model via parsers and formatters.
+          // This is since both the error message can change and given a pristine
+          // option to not show errors the ngModel.$error might not have changed
+          // but we're not pristine any more so we should change!
+          ngModel.$parsers.push(function (val) {
+            update(true);return val;
+          });
+          ngModel.$formatters.push(function (val) {
+            update(true);return val;
+          });
+          once();
+        }
+      });
+
+      // We watch for changes in $error
+      scope.$watchCollection('ngModel.$error', function () {
+        update(!!scope.ngModel);
+      });
+    }
+  };
+};
+
+/***/ },
+/* 10 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
+
+
+/*
+FIXME: real documentation
+<form sf-form="form"  sf-schema="schema" sf-decorator="foobar"></form>
+*/
+
+/* harmony default export */ exports["a"] = function ($compile, $http, $templateCache, $q, schemaForm, schemaFormDecorators, sfSelect, sfPath, sfBuilder) {
+
+  return {
+    scope: {
+      schema: '=sfSchema',
+      initialForm: '=sfForm',
+      model: '=sfModel',
+      options: '=sfOptions'
+    },
+    controller: ['$scope', function ($scope) {
+      this.evalInParentScope = function (expr, locals) {
+        return $scope.$parent.$eval(expr, locals);
+      };
+
+      // Set up form lookup map
+      var that = this;
+      $scope.lookup = function (lookup) {
+        if (lookup) {
+          that.lookup = lookup;
+        }
+        return that.lookup;
+      };
+    }],
+    replace: false,
+    restrict: 'A',
+    transclude: true,
+    require: '?form',
+    link: function link(scope, element, attrs, formCtrl, transclude) {
+
+      //expose form controller on scope so that we don't force authors to use name on form
+      scope.formCtrl = formCtrl;
+
+      //We'd like to handle existing markup,
+      //besides using it in our template we also
+      //check for ng-model and add that to an ignore list
+      //i.e. even if form has a definition for it or form is ["*"]
+      //we don't generate it.
+      var ignore = {};
+      transclude(scope, function (clone) {
+        clone.addClass('schema-form-ignore');
+        element.prepend(clone);
+
+        if (element[0].querySelectorAll) {
+          var models = element[0].querySelectorAll('[ng-model]');
+          if (models) {
+            for (var i = 0; i < models.length; i++) {
+              var key = models[i].getAttribute('ng-model');
+              //skip first part before .
+              ignore[key.substring(key.indexOf('.') + 1)] = true;
+            }
+          }
+        }
+      });
+
+      var lastDigest = {};
+      var childScope;
+
+      // Common renderer function, can either be triggered by a watch or by an event.
+      var render = function render(schema, form) {
+        var asyncTemplates = [];
+        var merged = schemaForm.merge(schema, form, ignore, scope.options, undefined, asyncTemplates);
+
+        if (asyncTemplates.length > 0) {
+          // Pre load all async templates and put them on the form for the builder to use.
+          $q.all(asyncTemplates.map(function (form) {
+            return $http.get(form.templateUrl, { cache: $templateCache }).then(function (res) {
+              form.template = res.data;
+            });
+          })).then(function () {
+            internalRender(schema, form, merged);
+          });
+        } else {
+          internalRender(schema, form, merged);
+        };
+      };
+
+      var internalRender = function internalRender(schema, form, merged) {
+        // Create a new form and destroy the old one.
+        // Not doing keeps old form elements hanging around after
+        // they have been removed from the DOM
+        // https://github.com/Textalk/angular-schema-form/issues/200
+        if (childScope) {
+          // Destroy strategy should not be acted upon
+          scope.externalDestructionInProgress = true;
+          childScope.$destroy();
+          scope.externalDestructionInProgress = false;
+        };
+        childScope = scope.$new();
+
+        //make the form available to decorators
+        childScope.schemaForm = { form: merged, schema: schema };
+
+        //clean all but pre existing html.
+        element.children(':not(.schema-form-ignore)').remove();
+
+        // Find all slots.
+        var slots = {};
+        var slotsFound = element[0].querySelectorAll('*[sf-insert-field]');
+
+        for (var i = 0; i < slotsFound.length; i++) {
+          slots[slotsFound[i].getAttribute('sf-insert-field')] = slotsFound[i];
+        }
+
+        // if sfUseDecorator is undefined the default decorator is used.
+        var decorator = schemaFormDecorators.decorator(attrs.sfUseDecorator);
+        // Use the builder to build it and append the result
+        var lookup = Object.create(null);
+        scope.lookup(lookup); // give the new lookup to the controller.
+        element[0].appendChild(sfBuilder.build(merged, decorator, slots, lookup));
+
+        // We need to know if we're in the first digest looping
+        // I.e. just rendered the form so we know not to validate
+        // empty fields.
+        childScope.firstDigest = true;
+        // We use a ordinary timeout since we don't need a digest after this.
+        setTimeout(function () {
+          childScope.firstDigest = false;
+        }, 0);
+
+        //compile only children
+        $compile(element.children())(childScope);
+
+        //ok, now that that is done let's set any defaults
+        if (!scope.options || scope.options.setSchemaDefaults !== false) {
+          schemaForm.traverseSchema(schema, function (prop, path) {
+            if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isDefined(prop['default'])) {
+              var val = sfSelect(path, scope.model);
+              if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isUndefined(val)) {
+                sfSelect(path, scope.model, prop['default']);
+              }
+            }
+          });
+        }
+
+        scope.$emit('sf-render-finished', element);
+      };
+
+      var defaultForm = ['*'];
+
+      //Since we are dependant on up to three
+      //attributes we'll do a common watch
+      scope.$watch(function () {
+        var schema = scope.schema;
+        var form = scope.initialForm || defaultForm;
+
+        //The check for schema.type is to ensure that schema is not {}
+        if (form && schema && schema.type && (lastDigest.form !== form || lastDigest.schema !== schema) && Object.keys(schema.properties).length > 0) {
+          lastDigest.schema = schema;
+          lastDigest.form = form;
+
+          render(schema, form);
+        }
+      });
+
+      // We also listen to the event schemaFormRedraw so you can manually trigger a change if
+      // part of the form or schema is chnaged without it being a new instance.
+      scope.$on('schemaFormRedraw', function () {
+        var schema = scope.schema;
+        var form = scope.initialForm ? __WEBPACK_IMPORTED_MODULE_0_angular___default.a.copy(scope.initialForm) : ['*'];
+        if (schema) {
+          render(schema, form);
+        }
+      });
+
+      scope.$on('$destroy', function () {
+        // Each field listens to the $destroy event so that it can remove any value
+        // from the model if that field is removed from the form. This is the default
+        // destroy strategy. But if the entire form (or at least the part we're on)
+        // gets removed, like when routing away to another page, then we definetly want to
+        // keep the model intact. So therefore we set a flag to tell the others it's time to just
+        // let it be.
+        scope.externalDestructionInProgress = true;
+      });
+
+      /**
+       * Evaluate an expression, i.e. scope.$eval
+       * but do it in parent scope
+       *
+       * @param {String} expression
+       * @param {Object} locals (optional)
+       * @return {Any} the result of the expression
+       */
+      scope.evalExpr = function (expression, locals) {
+        return scope.$parent.$eval(expression, locals);
+      };
+    }
+  };
+};
+
+/***/ },
+/* 11 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
+
+
+/* harmony default export */ exports["a"] = function ($compileProvider, sfPathProvider) {
+  var defaultDecorator = '';
+  var decorators = {};
+
+  // Map template after decorator and type.
+  var templateUrl = function templateUrl(name, form) {
+    //schemaDecorator is alias for whatever is set as default
+    if (name === 'sfDecorator') {
+      name = defaultDecorator;
+    }
+
+    var decorator = decorators[name];
+    if (decorator[form.type]) {
+      return decorator[form.type].template;
+    }
+
+    //try default
+    return decorator['default'].template;
+  };
+
+  /**************************************************
+   * DEPRECATED                                     *
+   * The new builder and sf-field is preferred, but *
+   * we keep this in during a transitional period   *
+   * so that add-ons that don't use the new builder *
+   * works.                                         *
+   **************************************************/
+  //TODO: Move to a compatability extra script.
+  var createDirective = function createDirective(name) {
+    $compileProvider.directive(name, ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', function ($parse, $compile, $http, $templateCache, $interpolate, $q, sfErrorMessage, sfPath, sfSelect) {
+
+      return {
+        restrict: 'AE',
+        replace: false,
+        transclude: false,
+        scope: true,
+        require: ['?^sfSchema', '?^form'],
+        link: function link(scope, element, attrs, ctrl) {
+          var sfSchema = ctrl[0];
+          var formCtrl = ctrl[1];
+
+          //The ngModelController is used in some templates and
+          //is needed for error messages,
+          scope.$on('schemaFormPropagateNgModelController', function (event, ngModel) {
+            event.stopPropagation();
+            event.preventDefault();
+            scope.ngModel = ngModel;
+          });
+
+          //Keep error prone logic from the template
+          scope.showTitle = function () {
+            return scope.form && scope.form.notitle !== true && scope.form.title;
+          };
+
+          //Normalise names and ids
+          scope.fieldId = function (prependFormName, omitArrayIndexes) {
+            var key = scope.parentKey || [];
+            if (scope.form.key) {
+              if (typeof key[key.length - 1] === 'number') {
+                var combinedKey = key.concat(scope.form.key.slice(-1));
+                var formName = prependFormName && formCtrl && formCtrl.$name ? formCtrl.$name : undefined;
+                return sfPath.name(combinedKey, '-', formName, omitArrayIndexes);
+              } else {
+                var formName = prependFormName && formCtrl && formCtrl.$name ? formCtrl.$name : undefined;
+                return sfPath.name(scope.form.key, '-', formName, omitArrayIndexes);
+              }
+            } else {
+              return '';
+            }
+          };
+
+          scope.listToCheckboxValues = function (list) {
+            var values = {};
+            __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(list, function (v) {
+              values[v] = true;
+            });
+            return values;
+          };
+
+          scope.checkboxValuesToList = function (values) {
+            var lst = [];
+            __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(values, function (v, k) {
+              if (v) {
+                lst.push(k);
+              }
+            });
+            return lst;
+          };
+
+          scope.buttonClick = function ($event, form) {
+            if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isFunction(form.onClick)) {
+              form.onClick($event, form);
+            } else if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isString(form.onClick)) {
+              if (sfSchema) {
+                //evaluating in scope outside of sfSchemas isolated scope
+                sfSchema.evalInParentScope(form.onClick, { '$event': $event, form: form });
+              } else {
+                scope.$eval(form.onClick, { '$event': $event, form: form });
+              };
+            };
+          };
+
+          /**
+           * Evaluate an expression, i.e. scope.$eval
+           * but do it in sfSchemas parent scope sf-schema directive is used
+           *
+           * @param {string} expression
+           * @param {Object} locals (optional)
+           * @return {Any} the result of the expression
+           */
+          scope.evalExpr = function (expression, locals) {
+            if (sfSchema) {
+              //evaluating in scope outside of sfSchemas isolated scope
+              return sfSchema.evalInParentScope(expression, locals);
+            }
+
+            return scope.$eval(expression, locals);
+          };
+
+          /**
+           * Evaluate an expression, i.e. scope.$eval
+           * in this decorators scope
+           *
+           * @param {string} expression
+           * @param {Object} locals (optional)
+           * @return {Any} the result of the expression
+           */
+          scope.evalInScope = function (expression, locals) {
+            if (expression) {
+              return scope.$eval(expression, locals);
+            }
+          };
+
+          /**
+           * Interpolate the expression.
+           * Similar to `evalExpr()` and `evalInScope()`
+           * but will not fail if the expression is
+           * text that contains spaces.
+           *
+           * Use the Angular `{{ interpolation }}`
+           * braces to access properties on `locals`.
+           *
+           * @param  {string} expression The string to interpolate.
+           * @param  {Object} locals (optional) Properties that may be accessed in the
+           *                         `expression` string.
+           * @return {Any} The result of the expression or `undefined`.
+           */
+          scope.interp = function (expression, locals) {
+            return expression && $interpolate(expression)(locals);
+          };
+
+          //This works since we ot the ngModel from the array or the schema-validate directive.
+          scope.hasSuccess = function () {
+            if (!scope.ngModel) {
+              return false;
+            }
+            if (scope.options && scope.options.pristine && scope.options.pristine.success === false) {
+              return scope.ngModel.$valid && !scope.ngModel.$pristine && !scope.ngModel.$isEmpty(scope.ngModel.$modelValue);
+            } else {
+              return scope.ngModel.$valid && (!scope.ngModel.$pristine || !scope.ngModel.$isEmpty(scope.ngModel.$modelValue));
+            }
+          };
+
+          scope.hasError = function () {
+            if (!scope.ngModel) {
+              return false;
+            }
+            return scope.ngModel.$invalid && !scope.ngModel.$pristine;
+          };
+
+          /**
+           * DEPRECATED: use sf-messages instead.
+           * Error message handler
+           * An error can either be a schema validation message or a angular js validtion
+           * error (i.e. required)
+           */
+          scope.errorMessage = function (schemaError) {
+            return sfErrorMessage.interpolate(schemaError && schemaError.code + '' || 'default', scope.ngModel && scope.ngModel.$modelValue || '', scope.ngModel && scope.ngModel.$viewValue || '', scope.form, scope.options && scope.options.validationMessage);
+          };
+
+          // Rebind our part of the form to the scope.
+          var once = scope.$watch(attrs.form, function (form) {
+            if (form) {
+              // Workaround for 'updateOn' error from ngModelOptions
+              // see https://github.com/Textalk/angular-schema-form/issues/255
+              // and https://github.com/Textalk/angular-schema-form/issues/206
+              form.ngModelOptions = form.ngModelOptions || {};
+              scope.form = form;
+
+              //ok let's replace that template!
+              //We do this manually since we need to bind ng-model properly and also
+              //for fieldsets to recurse properly.
+              var templatePromise;
+
+              // type: "template" is a special case. It can contain a template inline or an url.
+              // otherwise we find out the url to the template and load them.
+              if (form.type === 'template' && form.template) {
+                templatePromise = $q.when(form.template);
+              } else {
+                var url = form.type === 'template' ? form.templateUrl : templateUrl(name, form);
+                templatePromise = $http.get(url, { cache: $templateCache }).then(function (res) {
+                  return res.data;
+                });
+              }
+
+              templatePromise.then(function (template) {
+                if (form.key) {
+                  var key = form.key ? sfPathProvider.stringify(form.key).replace(/"/g, '&quot;') : '';
+                  template = template.replace(/\$\$value\$\$/g, 'model' + (key[0] !== '[' ? '.' : '') + key);
+                }
+                element.html(template);
+
+                // Do we have a condition? Then we slap on an ng-if on all children,
+                // but be nice to existing ng-if.
+                if (form.condition) {
+
+                  var evalExpr = 'evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';
+                  if (form.key) {
+                    evalExpr = 'evalExpr(form.condition, {' + 'model: model, "arrayIndex": arrayIndex, "modelValue": model' + sfPath.stringify(form.key) + '})';
+                  }
+
+                  __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(element.children(), function (child) {
+                    var ngIf = child.getAttribute('ng-if');
+                    child.setAttribute('ng-if', ngIf ? '(' + ngIf + ') || (' + evalExpr + ')' : evalExpr);
+                  });
+                }
+                $compile(element.contents())(scope);
+              });
+
+              // Where there is a key there is probably a ngModel
+              if (form.key) {
+                // It looks better with dot notation.
+                scope.$on('schemaForm.error.' + form.key.join('.'), function (event, error, validationMessage, validity, formName) {
+                  // validationMessage and validity are mutually exclusive
+                  formName = validity;
+                  if (validationMessage === true || validationMessage === false) {
+                    validity = validationMessage;
+                    validationMessage = undefined;
+                  };
+
+                  // If we have specified a form name, and this model is not within
+                  // that form, then leave things be.
+                  if (formName != undefined && scope.ngModel.$$parentForm.$name !== formName) {
+                    return;
+                  };
+
+                  // If we have specified a form name, and this model is not within
+                  // that form, then leave things be.
+                  if (formName != undefined && scope.ngModel.$$parentForm.$name !== formName) {
+                    return;
+                  }
+
+                  if (scope.ngModel && error) {
+                    if (scope.ngModel.$setDirty) {
+                      scope.ngModel.$setDirty();
+                    } else {
+                      // FIXME: Check that this actually works on 1.2
+                      scope.ngModel.$dirty = true;
+                      scope.ngModel.$pristine = false;
+                    };
+
+                    // Set the new validation message if one is supplied
+                    // Does not work when validationMessage is just a string.
+                    if (validationMessage) {
+                      if (!form.validationMessage) {
+                        form.validationMessage = {};
+                      }
+                      form.validationMessage[error] = validationMessage;
+                    }
+
+                    scope.ngModel.$setValidity(error, validity === true);
+
+                    if (validity === true) {
+                      // Re-trigger model validator, that model itself would be re-validated
+                      scope.ngModel.$validate();
+
+                      // Setting or removing a validity can change the field to believe its valid
+                      // but its not. So lets trigger its validation as well.
+                      scope.$broadcast('schemaFormValidate');
+                    }
+                  }
+                });
+
+                // Clean up the model when the corresponding form field is $destroy-ed.
+                // Default behavior can be supplied as a globalOption, and behavior can be overridden
+                // in the form definition.
+                scope.$on('$destroy', function () {
+                  // If the entire schema form is destroyed we don't touch the model
+                  if (!scope.externalDestructionInProgress) {
+                    var destroyStrategy = form.destroyStrategy || scope.options && scope.options.destroyStrategy || 'remove';
+                    // No key no model, and we might have strategy 'retain'
+                    if (form.key && destroyStrategy !== 'retain') {
+
+                      // Get the object that has the property we wan't to clear.
+                      var obj = scope.model;
+                      if (form.key.length > 1) {
+                        obj = sfSelect(form.key.slice(0, form.key.length - 1), obj);
+                      }
+
+                      // We can get undefined here if the form hasn't been filled out entirely
+                      if (obj === undefined) {
+                        return;
+                      }
+
+                      // Type can also be a list in JSON Schema
+                      var type = form.schema && form.schema.type || '';
+
+                      // Empty means '',{} and [] for appropriate types and undefined for the rest
+                      if (destroyStrategy === 'empty' && type.indexOf('string') !== -1) {
+                        obj[form.key.slice(-1)] = '';
+                      } else if (destroyStrategy === 'empty' && type.indexOf('object') !== -1) {
+                        obj[form.key.slice(-1)] = {};
+                      } else if (destroyStrategy === 'empty' && type.indexOf('array') !== -1) {
+                        obj[form.key.slice(-1)] = [];
+                      } else if (destroyStrategy === 'null') {
+                        obj[form.key.slice(-1)] = null;
+                      } else {
+                        delete obj[form.key.slice(-1)];
+                      }
+                    }
+                  }
+                });
+              }
+
+              once();
+            }
+          });
+        }
+      };
+    }]);
+  };
+
+  var createManualDirective = function createManualDirective(type, templateUrl, transclude) {
+    transclude = __WEBPACK_IMPORTED_MODULE_0_angular___default.a.isDefined(transclude) ? transclude : false;
+    $compileProvider.directive('sf' + __WEBPACK_IMPORTED_MODULE_0_angular___default.a.uppercase(type[0]) + type.substr(1), function () {
+      return {
+        restrict: 'EAC',
+        scope: true,
+        replace: true,
+        transclude: transclude,
+        template: '<sf-decorator form="form"></sf-decorator>',
+        link: function link(scope, element, attrs) {
+          var watchThis = {
+            'items': 'c',
+            'titleMap': 'c',
+            'schema': 'c'
+          };
+          var form = { type: type };
+          var once = true;
+          __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(attrs, function (value, name) {
+            if (name[0] !== '$' && name.indexOf('ng') !== 0 && name !== 'sfField') {
+
+              var updateForm = function updateForm(val) {
+                if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isDefined(val) && val !== form[name]) {
+                  form[name] = val;
+
+                  //when we have type, and if specified key we apply it on scope.
+                  if (once && form.type && (form.key || __WEBPACK_IMPORTED_MODULE_0_angular___default.a.isUndefined(attrs.key))) {
+                    scope.form = form;
+                    once = false;
+                  }
+                }
+              };
+
+              if (name === 'model') {
+                //"model" is bound to scope under the name "model" since this is what the decorators
+                //know and love.
+                scope.$watch(value, function (val) {
+                  if (val && scope.model !== val) {
+                    scope.model = val;
+                  }
+                });
+              } else if (watchThis[name] === 'c') {
+                //watch collection
+                scope.$watchCollection(value, updateForm);
+              } else {
+                //$observe
+                attrs.$observe(name, updateForm);
+              }
+            }
+          });
+        }
+      };
+    });
+  };
+
+  /**
+   * DEPRECATED: use defineDecorator instead.
+   * Create a decorator directive and its sibling "manual" use decorators.
+   * The directive can be used to create form fields or other form entities.
+   * It can be used in conjunction with <schema-form> directive in which case the decorator is
+   * given it's configuration via a the "form" attribute.
+   *
+   * ex. Basic usage
+   *   <sf-decorator form="myform"></sf-decorator>
+   **
+   * @param {string} name directive name (CamelCased)
+   * @param {Object} templates, an object that maps "type" => "templateUrl"
+   */
+  this.createDecorator = function (name, templates) {
+    //console.warn('schemaFormDecorators.createDecorator is DEPRECATED, use defineDecorator instead.');
+    decorators[name] = { '__name': name };
+
+    __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(templates, function (url, type) {
+      decorators[name][type] = { template: url, replace: false, builder: [] };
+    });
+
+    if (!decorators[defaultDecorator]) {
+      defaultDecorator = name;
+    }
+    createDirective(name);
+  };
+
+  /**
+   * Define a decorator. A decorator is a set of form types with templates and builder functions
+   * that help set up the form.
+   *
+   * @param {string} name directive name (CamelCased)
+   * @param {Object} fields, an object that maps "type" => `{ template, builder, replace}`.
+                     attributes `builder` and `replace` are optional, and replace defaults to true.
+                       `template` should be the key of the template to load and it should be pre-loaded
+                     in `$templateCache`.
+                       `builder` can be a function or an array of functions. They will be called in
+                     the order they are supplied.
+                       `replace` (DEPRECATED) is for backwards compatability. If false the builder
+                     will use the "old" way of building that form field using a <sf-decorator>
+                     directive.
+   */
+  this.defineDecorator = function (name, fields) {
+    decorators[name] = { '__name': name }; // TODO: this feels like a hack, come up with a better way.
+
+    __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(fields, function (field, type) {
+      field.builder = field.builder || [];
+      field.replace = __WEBPACK_IMPORTED_MODULE_0_angular___default.a.isDefined(field.replace) ? field.replace : true;
+      decorators[name][type] = field;
+    });
+
+    if (!decorators[defaultDecorator]) {
+      defaultDecorator = name;
+    }
+    createDirective(name);
+  };
+
+  /**
+   * DEPRECATED
+   * Creates a directive of a decorator
+   * Usable when you want to use the decorators without using <schema-form> directive.
+   * Specifically when you need to reuse styling.
+   *
+   * ex. createDirective('text','...')
+   *  <sf-text title="foobar" model="person" key="name" schema="schema"></sf-text>
+   *
+   * @param {string}  type The type of the directive, resulting directive will have sf- prefixed
+   * @param {string}  templateUrl
+   * @param {boolean} transclude (optional) sets transclude option of directive, defaults to false.
+   */
+  this.createDirective = createManualDirective;
+
+  /**
+   * DEPRECATED
+   * Same as createDirective, but takes an object where key is 'type' and value is 'templateUrl'
+   * Useful for batching.
+   *
+   * @param {Object} templates
+   */
+  this.createDirectives = function (templates) {
+    __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(templates, function (url, type) {
+      createManualDirective(type, url);
+    });
+  };
+
+  /**
+   * Getter for decorator settings
+   *
+   * @param {string} name (optional) defaults to defaultDecorator
+   * @return {Object} rules and templates { rules: [],templates: {}}
+   */
+  this.decorator = function (name) {
+    name = name || defaultDecorator;
+    return decorators[name];
+  };
+
+  /**
+   * DEPRECATED use defineAddOn() instead.
+   * Adds a mapping to an existing decorator.
+   *
+   * @param {String} name Decorator name
+   * @param {String} type Form type for the mapping
+   * @param {String} url  The template url
+   * @param {Function} builder (optional) builder function
+   * @param {boolean} replace (optional) defaults to false. Replace decorator directive with template.
+   */
+  this.addMapping = function (name, type, url, builder, replace) {
+    if (decorators[name]) {
+      decorators[name][type] = {
+        template: url,
+        builder: builder,
+        replace: !!replace
+      };
+    }
+  };
+
+  /**
+   * Adds an add-on to an existing decorator.
+   *
+   * @param {String} name Decorator name
+   * @param {String} type Form type for the mapping
+   * @param {String} url  The template url
+   * @param {Function|Array} builder (optional) builder function(s),
+   */
+  this.defineAddOn = function (name, type, url, builder) {
+    if (decorators[name]) {
+      decorators[name][type] = {
+        template: url,
+        builder: builder,
+        replace: true
+      };
+    }
+  };
+
+  //Service is just a getter for directive templates and rules
+  this.$get = function () {
+    return {
+      decorator: function decorator(name) {
+        return decorators[name] || decorators[defaultDecorator];
+      },
+      defaultDecorator: defaultDecorator
+    };
+  };
+
+  //Create a default directive
+  createDirective('sfDecorator');
+};;
+
+/***/ },
+/* 12 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__ = __webpack_require__(1);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__);
+
+
+
+
+/**
+ * Schema form service.
+ */
+/* harmony default export */ exports["a"] = function () {
+  var postProcessFn = function postProcessFn(form) {
+    return form;
+  };
+  var defaults = __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["schemaDefaults"].createDefaults();
+
+  /**
+   * Provider API
+   */
+  this.defaults = defaults;
+  this.stdFormObj = __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["schemaDefaults"].stdFormObj;
+  this.defaultFormDefinition = __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["schemaDefaults"].defaultFormDefinition;
+
+  /**
+   * Register a post process function.
+   * This function is called with the fully merged
+   * form definition (i.e. after merging with schema)
+   * and whatever it returns is used as form.
+   */
+  this.postProcess = function (fn) {
+    postProcessFn = fn;
+  };
+
+  /**
+   * Append default form rule
+   *
+   * @param {string}   type json schema type
+   * @param {Function} rule a function(propertyName,propertySchema,options) that returns a form
+   *                        definition or undefined
+   */
+  this.appendRule = function (type, rule) {
+    if (!this.defaults[type]) {
+      this.defaults[type] = [];
+    }
+    this.defaults[type].push(rule);
+  };
+
+  /**
+   * Prepend default form rule
+   *
+   * @param {string}   type json schema type
+   * @param {Function} rule a function(propertyName,propertySchema,options) that returns a form
+   *                        definition or undefined
+   */
+  this.prependRule = function (type, rule) {
+    if (!this.defaults[type]) {
+      this.defaults[type] = [];
+    }
+    this.defaults[type].unshift(rule);
+  };
+
+  /**
+   * Utility function to create a standard form object.
+   * This does *not* set the type of the form but rather all shared attributes.
+   * You probably want to start your rule with creating the form with this method
+   * then setting type and any other values you need.
+   * @param {Object} schema
+   * @param {Object} options
+   * @return {Object} a form field defintion
+   */
+  this.createStandardForm = __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["schemaDefaults"].stdFormObj;
+  /* End Provider API */
+
+  this.$get = function () {
+
+    var service = {};
+    var typeDefault = this.defaults;
+
+    service.merge = function (schema) {
+      var form = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ['*'];
+      var ignore = arguments[2];
+      var options = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};
+      var readonly = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : false;
+      var asyncTemplates = arguments[5];
+
+      //We look at the supplied form and extend it with schema standards
+      var canonical = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["merge"])(schema, form, ignore, options, readonly, asyncTemplates);
+      return postProcessFn(canonical);
+    };
+
+    /**
+     * Create form defaults from schema
+     */
+    service.defaults = function (schema, types, ignore, options) {
+      var defaultTypes = types || typeDefault;
+      return __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["schemaDefaults"].defaultForm(schema, defaultTypes, ignore, options);
+    };
+
+    //Utility functions
+    /**
+     * Form defaults for schema by type
+     * As a form is generated from a schema these are the definitions of each json-schema type
+     */
+    service.typeDefault = typeDefault;
+
+    /**
+     * Traverse a schema, applying a function(schema,path) on every sub schema
+     * i.e. every property of an object.
+     */
+    service.traverseSchema = __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["traverseSchema"];
+
+    service.traverseForm = __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["traverseForm"];
+
+    return service;
+  };
+};
+
+/***/ },
+/* 13 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+
+// FIXME: type template (using custom builder)
+/* harmony default export */ exports["a"] = function (sfPathProvider) {
+
+  var SNAKE_CASE_REGEXP = /[A-Z]/g;
+  var snakeCase = function snakeCase(name, separator) {
+    separator = separator || '_';
+    return name.replace(SNAKE_CASE_REGEXP, function (letter, pos) {
+      return (pos ? separator : '') + letter.toLowerCase();
+    });
+  };
+  var formId = 0;
+
+  if (!("firstElementChild" in document.createDocumentFragment())) {
+    Object.defineProperty(DocumentFragment.prototype, "firstElementChild", {
+      get: function get() {
+        for (var nodes = this.childNodes, n, i = 0, l = nodes.length; i < l; ++i) {
+          if (n = nodes[i], 1 === n.nodeType) return n;
+        }return null;
+      }
+    });
+  }
+
+  var builders = {
+    sfField: function sfField(args) {
+      args.fieldFrag.firstElementChild.setAttribute('sf-field', formId);
+
+      // We use a lookup table for easy access to our form.
+      args.lookup['f' + formId] = args.form;
+      formId++;
+    },
+    ngModel: function ngModel(args) {
+      if (!args.form.key) {
+        return;
+      }
+      var key = args.form.key;
+
+      // Redact part of the key, used in arrays
+      // KISS keyRedaction is a number.
+      if (args.state.keyRedaction) {
+        key = key.slice(args.state.keyRedaction);
+      }
+
+      // Stringify key.
+      var modelValue;
+      if (!args.state.modelValue) {
+        var strKey = sfPathProvider.stringify(key).replace(/"/g, '&quot;');
+        modelValue = args.state.modelName || 'model';
+
+        if (strKey) {
+          // Sometimes, like with arrays directly in arrays strKey is nothing.
+          modelValue += (strKey[0] !== '[' ? '.' : '') + strKey;
+        }
+      } else {
+        // Another builder, i.e. array has overriden the modelValue
+        modelValue = args.state.modelValue;
+      }
+
+      // Find all sf-field-value attributes.
+      // No value means a add a ng-model.
+      // sf-field-value="replaceAll", loop over attributes and replace $$value$$ in each.
+      // sf-field-value="attrName", replace or set value of that attribute.
+      var nodes = args.fieldFrag.querySelectorAll('[sf-field-model]');
+      for (var i = 0; i < nodes.length; i++) {
+        var n = nodes[i];
+        var conf = n.getAttribute('sf-field-model');
+        if (!conf || conf === '') {
+          n.setAttribute('ng-model', modelValue);
+        } else if (conf === 'replaceAll') {
+          var attributes = n.attributes;
+          for (var j = 0; j < attributes.length; j++) {
+            if (attributes[j].value && attributes[j].value.indexOf('$$value') !== -1) {
+              attributes[j].value = attributes[j].value.replace(/\$\$value\$\$/g, modelValue);
+            }
+          }
+        } else {
+          var val = n.getAttribute(conf);
+          if (val && val.indexOf('$$value$$')) {
+            n.setAttribute(conf, val.replace(/\$\$value\$\$/g, modelValue));
+          } else {
+            n.setAttribute(conf, modelValue);
+          }
+        }
+      }
+    },
+    simpleTransclusion: function simpleTransclusion(args) {
+      var children = args.build(args.form.items, args.path + '.items', args.state);
+      args.fieldFrag.firstChild.appendChild(children);
+    },
+
+    // Patch on ngModelOptions, since it doesn't like waiting for its value.
+    ngModelOptions: function ngModelOptions(args) {
+      if (args.form.ngModelOptions && Object.keys(args.form.ngModelOptions).length > 0) {
+        args.fieldFrag.firstChild.setAttribute('ng-model-options', JSON.stringify(args.form.ngModelOptions));
+      }
+    },
+    transclusion: function transclusion(args) {
+      var transclusions = args.fieldFrag.querySelectorAll('[sf-field-transclude]');
+
+      if (transclusions.length) {
+        for (var i = 0; i < transclusions.length; i++) {
+          var n = transclusions[i];
+
+          // The sf-transclude attribute is not a directive,
+          // but has the name of what we're supposed to
+          // traverse. Default to `items`
+          var sub = n.getAttribute('sf-field-transclude') || 'items';
+          var items = args.form[sub];
+
+          if (items) {
+            var childFrag = args.build(items, args.path + '.' + sub, args.state);
+            n.appendChild(childFrag);
+          }
+        }
+      }
+    },
+    condition: function condition(args) {
+      var strKey = '';
+      var strModel = 'undefined';
+      var ngIf = '';
+      // Do we have a condition? Then we slap on an ng-if on all children,
+      // but be nice to existing ng-if.
+      if (args.form.condition) {
+        if (args.form.key) {
+          strKey = sfPathProvider.stringify(args.form.key);
+          strModel = 'model' + (strKey[0] === '[' ? '' : '.') + strKey;
+        }
+
+        var evalExpr = 'evalExpr(' + args.path + '.condition, { model: model, ' + '"arrayIndex": $index, ' + '"arrayIndices": arrayIndices, ' + '"path": path, ' + '"$i": $i, ' + '"$index": $index, ' + '"modelValue": ' + strModel + '})';
+
+        var children = args.fieldFrag.children || args.fieldFrag.childNodes;
+
+        for (var i = 0; i < children.length; i++) {
+          var child = children[i];
+
+          if (child.hasAttribute && child.hasAttribute('ng-if')) {
+            ngIf = child.getAttribute('ng-if');
+          };
+
+          if (child.setAttribute) {
+            child.setAttribute('ng-if', ngIf ? '(' + ngIf + ') || (' + evalExpr + ')' : evalExpr);
+          };
+        }
+      }
+    },
+    array: function array(args) {
+      var items = args.fieldFrag.querySelector('[schema-form-array-items]');
+
+      if (args.form.key) {
+        var arrayDepth = args.form.key.filter(function (e) {
+          return e === '';
+        }).length;
+      }
+
+      if (items) {
+        var state = angular.copy(args.state);
+        state.keyRedaction = 0;
+        state.keyRedaction += args.form.key.length + 1;
+
+        // Special case, an array with just one item in it that is not an object.
+        // So then we just override the modelValue
+        if (args.form.schema && args.form.schema.items && args.form.schema.items.type && args.form.schema.items.type.indexOf('object') === -1 && args.form.schema.items.type.indexOf('array') === -1) {
+          var strKey = sfPathProvider.stringify(args.form.key).replace(/"/g, '&quot;') + '[$index]';
+          state.modelValue = 'modelArray[$index]';
+        } else {
+          state.modelName = 'item';
+        }
+
+        // Flag to the builder that we're in an array.
+        // This is needed for compatabiliy if a "old" add-on is used that
+        // hasn't been transitioned to the new builder.
+        state.arrayCompatFlag = true;
+
+        var childFrag = args.build(args.form.items, args.path + '.items', state);
+        items.appendChild(childFrag);
+      }
+    },
+    numeric: function numeric(args) {
+      var inputFrag = args.fieldFrag.querySelector('input');
+      var maximum = args.form.maximum || false;
+      var exclusiveMaximum = args.form.exclusiveMaximum || false;
+      var minimum = args.form.minimum || false;
+      var exclusiveMinimum = args.form.exclusiveMinimum || false;
+      var multipleOf = args.form.multipleOf || false;
+      if (inputFrag) {
+        if (multipleOf !== false) {
+          inputFrag.setAttribute('step', multipleOf);
+        };
+
+        if (maximum !== false) {
+          if (exclusiveMaximum !== false && multipleOf !== false) {
+            maximum = maximum - multipleOf;
+          };
+          inputFrag.setAttribute('max', maximum);
+        };
+
+        if (minimum !== false) {
+          if (exclusiveMinimum !== false && multipleOf !== false) {
+            minimum = minimum + multipleOf;
+          };
+          inputFrag.setAttribute('min', minimum);
+        };
+      };
+    }
+  };
+  this.builders = builders;
+  var stdBuilders = [builders.sfField, builders.ngModel, builders.ngModelOptions, builders.condition];
+  this.stdBuilders = stdBuilders;
+
+  this.$get = ['$templateCache', 'schemaFormDecorators', 'sfPath', function ($templateCache, schemaFormDecorators, sfPath) {
+    var checkForSlot = function checkForSlot(form, slots) {
+      // Finally append this field to the frag.
+      // Check for slots
+      if (form.key) {
+        var slot = slots[sfPath.stringify(form.key)];
+        if (slot) {
+          while (slot.firstChild) {
+            slot.removeChild(slot.firstChild);
+          }
+          return slot;
+        }
+      }
+    };
+
+    var _build = function _build(items, decorator, templateFn, slots, path, state, lookup) {
+      state = state || {};
+      state = state || {};
+      lookup = lookup || Object.create(null);
+      path = path || 'schemaForm.form';
+      var container = document.createDocumentFragment();
+      items.reduce(function (frag, f, index) {
+
+        // Sanity check.
+        if (!f.type) {
+          return frag;
+        }
+
+        var field = decorator[f.type] || decorator['default'];
+        if (!field.replace) {
+          // Backwards compatability build
+          var n = document.createElement(snakeCase(decorator.__name, '-'));
+          if (state.arrayCompatFlag) {
+            n.setAttribute('form', 'copyWithIndex($index)');
+          } else {
+            n.setAttribute('form', path + '[' + index + ']');
+          }
+
+          (checkForSlot(f, slots) || frag).appendChild(n);
+        } else {
+          var tmpl;
+
+          // Reset arrayCompatFlag, it's only valid for direct children of the array.
+          state.arrayCompatFlag = false;
+
+          // TODO: Create a couple of testcases, small and large and
+          //       measure optmization. A good start is probably a
+          //       cache of DOM nodes for a particular template
+          //       that can be cloned instead of using innerHTML
+          var div = document.createElement('div');
+          var template = templateFn(f, field) || templateFn(f, decorator['default']);
+          div.innerHTML = template;
+
+          // Move node to a document fragment, we don't want the div.
+          tmpl = document.createDocumentFragment();
+          while (div.childNodes.length > 0) {
+            tmpl.appendChild(div.childNodes[0]);
+          }
+
+          // Possible builder, often a noop
+          var args = {
+            fieldFrag: tmpl,
+            form: f,
+            lookup: lookup,
+            state: state,
+            path: path + '[' + index + ']',
+
+            // Recursive build fn
+            build: function build(items, path, state) {
+              return _build(items, decorator, templateFn, slots, path, state, lookup);
+            }
+
+          };
+
+          // Let the form definiton override builders if it wants to.
+          var builderFn = f.builder || field.builder;
+
+          // Builders are either a function or a list of functions.
+          if (typeof builderFn === 'function') {
+            builderFn(args);
+          } else {
+            builderFn.forEach(function (fn) {
+              fn(args);
+            });
+          }
+
+          // Append
+          (checkForSlot(f, slots) || frag).appendChild(tmpl);
+        }
+        return frag;
+      }, container);
+
+      return container;
+    };
+
+    return {
+      /**
+       * Builds a form from a canonical form definition
+       */
+      build: function build(form, decorator, slots, lookup) {
+        return _build(form, decorator, function (form, field) {
+          if (form.type === 'template') {
+            return form.template;
+          }
+          return $templateCache.get(field.template);
+        }, slots, undefined, undefined, lookup);
+      },
+      builder: builders,
+      stdBuilders: stdBuilders,
+      internalBuild: _build
+    };
+  }];
+};
+
+/***/ },
+/* 14 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
+
+
+/* harmony default export */ exports["a"] = function () {
+
+  // The codes are tv4 error codes.
+  // Not all of these can actually happen in a field, but for
+  // we never know when one might pop up so it's best to cover them all.
+
+  // TODO: Humanize these.
+  var defaultMessages = {
+    'default': 'Field does not validate',
+    0: 'Invalid type, expected {{schema.type}}',
+    1: 'No enum match for: {{viewValue}}',
+    10: 'Data does not match any schemas from "anyOf"',
+    11: 'Data does not match any schemas from "oneOf"',
+    12: 'Data is valid against more than one schema from "oneOf"',
+    13: 'Data matches schema from "not"',
+    // Numeric errors
+    100: 'Value is not a multiple of {{schema.multipleOf}}',
+    101: '{{viewValue}} is less than the allowed minimum of {{schema.minimum}}',
+    102: '{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}',
+    103: '{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}',
+    104: '{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}',
+    105: 'Value is not a valid number',
+    // String errors
+    200: 'String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}',
+    201: 'String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}',
+    202: 'String does not match pattern: {{schema.pattern}}',
+    // Object errors
+    300: 'Too few properties defined, minimum {{schema.minProperties}}',
+    301: 'Too many properties defined, maximum {{schema.maxProperties}}',
+    302: 'Required',
+    303: 'Additional properties not allowed',
+    304: 'Dependency failed - key must exist',
+    // Array errors
+    400: 'Array is too short ({{value.length}}), minimum {{schema.minItems}}',
+    401: 'Array is too long ({{value.length}}), maximum {{schema.maxItems}}',
+    402: 'Array items are not unique',
+    403: 'Additional items not allowed',
+    // Format errors
+    500: 'Format validation failed',
+    501: 'Keyword failed: "{{title}}"',
+    // Schema structure
+    600: 'Circular $refs',
+    // Non-standard validation options
+    1000: 'Unknown property (not in schema)'
+  };
+
+  // In some cases we get hit with an angular validation error
+  defaultMessages.number = defaultMessages[105];
+  defaultMessages.required = defaultMessages[302];
+  defaultMessages.min = defaultMessages[101];
+  defaultMessages.max = defaultMessages[103];
+  defaultMessages.maxlength = defaultMessages[201];
+  defaultMessages.minlength = defaultMessages[200];
+  defaultMessages.pattern = defaultMessages[202];
+
+  this.setDefaultMessages = function (messages) {
+    defaultMessages = messages;
+  };
+
+  this.getDefaultMessages = function () {
+    return defaultMessages;
+  };
+
+  this.setDefaultMessage = function (error, msg) {
+    defaultMessages[error] = msg;
+  };
+
+  this.$get = ['$interpolate', function ($interpolate) {
+
+    var service = {};
+    service.defaultMessages = defaultMessages;
+
+    /**
+     * Interpolate and return proper error for an eror code.
+     * Validation message on form trumps global error messages.
+     * and if the message is a function instead of a string that function will be called instead.
+     *
+     * @param {string} error the error code, i.e. tv4-xxx for tv4 errors, otherwise it's whats on
+     *                       ngModel.$error for custom errors.
+     * @param {Any} value the actual model value.
+     * @param {Any} viewValue the viewValue
+     * @param {Object} form a form definition object for this field
+     * @param  {Object} global the global validation messages object (even though its called global
+     *                         its actually just shared in one instance of sf-schema)
+     * @return {string} The error message.
+     */
+    service.interpolate = function (error, value, viewValue, form, global) {
+      global = global || {};
+      var validationMessage = form.validationMessage || {};
+
+      // Drop tv4 prefix so only the code is left.
+      if (error.indexOf('tv4-') === 0) {
+        error = error.substring(4);
+      }
+
+      // First find apropriate message or function
+      var message = validationMessage['default'] || global['default'] || '';
+
+      [validationMessage, global, defaultMessages].some(function (val) {
+        if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isString(val) || __WEBPACK_IMPORTED_MODULE_0_angular___default.a.isFunction(val)) {
+          message = val;
+          return true;
+        }
+        if (val && val[error]) {
+          message = val[error];
+          return true;
+        }
+      });
+
+      var context = {
+        error: error,
+        value: value,
+        viewValue: viewValue,
+        form: form,
+        schema: form.schema,
+        title: form.title || form.schema && form.schema.title
+      };
+      if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isFunction(message)) {
+        return message(context);
+      } else {
+        return $interpolate(message)(context);
+      }
+    };
+
+    return service;
+  }];
+};
+
+/***/ },
+/* 15 */
+/***/ function(module, exports, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__ = __webpack_require__(1);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_angular__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_angular__);
+var _createClass = function () { function defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } return function (Constructor, protoProps, staticProps) { if (protoProps) defineProperties(Constructor.prototype, protoProps); if (staticProps) defineProperties(Constructor, staticProps); return Constructor; }; }();
+
+function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
+
+// var JSONSchemaFormCore = require('../../json-schema-form-core/dist/json-schema-form-core');
+// import JSONSchemaFormCore from 'json-schema-form-core';
+
+
+
+var sfPathProviderClass = function () {
+  function sfPathProviderClass() {
+    _classCallCheck(this, sfPathProviderClass);
+
+    this.name = __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__["sfPath"].name;
+    this.parse = __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__["sfPath"].parse;
+    this.stringify = __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__["sfPath"].stringify;
+    this.normalize = __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__["sfPath"].normalize;
+  }
+
+  _createClass(sfPathProviderClass, [{
+    key: '$get',
+    value: function $get() {
+      return __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__["sfPath"];
+    }
+  }]);
+
+  return sfPathProviderClass;
+}();
+
+/* harmony default export */ exports["a"] = sfPathProviderClass;
+
+/***/ },
+/* 16 */
+/***/ function(module, exports, __webpack_require__) {
+
+__webpack_require__(1);
+module.exports = __webpack_require__(3);
+
+
+/***/ }
+/******/ ]);
 
 /***/ },
 /* 19 */,
diff --git a/dist/angular-schema-form-bootstrap-bundled.min.js b/dist/angular-schema-form-bootstrap-bundled.min.js
index c9f597f..c7ecf19 100644
--- a/dist/angular-schema-form-bootstrap-bundled.min.js
+++ b/dist/angular-schema-form-bootstrap-bundled.min.js
@@ -1,23 +1,26 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.1
+ * @date Sat, 14 Jan 2017 17:11:45 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
- * Copyright (c) 2016 JSON Schema Form
+ * Copyright (c) 2014-2017 JSON Schema Form
  */
-(function webpackUniversalModuleDefinition(root,factory){if(typeof exports==="object"&&typeof module==="object")module.exports=factory(require("angular"),require("tv4"));else if(typeof define==="function"&&define.amd)define(["angular","tv4"],factory);else{var a=typeof exports==="object"?factory(require("angular"),require("tv4")):factory(root["angular"],root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_19__,__WEBPACK_EXTERNAL_MODULE_20__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){"use strict";__webpack_require__(18);__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var textareaTemplate=__webpack_require__(17);var fieldsetTemplate=__webpack_require__(7);var arrayTemplate=__webpack_require__(3);var tabarrayTemplate=__webpack_require__(15);var tabsTemplate=__webpack_require__(16);var sectionTemplate=__webpack_require__(12);var actionsTemplate=__webpack_require__(2);var selectTemplate=__webpack_require__(13);var checkboxTemplate=__webpack_require__(4);var checkboxesTemplate=__webpack_require__(5);var submitTemplate=__webpack_require__(14);var radiosTemplate=__webpack_require__(11);var radiosInlineTemplate=__webpack_require__(10);var radiobuttonsTemplate=__webpack_require__(9);var helpTemplate=__webpack_require__(8);var defaultTemplate=__webpack_require__(6);angular.module("schemaForm").config(bootstrapDecoratorConfig).filter("sfCamelKey",sfCamelKeyFilter);bootstrapDecoratorConfig.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"];function bootstrapDecoratorConfig(schemaFormProvider,decoratorsProvider,sfBuilderProvider,sfPathProvider,$injector){var base="decorators/bootstrap/";var simpleTransclusion=sfBuilderProvider.builders.simpleTransclusion;var ngModelOptions=sfBuilderProvider.builders.ngModelOptions;var ngModel=sfBuilderProvider.builders.ngModel;var sfField=sfBuilderProvider.builders.sfField;var condition=sfBuilderProvider.builders.condition;var array=sfBuilderProvider.builders.array;var numeric=sfBuilderProvider.builders.numeric;var tabs=function tabs(args){if(args.form.tabs&&args.form.tabs.length>0){var tabContent=args.fieldFrag.querySelector(".tab-content");args.form.tabs.forEach(function(tab,index){var evalExpr="(evalExpr("+args.path+".tabs["+index+"]"+'.condition, { model: model, "arrayIndex": $index}))';var div=document.createElement("div");div.className="tab-pane";div.setAttribute("ng-disabled","form.readonly");div.setAttribute("ng-show","selected.tab === "+index);div.setAttribute("ng-class","{active: selected.tab === "+index+"}");if(!!tab.condition){div.setAttribute("ng-if",evalExpr)}var childFrag=args.build(tab.items,args.path+".tabs["+index+"].items",args.state);div.appendChild(childFrag);tabContent.appendChild(div)})}};var selectPlaceholder=function selectPlaceholder(args){if(args.form.placeholder){var selectBox=args.fieldFrag.querySelector("select");var option=document.createElement("option");option.setAttribute("value","");option.setAttribute("sf-field-model","replaceAll");if(angular.version.major===1&&angular.version.minor<4){option.setAttribute("ng-if","$$value$$ === undefined")}else{option.setAttribute("ng-show","$$value$$ === undefined")}option.textContent=args.form.placeholder;selectBox.appendChild(option)}};var defaults=[sfField,ngModel,ngModelOptions,condition];decoratorsProvider.defineDecorator("bootstrapDecorator",{actions:{template:actionsTemplate,builder:defaults},array:{template:arrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},button:{template:submitTemplate,builder:defaults},checkbox:{template:checkboxTemplate,builder:defaults},checkboxes:{template:checkboxesTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},conditional:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},default:{template:defaultTemplate,builder:defaults},fieldset:{template:fieldsetTemplate,builder:[sfField,simpleTransclusion,condition]},help:{template:helpTemplate,builder:defaults},number:{template:defaultTemplate,builder:defaults.concat(numeric)},password:{template:defaultTemplate,builder:defaults},radios:{template:radiosTemplate,builder:defaults},"radios-inline":{template:radiosInlineTemplate,builder:defaults},radiobuttons:{template:radiobuttonsTemplate,builder:defaults},section:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},select:{template:selectTemplate,builder:defaults.concat(selectPlaceholder)},submit:{template:submitTemplate,builder:defaults},tabarray:{template:tabarrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},tabs:{template:tabsTemplate,builder:[sfField,ngModelOptions,tabs,condition]},textarea:{template:textareaTemplate,builder:defaults}},[])}function sfCamelKeyFilter(){return function(formKey){if(!formKey){return""}var part,i,key;key=formKey.slice();for(i=0;i<key.length;i++){part=key[i].toLowerCase().split("");if(i&&part.length){part[0]=part[0].toUpperCase()}key[i]=part.join("")}return key.join("")}}},function(module,exports){var path="bootstrap/actions.html";var html='<div class="btn-group schema-form-actions {{::form.htmlClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/array.html";var html='<div  class="schema-form-array {{::form.htmlClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkbox.html";var html='<div class="checkbox schema-form-checkbox {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{form.key.slice(-1)[0]}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkboxes.html";var html='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{form.key.slice(-1)[0]}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/default.html";var html='<div class="form-group {{::form.htmlClass}}"\r\n     ng-class="{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{form.key.slice(-1)[0]}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{form.key.slice(-1)[0]}}"\r\n         aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{form.key.slice(-1)[0]}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{form.key.slice(-1)[0]}}"\r\n           aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{form.key.slice(-1)[0] + \'Status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/fieldset.html";var html='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/help.html";var html='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radio-buttons.html";var html='<div class="form-group schema-form-radiobuttons {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios-inline.html";var html='<div class="form-group schema-form-radios-inline {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios.html";var html='<div class="form-group schema-form-radios {{::form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/section.html";var html='<div class="schema-form-section {{::form.htmlClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/select.html";var html='<div class="form-group {{::form.htmlClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{form.key.slice(-1)[0]}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/submit.html";var html='<div class="form-group schema-form-submit {{::form.htmlClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabarray.html";var html='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabs.html";var html='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/textarea.html";var html='<div class="form-group has-feedback {{::form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{form.key.slice(-1)[0]}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{form.key.slice(-1)[0]}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{form.key.slice(-1)[0]}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{form.key.slice(-1)[0]}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports,__webpack_require__){/*!
-	 * angular-schema-form
-	 * @version 1.0.0-alpha.2
-	 * @link https://github.com/json-schema-form/angular-schema-form
-	 * @license MIT
-	 * Copyright (c) 2016 JSON Schema Form
-	 */
-(function webpackUniversalModuleDefinition(root,factory){if(true)module.exports=factory(__webpack_require__(19),__webpack_require__(20));else if(typeof define==="function"&&define.amd)define(["angular","tv4"],factory);else{var a=typeof exports==="object"?factory(require("angular"),require("tv4")):factory(root["angular"],root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_2__,__WEBPACK_EXTERNAL_MODULE_7__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){module.exports=__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _builder=__webpack_require__(3);var _builder2=_interopRequireDefault(_builder);var _decorators=__webpack_require__(4);var _decorators2=_interopRequireDefault(_decorators);var _schemaForm=__webpack_require__(5);var _schemaForm2=_interopRequireDefault(_schemaForm);var _jsonSchemaFormCore=__webpack_require__(6);var _validator=__webpack_require__(8);var _validator2=_interopRequireDefault(_validator);var _errors=__webpack_require__(9);var _errors2=_interopRequireDefault(_errors);var _sfPath=__webpack_require__(10);var _sfPath2=_interopRequireDefault(_sfPath);var _array=__webpack_require__(11);var _array2=_interopRequireDefault(_array);var _changed=__webpack_require__(12);var _changed2=_interopRequireDefault(_changed);var _field=__webpack_require__(13);var _field2=_interopRequireDefault(_field);var _message=__webpack_require__(14);var _message2=_interopRequireDefault(_message);var _newArray=__webpack_require__(15);var _newArray2=_interopRequireDefault(_newArray);var _keyController=__webpack_require__(16);var _keyController2=_interopRequireDefault(_keyController);var _schemaForm3=__webpack_require__(17);var _schemaForm4=_interopRequireDefault(_schemaForm3);var _schemaValidate=__webpack_require__(18);var _schemaValidate2=_interopRequireDefault(_schemaValidate);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}var deps=[];try{_angular2.default.module("ngSanitize");deps.push("ngSanitize")}catch(e){}try{_angular2.default.module("ui.sortable");deps.push("ui.sortable")}catch(e){}try{_angular2.default.module("angularSpectrumColorpicker");deps.push("angularSpectrumColorpicker")}catch(e){}_angular2.default.module("schemaForm",deps).provider("sfPath",_sfPath2.default).provider("sfBuilder",["sfPathProvider",_builder2.default]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",_decorators2.default]).provider("sfErrorMessage",_errors2.default).provider("schemaForm",["sfPathProvider",_schemaForm2.default]).factory("sfSelect",function(){return _jsonSchemaFormCore.select}).factory("sfValidator",_validator2.default).directive("sfArray",["sfSelect","schemaForm","sfValidator","sfPath",_array2.default]).directive("sfChanged",_changed2.default).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",_field2.default]).directive("sfMessage",["$injector","sfErrorMessage",_message2.default]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",_newArray2.default]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",_schemaForm4.default]).directive("schemaValidate",["sfValidator","$parse","sfSelect",_schemaValidate2.default]).directive("sfKeyController",["schemaForm","sfPath",_keyController2.default])},function(module,exports){module.exports=angular},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfPathProvider){var SNAKE_CASE_REGEXP=/[A-Z]/g;var snakeCase=function snakeCase(name,separator){separator=separator||"_";return name.replace(SNAKE_CASE_REGEXP,function(letter,pos){return(pos?separator:"")+letter.toLowerCase()})};var formId=0;var builders={sfField:function sfField(args){args.fieldFrag.firstChild.setAttribute("sf-field",formId);args.lookup["f"+formId]=args.form;formId++},ngModel:function ngModel(args){if(!args.form.key){return}var key=args.form.key;if(args.state.keyRedaction){key=key.slice(args.state.keyRedaction)}var modelValue;if(!args.state.modelValue){var strKey=sfPathProvider.stringify(key).replace(/"/g,"&quot;");modelValue=args.state.modelName||"model";if(strKey){modelValue+=(strKey[0]!=="["?".":"")+strKey}}else{modelValue=args.state.modelValue}var nodes=args.fieldFrag.querySelectorAll("[sf-field-model]");for(var i=0;i<nodes.length;i++){var n=nodes[i];var conf=n.getAttribute("sf-field-model");if(!conf||conf===""){n.setAttribute("ng-model",modelValue)}else if(conf==="replaceAll"){var attributes=n.attributes;for(var j=0;j<attributes.length;j++){if(attributes[j].value&&attributes[j].value.indexOf("$$value")!==-1){attributes[j].value=attributes[j].value.replace(/\$\$value\$\$/g,modelValue)}}}else{var val=n.getAttribute(conf);if(val&&val.indexOf("$$value$$")){n.setAttribute(conf,val.replace(/\$\$value\$\$/g,modelValue))}else{n.setAttribute(conf,modelValue)}}}},simpleTransclusion:function simpleTransclusion(args){var children=args.build(args.form.items,args.path+".items",args.state);args.fieldFrag.firstChild.appendChild(children)},ngModelOptions:function ngModelOptions(args){if(args.form.ngModelOptions&&Object.keys(args.form.ngModelOptions).length>0){args.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(args.form.ngModelOptions))}},transclusion:function transclusion(args){var transclusions=args.fieldFrag.querySelectorAll("[sf-field-transclude]");if(transclusions.length){for(var i=0;i<transclusions.length;i++){var n=transclusions[i];var sub=n.getAttribute("sf-field-transclude")||"items";var items=args.form[sub];if(items){var childFrag=args.build(items,args.path+"."+sub,args.state);n.appendChild(childFrag)}}}},condition:function condition(args){if(args.form.condition){var evalExpr="evalExpr("+args.path+'.condition, { model: model, "arrayIndex": $index})';if(args.form.key){var strKey=sfPathProvider.stringify(args.form.key);var arrayDepth=args.form.key.filter(function(e){return e===""}).length;var arrayIndices=arrayDepth>1?Array(arrayDepth-1).join("$parent.$parent.$parent.")+"$parent.$parent.$index,":"";for(var i=arrayDepth;i>2;i--){arrayIndices+=Array(i-1).join("$parent.$parent.$parent.")+"$index,"}arrayIndices+="$index";evalExpr="evalExpr("+args.path+'.condition,{ model: model, "arrayIndex": $index, '+'"arrayIndices": ['+arrayIndices+"],"+'"modelValue": model'+(strKey[0]==="["?"":".")+strKey+"})"}var children=args.fieldFrag.children||args.fieldFrag.childNodes;for(var i=0;i<children.length;i++){var child=children[i];var ngIf=child.getAttribute("ng-if");child.setAttribute("ng-if",ngIf?"("+ngIf+") || ("+evalExpr+")":evalExpr)}}},array:function array(args){var items=args.fieldFrag.querySelector("[schema-form-array-items]");if(args.form.key){var arrayDepth=args.form.key.filter(function(e){return e===""}).length}if(items){var state=angular.copy(args.state);state.keyRedaction=0;state.keyRedaction+=args.form.key.length+1;if(args.form.schema&&args.form.schema.items&&args.form.schema.items.type&&args.form.schema.items.type.indexOf("object")===-1&&args.form.schema.items.type.indexOf("array")===-1){var strKey=sfPathProvider.stringify(args.form.key).replace(/"/g,"&quot;")+"[$index]";state.modelValue="modelArray[$index]"}else{state.modelName="item"}state.arrayCompatFlag=true;var childFrag=args.build(args.form.items,args.path+".items",state);items.appendChild(childFrag)}},numeric:function numeric(args){var inputFrag=args.fieldFrag.querySelector("input");var maximum=args.form.maximum||false;var exclusiveMaximum=args.form.exclusiveMaximum||false;var minimum=args.form.minimum||false;var exclusiveMinimum=args.form.exclusiveMinimum||false;var multipleOf=args.form.multipleOf||false;if(inputFrag){if(multipleOf!==false){inputFrag.setAttribute("step",multipleOf)}if(maximum!==false){if(exclusiveMaximum!==false&&multipleOf!==false){maximum=maximum-multipleOf}inputFrag.setAttribute("max",maximum)}if(minimum!==false){if(exclusiveMinimum!==false&&multipleOf!==false){minimum=minimum+multipleOf}inputFrag.setAttribute("min",minimum)}}}};this.builders=builders;var stdBuilders=[builders.sfField,builders.ngModel,builders.ngModelOptions,builders.condition];this.stdBuilders=stdBuilders;this.$get=["$templateCache","schemaFormDecorators","sfPath",function($templateCache,schemaFormDecorators,sfPath){var checkForSlot=function checkForSlot(form,slots){if(form.key){var slot=slots[sfPath.stringify(form.key)];if(slot){while(slot.firstChild){slot.removeChild(slot.firstChild)}return slot}}};var _build=function _build(items,decorator,templateFn,slots,path,state,lookup){state=state||{};state=state||{};lookup=lookup||Object.create(null);path=path||"schemaForm.form";var container=document.createDocumentFragment();items.reduce(function(frag,f,index){if(!f.type){return frag}var field=decorator[f.type]||decorator["default"];if(!field.replace){var n=document.createElement(snakeCase(decorator.__name,"-"));if(state.arrayCompatFlag){n.setAttribute("form","copyWithIndex($index)")}else{n.setAttribute("form",path+"["+index+"]")}(checkForSlot(f,slots)||frag).appendChild(n)}else{var tmpl;state.arrayCompatFlag=false;var div=document.createElement("div");var template=templateFn(f,field)||templateFn(f,decorator["default"]);div.innerHTML=template;tmpl=document.createDocumentFragment();while(div.childNodes.length>0){tmpl.appendChild(div.childNodes[0])}var args={fieldFrag:tmpl,form:f,lookup:lookup,state:state,path:path+"["+index+"]",build:function build(items,path,state){return _build(items,decorator,templateFn,slots,path,state,lookup)}};var builderFn=f.builder||field.builder;if(typeof builderFn==="function"){builderFn(args)}else{builderFn.forEach(function(fn){fn(args)})}(checkForSlot(f,slots)||frag).appendChild(tmpl)}return frag},container);return container};return{build:function build(form,decorator,slots,lookup){return _build(form,decorator,function(form,field){if(form.type==="template"){return form.template}return $templateCache.get(field.template)},slots,undefined,undefined,lookup)},builder:builders,stdBuilders:stdBuilders,internalBuild:_build}}]}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($compileProvider,sfPathProvider){var defaultDecorator="";var decorators={};var templateUrl=function templateUrl(name,form){if(name==="sfDecorator"){name=defaultDecorator}var decorator=decorators[name];if(decorator[form.type]){return decorator[form.type].template}return decorator["default"].template};var createDirective=function createDirective(name){$compileProvider.directive(name,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function($parse,$compile,$http,$templateCache,$interpolate,$q,sfErrorMessage,sfPath,sfSelect){return{restrict:"AE",replace:false,transclude:false,scope:true,require:["^sfSchema","?^form"],link:function link(scope,element,attrs,ctrl){var sfSchema=ctrl[0];var formCtrl=ctrl[1];scope.$on("schemaFormPropagateNgModelController",function(event,ngModel){event.stopPropagation();event.preventDefault();scope.ngModel=ngModel});scope.showTitle=function(){return scope.form&&scope.form.notitle!==true&&scope.form.title};scope.fieldId=function(prependFormName,omitArrayIndexes){var key=scope.parentKey||[];if(scope.form.key){if(typeof key[key.length-1]==="number"){var combinedKey=key.concat(scope.form.key.slice(-1));var formName=prependFormName&&formCtrl&&formCtrl.$name?formCtrl.$name:undefined;return sfPath.name(combinedKey,"-",formName,omitArrayIndexes)}else{var formName=prependFormName&&formCtrl&&formCtrl.$name?formCtrl.$name:undefined;return sfPath.name(scope.form.key,"-",formName,omitArrayIndexes)}}else{return""}};scope.listToCheckboxValues=function(list){var values={};_angular2.default.forEach(list,function(v){values[v]=true});return values};scope.checkboxValuesToList=function(values){var lst=[];_angular2.default.forEach(values,function(v,k){if(v){lst.push(k)}});return lst};scope.buttonClick=function($event,form){if(_angular2.default.isFunction(form.onClick)){form.onClick($event,form)}else if(_angular2.default.isString(form.onClick)){if(sfSchema){sfSchema.evalInParentScope(form.onClick,{$event:$event,form:form})}else{scope.$eval(form.onClick,{$event:$event,form:form})}}};scope.evalExpr=function(expression,locals){if(sfSchema){return sfSchema.evalInParentScope(expression,locals)}return scope.$eval(expression,locals)};scope.evalInScope=function(expression,locals){if(expression){return scope.$eval(expression,locals)}};scope.interp=function(expression,locals){return expression&&$interpolate(expression)(locals)};scope.hasSuccess=function(){if(!scope.ngModel){return false}if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return scope.ngModel.$valid&&!scope.ngModel.$pristine&&!scope.ngModel.$isEmpty(scope.ngModel.$modelValue)}else{return scope.ngModel.$valid&&(!scope.ngModel.$pristine||!scope.ngModel.$isEmpty(scope.ngModel.$modelValue))}};scope.hasError=function(){if(!scope.ngModel){return false}return scope.ngModel.$invalid&&!scope.ngModel.$pristine};scope.errorMessage=function(schemaError){return sfErrorMessage.interpolate(schemaError&&schemaError.code+""||"default",scope.ngModel&&scope.ngModel.$modelValue||"",scope.ngModel&&scope.ngModel.$viewValue||"",scope.form,scope.options&&scope.options.validationMessage)};var once=scope.$watch(attrs.form,function(form){if(form){form.ngModelOptions=form.ngModelOptions||{};scope.form=form;var templatePromise;if(form.type==="template"&&form.template){templatePromise=$q.when(form.template)}else{var url=form.type==="template"?form.templateUrl:templateUrl(name,form);templatePromise=$http.get(url,{cache:$templateCache}).then(function(res){return res.data})}templatePromise.then(function(template){if(form.key){var key=form.key?sfPathProvider.stringify(form.key).replace(/"/g,"&quot;"):"";template=template.replace(/\$\$value\$\$/g,"model"+(key[0]!=="["?".":"")+key)}element.html(template);if(form.condition){var evalExpr='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';if(form.key){evalExpr="evalExpr(form.condition, {"+'model: model, "arrayIndex": arrayIndex, "modelValue": model'+sfPath.stringify(form.key)+"})"}_angular2.default.forEach(element.children(),function(child){var ngIf=child.getAttribute("ng-if");child.setAttribute("ng-if",ngIf?"("+ngIf+") || ("+evalExpr+")":evalExpr)})}$compile(element.contents())(scope)});if(form.key){scope.$on("schemaForm.error."+form.key.join("."),function(event,error,validationMessage,validity,formName){formName=validity;if(validationMessage===true||validationMessage===false){validity=validationMessage;validationMessage=undefined}if(formName!=undefined&&scope.ngModel.$$parentForm.$name!==formName){return}if(scope.ngModel&&error){if(scope.ngModel.$setDirty){scope.ngModel.$setDirty()}else{scope.ngModel.$dirty=true;scope.ngModel.$pristine=false}if(validationMessage){if(!form.validationMessage){form.validationMessage={}}form.validationMessage[error]=validationMessage}scope.ngModel.$setValidity(error,validity===true);if(validity===true){scope.ngModel.$validate();scope.$broadcast("schemaFormValidate")}}});scope.$on("$destroy",function(){if(!scope.externalDestructionInProgress){var destroyStrategy=form.destroyStrategy||scope.options&&scope.options.destroyStrategy||"remove";if(form.key&&destroyStrategy!=="retain"){var obj=scope.model;if(form.key.length>1){obj=sfSelect(form.key.slice(0,form.key.length-1),obj)}if(obj===undefined){return}var type=form.schema&&form.schema.type||"";if(destroyStrategy==="empty"&&type.indexOf("string")!==-1){obj[form.key.slice(-1)]=""}else if(destroyStrategy==="empty"&&type.indexOf("object")!==-1){obj[form.key.slice(-1)]={}}else if(destroyStrategy==="empty"&&type.indexOf("array")!==-1){obj[form.key.slice(-1)]=[]}else if(destroyStrategy==="null"){obj[form.key.slice(-1)]=null}else{delete obj[form.key.slice(-1)]}}}})}once()}})}}}])};var createManualDirective=function createManualDirective(type,templateUrl,transclude){transclude=_angular2.default.isDefined(transclude)?transclude:false;$compileProvider.directive("sf"+_angular2.default.uppercase(type[0])+type.substr(1),function(){return{restrict:"EAC",scope:true,replace:true,transclude:transclude,template:'<sf-decorator form="form"></sf-decorator>',link:function link(scope,element,attrs){var watchThis={items:"c",titleMap:"c",schema:"c"};var form={type:type};var once=true;_angular2.default.forEach(attrs,function(value,name){if(name[0]!=="$"&&name.indexOf("ng")!==0&&name!=="sfField"){var updateForm=function updateForm(val){if(_angular2.default.isDefined(val)&&val!==form[name]){form[name]=val;if(once&&form.type&&(form.key||_angular2.default.isUndefined(attrs.key))){scope.form=form;once=false}}};if(name==="model"){scope.$watch(value,function(val){if(val&&scope.model!==val){scope.model=val}})}else if(watchThis[name]==="c"){scope.$watchCollection(value,updateForm)}else{attrs.$observe(name,updateForm)}}})}}})};this.createDecorator=function(name,templates){decorators[name]={__name:name};_angular2.default.forEach(templates,function(url,type){decorators[name][type]={template:url,replace:false,builder:[]}});if(!decorators[defaultDecorator]){defaultDecorator=name}createDirective(name)};this.defineDecorator=function(name,fields){decorators[name]={__name:name};_angular2.default.forEach(fields,function(field,type){field.builder=field.builder||[];field.replace=_angular2.default.isDefined(field.replace)?field.replace:true;decorators[name][type]=field});if(!decorators[defaultDecorator]){defaultDecorator=name}createDirective(name)};this.createDirective=createManualDirective;this.createDirectives=function(templates){_angular2.default.forEach(templates,function(url,type){createManualDirective(type,url)})};this.decorator=function(name){name=name||defaultDecorator;return decorators[name]};this.addMapping=function(name,type,url,builder,replace){if(decorators[name]){decorators[name][type]={template:url,builder:builder,replace:!!replace}}};this.defineAddOn=function(name,type,url,builder){if(decorators[name]){decorators[name][type]={template:url,builder:builder,replace:true}}};this.$get=function(){return{decorator:function decorator(name){return decorators[name]||decorators[defaultDecorator]},defaultDecorator:defaultDecorator}};createDirective("sfDecorator")};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var postProcessFn=function postProcessFn(form){return form};var defaults=_jsonSchemaFormCore.schemaDefaults.createDefaults();this.defaults=defaults;this.stdFormObj=_jsonSchemaFormCore.schemaDefaults.stdFormObj;this.defaultFormDefinition=_jsonSchemaFormCore.schemaDefaults.defaultFormDefinition;this.postProcess=function(fn){postProcessFn=fn};this.appendRule=function(type,rule){if(!defaults[type]){defaults[type]=[]}defaults[type].push(rule)};this.prependRule=function(type,rule){if(!defaults[type]){defaults[type]=[]}defaults[type].unshift(rule)};this.createStandardForm=_jsonSchemaFormCore.schemaDefaults.stdFormObj;this.$get=function(){var service={};var typeDefault=this.defaults;service.merge=function(schema,form,ignore,options,readonly,asyncTemplates){form=form||["*"];options=options||{};readonly=readonly||schema.readonly||schema.readOnly;var stdForm=_jsonSchemaFormCore.schemaDefaults.defaultForm(schema,typeDefault,ignore,options);var idx=form.indexOf("*");if(idx!==-1){form=form.slice(0,idx).concat(stdForm.form).concat(form.slice(idx+1))}var canonical=(0,_jsonSchemaFormCore.merge)(stdForm.lookup,form,options,readonly,asyncTemplates);return postProcessFn(canonical)};service.defaults=_jsonSchemaFormCore.schemaDefaults.defaultForm;service.typeDefault=typeDefault;service.traverseSchema=_jsonSchemaFormCore.traverseSchema;service.traverseForm=_jsonSchemaFormCore.traverseForm;return service}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _jsonSchemaFormCore=__webpack_require__(6);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){/*!
-		 * json-schema-form
-		 * @version 1.0.0-alpha.2
-		 * @link https://github.com/json-schema-form/json-schema-form-core
-		 * @license MIT
-		 * Copyright (c) 2016 JSON Schema Form
-		 */
-(function webpackUniversalModuleDefinition(root,factory){if(true)module.exports=factory(__webpack_require__(7));else if(typeof define==="function"&&define.amd)define(["tv4"],factory);else{var a=typeof exports==="object"?factory(require("tv4")):factory(root["tv4"]);for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(__WEBPACK_EXTERNAL_MODULE_10__){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){module.exports=__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.canonicalTitleMap=exports.schemaDefaults=exports.sfPath=undefined;var _merge=__webpack_require__(2);Object.keys(_merge).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _merge[key]}})});var _select=__webpack_require__(7);Object.keys(_select).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _select[key]}})});var _traverse=__webpack_require__(8);Object.keys(_traverse).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _traverse[key]}})});var _validate=__webpack_require__(9);Object.keys(_validate).forEach(function(key){if(key==="default")return;Object.defineProperty(exports,key,{enumerable:true,get:function get(){return _validate[key]}})});var _schemaDefaults=__webpack_require__(11);var schemaDefaultsImp=_interopRequireWildcard(_schemaDefaults);var _sfPath=__webpack_require__(3);var sfPathImp=_interopRequireWildcard(_sfPath);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function _interopRequireWildcard(obj){if(obj&&obj.__esModule){return obj}else{var newObj={};if(obj!=null){for(var key in obj){if(Object.prototype.hasOwnProperty.call(obj,key))newObj[key]=obj[key]}}newObj.default=obj;return newObj}}var sfPath=exports.sfPath=sfPathImp;var schemaDefaults=exports.schemaDefaults=schemaDefaultsImp;var canonicalTitleMap=exports.canonicalTitleMap=_canonicalTitleMap2.default},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.merge=merge;var _sfPath=__webpack_require__(3);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function merge(lookup,form,options,readonly,asyncTemplates){form=form||[];options=options||{};return form.map(function(obj){if(typeof obj==="string"){obj={key:obj}}if(obj.key){if(typeof obj.key==="string"){obj.key=(0,_sfPath.parse)(obj.key)}}if(obj.titleMap){obj.titleMap=(0,_canonicalTitleMap2.default)(obj.titleMap)}if(obj.key){var strid=(0,_sfPath.stringify)(obj.key);if(lookup[strid]){(function(){var schemaDefaults=lookup[strid];if(schemaDefaults){Object.keys(schemaDefaults).forEach(function(attr){if(obj[attr]===undefined){obj[attr]=schemaDefaults[attr]}})}})()}}if(readonly===true){obj.readonly=true}if(obj.items){obj.items=merge(lookup,obj.items,options,obj.readonly,asyncTemplates)}if(obj.tabs){obj.tabs.forEach(function(tab){if(tab.items){tab.items=merge(lookup,tab.items,options,obj.readonly,asyncTemplates)}})}if(obj.type==="checkbox"&&obj.schema["default"]===undefined){obj.schema["default"]=false}if(asyncTemplates&&obj.type==="template"&&!obj.template&&obj.templateUrl){asyncTemplates.push(obj)}return obj})}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.name=exports.normalize=exports.stringify=exports.parse=undefined;var _objectpath=__webpack_require__(4);var name=function name(key,separator,formName,omitNumbers){if(key){var fieldKey=key;var fieldSeparator=separator||"-";if(omitNumbers){fieldKey=fieldKey.filter(function(key){return typeof key!=="number"})}return(formName?formName+fieldSeparator:"")+fieldKey.join(fieldSeparator)}return""};exports.parse=_objectpath.parse;exports.stringify=_objectpath.stringify;exports.normalize=_objectpath.normalize;exports.name=name},function(module,exports,__webpack_require__){"use strict";module.exports=__webpack_require__(5).ObjectPath},function(module,exports,__webpack_require__){var __WEBPACK_AMD_DEFINE_RESULT__;"use strict";var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};!function(undefined){var ObjectPath={parse:function parse(str){if(typeof str!=="string"){throw new TypeError("ObjectPath.parse must be passed a string")}var i=0;var parts=[];var d,b,q,c;while(i<str.length){d=str.indexOf(".",i);b=str.indexOf("[",i);if(d===-1&&b===-1){parts.push(str.slice(i,str.length));i=str.length}else if(b===-1||d!==-1&&d<b){parts.push(str.slice(i,d));i=d+1}else{if(b>i){parts.push(str.slice(i,b));i=b}q=str.slice(b+1,b+2);if(q!=='"'&&q!=="'"){c=str.indexOf("]",b);if(c===-1)c=str.length;parts.push(str.slice(i+1,c));i=str.slice(c+1,c+2)==="."?c+2:c+1}else{c=str.indexOf(q+"]",b);if(c===-1)c=str.length;while(str.slice(c-1,c)==="\\"&&b<str.length){b++;c=str.indexOf(q+"]",b)}parts.push(str.slice(i+2,c).replace(new RegExp("\\"+q,"g"),q));i=str.slice(c+2,c+3)==="."?c+3:c+2}}}return parts},stringify:function stringify(arr,quote){if(!Array.isArray(arr))arr=[arr.toString()];quote=quote==='"'?'"':"'";return arr.map(function(n){return"["+quote+n.toString().replace(new RegExp(quote,"g"),"\\"+quote)+quote+"]"}).join("")},normalize:function normalize(data,quote){return ObjectPath.stringify(Array.isArray(data)?data:ObjectPath.parse(data),quote)},registerModule:function registerModule(angular){angular.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=ObjectPath.parse;this.stringify=ObjectPath.stringify;this.normalize=ObjectPath.normalize;this.$get=function(){return ObjectPath}})}};if(true){!(__WEBPACK_AMD_DEFINE_RESULT__=function(){return{ObjectPath:ObjectPath}}.call(exports,__webpack_require__,exports,module),__WEBPACK_AMD_DEFINE_RESULT__!==undefined&&(module.exports=__WEBPACK_AMD_DEFINE_RESULT__))}else if((typeof exports==="undefined"?"undefined":_typeof(exports))==="object"){exports.ObjectPath=ObjectPath}else{window.ObjectPath=ObjectPath}}()},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.default=function(titleMap,originalEnum){if(!Array.isArray(titleMap)){var _ret=function(){var canonical=[];if(originalEnum){originalEnum.forEach(function(value){canonical.push({name:titleMap[value],value:value})})}else{Object.keys(titleMap).forEach(function(value){canonical.push({name:titleMap[value],value:value})})}return{v:canonical}}();if((typeof _ret==="undefined"?"undefined":_typeof(_ret))==="object")return _ret.v}return titleMap}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.select=select;var _sfPath=__webpack_require__(3);var _sfPath2=_interopRequireDefault(_sfPath);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}var numRe=/^\d+$/;function select(projection,obj,valueToSet){if(!obj){obj=this}var parts=typeof projection==="string"?_sfPath2.default.parse(projection):projection;if(typeof valueToSet!=="undefined"&&parts.length===1){obj[parts[0]]=valueToSet;return obj}if(typeof valueToSet!=="undefined"&&typeof obj[parts[0]]==="undefined"){obj[parts[0]]=parts.length>2&&numRe.test(parts[1])?[]:{}}var value=obj[parts[0]];for(var i=1;i<parts.length;i++){if(parts[i]===""){return undefined}if(typeof valueToSet!=="undefined"){if(i===parts.length-1){value[parts[i]]=valueToSet;return valueToSet}else{var tmp=value[parts[i]];if(typeof tmp==="undefined"||tmp===null){tmp=numRe.test(parts[i+1])?[]:{};value[parts[i]]=tmp}value=tmp}}else if(value){value=value[parts[i]]}}return value}},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.traverseSchema=traverseSchema;exports.traverseForm=traverseForm;function traverseSchema(schema,fn,path,ignoreArrays){ignoreArrays=ignoreArrays===undefined?true:ignoreArrays;path=path||[];var traverse=function traverse(schema,fn,path){fn(schema,path);if(schema.properties){Object.keys(schema.properties).forEach(function(name){var currentPath=path.slice();currentPath.push(name);traverse(schema.properties[name],fn,currentPath)})}if(!ignoreArrays&&schema.items){var arrPath=path.slice();arrPath.push("");traverse(schema.items,fn,arrPath)}};traverse(schema,fn,path||[])}function traverseForm(form,fn){fn(form);if(form.items){form.items.forEach(function(f){traverseForm(f,fn)})}if(form.tabs){form.tabs.forEach(function(tab){if(tab.items){tab.items.forEach(function(f){traverseForm(f,fn)})}})}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.validate=validate;var _tv=__webpack_require__(10);var _tv2=_interopRequireDefault(_tv);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}function validate(form,value){if(!form){return{valid:true}}var schema=form.schema;if(!schema){return{valid:true}}if(value===""){value=undefined}if(form.type==="number"&&value===null){value=undefined}var wrap={type:"object",properties:{}};var propName=form.key[form.key.length-1];wrap.properties[propName]=schema;if(form.required){wrap.required=[propName]}var valueWrap={};if(!!value){valueWrap[propName]=value}return _tv2.default.validateResult(valueWrap,wrap)}},function(module,exports){module.exports=tv4},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.defaultFormDefinition=defaultFormDefinition;exports.stdFormObj=stdFormObj;exports.text=text;exports.number=number;exports.integer=integer;exports.checkbox=checkbox;exports.select=select;exports.checkboxes=checkboxes;exports.fieldset=fieldset;exports.array=array;exports.createDefaults=createDefaults;exports.defaultForm=defaultForm;var _sfPath=__webpack_require__(3);var _canonicalTitleMap=__webpack_require__(6);var _canonicalTitleMap2=_interopRequireDefault(_canonicalTitleMap);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}var stripNullType=function stripNullType(type){if(Array.isArray(type)&&type.length==2){if(type[0]==="null"){return type[1]}if(type[1]==="null"){return type[0]}}return type};var enumToTitleMap=function enumToTitleMap(enm){var titleMap=[];enm.forEach(function(name){titleMap.push({name:name,value:name})});return titleMap};function defaultFormDefinition(schemaTypes,name,schema,options){var rules=schemaTypes[stripNullType(schema.type)];if(rules){var def=void 0;var innerDefaultFormDefinition=function innerDefaultFormDefinition(childName,childSchema,childOptions){return defaultFormDefinition(schemaTypes,childName,childSchema,childOptions)};for(var i=0;i<rules.length;i++){def=rules[i](name,schema,options,innerDefaultFormDefinition);if(def){if(def.schema["x-schema-form"]){Object.assign(def,def.schema["x-schema-form"])}return def}}}}function stdFormObj(name,schema,options){options=options||{};var f=options.global&&options.global.formDefaults?Object.assign({},options.global.formDefaults):{};if(options.global&&options.global.supressPropertyTitles===true){f.title=schema.title}else{f.title=schema.title||name}if(schema.description){f.description=schema.description}if(options.required===true||schema.required===true){f.required=true}if(schema.maxLength){f.maxlength=schema.maxLength}if(schema.minLength){f.minlength=schema.minLength}if(schema.readOnly||schema.readonly){f.readonly=true}if(schema.minimum){f.minimum=schema.minimum+(schema.exclusiveMinimum?1:0)}if(schema.maximum){f.maximum=schema.maximum-(schema.exclusiveMaximum?1:0)}if(schema.validationMessage){f.validationMessage=schema.validationMessage}if(schema.enumNames){f.titleMap=(0,_canonicalTitleMap2.default)(schema.enumNames,schema["enum"])}f.schema=schema;f.ngModelOptions=f.ngModelOptions||{};return f}function text(name,schema,options){if(stripNullType(schema.type)==="string"&&!schema["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="text";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function number(name,schema,options){if(stripNullType(schema.type)==="number"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="number";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function integer(name,schema,options){if(stripNullType(schema.type)==="integer"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="number";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function checkbox(name,schema,options){if(stripNullType(schema.type)==="boolean"){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="checkbox";options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function select(name,schema,options){if(stripNullType(schema.type)==="string"&&schema["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="select";if(!f.titleMap){f.titleMap=enumToTitleMap(schema["enum"])}options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function checkboxes(name,schema,options){if(stripNullType(schema.type)==="array"&&schema.items&&schema.items["enum"]){var f=stdFormObj(name,schema,options);f.key=options.path;f.type="checkboxes";if(!f.titleMap){f.titleMap=enumToTitleMap(schema.items["enum"])}options.lookup[(0,_sfPath.stringify)(options.path)]=f;return f}}function fieldset(name,schema,options,defaultFormDef){if(stripNullType(schema.type)==="object"){var _ret=function(){var f=stdFormObj(name,schema,options);f.type="fieldset";f.key=options.path;f.items=[];options.lookup[(0,_sfPath.stringify)(options.path)]=f;if(schema.properties){Object.keys(schema.properties).forEach(function(key){var value=schema.properties[key];var path=options.path.slice();path.push(key);if(options.ignore[(0,_sfPath.stringify)(path)]!==true){var required=schema.required&&schema.required.indexOf(key)!==-1;var def=defaultFormDef(key,value,{path:path,required:required||false,lookup:options.lookup,ignore:options.ignore,global:options.global});if(def){f.items.push(def)}}})}return{v:f}}();if((typeof _ret==="undefined"?"undefined":_typeof(_ret))==="object")return _ret.v}}function array(name,schema,options,defaultFormDef){if(stripNullType(schema.type)==="array"){var f=stdFormObj(name,schema,options);f.type="array";f.key=options.path;options.lookup[(0,_sfPath.stringify)(options.path)]=f;var required=schema.required&&schema.required.indexOf(options.path[options.path.length-1])!==-1;var arrPath=options.path.slice();arrPath.push("");f.items=[defaultFormDef(name,schema.items,{path:arrPath,required:required||false,lookup:options.lookup,ignore:options.ignore,global:options.global})];return f}}function createDefaults(){return{string:[select,text],object:[fieldset],number:[number],integer:[integer],boolean:[checkbox],array:[checkboxes,array]}}function defaultForm(schema,defaultSchemaTypes,ignore,globalOptions){var form=[];var lookup={};ignore=ignore||{};globalOptions=globalOptions||{};defaultSchemaTypes=defaultSchemaTypes||createDefaults();if(schema.properties){Object.keys(schema.properties).forEach(function(key){if(ignore[key]!==true){var required=schema.required&&schema.required.indexOf(key)!==-1;var def=defaultFormDefinition(defaultSchemaTypes,key,schema.properties[key],{path:[key],lookup:lookup,ignore:ignore,required:required,global:globalOptions});if(def){form.push(def)}}})}else{throw new Error('Not implemented. Only type "object" allowed at root level of schema.')}return{form:form,lookup:lookup}}}])})},function(module,exports){module.exports=tv4},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var validator={};validator.validate=function(form,value){if(!form){return{valid:true}}var schema=form.schema;if(!schema){return{valid:true}}if(value===""){value=undefined}if(form.type==="number"&&value===null){value=undefined}var wrap={type:"object",properties:{}};var propName=form.key[form.key.length-1];wrap.properties[propName]=schema;if(form.required){wrap.required=[propName]}var valueWrap={};if(_angular2.default.isDefined(value)){valueWrap[propName]=value}return _tv2.default.validateResult(valueWrap,wrap)};return validator};var _tv=__webpack_require__(7);var _tv2=_interopRequireDefault(_tv);var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){var defaultMessages={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};defaultMessages.number=defaultMessages[105];defaultMessages.required=defaultMessages[302];defaultMessages.min=defaultMessages[101];defaultMessages.max=defaultMessages[103];defaultMessages.maxlength=defaultMessages[201];defaultMessages.minlength=defaultMessages[200];defaultMessages.pattern=defaultMessages[202];this.setDefaultMessages=function(messages){defaultMessages=messages};this.getDefaultMessages=function(){return defaultMessages};this.setDefaultMessage=function(error,msg){defaultMessages[error]=msg};this.$get=["$interpolate",function($interpolate){var service={};service.defaultMessages=defaultMessages;service.interpolate=function(error,value,viewValue,form,global){global=global||{};var validationMessage=form.validationMessage||{};if(error.indexOf("tv4-")===0){error=error.substring(4)}var message=validationMessage["default"]||global["default"]||"";[validationMessage,global,defaultMessages].some(function(val){if(_angular2.default.isString(val)||_angular2.default.isFunction(val)){message=val;return true}if(val&&val[error]){message=val[error];return true}});var context={error:error,value:value,viewValue:viewValue,form:form,schema:form.schema,title:form.title||form.schema&&form.schema.title};if(_angular2.default.isFunction(message)){return message(context)}else{return $interpolate(message)(context)}};return service}]};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){this.parse=_jsonSchemaFormCore.sfPath.parse;this.stringify=_jsonSchemaFormCore.sfPath.stringify;this.normalize=_jsonSchemaFormCore.sfPath.normalize;this.$get=function(){return _jsonSchemaFormCore.sfPath}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);var _jsonSchemaFormCore=__webpack_require__(6);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfSelect,schemaForm,sfValidator,sfPath){var setIndex=function setIndex(index){return function(form){if(form.key){form.key[form.key.indexOf("")]=index}}};return{restrict:"A",scope:true,require:"?ngModel",link:function link(scope,element,attrs,ngModel){var formDefCache={};scope.validateArray=_angular2.default.noop;if(ngModel){scope.$emit("schemaFormPropagateNgModelController",ngModel)}var once=scope.$watch(attrs.sfArray,function(form){if(!form){return}var list=sfSelect(form.key,scope.model);var key=sfPath.normalize(form.key);scope.$watch("model"+(key[0]!=="["?".":"")+key,function(value){list=scope.modelArray=value});if(_angular2.default.isUndefined(list)){list=[];sfSelect(form.key,scope.model,list)}scope.modelArray=list;if(form.items){var subForm=form.items[0];if(form.items.length>1){subForm={type:"section",items:form.items.map(function(item){item.ngModelOptions=form.ngModelOptions;if(_angular2.default.isUndefined(item.readonly)){item.readonly=form.readonly}return item})}}}scope.copyWithIndex=function(index){if(!formDefCache[index]){if(subForm){var copy=_angular2.default.copy(subForm);copy.arrayIndex=index;schemaForm.traverseForm(copy,setIndex(index));formDefCache[index]=copy}}return formDefCache[index]};scope.appendToArray=function(){var len=list.length;var copy=scope.copyWithIndex(len);schemaForm.traverseForm(copy,function(part){if(part.key){var def;if(_angular2.default.isDefined(part["default"])){def=part["default"]}if(_angular2.default.isDefined(part.schema)&&_angular2.default.isDefined(part.schema["default"])){def=part.schema["default"]}if(_angular2.default.isDefined(def)){sfSelect(part.key,scope.model,def)}}});if(len===list.length){var type=sfSelect("schema.items.type",form);var dflt;if(type==="object"){dflt={}}else if(type==="array"){dflt=[]}list.push(dflt)}scope.validateArray();return list};scope.deleteFromArray=function(index){list.splice(index,1);scope.validateArray();if(ngModel&&ngModel.$setDirty){ngModel.$setDirty()}return list};if(!form.titleMap&&form.startEmpty!==true&&list.length===0){scope.appendToArray()}if(form.titleMap&&form.titleMap.length>0){scope.titleMapValues=[];var updateTitleMapValues=function updateTitleMapValues(arr){scope.titleMapValues=[];arr=arr||[];form.titleMap.forEach(function(item){scope.titleMapValues.push(arr.indexOf(item.value)!==-1)})};updateTitleMapValues(scope.modelArray);scope.$watchCollection("modelArray",updateTitleMapValues);scope.$watchCollection("titleMapValues",function(vals,old){if(vals&&vals!==old){var arr=scope.modelArray;while(arr.length>0){arr.pop()}form.titleMap.forEach(function(item,index){if(vals[index]){arr.push(item.value)}});scope.validateArray()}})}if(ngModel){var error;scope.validateArray=function(){var result=sfValidator.validate(form,scope.modelArray.length>0?scope.modelArray:undefined);Object.keys(ngModel.$error).filter(function(k){return k.indexOf("tv4-")===0}).forEach(function(k){ngModel.$setValidity(k,true)});if(result.valid===false&&result.error&&(result.error.dataPath===""||result.error.dataPath==="/"+form.key[form.key.length-1])){ngModel.$setViewValue(scope.modelArray);error=result.error;ngModel.$setValidity("tv4-"+result.error.code,false)}};scope.$on("schemaFormValidate",scope.validateArray);scope.hasSuccess=function(){if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return ngModel.$valid&&!ngModel.$pristine&&!ngModel.$isEmpty(ngModel.$modelValue)}else{return ngModel.$valid&&(!ngModel.$pristine||!ngModel.$isEmpty(ngModel.$modelValue))}};scope.hasError=function(){if(!scope.options||!scope.options.pristine||scope.options.pristine.errors!==false){return ngModel.$invalid}else{return ngModel.$invalid&&!ngModel.$pristine}};scope.schemaError=function(){return error}}once()})}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(){return{require:"ngModel",restrict:"AC",scope:false,link:function link(scope,element,attrs,ctrl){var form=scope.$eval(attrs.sfChanged);if(form&&form.onChange){ctrl.$viewChangeListeners.push(function(){if(_angular2.default.isFunction(form.onChange)){form.onChange(ctrl.$modelValue,form)}else{scope.evalExpr(form.onChange,{modelValue:ctrl.$modelValue,form:form})}})}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol?"symbol":typeof obj};exports.default=function($parse,$compile,$http,$templateCache,$interpolate,$q,sfErrorMessage,sfPath,sfSelect){var keyFormat={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:false,transclude:false,scope:true,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function pre(scope,element,attrs,ctrl){var sfSchema=ctrl[0];var formCtrl=ctrl[1];var keyCtrl=ctrl[2];scope.$on("schemaFormPropagateNgModelController",function(event,ngModel){event.stopPropagation();event.preventDefault();scope.ngModel=ngModel});scope.form=sfSchema.lookup["f"+attrs.sfField]},post:function post(scope,element,attrs,ctrl){var sfSchema=ctrl[0];var formCtrl=ctrl[1];var keyCtrl=ctrl[2];scope.showTitle=function(){return scope.form&&scope.form.notitle!==true&&scope.form.title};scope.getKey=function(requiredFormat){var format=requiredFormat||keyFormat.COMPLETE;var key=scope.parentKey?scope.parentKey.slice(0,scope.parentKey.length-1):[];if(typeof scope.$index==="number"){key=key.concat(scope.$index)}if(scope.form.key&&scope.form.key.length){if(typeof key[key.length-1]==="number"&&scope.form.key.length>=1){scope.completeKey=key.concat(scope.form.key.slice(-1))}else{scope.completeKey=scope.form.key.slice()}}if(!Array.isArray(scope.completeKey)){return undefined}if(format===keyFormat.COMPLETE){return scope.completeKey}return scope.completeKey.reduce(function(output,input,i){if(-1!==[format].indexOf(typeof input==="undefined"?"undefined":_typeof(input))){return output.concat(input)}return output},[])};if(scope.form.key)scope.completeKey=scope.getKey();scope.path=function(modelPath){var i=-1;modelPath=modelPath.replace(/\[\]/gi,function(matched){i++;return scope.$i[i]});return scope.$eval(modelPath,scope)};scope.fieldId=function(prependFormName,omitArrayIndexes){var formName=prependFormName&&formCtrl&&formCtrl.$name?formCtrl.$name:undefined;var key=scope.getKey();if(Array.isArray(key)){return sfPath.name(key,"-",formName,omitArrayIndexes)}else{return""}};scope.listToCheckboxValues=function(list){var values={};_angular2.default.forEach(list,function(v){values[v]=true});return values};scope.checkboxValuesToList=function(values){var lst=[];_angular2.default.forEach(values,function(v,k){if(v){lst.push(k)}});return lst};scope.buttonClick=function($event,form){if(_angular2.default.isFunction(form.onClick)){form.onClick($event,form)}else if(_angular2.default.isString(form.onClick)){if(sfSchema){sfSchema.evalInParentScope(form.onClick,{$event:$event,form:form})}else{scope.$eval(form.onClick,{$event:$event,form:form})}}};scope.evalExpr=function(expression,locals){if(sfSchema){return sfSchema.evalInParentScope(expression,locals)}return scope.$eval(expression,locals)};scope.evalInScope=function(expression,locals){if(expression){return scope.$eval(expression,locals)}};scope.interp=function(expression,locals){return expression&&$interpolate(expression)(locals)};scope.hasSuccess=function(){if(!scope.ngModel){return false}if(scope.options&&scope.options.pristine&&scope.options.pristine.success===false){return scope.ngModel.$valid&&!scope.ngModel.$pristine&&!scope.ngModel.$isEmpty(scope.ngModel.$modelValue)}else{return scope.ngModel.$valid&&(!scope.ngModel.$pristine||!scope.ngModel.$isEmpty(scope.ngModel.$modelValue))}};scope.hasError=function(){if(!scope.ngModel){return false}if(!scope.options||!scope.options.pristine||scope.options.pristine.errors!==false){return scope.ngModel.$invalid}else{return scope.ngModel.$invalid&&!scope.ngModel.$pristine}};scope.errorMessage=function(schemaError){return sfErrorMessage.interpolate(schemaError&&schemaError.code+""||"default",scope.ngModel&&scope.ngModel.$modelValue||"",scope.ngModel&&scope.ngModel.$viewValue||"",scope.form,scope.options&&scope.options.validationMessage)};scope.form.htmlClass=scope.form.htmlClass||"";scope.form.htmlClass+=(scope.form.htmlClass?" ":"")+scope.fieldId(false,true);var form=scope.form;if(form.key){scope.$on("schemaForm.error."+form.key.join("."),function(event,error,validationMessage,validity,formName){formName=validity;if(validationMessage===true||validationMessage===false){validity=validationMessage;validationMessage=undefined}if(formName!=undefined&&scope.ngModel.$$parentForm.$name!==formName){return}if(scope.ngModel&&error){if(scope.ngModel.$setDirty){scope.ngModel.$setDirty()}else{scope.ngModel.$dirty=true;scope.ngModel.$pristine=false}if(validationMessage){if(!form.validationMessage){form.validationMessage={}}form.validationMessage[error]=validationMessage}scope.ngModel.$setValidity(error,validity===true);if(validity===true){scope.ngModel.$validate();scope.$broadcast("schemaFormValidate")}}});scope.$on("$destroy",function(){var key=scope.getKey();if(!scope.externalDestructionInProgress){var destroyStrategy=form.destroyStrategy||scope.options&&scope.options.destroyStrategy||"remove";if(key&&destroyStrategy!=="retain"){var obj=scope.model;if(key.length>1){obj=sfSelect(key.slice(0,key.length-1),obj)}if(obj===undefined){return}var type=form.schema&&form.schema.type||"";if(destroyStrategy==="empty"&&type.indexOf("string")!==-1){obj[key.slice(-1)]=""}else if(destroyStrategy==="empty"&&type.indexOf("object")!==-1){obj[key.slice(-1)]={}}else if(destroyStrategy==="empty"&&type.indexOf("array")!==-1){obj[key.slice(-1)]=[]}else if(destroyStrategy==="null"){obj[key.slice(-1)]=null}else{delete obj[key.slice(-1)]}}}})}}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{
-default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($injector,sfErrorMessage){var $sanitize=$injector.has("$sanitize")?$injector.get("$sanitize"):function(html){return html};return{scope:false,restrict:"EA",link:function link(scope,element,attrs){var message="";if(attrs.sfMessage){scope.$watch(attrs.sfMessage,function(msg){if(msg){message=$sanitize(msg);update(!!scope.ngModel)}})}var currentMessage;var setMessage=function setMessage(msg){if(msg!==currentMessage){element.html(msg);currentMessage=msg}};var update=function update(checkForErrors){if(checkForErrors){if(!scope.hasError()){setMessage(message)}else{var errors=[];_angular2.default.forEach(scope.ngModel&&scope.ngModel.$error,function(status,code){if(status){errors.push(code)}});errors=errors.filter(function(e){return e!=="schemaForm"});var error=errors[0];if(error){setMessage(sfErrorMessage.interpolate(error,scope.ngModel.$modelValue,scope.ngModel.$viewValue,scope.form,scope.options&&scope.options.validationMessage))}else{setMessage(message)}}}else{setMessage(message)}};update();var once=scope.$watch("ngModel",function(ngModel){if(ngModel){ngModel.$parsers.push(function(val){update(true);return val});ngModel.$formatters.push(function(val){update(true);return val});once()}});scope.$watchCollection("ngModel.$error",function(){update(!!scope.ngModel)})}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sel,sfPath,schemaForm){return{scope:true,controller:["$scope",function SFArrayController($scope){this.key=$scope.form&&$scope.form.key?$scope.form.key.splice(0,-2):[]}],link:function link(scope,element,attrs){scope.min=0;scope.modelArray=scope.$eval(attrs.sfNewArray);var watchFn=function watchFn(){scope.modelArray=scope.$eval(attrs.sfNewArray);if(scope.ngModel&&scope.ngModel.$pristine&&scope.firstDigest&&(!scope.options||scope.options.validateOnRender!==true)){return}else if(scope.validateField){scope.validateField()}};var onChangeFn=function onChangeFn(){if(scope.form&&scope.form.onChange){if(_angular2.default.isFunction(scope.form.onChange)){scope.form.onChange(scope.modelArray,scope.form)}else{scope.evalExpr(scope.form.onChange,{modelValue:scope.modelArray,form:scope.form})}}};var getOrCreateModel=function getOrCreateModel(){var model=scope.modelArray;if(!model){var selection=sfPath.parse(attrs.sfNewArray);model=[];sel(selection,scope,model);scope.modelArray=model}return model};var once=scope.$watch("form",function(form){if(!form){return}if(!form.titleMap&&form.startEmpty!==true&&(!scope.modelArray||scope.modelArray.length===0)){scope.appendToArray()}if(scope.form&&scope.form.schema&&scope.form.schema.uniqueItems===true){scope.$watch(attrs.sfNewArray,watchFn,true);scope.$watch([attrs.sfNewArray,attrs.sfNewArray+".length"],onChangeFn)}else{if(scope.$watchGroup){scope.$watchGroup([attrs.sfNewArray,attrs.sfNewArray+".length"],function(){watchFn();onChangeFn()})}else{scope.$watch(attrs.sfNewArray,function(){watchFn();onChangeFn()});scope.$watch(attrs.sfNewArray+".length",function(){watchFn();onChangeFn()})}}if(form.titleMap&&form.titleMap.length>0){scope.titleMapValues=[];var updateTitleMapValues=function updateTitleMapValues(arr){scope.titleMapValues=[];arr=arr||[];form.titleMap.forEach(function(item){scope.titleMapValues.push(arr.indexOf(item.value)!==-1)})};updateTitleMapValues(scope.modelArray);scope.$watchCollection("modelArray",updateTitleMapValues);scope.$watchCollection("titleMapValues",function(vals,old){if(vals&&vals!==old){var arr=getOrCreateModel();form.titleMap.forEach(function(item,index){var arrIndex=arr.indexOf(item.value);if(arrIndex===-1&&vals[index]){arr.push(item.value)}if(arrIndex!==-1&&!vals[index]){arr.splice(arrIndex,1)}});if(scope.validateField){scope.validateField()}}})}once()});scope.appendToArray=function(){var empty;var model=getOrCreateModel();if(scope.form&&scope.form.schema&&scope.form.schema.items){var items=scope.form.schema.items;if(items.type&&items.type.indexOf("object")!==-1){empty={};if(!scope.options||scope.options.setSchemaDefaults!==false){empty=_angular2.default.isDefined(items["default"])?items["default"]:empty;if(empty){schemaForm.traverseSchema(items,function(prop,path){if(_angular2.default.isDefined(prop["default"])){sel(path,empty,prop["default"])}})}}}else if(items.type&&items.type.indexOf("array")!==-1){empty=[];if(!scope.options||scope.options.setSchemaDefaults!==false){empty=items["default"]||empty}}else{if(!scope.options||scope.options.setSchemaDefaults!==false){empty=items["default"]||empty}}}model.push(empty);return model};scope.deleteFromArray=function(index){var model=scope.modelArray;if(model){model.splice(index,1)}return model};var setIndex=function setIndex(index){return function(form){if(form.key){form.key[form.key.indexOf("")]=index}}};var formDefCache={};scope.copyWithIndex=function(index){var form=scope.form;if(!formDefCache[index]){var subForm=form.items[0];if(form.items.length>1){subForm={type:"section",items:form.items.map(function(item){item.ngModelOptions=form.ngModelOptions;if(_angular2.default.isUndefined(item.readonly)){item.readonly=form.readonly}return item})}}if(subForm){var copy=_angular2.default.copy(subForm);copy.arrayIndex=index;schemaForm.traverseForm(copy,setIndex(index));formDefCache[index]=copy}}return formDefCache[index]}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(schemaForm,sfPath){return{scope:true,require:["^^sfNewArray"],link:{pre:function pre(scope,element,attrs,ctrl){var currentKey=sfPath.parse(attrs.sfParentKey);if(currentKey.length>1)currentKey=currentKey.splice(-1);scope.parentKey=scope.parentKey||[];scope.parentKey=scope.parentKey.concat(currentKey,Number(attrs.sfIndex));scope.arrayIndex=Number(attrs.sfIndex);scope.arrayIndices=scope.arrayIndices||[];scope.arrayIndices=scope.arrayIndices.concat(scope.arrayIndex);scope.$i=scope.arrayIndices}}}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function($compile,$http,$templateCache,$q,schemaForm,schemaFormDecorators,sfSelect,sfPath,sfBuilder){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function($scope){this.evalInParentScope=function(expr,locals){return $scope.$parent.$eval(expr,locals)};var that=this;$scope.lookup=function(lookup){if(lookup){that.lookup=lookup}return that.lookup}}],replace:false,restrict:"A",transclude:true,require:"?form",link:function link(scope,element,attrs,formCtrl,transclude){scope.formCtrl=formCtrl;var ignore={};transclude(scope,function(clone){clone.addClass("schema-form-ignore");element.prepend(clone);if(element[0].querySelectorAll){var models=element[0].querySelectorAll("[ng-model]");if(models){for(var i=0;i<models.length;i++){var key=models[i].getAttribute("ng-model");ignore[key.substring(key.indexOf(".")+1)]=true}}}});var lastDigest={};var childScope;var render=function render(schema,form){var asyncTemplates=[];var merged=schemaForm.merge(schema,form,ignore,scope.options,undefined,asyncTemplates);if(asyncTemplates.length>0){$q.all(asyncTemplates.map(function(form){return $http.get(form.templateUrl,{cache:$templateCache}).then(function(res){form.template=res.data})})).then(function(){internalRender(schema,form,merged)})}else{internalRender(schema,form,merged)}};var internalRender=function internalRender(schema,form,merged){if(childScope){scope.externalDestructionInProgress=true;childScope.$destroy();scope.externalDestructionInProgress=false}childScope=scope.$new();childScope.schemaForm={form:merged,schema:schema};element.children(":not(.schema-form-ignore)").remove();var slots={};var slotsFound=element[0].querySelectorAll("*[sf-insert-field]");for(var i=0;i<slotsFound.length;i++){slots[slotsFound[i].getAttribute("sf-insert-field")]=slotsFound[i]}var decorator=schemaFormDecorators.decorator(attrs.sfUseDecorator);var lookup=Object.create(null);scope.lookup(lookup);element[0].appendChild(sfBuilder.build(merged,decorator,slots,lookup));childScope.firstDigest=true;setTimeout(function(){childScope.firstDigest=false},0);$compile(element.children())(childScope);if(!scope.options||scope.options.setSchemaDefaults!==false){schemaForm.traverseSchema(schema,function(prop,path){if(_angular2.default.isDefined(prop["default"])){var val=sfSelect(path,scope.model);if(_angular2.default.isUndefined(val)){sfSelect(path,scope.model,prop["default"])}}})}scope.$emit("sf-render-finished",element)};var defaultForm=["*"];scope.$watch(function(){var schema=scope.schema;var form=scope.initialForm||defaultForm;if(form&&schema&&schema.type&&(lastDigest.form!==form||lastDigest.schema!==schema)&&Object.keys(schema.properties).length>0){lastDigest.schema=schema;lastDigest.form=form;render(schema,form)}});scope.$on("schemaFormRedraw",function(){var schema=scope.schema;var form=scope.initialForm?_angular2.default.copy(scope.initialForm):["*"];if(schema){render(schema,form)}});scope.$on("$destroy",function(){scope.externalDestructionInProgress=true});scope.evalExpr=function(expression,locals){return scope.$parent.$eval(expression,locals)}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}},function(module,exports,__webpack_require__){"use strict";Object.defineProperty(exports,"__esModule",{value:true});exports.default=function(sfValidator,$parse,sfSelect){return{restrict:"A",scope:false,priority:500,require:"ngModel",link:function link(scope,element,attrs,ngModel){scope.$emit("schemaFormPropagateNgModelController",ngModel);var error=null;var form=scope.$eval(attrs.schemaValidate);if(form.copyValueTo){ngModel.$viewChangeListeners.push(function(){var paths=form.copyValueTo;_angular2.default.forEach(paths,function(path){sfSelect(path,scope.model,ngModel.$modelValue)})})}var validate=function validate(viewValue){if(!form){return viewValue}if(scope.options&&scope.options.tv4Validation===false){return viewValue}var result=sfValidator.validate(form,viewValue);Object.keys(ngModel.$error).filter(function(k){return k.indexOf("tv4-")===0}).forEach(function(k){ngModel.$setValidity(k,true)});if(!result.valid){ngModel.$setValidity("tv4-"+result.error.code,false);error=result.error;if(ngModel.$validators){return viewValue}return undefined}return viewValue};if(typeof form.ngModel==="function"){form.ngModel(ngModel)}["$parsers","$viewChangeListeners","$formatters"].forEach(function(attr){if(form[attr]&&ngModel[attr]){form[attr].forEach(function(fn){ngModel[attr].push(fn)})}});["$validators","$asyncValidators"].forEach(function(attr){if(form[attr]&&ngModel[attr]){_angular2.default.forEach(form[attr],function(fn,name){ngModel[attr][name]=fn})}});ngModel.$parsers.push(validate);if(ngModel.$validators){ngModel.$validators.schemaForm=function(){return!Object.keys(ngModel.$error).some(function(e){return e!=="schemaForm"})}}var schema=form.schema;scope.validateField=function(formName){if(formName!=undefined&&ngModel.$$parentForm.$name!==formName){return}if(schema&&schema.type.indexOf("array")!==-1){validate(ngModel.$modelValue)}if(ngModel.$setDirty){ngModel.$setDirty();ngModel.$setViewValue(ngModel.$viewValue);ngModel.$commitViewValue();if(form.type==="checkbox"){if(form.required&&ngModel.$modelValue===undefined){ngModel.$setValidity("tv4-302",false)}}else if(form.required&&ngModel.$isEmpty(ngModel.$modelValue)){ngModel.$setValidity("tv4-302",false)}}else{ngModel.$setViewValue(ngModel.$viewValue)}};var first=true;ngModel.$formatters.push(function(val){if(ngModel.$pristine&&first&&(!scope.options||scope.options.validateOnRender!==true)){first=false;return val}validate(ngModel.$modelValue);return val});scope.$on("schemaFormValidate",function(event,formName){scope.validateField(formName)});scope.schemaError=function(){return error}}}};var _angular=__webpack_require__(2);var _angular2=_interopRequireDefault(_angular);function _interopRequireDefault(obj){return obj&&obj.__esModule?obj:{default:obj}}}])})},function(module,exports){module.exports=angular},function(module,exports){module.exports=tv4}])});
\ No newline at end of file
+!function(e){function r(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,r),a.l=!0,a.exports}var t={};return r.m=e,r.c=t,r.i=function(e){return e},r.d=function(e,r,t){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:t})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=21)}([function(e,r,t){t(17)},function(e,r){var t="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r,t){"use strict";function n(e,r,t,n,a){var o=t.builders.simpleTransclusion,l=t.builders.ngModelOptions,f=t.builders.ngModel,d=t.builders.sfField,m=t.builders.condition,h=t.builders.array,v=t.builders.numeric,b=function(e){if(e.form.tabs&&e.form.tabs.length>0){var r=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(t,n){var a="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',o=document.createElement("div");o.className="tab-pane",o.setAttribute("ng-disabled","form.readonly"),o.setAttribute("ng-show","selected.tab === "+n),o.setAttribute("ng-class","{active: selected.tab === "+n+"}"),t.condition&&o.setAttribute("ng-if",a);var i=e.build(t.items,e.path+".tabs["+n+"].items",e.state);o.appendChild(i),r.appendChild(o)})}},x=function(e){if(e.form.placeholder){var r=e.fieldFrag.querySelector("select"),t=document.createElement("option");t.setAttribute("value",""),t.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?t.setAttribute("ng-if","$$value$$ === undefined"):t.setAttribute("ng-show","$$value$$ === undefined"),t.textContent=e.form.placeholder,r.appendChild(t)}},C=[d,f,l,m];r.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,f,h,m]},button:{template:F.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:u.a,builder:[d,l,f,h,m]},conditional:{template:A.a,builder:[d,o,m]},default:{template:p.a,builder:C},fieldset:{template:g.a,builder:[d,o,m]},help:{template:y.a,builder:C},number:{template:p.a,builder:C.concat(v)},password:{template:p.a,builder:C},radios:{template:k.a,builder:C},"radios-inline":{template:M.a,builder:C},radiobuttons:{template:$.a,builder:C},section:{template:A.a,builder:[d,o,m]},select:{template:E.a,builder:C.concat(x)},submit:{template:F.a,builder:C},tabarray:{template:I.a,builder:[d,l,f,h,m]},tabs:{template:P.a,builder:[d,l,b,m]},textarea:{template:T.a,builder:C}},[])}function a(){return function(e){if(!e)return"";var r,t,n;for(n=e.slice(),t=0;t<n.length;t++)r=n[t].toLowerCase().split(""),t&&r.length&&(r[0]=r[0].toUpperCase()),n[t]=r.join("");return n.join("")}}var o=t(1),i=t.n(o),l=t(2),s=t.n(l),f=t(3),c=t.n(f),d=t(4),u=t.n(d),m=t(5),p=t.n(m),h=t(6),g=t.n(h),v=t(7),y=t.n(v),b=t(8),$=t.n(b),x=t(10),k=t.n(x),C=t(9),M=t.n(C),w=t(11),A=t.n(w),S=t(12),E=t.n(S),O=t(13),F=t.n(O),D=t(14),I=t.n(D),V=t(15),P=t.n(V),j=t(16),T=t.n(j);angular.module("schemaForm").config(n).filter("sfCamelKey",a),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,r){/*!
+ * angular-schema-form
+ * @version 1.0.0-alpha.1
+ * @date Sat, 14 Jan 2017 17:09:44 GMT
+ * @link https://github.com/json-schema-form/angular-schema-form
+ * @license MIT
+ * Copyright (c) 2014-2017 JSON Schema Form
+ */
+!function(e){function r(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,r),a.l=!0,a.exports}var t={};return r.m=e,r.c=t,r.i=function(e){return e},r.d=function(e,r,t){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:t})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=16)}([function(e,r){e.exports=angular},function(e,r){/*!
+ * json-schema-form-core
+ * @version 1.0.0-alpha.1
+ * @date Sat, 14 Jan 2017 17:07:51 GMT
+ * @link https://github.com/json-schema-form/json-schema-form-core
+ * @license MIT
+ * Copyright (c) 2014-2017 JSON Schema Form
+ */
+e.exports=function(e){function r(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,r),a.l=!0,a.exports}var t={};return r.m=e,r.c=t,r.i=function(e){return e},r.d=function(e,r,t){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:t})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=11)}([function(e,r,t){"use strict";function n(e,r){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(e){var a=e.slice(),o=r||"-";return n&&(a=a.filter(function(e){return"number"!=typeof e})),(0!==t.length?t+o:"")+a.join(o)}return""}var a=t(2);t.n(a);r.name=n,t.o(a,"parse")&&t.d(r,"parse",function(){return a.parse}),t.o(a,"stringify")&&t.d(r,"stringify",function(){return a.stringify}),t.o(a,"normalize")&&t.d(r,"normalize",function(){return a.normalize})},function(e,r,t){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};r.a=function(e,r){if(!Array.isArray(e)){var t=function(){var t=[];return r?r.forEach(function(r){t.push({name:e[r],value:r})}):Object.keys(e).forEach(function(r){t.push({name:e[r],value:r})}),{v:t}}();if("object"===("undefined"==typeof t?"undefined":n(t)))return t.v}return e}},function(e,r,t){e.exports=t(9).ObjectPath},function(e,r,t){"use strict";function n(e,r,t,a){var o=e[y(t.type)];if(o)for(var i=void 0,l=function(r,t,a){return n(e,r,t,a)},s=0;s<o.length;s++)if(i=o[s](r,t,a,l))return i.schema["x-schema-form"]&&Object.assign(i,i.schema["x-schema-form"]),i}function a(e,r,n){n=n||{};var a=n.global&&n.global.formDefaults?Object.assign({},n.global.formDefaults):{};return n.global&&n.global.supressPropertyTitles===!0?a.title=r.title:a.title=r.title||e,r.description&&(a.description=r.description),n.required!==!0&&r.required!==!0||(a.required=!0),r.maxLength&&(a.maxlength=r.maxLength),r.minLength&&(a.minlength=r.minLength),(r.readOnly||r.readonly)&&(a.readonly=!0),r.minimum&&(a.minimum=r.minimum+(r.exclusiveMinimum?1:0)),r.maximum&&(a.maximum=r.maximum-(r.exclusiveMaximum?1:0)),r.validationMessage&&(a.validationMessage=r.validationMessage),r.enumNames&&(a.titleMap=t.i(g.a)(r.enumNames,r.enum)),a.schema=r,a.ngModelOptions=a.ngModelOptions||{},a}function o(e,r,n){if("string"===y(r.type)&&!r.enum){var o=a(e,r,n);return o.key=n.path,o.type="text",n.lookup[t.i(h.stringify)(n.path)]=o,o}}function i(e,r,n){if("number"===y(r.type)){var o=a(e,r,n);return o.key=n.path,o.type="number",n.lookup[t.i(h.stringify)(n.path)]=o,o}}function l(e,r,n){if("integer"===y(r.type)){var o=a(e,r,n);return o.key=n.path,o.type="number",n.lookup[t.i(h.stringify)(n.path)]=o,o}}function s(e,r,n){if("boolean"===y(r.type)){var o=a(e,r,n);return o.key=n.path,o.type="checkbox",n.lookup[t.i(h.stringify)(n.path)]=o,o}}function f(e,r,n){if("string"===y(r.type)&&r.enum){var o=a(e,r,n);return o.key=n.path,o.type="select",o.titleMap||(o.titleMap=b(r.enum)),n.lookup[t.i(h.stringify)(n.path)]=o,o}}function c(e,r,n){if("array"===y(r.type)&&r.items&&r.items.enum){var o=a(e,r,n);return o.key=n.path,o.type="checkboxes",o.titleMap||(o.titleMap=b(r.items.enum)),n.lookup[t.i(h.stringify)(n.path)]=o,o}}function d(e,r,n,o){if("object"===y(r.type)){var i=function(){var i=a(e,r,n);return i.type="fieldset",i.key=n.path,i.items=[],n.lookup[t.i(h.stringify)(n.path)]=i,r.properties&&Object.keys(r.properties).forEach(function(e){var a=r.properties[e],l=n.path.slice();if(l.push(e),n.ignore[t.i(h.stringify)(l)]!==!0){var s=r.required&&r.required.indexOf(e)!==-1,f=o(e,a,{path:l,required:s||!1,lookup:n.lookup,ignore:n.ignore,global:n.global});f&&i.items.push(f)}}),{v:i}}();if("object"===("undefined"==typeof i?"undefined":v(i)))return i.v}}function u(e,r,n,o){if("array"===y(r.type)){var i=a(e,r,n);i.type="array",i.key=n.path,n.lookup[t.i(h.stringify)(n.path)]=i;var l=r.required&&r.required.indexOf(n.path[n.path.length-1])!==-1,s=n.path.slice();return s.push(""),i.items=[o(e,r.items,{path:s,required:l||!1,lookup:n.lookup,ignore:n.ignore,global:n.global})],i}}function m(){return{string:[f,o],object:[d],number:[i],integer:[l],boolean:[s],array:[c,u]}}function p(e,r,t,a){var o=[],i={};if(t=t||{},a=a||{},r=r||m(),!e.properties)throw new Error('Not implemented. Only type "object" allowed at root level of schema.');return Object.keys(e.properties).forEach(function(l){if(t[l]!==!0){var s=e.required&&e.required.indexOf(l)!==-1,f=n(r,l,e.properties[l],{path:[l],lookup:i,ignore:t,required:s,global:a});f&&o.push(f)}}),{form:o,lookup:i}}var h=t(0),g=t(1);r.defaultFormDefinition=n,r.stdFormObj=a,r.text=o,r.number=i,r.integer=l,r.checkbox=s,r.select=f,r.checkboxes=c,r.fieldset=d,r.array=u,r.createDefaults=m,r.defaultForm=p;var v="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},y=function(e){if(Array.isArray(e)&&2===e.length){if("null"===e[0])return e[1];if("null"===e[1])return e[0]}return e},b=function(e){var r=[];return e.forEach(function(e){r.push({name:e,value:e})}),r}},function(e,r,t){"use strict";var n=t(3),a=t(0),o=t(1),i=t(5),l=t(6),s=t(7),f=t(8);t.d(r,"sfPath",function(){return c}),t.d(r,"schemaDefaults",function(){return d}),t.d(r,"canonicalTitleMap",function(){return u}),t.d(r,"merge",function(){return i.a}),t.d(r,"select",function(){return l.a}),t.d(r,"traverseSchema",function(){return s.a}),t.d(r,"traverseForm",function(){return s.b}),t.d(r,"validate",function(){return f.a});var c=a,d=n,u=o.a},function(e,r,t){"use strict";function n(e,r,s,f,c,d){var u=[];r=r||[];var m=r.indexOf("*");if(f=f||{},"object"===("undefined"==typeof e?"undefined":l(e))&&e.hasOwnProperty("properties")){c=c||e.readonly||e.readOnly;var p=t.i(o.defaultForm)(e,t.i(o.createDefaults)(),s,f),h=p.lookup;e=h||e,u=u.concat(p.form)}return m!==-1&&(r=r.slice(0,m).concat(u).concat(r.slice(m+1))),r.map(function(r){if("string"==typeof r&&(r={key:r}),r.key&&"string"==typeof r.key&&(r.key=t.i(a.parse)(r.key)),r.titleMap&&(r.titleMap=t.i(i.a)(r.titleMap)),r.key){var o=t.i(a.stringify)(r.key);e[o]&&!function(){var t=e[o];t&&Object.keys(t).forEach(function(e){void 0===r[e]&&(r[e]=t[e])})}()}return c===!0&&(r.readonly=!0),r.items&&(r.items=n(e,r.items,s,f,r.readonly,d)),r.tabs&&r.tabs.forEach(function(t){t.items&&(t.items=n(e,t.items,s,f,r.readonly,d))}),"checkbox"===r.type&&void 0===r.schema.default&&(r.schema.default=!1),d&&"template"===r.type&&!r.template&&r.templateUrl&&d.push(r),r})}var a=t(0),o=t(3),i=t(1);r.a=n;var l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e}},function(e,r,t){"use strict";function n(e,r,t){r||(r=this);var n="string"==typeof e?a.parse(e):e;if("undefined"!=typeof t&&1===n.length)return r[n[0]]=t,r;"undefined"!=typeof t&&"undefined"==typeof r[n[0]]&&(r[n[0]]=n.length>2&&o.test(n[1])?[]:{});for(var i=r[n[0]],l=1;l<n.length;l++){if(""===n[l])return;if("undefined"!=typeof t){if(l===n.length-1)return i[n[l]]=t,t;var s=i[n[l]];"undefined"!=typeof s&&null!==s||(s=o.test(n[l+1])?[]:{},i[n[l]]=s),i=s}else i&&(i=i[n[l]])}return i}var a=t(0);r.a=n;var o=/^\d+$/},function(e,r,t){"use strict";function n(e,r,t,n){n=void 0===n||n,t=t||[];var a=function e(r,t,a){if(t(r,a),r.properties&&Object.keys(r.properties).forEach(function(n){var o=a.slice();o.push(n),e(r.properties[n],t,o)}),!n&&r.items){var o=a.slice();o.push(""),e(r.items,t,o)}};a(e,r,t||[])}function a(e,r){r(e),e.items&&e.items.forEach(function(e){a(e,r)}),e.tabs&&e.tabs.forEach(function(e){e.items&&e.items.forEach(function(e){a(e,r)})})}r.a=n,r.b=a},function(e,r,t){"use strict";function n(e,r){if(!e)return{valid:!0};var t=e.schema;if(!t)return{valid:!0};""===r&&(r=void 0),"number"===e.type&&null===r&&(r=void 0);var n={type:"object",properties:{},required:void 0},a=e.key[e.key.length-1];n.properties[a]=t,e.required&&(n.required=[a]);var i={};return r&&(i[a]=r),o.a.validateResult(i,n)}var a=t(10),o=t.n(a);r.a=n},function(e,r,t){"use strict";var n;!function(a){var o={parse:function(e){if("string"!=typeof e)throw new TypeError("ObjectPath.parse must be passed a string");for(var r,t,n,a,o=0,i=[];o<e.length;)if(r=e.indexOf(".",o),t=e.indexOf("[",o),r===-1&&t===-1)i.push(e.slice(o,e.length)),o=e.length;else if(t===-1||r!==-1&&r<t)i.push(e.slice(o,r)),o=r+1;else if(t>o&&(i.push(e.slice(o,t)),o=t),n=e.slice(t+1,t+2),'"'!==n&&"'"!==n)a=e.indexOf("]",t),a===-1&&(a=e.length),i.push(e.slice(o+1,a)),o="."===e.slice(a+1,a+2)?a+2:a+1;else{for(a=e.indexOf(n+"]",t),a===-1&&(a=e.length);"\\"===e.slice(a-1,a)&&t<e.length;)t++,a=e.indexOf(n+"]",t);i.push(e.slice(o+2,a).replace(new RegExp("\\"+n,"g"),n)),o="."===e.slice(a+2,a+3)?a+3:a+2}return i},stringify:function(e,r){return Array.isArray(e)||(e=[e.toString()]),r='"'===r?'"':"'",e.map(function(e){return"["+r+e.toString().replace(new RegExp(r,"g"),"\\"+r)+r+"]"}).join("")},normalize:function(e,r){return o.stringify(Array.isArray(e)?e:o.parse(e),r)},registerModule:function(e){e.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=o.parse,this.stringify=o.stringify,this.normalize=o.normalize,this.$get=function(){return o}})}};n=function(){return{ObjectPath:o}}.call(r,t,r,e),!(n!==a&&(e.exports=n))}()},function(e,r){e.exports=tv4},function(e,r,t){e.exports=t(4)}])},,function(e,r,t){"use strict";var n=t(1),a=t.n(n),o=t(0),i=t.n(o),l=t(13),s=t(11),f=t(12),c=t(14),d=t(15),u=t(6),m=t(7),p=t(9),h=t(5),g=t(8),v=t(10),y=t(4),b=[];try{i.a.module("ngSanitize"),b.push("ngSanitize")}catch(e){}try{i.a.module("ui.sortable"),b.push("ui.sortable")}catch(e){}try{i.a.module("angularSpectrumColorpicker"),b.push("angularSpectrumColorpicker")}catch(e){}i.a.module("schemaForm",b).provider("sfPath",d.a).provider("sfBuilder",["sfPathProvider",l.a]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",s.a]).provider("sfErrorMessage",c.a).provider("schemaForm",["sfPathProvider",f.a]).factory("sfSelect",function(){return a.a.select}).factory("sfValidator",function(){return a.a.validate}).directive("sfChanged",u.a).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",m.a]).directive("sfMessage",["$injector","sfErrorMessage",p.a]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",h.a]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",v.a]).directive("schemaValidate",["sfValidator","$parse","sfSelect",y.a]).directive("sfKeyController",["schemaForm","sfPath",g.a])},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(e,r,t){return{restrict:"A",scope:!1,priority:500,require:"ngModel",link:function(r,n,o,i){r.$emit("schemaFormPropagateNgModelController",i);var l=null,s=r.$eval(o.schemaValidate);s.copyValueTo&&i.$viewChangeListeners.push(function(){var e=s.copyValueTo;a.a.forEach(e,function(e){t(e,r.model,i.$modelValue)})});var f=function(t){if(!s)return t;if(r.options&&r.options.tv4Validation===!1)return t;var n=e(s,t);Object.keys(i.$error).filter(function(e){return 0===e.indexOf("tv4-")}).forEach(function(e){i.$setValidity(e,!0)});{if(n.valid)return t;if(i.$setValidity("tv4-"+n.error.code,!1),l=n.error,i.$validators)return t}};"function"==typeof s.ngModel&&s.ngModel(i),["$parsers","$viewChangeListeners","$formatters"].forEach(function(e){s[e]&&i[e]&&s[e].forEach(function(r){i[e].push(r)})}),["$validators","$asyncValidators"].forEach(function(e){s[e]&&i[e]&&a.a.forEach(s[e],function(r,t){i[e][t]=r})}),i.$parsers.push(f),i.$validators&&(i.$validators.schemaForm=function(){return!Object.keys(i.$error).some(function(e){return"schemaForm"!==e})});var c=s.schema;r.validateField=function(e){void 0!=e&&i.$$parentForm.$name!==e||(c&&c.type.indexOf("array")!==-1&&f(i.$modelValue),i.$setDirty?(i.$setDirty(),i.$setViewValue(i.$viewValue),i.$commitViewValue(),"checkbox"===s.type?s.required&&void 0===i.$modelValue&&i.$setValidity("tv4-302",!1):s.required&&i.$isEmpty(i.$modelValue)&&i.$setValidity("tv4-302",!1)):i.$setViewValue(i.$viewValue))};var d=!0;i.$formatters.push(function(e){return!i.$pristine||!d||r.options&&r.options.validateOnRender===!0?(f(i.$modelValue),e):(d=!1,e)}),r.$on("schemaFormValidate",function(e,t){r.validateField(t)}),r.schemaError=function(){return l}}}}},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(e,r,t){return{scope:!0,controller:["$scope",function(e){this.key=e.form&&e.form.key?e.form.key.splice(0,-2):[]}],link:function(n,o,i){n.min=0,n.modelArray=n.$eval(i.sfNewArray);var l=function(){n.modelArray=n.$eval(i.sfNewArray),n.ngModel&&n.ngModel.$pristine&&n.firstDigest&&(!n.options||n.options.validateOnRender!==!0)||n.validateField&&n.validateField()},s=function(){n.form&&n.form.onChange&&(a.a.isFunction(n.form.onChange)?n.form.onChange(n.modelArray,n.form):n.evalExpr(n.form.onChange,{modelValue:n.modelArray,form:n.form}))},f=function(){var t=n.modelArray;if(!t){var a=r.parse(i.sfNewArray);t=[],e(a,n,t),n.modelArray=t}return t},c=n.$watch("form",function(e){if(e){if(e.titleMap||e.startEmpty===!0||n.modelArray&&0!==n.modelArray.length||n.appendToArray(),n.form&&n.form.schema&&n.form.schema.uniqueItems===!0?(n.$watch(i.sfNewArray,l,!0),n.$watch([i.sfNewArray,i.sfNewArray+".length"],s)):n.$watchGroup?n.$watchGroup([i.sfNewArray,i.sfNewArray+".length"],function(){l(),s()}):(n.$watch(i.sfNewArray,function(){l(),s()}),n.$watch(i.sfNewArray+".length",function(){l(),s()})),e.titleMap&&e.titleMap.length>0){n.titleMapValues=[];var r=function(r){n.titleMapValues=[],r=r||[],e.titleMap.forEach(function(e){n.titleMapValues.push(r.indexOf(e.value)!==-1)})};r(n.modelArray),n.$watchCollection("modelArray",r),n.$watchCollection("titleMapValues",function(r,t){if(r&&r!==t){var a=f();e.titleMap.forEach(function(e,t){var n=a.indexOf(e.value);n===-1&&r[t]&&a.push(e.value),n===-1||r[t]||a.splice(n,1)}),n.validateField&&n.validateField()}})}c()}});n.appendToArray=function(){var r,o=f();if(n.form&&n.form.schema&&n.form.schema.items){var i=n.form.schema.items;i.type&&i.type.indexOf("object")!==-1?(r={},n.options&&n.options.setSchemaDefaults===!1||(r=a.a.isDefined(i.default)?i.default:r,r&&t.traverseSchema(i,function(t,n){a.a.isDefined(t.default)&&e(n,r,t.default)}))):i.type&&i.type.indexOf("array")!==-1?(r=[],n.options&&n.options.setSchemaDefaults===!1||(r=i.default||r)):n.options&&n.options.setSchemaDefaults===!1||(r=i.default||r)}return o.push(r),o},n.deleteFromArray=function(e){var r=n.modelArray;return r&&r.splice(e,1),r};var d=function(e){return function(r){r.key&&(r.key[r.key.indexOf("")]=e)}},u={};n.copyWithIndex=function(e){var r=n.form;if(!u[e]){var o=r.items[0];if(r.items.length>1&&(o={type:"section",items:r.items.map(function(e){return e.ngModelOptions=r.ngModelOptions,a.a.isUndefined(e.readonly)&&(e.readonly=r.readonly),e})}),o){var i=a.a.copy(o);i.arrayIndex=e,t.traverseForm(i,d(e)),u[e]=i}}return u[e]}}}}},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(){return{require:"ngModel",restrict:"AC",scope:!1,link:function(e,r,t,n){var o=e.$eval(t.sfChanged);o&&o.onChange&&n.$viewChangeListeners.push(function(){a.a.isFunction(o.onChange)?o.onChange(n.$modelValue,o):e.evalExpr(o.onChange,{modelValue:n.$modelValue,form:o,arrayIndex:e.$index,arrayIndices:e.arrayIndices,path:e.path,$i:e.$i,$index:e.$index})})}}}},function(e,r,t){"use strict";var n=t(0),a=t.n(n),o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};r.a=function(e,r,t,n,i,l,s,f,c){var d={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function(e,r,t,n){var a=n[0];n[1],n[2];e.$on("schemaFormPropagateNgModelController",function(r,t){r.stopPropagation(),r.preventDefault(),e.ngModel=t}),e.initialForm=Object.assign({},a.lookup["f"+t.sfField]),e.form=a.lookup["f"+t.sfField]},post:function(e,r,t,n){var l=n[0],u=n[1];n[2];e.getKey=function(r){var t=r||d.COMPLETE,n=e.parentKey?e.parentKey.slice(0,e.parentKey.length-1):[];if(e.completeKey!==e.form.key&&("number"==typeof e.$index&&(n=n.concat(e.$index)),e.form.key&&e.form.key.length))if("number"==typeof n[n.length-1]&&e.form.key.length>=1){var a=e.form.key.length-n.length;e.completeKey=n.concat(e.form.key.slice(-a))}else e.completeKey=e.form.key.slice();if(Array.isArray(e.completeKey))return t===d.COMPLETE?e.completeKey:e.completeKey.reduce(function(e,r,n){return-1!==[t].indexOf("undefined"==typeof r?"undefined":o(r))?e.concat(r):e},[])},e.form.key&&(e.form.key=e.completeKey=e.getKey()),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(r,t){var n=t||!1,a=r&&u&&u.$name?u.$name:void 0,o=e.completeKey;return Array.isArray(o)?f.name(o,"-",a,n):""},e.listToCheckboxValues=function(e){var r={};return a.a.forEach(e,function(e){r[e]=!0}),r},e.checkboxValuesToList=function(e){var r=[];return a.a.forEach(e,function(e,t){e&&r.push(t)}),r},e.buttonClick=function(r,t){a.a.isFunction(t.onClick)?t.onClick(r,t):a.a.isString(t.onClick)&&(l?l.evalInParentScope(t.onClick,{$event:r,form:t}):e.$eval(t.onClick,{$event:r,form:t}))},e.evalExpr=function(r,t){return l?l.evalInParentScope(r,t):e.$eval(r,t)},e.evalInScope=function(r,t){if(r)return e.$eval(r,t)},e.interp=function(e,r){return e&&i(e)(r)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.errors===!1?e.ngModel.$invalid&&!e.ngModel.$pristine:e.ngModel.$invalid)},e.errorMessage=function(r){return s.interpolate(r&&r.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)},e.form.htmlClass=e.form.htmlClass||"",e.idClass=e.fieldId(!1)+" "+e.fieldId(!1,!0);var m=e.form;m.key&&(e.$on("schemaForm.error."+m.key.join("."),function(r,t,n,a,o){o=a,n!==!0&&n!==!1||(a=n,n=void 0),void 0!=o&&e.ngModel.$$parentForm.$name!==o||e.ngModel&&t&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(m.validationMessage||(m.validationMessage={}),m.validationMessage[t]=n),e.ngModel.$setValidity(t,a===!0),a===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){var r=e.getKey();if(!e.externalDestructionInProgress){var t=m.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(r&&"retain"!==t){var n=e.model;if(r.length>1&&(n=c(r.slice(0,r.length-1),n)),void 0===n)return;var a=m.schema&&m.schema.type||"";"empty"===t&&a.indexOf("string")!==-1?n[r.slice(-1)]="":"empty"===t&&a.indexOf("object")!==-1?n[r.slice(-1)]={}:"empty"===t&&a.indexOf("array")!==-1?n[r.slice(-1)]=[]:"null"===t?n[r.slice(-1)]=null:delete n[r.slice(-1)]}}}))}}}}},function(e,r,t){"use strict";r.a=function(e,r){return{scope:!0,require:["?^^sfNewArray"],link:{pre:function(e,t,n,a){e.parentKey=e.parentKey||[];var o=r.parse(n.sfParentKey),i=o.length-e.parentKey.length;o.length>1&&(o=o.splice(-i)),e.parentKey=e.parentKey.concat(o,Number(n.sfIndex)),e.arrayIndex=Number(n.sfIndex),e.arrayIndices=e.arrayIndices||[],e.arrayIndices=e.arrayIndices.concat(e.arrayIndex),e.$i=e.arrayIndices,e.path=function(r){var t=-1;return r=r.replace(/\[\]/gi,function(r){return t++,"["+e.$i[t]+"]"}),e.evalExpr(r,e)}}}}}},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(e,r){var t=e.has("$sanitize")?e.get("$sanitize"):function(e){return e};return{scope:!1,restrict:"EA",link:function(e,n,o){var i="";o.sfMessage&&e.$watch(o.sfMessage,function(r){r&&(i=t(r),f(!!e.ngModel))});var l,s=function(e){e!==l&&(n.html(e),l=e)},f=function(t){if(t)if(e.hasError()){var n=[];a.a.forEach(e.ngModel&&e.ngModel.$error,function(e,r){e&&n.push(r)}),n=n.filter(function(e){return"schemaForm"!==e});var o=n[0];s(o?r.interpolate(o,e.ngModel.$modelValue,e.ngModel.$viewValue,e.form,e.options&&e.options.validationMessage):i)}else s(i);else s(i)};f();var c=e.$watch("ngModel",function(e){e&&(e.$parsers.push(function(e){return f(!0),e}),e.$formatters.push(function(e){return f(!0),e}),c())});e.$watchCollection("ngModel.$error",function(){f(!!e.ngModel)})}}}},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(e,r,t,n,o,i,l,s,f){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function(e){this.evalInParentScope=function(r,t){return e.$parent.$eval(r,t)};var r=this;e.lookup=function(e){return e&&(r.lookup=e),r.lookup}}],replace:!1,restrict:"A",transclude:!0,require:"?form",link:function(s,c,d,u,m){s.formCtrl=u;var p={};m(s,function(e){if(e.addClass("schema-form-ignore"),c.prepend(e),c[0].querySelectorAll){var r=c[0].querySelectorAll("[ng-model]");if(r)for(var t=0;t<r.length;t++){var n=r[t].getAttribute("ng-model");p[n.substring(n.indexOf(".")+1)]=!0}}});var h,g={},v=function(e,a){var i=[],l=o.merge(e,a,p,s.options,void 0,i);i.length>0?n.all(i.map(function(e){return r.get(e.templateUrl,{cache:t}).then(function(r){e.template=r.data})})).then(function(){y(e,a,l)}):y(e,a,l)},y=function(r,t,n){h&&(s.externalDestructionInProgress=!0,h.$destroy(),s.externalDestructionInProgress=!1),h=s.$new(),h.schemaForm={form:n,schema:r},c.children(":not(.schema-form-ignore)").remove();for(var u={},m=c[0].querySelectorAll("*[sf-insert-field]"),p=0;p<m.length;p++)u[m[p].getAttribute("sf-insert-field")]=m[p];var g=i.decorator(d.sfUseDecorator),v=Object.create(null);s.lookup(v),c[0].appendChild(f.build(n,g,u,v)),h.firstDigest=!0,setTimeout(function(){h.firstDigest=!1},0),e(c.children())(h),s.options&&s.options.setSchemaDefaults===!1||o.traverseSchema(r,function(e,r){if(a.a.isDefined(e.default)){var t=l(r,s.model);a.a.isUndefined(t)&&l(r,s.model,e.default)}}),s.$emit("sf-render-finished",c)},b=["*"];s.$watch(function(){var e=s.schema,r=s.initialForm||b;r&&e&&e.type&&(g.form!==r||g.schema!==e)&&Object.keys(e.properties).length>0&&(g.schema=e,g.form=r,v(e,r))}),s.$on("schemaFormRedraw",function(){var e=s.schema,r=s.initialForm?a.a.copy(s.initialForm):["*"];e&&v(e,r)}),s.$on("$destroy",function(){s.externalDestructionInProgress=!0}),s.evalExpr=function(e,r){return s.$parent.$eval(e,r)}}}}},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(e,r){var t="",n={},o=function(e,r){"sfDecorator"===e&&(e=t);var a=n[e];return a[r.type]?a[r.type].template:a.default.template},i=function(t){e.directive(t,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function(e,n,i,l,s,f,c,d,u){return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["?^sfSchema","?^form"],link:function(e,m,p,h){var g=h[0],v=h[1];e.$on("schemaFormPropagateNgModelController",function(r,t){r.stopPropagation(),r.preventDefault(),e.ngModel=t}),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(r,t){var n=e.parentKey||[];if(e.form.key){if("number"==typeof n[n.length-1]){var a=n.concat(e.form.key.slice(-1)),o=r&&v&&v.$name?v.$name:void 0;return d.name(a,"-",o,t)}var o=r&&v&&v.$name?v.$name:void 0;return d.name(e.form.key,"-",o,t)}return""},e.listToCheckboxValues=function(e){var r={};return a.a.forEach(e,function(e){r[e]=!0}),r},e.checkboxValuesToList=function(e){var r=[];return a.a.forEach(e,function(e,t){e&&r.push(t)}),r},e.buttonClick=function(r,t){a.a.isFunction(t.onClick)?t.onClick(r,t):a.a.isString(t.onClick)&&(g?g.evalInParentScope(t.onClick,{$event:r,form:t}):e.$eval(t.onClick,{$event:r,form:t}))},e.evalExpr=function(r,t){return g?g.evalInParentScope(r,t):e.$eval(r,t)},e.evalInScope=function(r,t){if(r)return e.$eval(r,t)},e.interp=function(e,r){return e&&s(e)(r)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.ngModel.$invalid&&!e.ngModel.$pristine)},e.errorMessage=function(r){return c.interpolate(r&&r.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)};var y=e.$watch(p.form,function(s){if(s){s.ngModelOptions=s.ngModelOptions||{},e.form=s;var c;if("template"===s.type&&s.template)c=f.when(s.template);else{var p="template"===s.type?s.templateUrl:o(t,s);c=i.get(p,{cache:l}).then(function(e){return e.data})}c.then(function(t){if(s.key){var o=s.key?r.stringify(s.key).replace(/"/g,"&quot;"):"";t=t.replace(/\$\$value\$\$/g,"model"+("["!==o[0]?".":"")+o)}if(m.html(t),s.condition){var i='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';s.key&&(i='evalExpr(form.condition, {model: model, "arrayIndex": arrayIndex, "modelValue": model'+d.stringify(s.key)+"})"),a.a.forEach(m.children(),function(e){var r=e.getAttribute("ng-if");e.setAttribute("ng-if",r?"("+r+") || ("+i+")":i)})}n(m.contents())(e)}),s.key&&(e.$on("schemaForm.error."+s.key.join("."),function(r,t,n,a,o){o=a,n!==!0&&n!==!1||(a=n,n=void 0),void 0!=o&&e.ngModel.$$parentForm.$name!==o||void 0!=o&&e.ngModel.$$parentForm.$name!==o||e.ngModel&&t&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(s.validationMessage||(s.validationMessage={}),s.validationMessage[t]=n),e.ngModel.$setValidity(t,a===!0),a===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){if(!e.externalDestructionInProgress){var r=s.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(s.key&&"retain"!==r){var t=e.model;if(s.key.length>1&&(t=u(s.key.slice(0,s.key.length-1),t)),void 0===t)return;var n=s.schema&&s.schema.type||"";"empty"===r&&n.indexOf("string")!==-1?t[s.key.slice(-1)]="":"empty"===r&&n.indexOf("object")!==-1?t[s.key.slice(-1)]={}:"empty"===r&&n.indexOf("array")!==-1?t[s.key.slice(-1)]=[]:"null"===r?t[s.key.slice(-1)]=null:delete t[s.key.slice(-1)]}}})),y()}})}}}])},l=function(r,t,n){n=!!a.a.isDefined(n)&&n,e.directive("sf"+a.a.uppercase(r[0])+r.substr(1),function(){return{restrict:"EAC",scope:!0,replace:!0,transclude:n,template:'<sf-decorator form="form"></sf-decorator>',link:function(e,t,n){var o={items:"c",titleMap:"c",schema:"c"},i={type:r},l=!0;a.a.forEach(n,function(r,t){if("$"!==t[0]&&0!==t.indexOf("ng")&&"sfField"!==t){var s=function(r){a.a.isDefined(r)&&r!==i[t]&&(i[t]=r,l&&i.type&&(i.key||a.a.isUndefined(n.key))&&(e.form=i,l=!1))};"model"===t?e.$watch(r,function(r){r&&e.model!==r&&(e.model=r)}):"c"===o[t]?e.$watchCollection(r,s):n.$observe(t,s)}})}}})};this.createDecorator=function(e,r){n[e]={__name:e},a.a.forEach(r,function(r,t){n[e][t]={template:r,replace:!1,builder:[]}}),n[t]||(t=e),i(e)},this.defineDecorator=function(e,r){n[e]={__name:e},a.a.forEach(r,function(r,t){r.builder=r.builder||[],r.replace=!a.a.isDefined(r.replace)||r.replace,n[e][t]=r}),n[t]||(t=e),i(e)},this.createDirective=l,this.createDirectives=function(e){a.a.forEach(e,function(e,r){l(r,e)})},this.decorator=function(e){return e=e||t,n[e]},this.addMapping=function(e,r,t,a,o){n[e]&&(n[e][r]={template:t,builder:a,replace:!!o})},this.defineAddOn=function(e,r,t,a){n[e]&&(n[e][r]={template:t,builder:a,replace:!0})},this.$get=function(){return{decorator:function(e){return n[e]||n[t]},defaultDecorator:t}},i("sfDecorator")}},function(e,r,t){"use strict";var n=t(0),a=(t.n(n),t(1));t.n(a);r.a=function(){var e=function(e){return e},r=a.schemaDefaults.createDefaults();this.defaults=r,this.stdFormObj=a.schemaDefaults.stdFormObj,this.defaultFormDefinition=a.schemaDefaults.defaultFormDefinition,this.postProcess=function(r){e=r},this.appendRule=function(e,r){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].push(r)},this.prependRule=function(e,r){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].unshift(r)},this.createStandardForm=a.schemaDefaults.stdFormObj,this.$get=function(){var r={},n=this.defaults;return r.merge=function(r){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["*"],o=arguments[2],i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},l=arguments.length>4&&void 0!==arguments[4]&&arguments[4],s=arguments[5],f=t.i(a.merge)(r,n,o,i,l,s);return e(f)},r.defaults=function(e,r,t,o){var i=r||n;return a.schemaDefaults.defaultForm(e,i,t,o)},r.typeDefault=n,r.traverseSchema=a.traverseSchema,r.traverseForm=a.traverseForm,r}}},function(e,r,t){"use strict";r.a=function(e){var r=/[A-Z]/g,t=function(e,t){return t=t||"_",e.replace(r,function(e,r){return(r?t:"")+e.toLowerCase()})},n=0;"firstElementChild"in document.createDocumentFragment()||Object.defineProperty(DocumentFragment.prototype,"firstElementChild",{get:function(){for(var e,r=this.childNodes,t=0,n=r.length;t<n;++t)if(e=r[t],1===e.nodeType)return e;return null}});var a={sfField:function(e){e.fieldFrag.firstElementChild.setAttribute("sf-field",n),e.lookup["f"+n]=e.form,n++},ngModel:function(r){if(r.form.key){var t=r.form.key;r.state.keyRedaction&&(t=t.slice(r.state.keyRedaction));var n;if(r.state.modelValue)n=r.state.modelValue;else{var a=e.stringify(t).replace(/"/g,"&quot;");n=r.state.modelName||"model",a&&(n+=("["!==a[0]?".":"")+a)}for(var o=r.fieldFrag.querySelectorAll("[sf-field-model]"),i=0;i<o.length;i++){var l=o[i],s=l.getAttribute("sf-field-model");if(s&&""!==s)if("replaceAll"===s)for(var f=l.attributes,c=0;c<f.length;c++)f[c].value&&f[c].value.indexOf("$$value")!==-1&&(f[c].value=f[c].value.replace(/\$\$value\$\$/g,n));else{var d=l.getAttribute(s);d&&d.indexOf("$$value$$")?l.setAttribute(s,d.replace(/\$\$value\$\$/g,n)):l.setAttribute(s,n)}else l.setAttribute("ng-model",n)}}},simpleTransclusion:function(e){var r=e.build(e.form.items,e.path+".items",e.state);e.fieldFrag.firstChild.appendChild(r)},ngModelOptions:function(e){e.form.ngModelOptions&&Object.keys(e.form.ngModelOptions).length>0&&e.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(e.form.ngModelOptions))},transclusion:function(e){var r=e.fieldFrag.querySelectorAll("[sf-field-transclude]");if(r.length)for(var t=0;t<r.length;t++){var n=r[t],a=n.getAttribute("sf-field-transclude")||"items",o=e.form[a];if(o){var i=e.build(o,e.path+"."+a,e.state);n.appendChild(i)}}},condition:function(r){var t="",n="undefined",a="";if(r.form.condition){r.form.key&&(t=e.stringify(r.form.key),n="model"+("["===t[0]?"":".")+t);for(var o="evalExpr("+r.path+'.condition, { model: model, "arrayIndex": $index, "arrayIndices": arrayIndices, "path": path, "$i": $i, "$index": $index, "modelValue": '+n+"})",i=r.fieldFrag.children||r.fieldFrag.childNodes,l=0;l<i.length;l++){var s=i[l];s.hasAttribute&&s.hasAttribute("ng-if")&&(a=s.getAttribute("ng-if")),s.setAttribute&&s.setAttribute("ng-if",a?"("+a+") || ("+o+")":o)}}},array:function(r){var t=r.fieldFrag.querySelector("[schema-form-array-items]");if(r.form.key){r.form.key.filter(function(e){return""===e}).length}if(t){var n=angular.copy(r.state);if(n.keyRedaction=0,n.keyRedaction+=r.form.key.length+1,r.form.schema&&r.form.schema.items&&r.form.schema.items.type&&r.form.schema.items.type.indexOf("object")===-1&&r.form.schema.items.type.indexOf("array")===-1){e.stringify(r.form.key).replace(/"/g,"&quot;")+"[$index]";n.modelValue="modelArray[$index]"}else n.modelName="item";n.arrayCompatFlag=!0;var a=r.build(r.form.items,r.path+".items",n);
+t.appendChild(a)}},numeric:function(e){var r=e.fieldFrag.querySelector("input"),t=e.form.maximum||!1,n=e.form.exclusiveMaximum||!1,a=e.form.minimum||!1,o=e.form.exclusiveMinimum||!1,i=e.form.multipleOf||!1;r&&(i!==!1&&r.setAttribute("step",i),t!==!1&&(n!==!1&&i!==!1&&(t-=i),r.setAttribute("max",t)),a!==!1&&(o!==!1&&i!==!1&&(a+=i),r.setAttribute("min",a)))}};this.builders=a;var o=[a.sfField,a.ngModel,a.ngModelOptions,a.condition];this.stdBuilders=o,this.$get=["$templateCache","schemaFormDecorators","sfPath",function(e,r,n){var i=function(e,r){if(e.key){var t=r[n.stringify(e.key)];if(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}}},l=function e(r,n,a,o,l,s,f){s=s||{},s=s||{},f=f||Object.create(null),l=l||"schemaForm.form";var c=document.createDocumentFragment();return r.reduce(function(r,c,d){if(!c.type)return r;var u=n[c.type]||n.default;if(u.replace){var m;s.arrayCompatFlag=!1;var p=document.createElement("div"),h=a(c,u)||a(c,n.default);for(p.innerHTML=h,m=document.createDocumentFragment();p.childNodes.length>0;)m.appendChild(p.childNodes[0]);var g={fieldFrag:m,form:c,lookup:f,state:s,path:l+"["+d+"]",build:function(r,t,i){return e(r,n,a,o,t,i,f)}},v=c.builder||u.builder;"function"==typeof v?v(g):v.forEach(function(e){e(g)}),(i(c,o)||r).appendChild(m)}else{var y=document.createElement(t(n.__name,"-"));s.arrayCompatFlag?y.setAttribute("form","copyWithIndex($index)"):y.setAttribute("form",l+"["+d+"]"),(i(c,o)||r).appendChild(y)}return r},c),c};return{build:function(r,t,n,a){return l(r,t,function(r,t){return"template"===r.type?r.template:e.get(t.template)},n,void 0,void 0,a)},builder:a,stdBuilders:o,internalBuild:l}}]}},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(){var e={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};e.number=e[105],e.required=e[302],e.min=e[101],e.max=e[103],e.maxlength=e[201],e.minlength=e[200],e.pattern=e[202],this.setDefaultMessages=function(r){e=r},this.getDefaultMessages=function(){return e},this.setDefaultMessage=function(r,t){e[r]=t},this.$get=["$interpolate",function(r){var t={};return t.defaultMessages=e,t.interpolate=function(t,n,o,i,l){l=l||{};var s=i.validationMessage||{};0===t.indexOf("tv4-")&&(t=t.substring(4));var f=s.default||l.default||"";[s,l,e].some(function(e){return a.a.isString(e)||a.a.isFunction(e)?(f=e,!0):e&&e[t]?(f=e[t],!0):void 0});var c={error:t,value:n,viewValue:o,form:i,schema:i.schema,title:i.title||i.schema&&i.schema.title};return a.a.isFunction(f)?f(c):r(f)(c)},t}]}},function(e,r,t){"use strict";function n(e,r){if(!(e instanceof r))throw new TypeError("Cannot call a class as a function")}var a=t(1),o=(t.n(a),t(0)),i=(t.n(o),function(){function e(e,r){for(var t=0;t<r.length;t++){var n=r[t];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(r,t,n){return t&&e(r.prototype,t),n&&e(r,n),r}}()),l=function(){function e(){n(this,e),this.name=a.sfPath.name,this.parse=a.sfPath.parse,this.stringify=a.sfPath.stringify,this.normalize=a.sfPath.normalize}return i(e,[{key:"$get",value:function(){return a.sfPath}}]),e}();r.a=l},function(e,r,t){t(1),e.exports=t(3)}])},,,function(e,r,t){t(18),e.exports=t(0)}]);
\ No newline at end of file
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index bb5fedb..04753c3 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.5
- * @date Sun, 01 Jan 2017 14:14:55 GMT
+ * @version 1.0.0-alpha.1
+ * @date Sat, 14 Jan 2017 17:11:45 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -228,39 +228,39 @@ module.exports = path;
 /***/ function(module, exports, __webpack_require__) {
 
 "use strict";
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html__ = __webpack_require__(16);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html__ = __webpack_require__(6);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html__ = __webpack_require__(2);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html__ = __webpack_require__(14);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html__ = __webpack_require__(15);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html__ = __webpack_require__(11);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html__ = __webpack_require__(1);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html__ = __webpack_require__(12);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html__ = __webpack_require__(3);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html__ = __webpack_require__(4);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html__ = __webpack_require__(13);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html__ = __webpack_require__(10);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html__ = __webpack_require__(9);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html__ = __webpack_require__(8);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html__ = __webpack_require__(7);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html__ = __webpack_require__(5);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html__);
-// angular-templatecache-loader
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html__ = __webpack_require__(1);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html__ = __webpack_require__(2);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html__ = __webpack_require__(3);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html__ = __webpack_require__(4);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html__ = __webpack_require__(5);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html__ = __webpack_require__(6);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html__ = __webpack_require__(7);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html__ = __webpack_require__(8);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html__ = __webpack_require__(10);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html__ = __webpack_require__(9);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html__ = __webpack_require__(11);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html__ = __webpack_require__(12);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html__ = __webpack_require__(13);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html__ = __webpack_require__(14);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html__ = __webpack_require__(15);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html__);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html__ = __webpack_require__(16);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html__);
+// ngtemplate-loader embeds the html on build
 
 
 
@@ -352,26 +352,26 @@ function bootstrapDecoratorConfig(
 
   var defaults = [sfField, ngModel, ngModelOptions, condition];
   decoratorsProvider.defineDecorator('bootstrapDecorator', {
-    actions: {template: __WEBPACK_IMPORTED_MODULE_6__bootstrap_actions_html___default.a, builder: defaults},
-    array: {template: __WEBPACK_IMPORTED_MODULE_2__bootstrap_array_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    button: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html___default.a, builder: defaults},
-    checkbox: {template: __WEBPACK_IMPORTED_MODULE_8__bootstrap_checkbox_html___default.a, builder: defaults},
-    checkboxes: {template: __WEBPACK_IMPORTED_MODULE_9__bootstrap_checkboxes_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    conditional: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
-    'default': {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default.a, builder: defaults},
-    fieldset: {template: __WEBPACK_IMPORTED_MODULE_1__bootstrap_fieldset_html___default.a, builder: [sfField, simpleTransclusion, condition]},
-    help: {template: __WEBPACK_IMPORTED_MODULE_14__bootstrap_help_html___default.a, builder: defaults},
-    number: {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default.a, builder: defaults.concat(numeric)},
-    password: {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_default_html___default.a, builder: defaults},
-    radios: {template: __WEBPACK_IMPORTED_MODULE_11__bootstrap_radios_html___default.a, builder: defaults},
-    'radios-inline': {template: __WEBPACK_IMPORTED_MODULE_12__bootstrap_radios_inline_html___default.a, builder: defaults},
-    radiobuttons: {template: __WEBPACK_IMPORTED_MODULE_13__bootstrap_radio_buttons_html___default.a, builder: defaults},
-    section: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
-    select: {template: __WEBPACK_IMPORTED_MODULE_7__bootstrap_select_html___default.a, builder: defaults.concat(selectPlaceholder)},
-    submit: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_submit_html___default.a, builder: defaults},
-    tabarray: {template: __WEBPACK_IMPORTED_MODULE_3__bootstrap_tabarray_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    tabs: {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_tabs_html___default.a, builder: [sfField, ngModelOptions, tabs, condition]},
-    textarea: {template: __WEBPACK_IMPORTED_MODULE_0__bootstrap_textarea_html___default.a, builder: defaults},
+    actions: {template: __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html___default.a, builder: defaults},
+    array: {template: __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    button: {template: __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html___default.a, builder: defaults},
+    checkbox: {template: __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html___default.a, builder: defaults},
+    checkboxes: {template: __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    conditional: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    'default': {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default.a, builder: defaults},
+    fieldset: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    help: {template: __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html___default.a, builder: defaults},
+    number: {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default.a, builder: defaults.concat(numeric)},
+    password: {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default.a, builder: defaults},
+    radios: {template: __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html___default.a, builder: defaults},
+    'radios-inline': {template: __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html___default.a, builder: defaults},
+    radiobuttons: {template: __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html___default.a, builder: defaults},
+    section: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    select: {template: __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html___default.a, builder: defaults.concat(selectPlaceholder)},
+    submit: {template: __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html___default.a, builder: defaults},
+    tabarray: {template: __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    tabs: {template: __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html___default.a, builder: [sfField, ngModelOptions, tabs, condition]},
+    textarea: {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html___default.a, builder: defaults},
   }, []);
 };
 
diff --git a/dist/angular-schema-form-bootstrap.min.js b/dist/angular-schema-form-bootstrap.min.js
index 796e330..4a05f9a 100644
--- a/dist/angular-schema-form-bootstrap.min.js
+++ b/dist/angular-schema-form-bootstrap.min.js
@@ -1,8 +1,9 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.1
+ * @date Sat, 14 Jan 2017 17:11:45 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
- * Copyright (c) 2016 JSON Schema Form
+ * Copyright (c) 2014-2017 JSON Schema Form
  */
-(function webpackUniversalModuleDefinition(root,factory){if(typeof exports==="object"&&typeof module==="object")module.exports=factory();else if(typeof define==="function"&&define.amd)define([],factory);else{var a=factory();for(var i in a)(typeof exports==="object"?exports:root)[i]=a[i]}})(this,function(){return function(modules){var installedModules={};function __webpack_require__(moduleId){if(installedModules[moduleId])return installedModules[moduleId].exports;var module=installedModules[moduleId]={exports:{},id:moduleId,loaded:false};modules[moduleId].call(module.exports,module,module.exports,__webpack_require__);module.loaded=true;return module.exports}__webpack_require__.m=modules;__webpack_require__.c=installedModules;__webpack_require__.p="";return __webpack_require__(0)}([function(module,exports,__webpack_require__){"use strict";__webpack_require__(1)},function(module,exports,__webpack_require__){"use strict";var textareaTemplate=__webpack_require__(17);var fieldsetTemplate=__webpack_require__(7);var arrayTemplate=__webpack_require__(3);var tabarrayTemplate=__webpack_require__(15);var tabsTemplate=__webpack_require__(16);var sectionTemplate=__webpack_require__(12);var actionsTemplate=__webpack_require__(2);var selectTemplate=__webpack_require__(13);var checkboxTemplate=__webpack_require__(4);var checkboxesTemplate=__webpack_require__(5);var submitTemplate=__webpack_require__(14);var radiosTemplate=__webpack_require__(11);var radiosInlineTemplate=__webpack_require__(10);var radiobuttonsTemplate=__webpack_require__(9);var helpTemplate=__webpack_require__(8);var defaultTemplate=__webpack_require__(6);angular.module("schemaForm").config(bootstrapDecoratorConfig).filter("sfCamelKey",sfCamelKeyFilter);bootstrapDecoratorConfig.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"];function bootstrapDecoratorConfig(schemaFormProvider,decoratorsProvider,sfBuilderProvider,sfPathProvider,$injector){var base="decorators/bootstrap/";var simpleTransclusion=sfBuilderProvider.builders.simpleTransclusion;var ngModelOptions=sfBuilderProvider.builders.ngModelOptions;var ngModel=sfBuilderProvider.builders.ngModel;var sfField=sfBuilderProvider.builders.sfField;var condition=sfBuilderProvider.builders.condition;var array=sfBuilderProvider.builders.array;var numeric=sfBuilderProvider.builders.numeric;var tabs=function tabs(args){if(args.form.tabs&&args.form.tabs.length>0){var tabContent=args.fieldFrag.querySelector(".tab-content");args.form.tabs.forEach(function(tab,index){var evalExpr="(evalExpr("+args.path+".tabs["+index+"]"+'.condition, { model: model, "arrayIndex": $index}))';var div=document.createElement("div");div.className="tab-pane";div.setAttribute("ng-disabled","form.readonly");div.setAttribute("ng-show","selected.tab === "+index);div.setAttribute("ng-class","{active: selected.tab === "+index+"}");if(!!tab.condition){div.setAttribute("ng-if",evalExpr)}var childFrag=args.build(tab.items,args.path+".tabs["+index+"].items",args.state);div.appendChild(childFrag);tabContent.appendChild(div)})}};var selectPlaceholder=function selectPlaceholder(args){if(args.form.placeholder){var selectBox=args.fieldFrag.querySelector("select");var option=document.createElement("option");option.setAttribute("value","");option.setAttribute("sf-field-model","replaceAll");if(angular.version.major===1&&angular.version.minor<4){option.setAttribute("ng-if","$$value$$ === undefined")}else{option.setAttribute("ng-show","$$value$$ === undefined")}option.textContent=args.form.placeholder;selectBox.appendChild(option)}};var defaults=[sfField,ngModel,ngModelOptions,condition];decoratorsProvider.defineDecorator("bootstrapDecorator",{actions:{template:actionsTemplate,builder:defaults},array:{template:arrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},button:{template:submitTemplate,builder:defaults},checkbox:{template:checkboxTemplate,builder:defaults},checkboxes:{template:checkboxesTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},conditional:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},default:{template:defaultTemplate,builder:defaults},fieldset:{template:fieldsetTemplate,builder:[sfField,simpleTransclusion,condition]},help:{template:helpTemplate,builder:defaults},number:{template:defaultTemplate,builder:defaults.concat(numeric)},password:{template:defaultTemplate,builder:defaults},radios:{template:radiosTemplate,builder:defaults},"radios-inline":{template:radiosInlineTemplate,builder:defaults},radiobuttons:{template:radiobuttonsTemplate,builder:defaults},section:{template:sectionTemplate,builder:[sfField,simpleTransclusion,condition]},select:{template:selectTemplate,builder:defaults.concat(selectPlaceholder)},submit:{template:submitTemplate,builder:defaults},tabarray:{template:tabarrayTemplate,builder:[sfField,ngModelOptions,ngModel,array,condition]},tabs:{template:tabsTemplate,builder:[sfField,ngModelOptions,tabs,condition]},textarea:{template:textareaTemplate,builder:defaults}},[])}function sfCamelKeyFilter(){return function(formKey){if(!formKey){return""}var part,i,key;key=formKey.slice();for(i=0;i<key.length;i++){part=key[i].toLowerCase().split("");if(i&&part.length){part[0]=part[0].toUpperCase()}key[i]=part.join("")}return key.join("")}}},function(module,exports){var path="bootstrap/actions.html";var html='<div class="btn-group schema-form-actions {{::form.htmlClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/array.html";var html='<div  class="schema-form-array {{::form.htmlClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkbox.html";var html='<div class="checkbox schema-form-checkbox {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{form.key.slice(-1)[0]}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/checkboxes.html";var html='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{form.key.slice(-1)[0]}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/default.html";var html='<div class="form-group {{::form.htmlClass}}"\r\n     ng-class="{ \'{{\'schema-form-\' + form.type}}\': true, \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{form.key.slice(-1)[0]}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{form.key.slice(-1)[0]}}"\r\n         aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{form.key.slice(-1)[0]}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{form.key.slice(-1)[0]}}"\r\n           aria-describedby="{{form.key.slice(-1)[0] + \'Status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{form.key.slice(-1)[0] + \'Status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/fieldset.html";var html='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/help.html";var html='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radio-buttons.html";var html='<div class="form-group schema-form-radiobuttons {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios-inline.html";var html='<div class="form-group schema-form-radios-inline {{::form.htmlClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/radios.html";var html='<div class="form-group schema-form-radios {{::form.htmlClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/section.html";var html='<div class="schema-form-section {{::form.htmlClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/select.html";var html='<div class="form-group {{::form.htmlClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{form.key.slice(-1)[0]}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/submit.html";var html='<div class="form-group schema-form-submit {{::form.htmlClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabarray.html";var html='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/tabs.html";var html='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path},function(module,exports){var path="bootstrap/textarea.html";var html='<div class="form-group has-feedback {{::form.htmlClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{form.key.slice(-1)[0]}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{form.key.slice(-1)[0]}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{form.key.slice(-1)[0]}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{form.key.slice(-1)[0]}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(c){c.put(path,html)}]);module.exports=path}])});
\ No newline at end of file
+!function(e){function r(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return e[a].call(l.exports,l,l.exports,r),l.l=!0,l.exports}var n={};return r.m=e,r.c=n,r.i=function(e){return e},r.d=function(e,r,n){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=22)}([function(e,r,n){n(17)},function(e,r){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r,n){"use strict";function a(e,r,n,a,l){var t=n.builders.simpleTransclusion,o=n.builders.ngModelOptions,d=n.builders.ngModel,f=n.builders.sfField,u=n.builders.condition,b=n.builders.array,g=n.builders.numeric,y=function(e){if(e.form.tabs&&e.form.tabs.length>0){var r=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(n,a){var l="(evalExpr("+e.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=e.build(n.items,e.path+".tabs["+a+"].items",e.state);t.appendChild(s),r.appendChild(t)})}},$=function(e){if(e.form.placeholder){var r=e.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=e.form.placeholder,r.appendChild(n)}},w=[f,d,o,u];r.defineDecorator("bootstrapDecorator",{actions:{template:s.a,builder:w},array:{template:i.a,builder:[f,o,d,b,u]},button:{template:T.a,builder:w},checkbox:{template:m.a,builder:w},checkboxes:{template:c.a,builder:[f,o,d,b,u]},conditional:{template:S.a,builder:[f,t,u]},default:{template:p.a,builder:w},fieldset:{template:h.a,builder:[f,t,u]},help:{template:v.a,builder:w},number:{template:p.a,builder:w.concat(g)},password:{template:p.a,builder:w},radios:{template:C.a,builder:w},"radios-inline":{template:k.a,builder:w},radiobuttons:{template:x.a,builder:w},section:{template:S.a,builder:[f,t,u]},select:{template:I.a,builder:w.concat($)},submit:{template:T.a,builder:w},tabarray:{template:j.a,builder:[f,o,d,b,u]},tabs:{template:R.a,builder:[f,o,y,u]},textarea:{template:F.a,builder:w}},[])}function l(){return function(e){if(!e)return"";var r,n,a;for(a=e.slice(),n=0;n<a.length;n++)r=a[n].toLowerCase().split(""),n&&r.length&&(r[0]=r[0].toUpperCase()),a[n]=r.join("");return a.join("")}}var t=n(1),s=n.n(t),o=n(2),i=n.n(o),d=n(3),m=n.n(d),f=n(4),c=n.n(f),u=n(5),p=n.n(u),b=n(6),h=n.n(b),g=n(7),v=n.n(g),y=n(8),x=n.n(y),$=n(10),C=n.n($),w=n(9),k=n.n(w),A=n(11),S=n.n(A),E=n(12),I=n.n(E),H=n(13),T=n.n(H),M=n(14),j=n.n(M),L=n(15),R=n.n(L),D=n(16),F=n.n(D);angular.module("schemaForm").config(a).filter("sfCamelKey",l),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,function(e,r,n){e.exports=n(0)}]);
\ No newline at end of file
diff --git a/package.json b/package.json
index eb95dac..5e3cd66 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
 {
   "name": "angular-schema-form-bootstrap",
-  "version": "1.0.0-alpha.5",
+  "version": "1.0.0-alpha.1",
   "description": "Bootstrap 3 decorator for Angular Schema Form",
   "main": "dist/bootstrap-decorator.js",
   "scripts": {
@@ -35,7 +35,7 @@
     "coveralls": "^2.11.0",
     "html": "^1.0.0",
     "html-loader": "^0.4.4",
-    "html-webpack-plugin": "^2.22.0",
+    "html-webpack-plugin": "^2.25.0",
     "karma": "^0.13.22",
     "karma-chai-sinon": "^0.1.5",
     "karma-coverage": "^1.0.0",
@@ -45,7 +45,6 @@
     "karma-webpack": "^1.7.0",
     "mocha": "^2.5.3",
     "mocha-lcov-reporter": "0.0.1",
-    "ng-cache-loader": "0.0.16",
     "ngtemplate-loader": "^1.3.1",
     "protractor": "^2.5.1",
     "sinon": "^1.17.4",
diff --git a/src/bootstrap-decorator.js b/src/bootstrap-decorator.js
index fb75a1a..3d9198a 100644
--- a/src/bootstrap-decorator.js
+++ b/src/bootstrap-decorator.js
@@ -1,20 +1,20 @@
-// angular-templatecache-loader
-import textareaTemplate from './bootstrap/textarea.html';
-import fieldsetTemplate from './bootstrap/fieldset.html';
-import arrayTemplate from './bootstrap/array.html';
-import tabarrayTemplate from './bootstrap/tabarray.html';
-import tabsTemplate from './bootstrap/tabs.html';
-import sectionTemplate from './bootstrap/section.html';
+// ngtemplate-loader embeds the html on build
 import actionsTemplate from './bootstrap/actions.html';
-import selectTemplate from './bootstrap/select.html';
+import arrayTemplate from './bootstrap/array.html';
 import checkboxTemplate from './bootstrap/checkbox.html';
 import checkboxesTemplate from './bootstrap/checkboxes.html';
-import submitTemplate from './bootstrap/submit.html';
+import defaultTemplate from './bootstrap/default.html';
+import fieldsetTemplate from './bootstrap/fieldset.html';
+import helpTemplate from './bootstrap/help.html';
+import radiobuttonsTemplate from './bootstrap/radio-buttons.html';
 import radiosTemplate from './bootstrap/radios.html';
 import radiosInlineTemplate from './bootstrap/radios-inline.html';
-import radiobuttonsTemplate from './bootstrap/radio-buttons.html';
-import helpTemplate from './bootstrap/help.html';
-import defaultTemplate from './bootstrap/default.html';
+import sectionTemplate from './bootstrap/section.html';
+import selectTemplate from './bootstrap/select.html';
+import submitTemplate from './bootstrap/submit.html';
+import tabarrayTemplate from './bootstrap/tabarray.html';
+import tabsTemplate from './bootstrap/tabs.html';
+import textareaTemplate from './bootstrap/textarea.html';
 
 angular
   .module('schemaForm')

From a54827fd734738bd15b9c2f295ddd8d35d95eb2a Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Tue, 24 Jan 2017 01:27:54 +1100
Subject: [PATCH 35/50] Update README

---
 README.md | 9 ++++-----
 1 file changed, 4 insertions(+), 5 deletions(-)

diff --git a/README.md b/README.md
index 182291c..224872f 100644
--- a/README.md
+++ b/README.md
@@ -1,13 +1,13 @@
 Angular Bootstrap Decorator
 ==========================
 
-For https://github.com/Textalk/angular-schema-form
+For https://github.com/json-schema-form/angular-schema-form
 
 This is the new Bootstrap Decorator! That means a Bootstrap 3 frontend for the Angular Schema Form
 project. The former Bootstrap decorator used to be included in the main repo, but has now moved
 here.
 
-The big difference is that it now uses the new builder in, for more info on the builder see
+The big difference is that it now uses new builder methods, for more info on the builder see
 [our blog](https://medium.com/@SchemaFormIO/the-new-builder-pt-1-61fadde3c678).
 
 The biggest change for users is that the form no longer contains any `<bootstrap-decorator>` tags
@@ -19,13 +19,12 @@ Install
 bower install angular-schema-form-bootstrap
 ```
 or
-
 ```sh
 npm install angular-schema-form-bootstrap
 ```
-And then include `angular-schema-form-bootstrap-bundled.min.js`. Note that angular-schema-form >= 1.0.0-alpha.1 is needed.
+And then include `angular-schema-form-bootstrap-bundled.min.js`. **Note that angular-schema-form >= 1.0.0-alpha.1 is needed**.
 
-You **DO NOT** need to include angular-schema-form with this version, it is now embedded within the above file. If you wish to include the files separately you can still use `angular-schema-form-bootstrap.min.js`
+You **DO NOT** need to include angular-schema-form with this version, it is now **embedded** within the above file. If you wish to include the files separately you can still use `angular-schema-form-bootstrap.min.js`
 
 Future
 ------

From cdafe112238b1973a973cb4771c281120600c866 Mon Sep 17 00:00:00 2001
From: Marcel J Bennett <iamanthropic@gmail.com>
Date: Tue, 21 Feb 2017 22:12:35 +1100
Subject: [PATCH 36/50] Update bower.json

---
 bower.json | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/bower.json b/bower.json
index ba87f10..276489f 100644
--- a/bower.json
+++ b/bower.json
@@ -23,7 +23,7 @@
     "tests"
   ],
   "dependencies": {
-    "angular-schema-form": ">=0.8.13"
+    "angular-schema-form": "1.0.0-alpha.2"
   },
   "devDependencies": {
     "angular-ui-ace": "bower",

From 74081702e424bb04b165a477251f9cffe301df98 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Tue, 21 Feb 2017 22:27:20 +1100
Subject: [PATCH 37/50] Remove key generator as that's in ASF now

---
 dist/angular-schema-form-bootstrap-bundled.js | 82 ++++++++-----------
 dist/angular-schema-form-bootstrap.js         | 22 +----
 src/bootstrap-decorator.js                    | 20 +----
 3 files changed, 38 insertions(+), 86 deletions(-)

diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index 4a5e9e9..2f3babe 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.1
- * @date Sat, 14 Jan 2017 17:11:45 GMT
+ * @date Sun, 29 Jan 2017 00:45:28 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -280,8 +280,7 @@ module.exports = path;
 
 angular
   .module('schemaForm')
-  .config(bootstrapDecoratorConfig)
-  .filter('sfCamelKey', sfCamelKeyFilter);
+  .config(bootstrapDecoratorConfig);
 
 bootstrapDecoratorConfig.$inject = [
   'schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'
@@ -375,23 +374,6 @@ function bootstrapDecoratorConfig(
   }, []);
 };
 
-/**
- * sfCamelKey Filter
- */
-function sfCamelKeyFilter() {
-  return function(formKey) {
-    if (!formKey) { return ''; };
-    var part, i, key;
-    key = formKey.slice();
-    for (i = 0; i < key.length; i++) {
-      part = key[i].toLowerCase().split('');
-      if (i && part.length) { part[0] = part[0].toUpperCase(); };
-      key[i] = part.join('');
-    };
-    return key.join('');
-  };
-};
-
 
 /***/ },
 /* 18 */
@@ -400,7 +382,7 @@ function sfCamelKeyFilter() {
 /*!
  * angular-schema-form
  * @version 1.0.0-alpha.1
- * @date Sat, 14 Jan 2017 17:09:44 GMT
+ * @date Mon, 23 Jan 2017 13:42:17 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -484,7 +466,7 @@ module.exports = angular;
 /*!
  * json-schema-form-core
  * @version 1.0.0-alpha.1
- * @date Sat, 14 Jan 2017 17:07:51 GMT
+ * @date Mon, 16 Jan 2017 13:06:10 GMT
  * @link https://github.com/json-schema-form/json-schema-form-core
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -954,21 +936,21 @@ function defaultForm(schema, defaultSchemaTypes, ignore, globalOptions) {
 /***/ function(module, exports, __webpack_require__) {
 
 "use strict";
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__schema_defaults__ = __webpack_require__(3);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__sf_path__ = __webpack_require__(0);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__canonical_title_map__ = __webpack_require__(1);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__merge__ = __webpack_require__(5);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__select__ = __webpack_require__(6);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__traverse__ = __webpack_require__(7);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__validate__ = __webpack_require__(8);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__lib_schema_defaults__ = __webpack_require__(3);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__lib_sf_path__ = __webpack_require__(0);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__lib_canonical_title_map__ = __webpack_require__(1);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__lib_merge__ = __webpack_require__(5);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__lib_select__ = __webpack_require__(6);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__lib_traverse__ = __webpack_require__(7);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__lib_validate__ = __webpack_require__(8);
 /* harmony export (binding) */ __webpack_require__.d(exports, "sfPath", function() { return sfPath; });
 /* harmony export (binding) */ __webpack_require__.d(exports, "schemaDefaults", function() { return schemaDefaults; });
 /* harmony export (binding) */ __webpack_require__.d(exports, "canonicalTitleMap", function() { return canonicalTitleMap; });
-/* harmony reexport (binding) */ __webpack_require__.d(exports, "merge", function() { return __WEBPACK_IMPORTED_MODULE_3__merge__["a"]; });
-/* harmony reexport (binding) */ __webpack_require__.d(exports, "select", function() { return __WEBPACK_IMPORTED_MODULE_4__select__["a"]; });
-/* harmony reexport (binding) */ __webpack_require__.d(exports, "traverseSchema", function() { return __WEBPACK_IMPORTED_MODULE_5__traverse__["a"]; });
-/* harmony reexport (binding) */ __webpack_require__.d(exports, "traverseForm", function() { return __WEBPACK_IMPORTED_MODULE_5__traverse__["b"]; });
-/* harmony reexport (binding) */ __webpack_require__.d(exports, "validate", function() { return __WEBPACK_IMPORTED_MODULE_6__validate__["a"]; });
+/* harmony reexport (binding) */ __webpack_require__.d(exports, "merge", function() { return __WEBPACK_IMPORTED_MODULE_3__lib_merge__["a"]; });
+/* harmony reexport (binding) */ __webpack_require__.d(exports, "select", function() { return __WEBPACK_IMPORTED_MODULE_4__lib_select__["a"]; });
+/* harmony reexport (binding) */ __webpack_require__.d(exports, "traverseSchema", function() { return __WEBPACK_IMPORTED_MODULE_5__lib_traverse__["a"]; });
+/* harmony reexport (binding) */ __webpack_require__.d(exports, "traverseForm", function() { return __WEBPACK_IMPORTED_MODULE_5__lib_traverse__["b"]; });
+/* harmony reexport (binding) */ __webpack_require__.d(exports, "validate", function() { return __WEBPACK_IMPORTED_MODULE_6__lib_validate__["a"]; });
 
 
 
@@ -978,9 +960,9 @@ function defaultForm(schema, defaultSchemaTypes, ignore, globalOptions) {
 
 
 
-var sfPath = __WEBPACK_IMPORTED_MODULE_1__sf_path__;
-var schemaDefaults = __WEBPACK_IMPORTED_MODULE_0__schema_defaults__;
-var canonicalTitleMap = __WEBPACK_IMPORTED_MODULE_2__canonical_title_map__["a" /* default */];
+var sfPath = __WEBPACK_IMPORTED_MODULE_1__lib_sf_path__;
+var schemaDefaults = __WEBPACK_IMPORTED_MODULE_0__lib_schema_defaults__;
+var canonicalTitleMap = __WEBPACK_IMPORTED_MODULE_2__lib_canonical_title_map__["a" /* default */];
 
 /***/ },
 /* 5 */
@@ -1128,6 +1110,7 @@ function select(projection, obj, valueToSet) {
   if (typeof valueToSet !== 'undefined' && parts.length === 1) {
     // special case, just setting one variable
     obj[parts[0]] = valueToSet;
+
     return obj;
   };
 
@@ -1137,12 +1120,14 @@ function select(projection, obj, valueToSet) {
   };
 
   var value = obj[parts[0]];
+
   for (var i = 1; i < parts.length; i++) {
     // Special case: We allow JSON Form syntax for arrays using empty brackets
     // These will of course not work here so we exit if they are found.
     if (parts[i] === '') {
       return undefined;
-    }
+    };
+
     if (typeof valueToSet !== 'undefined') {
       if (i === parts.length - 1) {
         // last step. Let's set the value
@@ -1152,19 +1137,22 @@ function select(projection, obj, valueToSet) {
         // Make sure to create new objects on the way if they are not there.
         // We need to look ahead to check if array is appropriate
         var tmp = value[parts[i]];
+
         if (typeof tmp === 'undefined' || tmp === null) {
           tmp = numRe.test(parts[i + 1]) ? [] : {};
           value[parts[i]] = tmp;
-        }
+        };
+
         value = tmp;
-      }
+      };
     } else if (value) {
       // Just get nex value.
       value = value[parts[i]];
-    }
-  }
+    };
+  };
+
   return value;
-}
+};
 
 /***/ },
 /* 7 */
@@ -1521,7 +1509,6 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
       // Validate against the schema.
 
       var validate = function validate(viewValue) {
-        //console.log('validate called', viewValue)
         //Still might be undefined
         if (!form) {
           return viewValue;
@@ -1602,9 +1589,10 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 
       // A bit ugly but useful.
       scope.validateField = function (formName) {
+        var noField = formName === undefined;
         // If we have specified a form name, and this model is not within
         // that form, then leave things be.
-        if (formName != undefined && ngModel.$$parentForm.$name !== formName) {
+        if (!noField && ngModel.$$parentForm.$name !== formName) {
           return;
         }
 
@@ -1613,9 +1601,9 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
         // Just setting the viewValue isn't enough to trigger validation
         // since it's the same value. This will be better when we drop
         // 1.2 support.
-        if (schema && schema.type.indexOf('array') !== -1) {
+        if (noField || schema && schema.type.indexOf('array') !== -1) {
           validate(ngModel.$modelValue);
-        }
+        };
 
         // We set the viewValue to trigger parsers,
         // since modelValue might be empty and validating just that
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index 04753c3..e174e31 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.1
- * @date Sat, 14 Jan 2017 17:11:45 GMT
+ * @date Sun, 29 Jan 2017 00:45:28 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -280,8 +280,7 @@ module.exports = path;
 
 angular
   .module('schemaForm')
-  .config(bootstrapDecoratorConfig)
-  .filter('sfCamelKey', sfCamelKeyFilter);
+  .config(bootstrapDecoratorConfig);
 
 bootstrapDecoratorConfig.$inject = [
   'schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'
@@ -375,23 +374,6 @@ function bootstrapDecoratorConfig(
   }, []);
 };
 
-/**
- * sfCamelKey Filter
- */
-function sfCamelKeyFilter() {
-  return function(formKey) {
-    if (!formKey) { return ''; };
-    var part, i, key;
-    key = formKey.slice();
-    for (i = 0; i < key.length; i++) {
-      part = key[i].toLowerCase().split('');
-      if (i && part.length) { part[0] = part[0].toUpperCase(); };
-      key[i] = part.join('');
-    };
-    return key.join('');
-  };
-};
-
 
 /***/ },
 /* 18 */,
diff --git a/src/bootstrap-decorator.js b/src/bootstrap-decorator.js
index 3d9198a..ba94cc2 100644
--- a/src/bootstrap-decorator.js
+++ b/src/bootstrap-decorator.js
@@ -18,8 +18,7 @@ import textareaTemplate from './bootstrap/textarea.html';
 
 angular
   .module('schemaForm')
-  .config(bootstrapDecoratorConfig)
-  .filter('sfCamelKey', sfCamelKeyFilter);
+  .config(bootstrapDecoratorConfig);
 
 bootstrapDecoratorConfig.$inject = [
   'schemaFormProvider', 'schemaFormDecoratorsProvider', 'sfBuilderProvider', 'sfPathProvider', '$injector'
@@ -112,20 +111,3 @@ function bootstrapDecoratorConfig(
     textarea: {template: textareaTemplate, builder: defaults},
   }, []);
 };
-
-/**
- * sfCamelKey Filter
- */
-function sfCamelKeyFilter() {
-  return function(formKey) {
-    if (!formKey) { return ''; };
-    var part, i, key;
-    key = formKey.slice();
-    for (i = 0; i < key.length; i++) {
-      part = key[i].toLowerCase().split('');
-      if (i && part.length) { part[0] = part[0].toUpperCase(); };
-      key[i] = part.join('');
-    };
-    return key.join('');
-  };
-};

From 46d1ab61e9ab52983e41cceed781950cb0c2cced Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Tue, 21 Feb 2017 22:40:49 +1100
Subject: [PATCH 38/50] reapply rename

---
 src/textarea.html | 33 ---------------------------------
 1 file changed, 33 deletions(-)
 delete mode 100644 src/textarea.html

diff --git a/src/textarea.html b/src/textarea.html
deleted file mode 100644
index 29176c3..0000000
--- a/src/textarea.html
+++ /dev/null
@@ -1,33 +0,0 @@
-<div class="form-group has-feedback {{form.htmlClass}} schema-form-textarea" ng-class="{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
-  <label class="control-label {{form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{form.key.slice(-1)[0]}}">{{form.title}}</label>
-
-  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"
-            class="form-control {{form.fieldHtmlClass}}"
-            id="{{form.key.slice(-1)[0]}}"
-            sf-changed="form"
-            ng-attr-placeholder="{{form.placeholder}}"
-            ng-disabled="form.readonly"
-            sf-field-model
-            schema-validate="form"
-            name="{{form.key.slice(-1)[0]}}"></textarea>
-
-  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"
-       ng-class="{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}">
-    <span ng-if="form.fieldAddonLeft"
-          class="input-group-addon"
-          ng-bind-html="form.fieldAddonLeft"></span>
-    <textarea class="form-control {{form.fieldHtmlClass}}"
-              id="{{form.key.slice(-1)[0]}}"
-              sf-changed="form"
-              ng-attr-placeholder="{{form.placeholder}}"
-              ng-disabled="form.readonly"
-              sf-field-model
-              schema-validate="form"
-              name="{{form.key.slice(-1)[0]}}"></textarea>
-    <span ng-if="form.fieldAddonRight"
-          class="input-group-addon"
-          ng-bind-html="form.fieldAddonRight"></span>
-  </div>
-
-  <span class="help-block" sf-message="form.description"></span>
-</div>

From af4eb637c83b3f4fe448afc836e7e2851aa58770 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Tue, 21 Feb 2017 22:45:54 +1100
Subject: [PATCH 39/50] Latest build

---
 dist/angular-schema-form-bootstrap-bundled.js | 2879 +++++++++++++++--
 ...gular-schema-form-bootstrap-bundled.min.js |   31 +-
 dist/angular-schema-form-bootstrap.js         |   78 +-
 dist/angular-schema-form-bootstrap.min.js     |    4 +-
 4 files changed, 2732 insertions(+), 260 deletions(-)

diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index 2f3babe..dc57104 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.1
- * @date Sun, 29 Jan 2017 00:45:28 GMT
+ * @date Tue, 21 Feb 2017 11:44:44 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -69,18 +69,100 @@
 /******/ 	__webpack_require__.p = "";
 
 /******/ 	// Load entry module and return exports
-/******/ 	return __webpack_require__(__webpack_require__.s = 20);
+/******/ 	return __webpack_require__(__webpack_require__.s = 22);
 /******/ })
 /************************************************************************/
 /******/ ([
 /* 0 */
 /***/ function(module, exports, __webpack_require__) {
 
-__webpack_require__(17);
+__webpack_require__(18);
 
 
 /***/ },
 /* 1 */
+/***/ function(module, exports, __webpack_require__) {
+
+/* WEBPACK VAR INJECTION */(function(setImmediate, clearImmediate) {var nextTick = __webpack_require__(20).nextTick;
+var apply = Function.prototype.apply;
+var slice = Array.prototype.slice;
+var immediateIds = {};
+var nextImmediateId = 0;
+
+// DOM APIs, for completeness
+
+exports.setTimeout = function() {
+  return new Timeout(apply.call(setTimeout, window, arguments), clearTimeout);
+};
+exports.setInterval = function() {
+  return new Timeout(apply.call(setInterval, window, arguments), clearInterval);
+};
+exports.clearTimeout =
+exports.clearInterval = function(timeout) { timeout.close(); };
+
+function Timeout(id, clearFn) {
+  this._id = id;
+  this._clearFn = clearFn;
+}
+Timeout.prototype.unref = Timeout.prototype.ref = function() {};
+Timeout.prototype.close = function() {
+  this._clearFn.call(window, this._id);
+};
+
+// Does not start the time, just sets up the members needed.
+exports.enroll = function(item, msecs) {
+  clearTimeout(item._idleTimeoutId);
+  item._idleTimeout = msecs;
+};
+
+exports.unenroll = function(item) {
+  clearTimeout(item._idleTimeoutId);
+  item._idleTimeout = -1;
+};
+
+exports._unrefActive = exports.active = function(item) {
+  clearTimeout(item._idleTimeoutId);
+
+  var msecs = item._idleTimeout;
+  if (msecs >= 0) {
+    item._idleTimeoutId = setTimeout(function onTimeout() {
+      if (item._onTimeout)
+        item._onTimeout();
+    }, msecs);
+  }
+};
+
+// That's not how node.js implements it but the exposed api is the same.
+exports.setImmediate = typeof setImmediate === "function" ? setImmediate : function(fn) {
+  var id = nextImmediateId++;
+  var args = arguments.length < 2 ? false : slice.call(arguments, 1);
+
+  immediateIds[id] = true;
+
+  nextTick(function onNextTick() {
+    if (immediateIds[id]) {
+      // fn.call() is faster so we optimize for the common use-case
+      // @see http://jsperf.com/call-apply-segu
+      if (args) {
+        fn.apply(null, args);
+      } else {
+        fn.call(null);
+      }
+      // Prevent ids from leaking
+      exports.clearImmediate(id);
+    }
+  });
+
+  return id;
+};
+
+exports.clearImmediate = typeof clearImmediate === "function" ? clearImmediate : function(id) {
+  delete immediateIds[id];
+};
+/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).setImmediate, __webpack_require__(1).clearImmediate))
+
+/***/ },
+/* 2 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/actions.html';
@@ -89,7 +171,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 2 */
+/* 3 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/array.html';
@@ -98,7 +180,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 3 */
+/* 4 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/checkbox.html';
@@ -107,7 +189,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 4 */
+/* 5 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/checkboxes.html';
@@ -116,7 +198,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 5 */
+/* 6 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/default.html';
@@ -125,7 +207,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 6 */
+/* 7 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/fieldset.html';
@@ -134,7 +216,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 7 */
+/* 8 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/help.html';
@@ -143,7 +225,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 8 */
+/* 9 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/radio-buttons.html';
@@ -152,7 +234,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 9 */
+/* 10 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/radios-inline.html';
@@ -161,7 +243,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 10 */
+/* 11 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/radios.html';
@@ -170,7 +252,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 11 */
+/* 12 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/section.html';
@@ -179,7 +261,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 12 */
+/* 13 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/select.html';
@@ -188,7 +270,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 13 */
+/* 14 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/submit.html';
@@ -197,7 +279,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 14 */
+/* 15 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/tabarray.html';
@@ -206,7 +288,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 15 */
+/* 16 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/tabs.html';
@@ -215,7 +297,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 16 */
+/* 17 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/textarea.html';
@@ -224,41 +306,41 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 17 */
+/* 18 */
 /***/ function(module, exports, __webpack_require__) {
 
 "use strict";
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html__ = __webpack_require__(1);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html__ = __webpack_require__(2);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html__ = __webpack_require__(2);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html__ = __webpack_require__(3);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html__ = __webpack_require__(3);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html__ = __webpack_require__(4);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html__ = __webpack_require__(4);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html__ = __webpack_require__(5);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html__ = __webpack_require__(5);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html__ = __webpack_require__(6);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html__ = __webpack_require__(6);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html__ = __webpack_require__(7);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html__ = __webpack_require__(7);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html__ = __webpack_require__(8);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html__ = __webpack_require__(8);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html__ = __webpack_require__(9);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html__ = __webpack_require__(10);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html__ = __webpack_require__(11);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html__ = __webpack_require__(9);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html__ = __webpack_require__(10);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html__ = __webpack_require__(11);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html__ = __webpack_require__(12);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html__ = __webpack_require__(12);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html__ = __webpack_require__(13);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html__ = __webpack_require__(13);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html__ = __webpack_require__(14);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html__ = __webpack_require__(14);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html__ = __webpack_require__(15);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html__ = __webpack_require__(15);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html__ = __webpack_require__(16);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html__ = __webpack_require__(16);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html__ = __webpack_require__(17);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html__);
 // ngtemplate-loader embeds the html on build
 
@@ -376,13 +458,13 @@ function bootstrapDecoratorConfig(
 
 
 /***/ },
-/* 18 */
-/***/ function(module, exports) {
+/* 19 */
+/***/ function(module, exports, __webpack_require__) {
 
-/*!
+/* WEBPACK VAR INJECTION */(function(setImmediate, clearImmediate) {/*!
  * angular-schema-form
- * @version 1.0.0-alpha.1
- * @date Mon, 23 Jan 2017 13:42:17 GMT
+ * @version 1.0.0-alpha.2
+ * @date Sun, 19 Feb 2017 13:13:18 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -422,16 +504,18 @@ function bootstrapDecoratorConfig(
 /******/ 	// expose the module cache
 /******/ 	__webpack_require__.c = installedModules;
 
-/******/ 	// identity function for calling harmory imports with the correct context
+/******/ 	// identity function for calling harmony imports with the correct context
 /******/ 	__webpack_require__.i = function(value) { return value; };
 
-/******/ 	// define getter function for harmory exports
+/******/ 	// define getter function for harmony exports
 /******/ 	__webpack_require__.d = function(exports, name, getter) {
-/******/ 		Object.defineProperty(exports, name, {
-/******/ 			configurable: false,
-/******/ 			enumerable: true,
-/******/ 			get: getter
-/******/ 		});
+/******/ 		if(!__webpack_require__.o(exports, name)) {
+/******/ 			Object.defineProperty(exports, name, {
+/******/ 				configurable: false,
+/******/ 				enumerable: true,
+/******/ 				get: getter
+/******/ 			});
+/******/ 		}
 /******/ 	};
 
 /******/ 	// getDefaultExport function for compatibility with non-harmony modules
@@ -450,23 +534,23 @@ function bootstrapDecoratorConfig(
 /******/ 	__webpack_require__.p = "";
 
 /******/ 	// Load entry module and return exports
-/******/ 	return __webpack_require__(__webpack_require__.s = 16);
+/******/ 	return __webpack_require__(__webpack_require__.s = 21);
 /******/ })
 /************************************************************************/
 /******/ ([
 /* 0 */
-/***/ function(module, exports) {
+/***/ (function(module, exports) {
 
 module.exports = angular;
 
-/***/ },
+/***/ }),
 /* 1 */
-/***/ function(module, exports) {
+/***/ (function(module, exports, __webpack_require__) {
 
-/*!
+/* WEBPACK VAR INJECTION */(function(global, setImmediate) {/*!
  * json-schema-form-core
- * @version 1.0.0-alpha.1
- * @date Mon, 16 Jan 2017 13:06:10 GMT
+ * @version 1.0.0-alpha.2
+ * @date Sun, 19 Feb 2017 13:06:51 GMT
  * @link https://github.com/json-schema-form/json-schema-form-core
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -507,16 +591,18 @@ module.exports =
 /******/ 	// expose the module cache
 /******/ 	__webpack_require__.c = installedModules;
 /******/
-/******/ 	// identity function for calling harmory imports with the correct context
+/******/ 	// identity function for calling harmony imports with the correct context
 /******/ 	__webpack_require__.i = function(value) { return value; };
 /******/
-/******/ 	// define getter function for harmory exports
+/******/ 	// define getter function for harmony exports
 /******/ 	__webpack_require__.d = function(exports, name, getter) {
-/******/ 		Object.defineProperty(exports, name, {
-/******/ 			configurable: false,
-/******/ 			enumerable: true,
-/******/ 			get: getter
-/******/ 		});
+/******/ 		if(!__webpack_require__.o(exports, name)) {
+/******/ 			Object.defineProperty(exports, name, {
+/******/ 				configurable: false,
+/******/ 				enumerable: true,
+/******/ 				get: getter
+/******/ 			});
+/******/ 		}
 /******/ 	};
 /******/
 /******/ 	// getDefaultExport function for compatibility with non-harmony modules
@@ -535,20 +621,21 @@ module.exports =
 /******/ 	__webpack_require__.p = "";
 /******/
 /******/ 	// Load entry module and return exports
-/******/ 	return __webpack_require__(__webpack_require__.s = 11);
+/******/ 	return __webpack_require__(__webpack_require__.s = 13);
 /******/ })
 /************************************************************************/
 /******/ ([
 /* 0 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
+Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_objectpath__ = __webpack_require__(2);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_objectpath___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_objectpath__);
-/* harmony export (immutable) */ exports["name"] = name;
-/* harmony reexport (binding) */ if(__webpack_require__.o(__WEBPACK_IMPORTED_MODULE_0_objectpath__, "parse")) __webpack_require__.d(exports, "parse", function() { return __WEBPACK_IMPORTED_MODULE_0_objectpath__["parse"]; });
-/* harmony reexport (binding) */ if(__webpack_require__.o(__WEBPACK_IMPORTED_MODULE_0_objectpath__, "stringify")) __webpack_require__.d(exports, "stringify", function() { return __WEBPACK_IMPORTED_MODULE_0_objectpath__["stringify"]; });
-/* harmony reexport (binding) */ if(__webpack_require__.o(__WEBPACK_IMPORTED_MODULE_0_objectpath__, "normalize")) __webpack_require__.d(exports, "normalize", function() { return __WEBPACK_IMPORTED_MODULE_0_objectpath__["normalize"]; });
+/* harmony reexport (binding) */ if(__webpack_require__.o(__WEBPACK_IMPORTED_MODULE_0_objectpath__, "parse")) __webpack_require__.d(__webpack_exports__, "parse", function() { return __WEBPACK_IMPORTED_MODULE_0_objectpath__["parse"]; });
+/* harmony reexport (binding) */ if(__webpack_require__.o(__WEBPACK_IMPORTED_MODULE_0_objectpath__, "stringify")) __webpack_require__.d(__webpack_exports__, "stringify", function() { return __WEBPACK_IMPORTED_MODULE_0_objectpath__["stringify"]; });
+/* harmony reexport (binding) */ if(__webpack_require__.o(__WEBPACK_IMPORTED_MODULE_0_objectpath__, "normalize")) __webpack_require__.d(__webpack_exports__, "normalize", function() { return __WEBPACK_IMPORTED_MODULE_0_objectpath__["normalize"]; });
+/* harmony export (immutable) */ __webpack_exports__["name"] = name;
 
 
 
@@ -583,15 +670,15 @@ function name(key, separator) {
   return '';
 };
 
-/***/ },
+/***/ }),
 /* 1 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
 
 // Takes a titleMap in either object or list format and returns one
-/* harmony default export */ exports["a"] = function (titleMap, originalEnum) {
+/* harmony default export */ __webpack_exports__["a"] = function (titleMap, originalEnum) {
   if (!Array.isArray(titleMap)) {
     var _ret = function () {
       var canonical = [];
@@ -614,32 +701,33 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
   return titleMap;
 };
 
-/***/ },
+/***/ }),
 /* 2 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ (function(module, exports, __webpack_require__) {
 
-module.exports = __webpack_require__(9).ObjectPath;
+module.exports = __webpack_require__(11).ObjectPath;
 
 
-/***/ },
+/***/ }),
 /* 3 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
+Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__sf_path__ = __webpack_require__(0);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__canonical_title_map__ = __webpack_require__(1);
-/* harmony export (immutable) */ exports["defaultFormDefinition"] = defaultFormDefinition;
-/* harmony export (immutable) */ exports["stdFormObj"] = stdFormObj;
-/* harmony export (immutable) */ exports["text"] = text;
-/* harmony export (immutable) */ exports["number"] = number;
-/* harmony export (immutable) */ exports["integer"] = integer;
-/* harmony export (immutable) */ exports["checkbox"] = checkbox;
-/* harmony export (immutable) */ exports["select"] = select;
-/* harmony export (immutable) */ exports["checkboxes"] = checkboxes;
-/* harmony export (immutable) */ exports["fieldset"] = fieldset;
-/* harmony export (immutable) */ exports["array"] = array;
-/* harmony export (immutable) */ exports["createDefaults"] = createDefaults;
-/* harmony export (immutable) */ exports["defaultForm"] = defaultForm;
+/* harmony export (immutable) */ __webpack_exports__["defaultFormDefinition"] = defaultFormDefinition;
+/* harmony export (immutable) */ __webpack_exports__["stdFormObj"] = stdFormObj;
+/* harmony export (immutable) */ __webpack_exports__["text"] = text;
+/* harmony export (immutable) */ __webpack_exports__["number"] = number;
+/* harmony export (immutable) */ __webpack_exports__["integer"] = integer;
+/* harmony export (immutable) */ __webpack_exports__["checkbox"] = checkbox;
+/* harmony export (immutable) */ __webpack_exports__["select"] = select;
+/* harmony export (immutable) */ __webpack_exports__["checkboxes"] = checkboxes;
+/* harmony export (immutable) */ __webpack_exports__["fieldset"] = fieldset;
+/* harmony export (immutable) */ __webpack_exports__["array"] = array;
+/* harmony export (immutable) */ __webpack_exports__["createDefaults"] = createDefaults;
+/* harmony export (immutable) */ __webpack_exports__["defaultForm"] = defaultForm;
 var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
 
 
@@ -931,26 +1019,30 @@ function defaultForm(schema, defaultSchemaTypes, ignore, globalOptions) {
   return { form: form, lookup: lookup };
 }
 
-/***/ },
+/***/ }),
 /* 4 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
+Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__lib_schema_defaults__ = __webpack_require__(3);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__lib_sf_path__ = __webpack_require__(0);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__lib_canonical_title_map__ = __webpack_require__(1);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__lib_merge__ = __webpack_require__(5);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__lib_select__ = __webpack_require__(6);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__lib_traverse__ = __webpack_require__(7);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__lib_validate__ = __webpack_require__(8);
-/* harmony export (binding) */ __webpack_require__.d(exports, "sfPath", function() { return sfPath; });
-/* harmony export (binding) */ __webpack_require__.d(exports, "schemaDefaults", function() { return schemaDefaults; });
-/* harmony export (binding) */ __webpack_require__.d(exports, "canonicalTitleMap", function() { return canonicalTitleMap; });
-/* harmony reexport (binding) */ __webpack_require__.d(exports, "merge", function() { return __WEBPACK_IMPORTED_MODULE_3__lib_merge__["a"]; });
-/* harmony reexport (binding) */ __webpack_require__.d(exports, "select", function() { return __WEBPACK_IMPORTED_MODULE_4__lib_select__["a"]; });
-/* harmony reexport (binding) */ __webpack_require__.d(exports, "traverseSchema", function() { return __WEBPACK_IMPORTED_MODULE_5__lib_traverse__["a"]; });
-/* harmony reexport (binding) */ __webpack_require__.d(exports, "traverseForm", function() { return __WEBPACK_IMPORTED_MODULE_5__lib_traverse__["b"]; });
-/* harmony reexport (binding) */ __webpack_require__.d(exports, "validate", function() { return __WEBPACK_IMPORTED_MODULE_6__lib_validate__["a"]; });
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__lib_merge__ = __webpack_require__(6);
+/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "merge", function() { return __WEBPACK_IMPORTED_MODULE_3__lib_merge__["a"]; });
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__lib_select__ = __webpack_require__(8);
+/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "select", function() { return __WEBPACK_IMPORTED_MODULE_4__lib_select__["a"]; });
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__lib_resolve__ = __webpack_require__(7);
+/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "jsonref", function() { return __WEBPACK_IMPORTED_MODULE_5__lib_resolve__["a"]; });
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__lib_traverse__ = __webpack_require__(9);
+/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "traverseSchema", function() { return __WEBPACK_IMPORTED_MODULE_6__lib_traverse__["a"]; });
+/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "traverseForm", function() { return __WEBPACK_IMPORTED_MODULE_6__lib_traverse__["b"]; });
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__lib_validate__ = __webpack_require__(10);
+/* harmony reexport (binding) */ __webpack_require__.d(__webpack_exports__, "validate", function() { return __WEBPACK_IMPORTED_MODULE_7__lib_validate__["a"]; });
+/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "sfPath", function() { return sfPath; });
+/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "schemaDefaults", function() { return schemaDefaults; });
+/* harmony export (binding) */ __webpack_require__.d(__webpack_exports__, "canonicalTitleMap", function() { return canonicalTitleMap; });
+
 
 
 
@@ -964,15 +1056,1643 @@ var sfPath = __WEBPACK_IMPORTED_MODULE_1__lib_sf_path__;
 var schemaDefaults = __WEBPACK_IMPORTED_MODULE_0__lib_schema_defaults__;
 var canonicalTitleMap = __WEBPACK_IMPORTED_MODULE_2__lib_canonical_title_map__["a" /* default */];
 
-/***/ },
+/***/ }),
 /* 5 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ (function(module, exports, __webpack_require__) {
+
+var __WEBPACK_AMD_DEFINE_FACTORY__, __WEBPACK_AMD_DEFINE_ARRAY__, __WEBPACK_AMD_DEFINE_RESULT__;var require;var require;var _typeof=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(obj){return typeof obj;}:function(obj){return obj&&typeof Symbol==="function"&&obj.constructor===Symbol&&obj!==Symbol.prototype?"symbol":typeof obj;};(function(f){if(( false?"undefined":_typeof(exports))==="object"&&typeof module!=="undefined"){module.exports=f();}else if(true){!(__WEBPACK_AMD_DEFINE_ARRAY__ = [], __WEBPACK_AMD_DEFINE_FACTORY__ = (f),
+				__WEBPACK_AMD_DEFINE_RESULT__ = (typeof __WEBPACK_AMD_DEFINE_FACTORY__ === 'function' ?
+				(__WEBPACK_AMD_DEFINE_FACTORY__.apply(exports, __WEBPACK_AMD_DEFINE_ARRAY__)) : __WEBPACK_AMD_DEFINE_FACTORY__),
+				__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));}else{var g;if(typeof window!=="undefined"){g=window;}else if(typeof global!=="undefined"){g=global;}else if(typeof self!=="undefined"){g=self;}else{g=this;}g.JsonRefs=f();}})(function(){var define,module,exports;return function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return require(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f;}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e);},l,l.exports,e,t,n,r);}return n[o].exports;}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++){s(r[o]);}return s;}({1:[function(require,module,exports){/*
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2014 Jeremy Whitlock
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ * THE SOFTWARE.
+ */'use strict';/**
+ * Various utilities for JSON References *(http://tools.ietf.org/html/draft-pbryan-zyp-json-ref-03)* and
+ * JSON Pointers *(https://tools.ietf.org/html/rfc6901)*.
+ *
+ * @module JsonRefs
+ */var path=require('path');var PathLoader=require('path-loader');var qs=require('querystring');var slash=require('slash');var URI=require('uri-js');var badPtrTokenRegex=/~(?:[^01]|$)/g;var remoteCache={};var remoteTypes=['relative','remote'];var remoteUriTypes=['absolute','uri'];var uriDetailsCache={};// Load promises polyfill if necessary
+/* istanbul ignore if */if(typeof Promise==='undefined'){require('native-promise-only');}/* Internal Functions */// This is a very simplistic clone function that does not take into account non-JSON types.  For these types the
+// original value is used as the clone.  So while it's not a complete deep clone, for the needs of this project
+// this should be sufficient.
+function clone(obj){var cloned;if(isType(obj,'Array')){cloned=[];obj.forEach(function(value,index){cloned[index]=clone(value);});}else if(isType(obj,'Object')){cloned={};Object.keys(obj).forEach(function(key){cloned[key]=clone(obj[key]);});}else{cloned=obj;}return cloned;}function combineQueryParams(qs1,qs2){var combined={};function mergeQueryParams(obj){Object.keys(obj).forEach(function(key){combined[key]=obj[key];});}mergeQueryParams(qs.parse(qs1||''));mergeQueryParams(qs.parse(qs2||''));return Object.keys(combined).length===0?undefined:qs.stringify(combined);}function combineURIs(u1,u2){// Convert Windows paths
+if(isType(u1,'String')){u1=slash(u1);}if(isType(u2,'String')){u2=slash(u2);}var u2Details=parseURI(isType(u2,'Undefined')?'':u2);var u1Details;var combinedDetails;if(remoteUriTypes.indexOf(u2Details.reference)>-1){combinedDetails=u2Details;}else{u1Details=isType(u1,'Undefined')?undefined:parseURI(u1);if(!isType(u1Details,'Undefined')){combinedDetails=u1Details;// Join the paths
+combinedDetails.path=slash(path.join(u1Details.path,u2Details.path));// Join query parameters
+combinedDetails.query=combineQueryParams(u1Details.query,u2Details.query);}else{combinedDetails=u2Details;}}// Remove the fragment
+combinedDetails.fragment=undefined;// For relative URIs, add back the '..' since it was removed above
+return(remoteUriTypes.indexOf(combinedDetails.reference)===-1&&combinedDetails.path.indexOf('../')===0?'../':'')+URI.serialize(combinedDetails);}function findAncestors(obj,path){var ancestors=[];var node;if(path.length>0){node=obj;path.slice(0,path.length-1).forEach(function(seg){if(seg in node){node=node[seg];ancestors.push(node);}});}return ancestors;}function processSubDocument(mode,doc,subDocPath,refDetails,options,parents,parentPtrs,allRefs,indirect){var refValue;var rOptions;if(subDocPath.length>0){try{refValue=findValue(doc,subDocPath);}catch(err){// We only mark missing remote references as missing because local references can have deferred values
+if(mode==='remote'){refDetails.error=err.message;refDetails.missing=true;}}}else{refValue=doc;}if(!isType(refValue,'Undefined')){refDetails.value=refValue;}if(isType(refValue,'Array')||isType(refValue,'Object')){rOptions=clone(options);if(mode==='local'){delete rOptions.subDocPath;// Traverse the dereferenced value
+doc=refValue;}else{rOptions.relativeBase=path.dirname(parents[parents.length-1]);if(subDocPath.length===0){delete rOptions.subDocPath;}else{rOptions.subDocPath=subDocPath;}}return findRefsRecursive(doc,rOptions,parents,parentPtrs,allRefs,indirect);}}// Should this be its own exported API?
+function findRefsRecursive(obj,options,parents,parentPtrs,allRefs,indirect){var allTasks=Promise.resolve();var parentPath=parentPtrs.length?pathFromPtr(parentPtrs[parentPtrs.length-1]):[];var refs=findRefs(obj,options);var subDocPath=options.subDocPath||[];var subDocPtr=pathToPtr(subDocPath);var ancestorPtrs=['#'];parents.forEach(function(parent,index){if(parent.charAt(0)!=='#'){ancestorPtrs.push(parentPtrs[index]);}});// Reverse the order so we search them in the proper order
+ancestorPtrs.reverse();if((parents[parents.length-1]||'').charAt(0)!=='#'){allRefs.documents[pathToPtr(parentPath)]=obj;}Object.keys(refs).forEach(function(refPtr){var refDetails=refs[refPtr];var location;var parentIndex;var refFullPath;var refFullPtr;// If there are no parents, treat the reference pointer as-is.  Otherwise, the reference is a reference within a
+// remote document and its sub document path prefix must be removed.
+if(parents.length===0){refFullPath=parentPath.concat(pathFromPtr(refPtr));}else{refFullPath=parentPath.concat(pathFromPtr(refPtr).slice(parents.length===0?0:subDocPath.length));}refFullPtr=pathToPtr(refFullPath);// It is possible to process the same reference more than once in the event of hierarchical references so we avoid
+// processing a reference if we've already done so.
+if(!isType(allRefs[refFullPtr],'Undefined')){return;}// Record the reference metadata
+allRefs.refs[refFullPtr]=refs[refPtr];// Do not process invalid references
+if(isType(refDetails.error,'Undefined')&&refDetails.type!=='invalid'){if(remoteTypes.indexOf(refDetails.type)>-1){location=combineURIs(options.relativeBase,refDetails.uri);parentIndex=parents.indexOf(location);}else{location=refDetails.uri;parentIndex=parentPtrs.indexOf(location);}// Record ancestor paths
+refDetails.ancestorPtrs=ancestorPtrs;// Record if the reference is indirect based on its parent
+refDetails.indirect=indirect;// Only process non-circular references further
+if(parentIndex===-1){if(remoteTypes.indexOf(refDetails.type)>-1){allTasks=allTasks.then(function(){return getRemoteDocument(location,options).then(function(doc){return processSubDocument('remote',doc,isType(refDetails.uriDetails.fragment,'Undefined')?[]:pathFromPtr(decodeURI(refDetails.uriDetails.fragment)),refDetails,options,parents.concat(location),parentPtrs.concat(refFullPtr),allRefs,indirect);}).catch(function(err){refDetails.error=err.message;refDetails.missing=true;});});}else{if(refFullPtr.indexOf(location+'/')!==0&&refFullPtr!==location&&subDocPtr.indexOf(location+'/')!==0&&subDocPtr!==location){if(location.indexOf(subDocPtr+'/')!==0){allTasks=allTasks.then(function(){return processSubDocument('local',obj,pathFromPtr(location),refDetails,options,parents.concat(location),parentPtrs.concat(refFullPtr),allRefs,indirect||location.indexOf(subDocPtr+'/')===-1&&location!==subDocPtr);});}}else{refDetails.circular=true;}}}else{// Mark seen ancestors as circular
+parentPtrs.slice(parentIndex).forEach(function(parentPtr){allRefs.refs[parentPtr].circular=true;});refDetails.circular=true;}}});allTasks=allTasks.then(function(){// Identify indirect, local circular references (Issue 82)
+var circulars=[];var processedRefPtrs=[];var processedRefs=[];function walkRefs(parentPtrs,parentRefs,refPtr,ref){Object.keys(allRefs.refs).forEach(function(dRefPtr){var dRefDetails=allRefs.refs[dRefPtr];// Do not process already processed references or references that are not a nested references
+if(processedRefs.indexOf(ref)===-1&&processedRefPtrs.indexOf(refPtr)===-1&&circulars.indexOf(ref)===-1&&dRefPtr!==refPtr&&dRefPtr.indexOf(ref+'/')===0){if(parentRefs.indexOf(ref)>-1){parentRefs.forEach(function(parentRef){if(circulars.indexOf(ref)===-1){circulars.push(parentRef);}});}else{walkRefs(parentPtrs.concat(refPtr),parentRefs.concat(ref),dRefPtr,dRefDetails.uri);}processedRefPtrs.push(refPtr);processedRefs.push(ref);}});}Object.keys(allRefs.refs).forEach(function(refPtr){var refDetails=allRefs.refs[refPtr];// Only process local, non-circular references
+if(refDetails.type==='local'&&!refDetails.circular&&circulars.indexOf(refDetails.uri)===-1){walkRefs([],[],refPtr,refDetails.uri);}});Object.keys(allRefs.refs).forEach(function(refPtr){var refDetails=allRefs.refs[refPtr];if(circulars.indexOf(refDetails.uri)>-1){refDetails.circular=true;}});}).then(function(){return allRefs;});return allTasks;}function findValue(obj,path){var value=obj;path.forEach(function(seg){seg=decodeURI(seg);if(seg in value){value=value[seg];}else{throw Error('JSON Pointer points to missing location: '+pathToPtr(path));}});return value;}function getExtraRefKeys(ref){return Object.keys(ref).filter(function(key){return key!=='$ref';});}function getRefType(refDetails){var type;// Convert the URI reference to one of our types
+switch(refDetails.uriDetails.reference){case'absolute':case'uri':type='remote';break;case'same-document':type='local';break;default:type=refDetails.uriDetails.reference;}return type;}function getRemoteDocument(url,options){var cacheEntry=remoteCache[url];var allTasks=Promise.resolve();var loaderOptions=clone(options.loaderOptions||{});if(isType(cacheEntry,'Undefined')){// If there is no content processor, default to processing the raw response as JSON
+if(isType(loaderOptions.processContent,'Undefined')){loaderOptions.processContent=function(res,callback){callback(undefined,JSON.parse(res.text));};}// Attempt to load the resource using path-loader
+allTasks=PathLoader.load(decodeURI(url),loaderOptions);// Update the cache
+allTasks=allTasks.then(function(res){remoteCache[url]={value:res};return res;}).catch(function(err){remoteCache[url]={error:err};throw err;});}else{// Return the cached version
+allTasks=allTasks.then(function(){return cacheEntry.value;});}// Return a cloned version to avoid updating the cache
+allTasks=allTasks.then(function(res){return clone(res);});return allTasks;}function isRefLike(obj,throwWithDetails){var refLike=true;try{if(!isType(obj,'Object')){throw new Error('obj is not an Object');}else if(!isType(obj.$ref,'String')){throw new Error('obj.$ref is not a String');}}catch(err){if(throwWithDetails){throw err;}refLike=false;}return refLike;}function isType(obj,type){// A PhantomJS bug (https://github.com/ariya/phantomjs/issues/11722) prohibits us from using the same approach for
+// undefined checking that we use for other types.
+if(type==='Undefined'){return typeof obj==='undefined';}else{return Object.prototype.toString.call(obj)==='[object '+type+']';}}function makeRefFilter(options){var refFilter;var validTypes;if(isType(options.filter,'Array')||isType(options.filter,'String')){validTypes=isType(options.filter,'String')?[options.filter]:options.filter;refFilter=function refFilter(refDetails){// Check the exact type or for invalid URIs, check its original type
+return validTypes.indexOf(refDetails.type)>-1||validTypes.indexOf(getRefType(refDetails))>-1;};}else if(isType(options.filter,'Function')){refFilter=options.filter;}else if(isType(options.filter,'Undefined')){refFilter=function refFilter(){return true;};}return function(refDetails,path){return(refDetails.type!=='invalid'||options.includeInvalid===true)&&refFilter(refDetails,path);};}function makeSubDocPath(options){var subDocPath;if(isType(options.subDocPath,'Array')){subDocPath=options.subDocPath;}else if(isType(options.subDocPath,'String')){subDocPath=pathFromPtr(options.subDocPath);}else if(isType(options.subDocPath,'Undefined')){subDocPath=[];}return subDocPath;}function parseURI(uri){// We decode first to avoid doubly encoding
+return URI.parse(encodeURI(decodeURI(uri)));}function setValue(obj,refPath,value){findValue(obj,refPath.slice(0,refPath.length-1))[decodeURI(refPath[refPath.length-1])]=value;}function walk(ancestors,node,path,fn){var processChildren=true;function walkItem(item,segment){path.push(segment);walk(ancestors,item,path,fn);path.pop();}// Call the iteratee
+if(isType(fn,'Function')){processChildren=fn(ancestors,node,path);}// We do not process circular objects again
+if(ancestors.indexOf(node)===-1){ancestors.push(node);if(processChildren!==false){if(isType(node,'Array')){node.forEach(function(member,index){walkItem(member,index.toString());});}else if(isType(node,'Object')){Object.keys(node).forEach(function(key){walkItem(node[key],key);});}}}ancestors.pop();}function validateOptions(options,obj){if(isType(options,'Undefined')){// Default to an empty options object
+options={};}else{// Clone the options so we do not alter the ones passed in
+options=clone(options);}if(!isType(options,'Object')){throw new TypeError('options must be an Object');}else if(!isType(options.filter,'Undefined')&&!isType(options.filter,'Array')&&!isType(options.filter,'Function')&&!isType(options.filter,'String')){throw new TypeError('options.filter must be an Array, a Function of a String');}else if(!isType(options.includeInvalid,'Undefined')&&!isType(options.includeInvalid,'Boolean')){throw new TypeError('options.includeInvalid must be a Boolean');}else if(!isType(options.refPreProcessor,'Undefined')&&!isType(options.refPreProcessor,'Function')){throw new TypeError('options.refPreProcessor must be a Function');}else if(!isType(options.refPostProcessor,'Undefined')&&!isType(options.refPostProcessor,'Function')){throw new TypeError('options.refPostProcessor must be a Function');}else if(!isType(options.subDocPath,'Undefined')&&!isType(options.subDocPath,'Array')&&!isPtr(options.subDocPath)){// If a pointer is provided, throw an error if it's not the proper type
+throw new TypeError('options.subDocPath must be an Array of path segments or a valid JSON Pointer');}options.filter=makeRefFilter(options);// Set the subDocPath to avoid everyone else having to compute it
+options.subDocPath=makeSubDocPath(options);if(!isType(obj,'Undefined')){try{findValue(obj,options.subDocPath);}catch(err){err.message=err.message.replace('JSON Pointer','options.subDocPath');throw err;}}return options;}/* Module Members *//*
+ * Each of the functions below are defined as function statements and *then* exported in two steps instead of one due
+ * to a bug in jsdoc (https://github.com/jsdoc2md/jsdoc-parse/issues/18) that causes our documentation to be
+ * generated improperly.  The impact to the user is significant enough for us to warrant working around it until this
+ * is fixed.
+ *//**
+ * The options used for various JsonRefs APIs.
+ *
+ * @typedef {object} JsonRefsOptions
+ *
+ * @param {string|string[]|function} [filter=function () {return true;}] - The filter to use when gathering JSON
+ * References *(If this value is a single string or an array of strings, the value(s) are expected to be the `type(s)`
+ * you are interested in collecting as described in {@link module:JsonRefs.getRefDetails}.  If it is a function, it is
+ * expected that the function behaves like {@link module:JsonRefs~RefDetailsFilter}.)*
+ * @param {boolean} [includeInvalid=false] - Whether or not to include invalid JSON Reference details *(This will make
+ * it so that objects that are like JSON Reference objects, as in they are an `Object` and the have a `$ref` property,
+ * but fail validation will be included.  This is very useful for when you want to know if you have invalid JSON
+ * Reference definitions.  This will not mean that APIs will process invalid JSON References but the reasons as to why
+ * the JSON References are invalid will be included in the returned metadata.)*
+ * @param {object} [loaderOptions] - The options to pass to
+ * {@link https://github.com/whitlockjc/path-loader/blob/master/docs/API.md#module_PathLoader.load|PathLoader~load}
+ * @param {module:JsonRefs~RefPreProcessor} [refPreProcessor] - The callback used to pre-process a JSON Reference like
+ * object *(This is called prior to validating the JSON Reference like object and getting its details)*
+ * @param {module:JsonRefs~RefPostProcessor} [refPostProcessor] - The callback used to post-process the JSON Reference
+ * metadata *(This is called prior filtering the references)*
+ * @param {string} [options.relativeBase] - The base location to use when resolving relative references *(Only useful
+ * for APIs that do remote reference resolution.  If this value is not defined,
+ * {@link https://github.com/whitlockjc/path-loader|path-loader} will use `window.location.href` for the browser and
+ * `process.cwd()` for Node.js.)*
+ * @param {string|string[]} [options.subDocPath=[]] - The JSON Pointer or array of path segments to the sub document
+ * location to search from
+ *//**
+ * Simple function used to filter out JSON References.
+ *
+ * @typedef {function} RefDetailsFilter
+ *
+ * @param {module:JsonRefs~UnresolvedRefDetails} refDetails - The JSON Reference details to test
+ * @param {string[]} path - The path to the JSON Reference
+ *
+ * @returns {boolean} whether the JSON Reference should be filtered *(out)* or not
+ *//**
+ * Simple function used to pre-process a JSON Reference like object.
+ *
+ * @typedef {function} RefPreProcessor
+ *
+ * @param {object} obj - The JSON Reference like object
+ * @param {string[]} path - The path to the JSON Reference like object
+ *
+ * @returns {object} the processed JSON Reference like object
+ *//**
+ * Simple function used to post-process a JSON Reference details.
+ *
+ * @typedef {function} RefPostProcessor
+ *
+ * @param {module:JsonRefs~UnresolvedRefDetails} refDetails - The JSON Reference details to test
+ * @param {string[]} path - The path to the JSON Reference
+ *
+ * @returns {object} the processed JSON Reference details object
+ *//**
+ * Detailed information about resolved JSON References.
+ *
+ * @typedef {module:JsonRefs~UnresolvedRefDetails} ResolvedRefDetails
+ *
+ * @property {boolean} [circular] - Whether or not the JSON Reference is circular *(Will not be set if the JSON
+ * Reference is not circular)*
+ * @property {boolean} [missing] - Whether or not the referenced value was missing or not *(Will not be set if the
+ * referenced value is not missing)*
+ * @property {*} [value] - The referenced value *(Will not be set if the referenced value is missing)*
+ *//**
+ * The results of resolving the JSON References of an array/object.
+ *
+ * @typedef {object} ResolvedRefsResults
+ *
+ * @property {module:JsonRefs~ResolvedRefDetails} refs - An object whose keys are JSON Pointers *(fragment version)*
+ * to where the JSON Reference is defined and whose values are {@link module:JsonRefs~ResolvedRefDetails}
+ * @property {object} resolved - The array/object with its JSON References fully resolved
+ *//**
+ * An object containing the retrieved document and detailed information about its JSON References.
+ *
+ * @typedef {module:JsonRefs~ResolvedRefsResults} RetrievedRefsResults
+ *
+ * @property {object} value - The retrieved document
+ *//**
+ * An object containing the retrieved document, the document with its references resolved and  detailed information
+ * about its JSON References.
+ *
+ * @typedef {object} RetrievedResolvedRefsResults
+ *
+ * @property {module:JsonRefs~UnresolvedRefDetails} refs - An object whose keys are JSON Pointers *(fragment version)*
+ * to where the JSON Reference is defined and whose values are {@link module:JsonRefs~UnresolvedRefDetails}
+ * @property {ResolvedRefsResults} - An object whose keys are JSON Pointers *(fragment version)*
+ * to where the JSON Reference is defined and whose values are {@link module:JsonRefs~ResolvedRefDetails}
+ * @property {object} value - The retrieved document
+ *//**
+ * Detailed information about unresolved JSON References.
+ *
+ * @typedef {object} UnresolvedRefDetails
+ *
+ * @property {object} def - The JSON Reference definition
+ * @property {string} [error] - The error information for invalid JSON Reference definition *(Only present when the
+ * JSON Reference definition is invalid or there was a problem retrieving a remote reference during resolution)*
+ * @property {string} uri - The URI portion of the JSON Reference
+ * @property {object} uriDetails - Detailed information about the URI as provided by
+ * {@link https://github.com/garycourt/uri-js|URI.parse}.
+ * @property {string} type - The JSON Reference type *(This value can be one of the following: `invalid`, `local`,
+ * `relative` or `remote`.)*
+ * @property {string} [warning] - The warning information *(Only present when the JSON Reference definition produces a
+ * warning)*
+ *//**
+ * Clears the internal cache of remote documents, reference details, etc.
+ *
+ * @alias module:JsonRefs.clearCache
+ */function clearCache(){remoteCache={};}/**
+ * Takes an array of path segments and decodes the JSON Pointer tokens in them.
+ *
+ * @param {string[]} path - The array of path segments
+ *
+ * @returns {string} the array of path segments with their JSON Pointer tokens decoded
+ *
+ * @throws {Error} if the path is not an `Array`
+ *
+ * @see {@link https://tools.ietf.org/html/rfc6901#section-3}
+ *
+ * @alias module:JsonRefs.decodePath
+ */function decodePath(path){if(!isType(path,'Array')){throw new TypeError('path must be an array');}return path.map(function(seg){if(!isType(seg,'String')){seg=JSON.stringify(seg);}return decodeURI(seg.replace(/~1/g,'/').replace(/~0/g,'~'));});}/**
+ * Takes an array of path segments and encodes the special JSON Pointer characters in them.
+ *
+ * @param {string[]} path - The array of path segments
+ *
+ * @returns {string} the array of path segments with their JSON Pointer tokens encoded
+ *
+ * @throws {Error} if the path is not an `Array`
+ *
+ * @see {@link https://tools.ietf.org/html/rfc6901#section-3}
+ *
+ * @alias module:JsonRefs.encodePath
+ */function encodePath(path){if(!isType(path,'Array')){throw new TypeError('path must be an array');}return path.map(function(seg){if(!isType(seg,'String')){seg=JSON.stringify(seg);}return seg.replace(/~/g,'~0').replace(/\//g,'~1');});}/**
+ * Finds JSON References defined within the provided array/object.
+ *
+ * @param {array|object} obj - The structure to find JSON References within
+ * @param {module:JsonRefs~JsonRefsOptions} [options] - The JsonRefs options
+ *
+ * @returns {object} an object whose keys are JSON Pointers *(fragment version)* to where the JSON Reference is defined
+ * and whose values are {@link module:JsonRefs~UnresolvedRefDetails}.
+ *
+ * @throws {Error} when the input arguments fail validation or if `options.subDocPath` points to an invalid location
+ *
+ * @alias module:JsonRefs.findRefs
+ *
+ * @example
+ * // Finding all valid references
+ * var allRefs = JsonRefs.findRefs(obj);
+ * // Finding all remote references
+ * var remoteRefs = JsonRefs.findRefs(obj, {filter: ['relative', 'remote']});
+ * // Finding all invalid references
+ * var invalidRefs = JsonRefs.findRefs(obj, {filter: 'invalid', includeInvalid: true});
+ */function findRefs(obj,options){var refs={};// Validate the provided document
+if(!isType(obj,'Array')&&!isType(obj,'Object')){throw new TypeError('obj must be an Array or an Object');}// Validate options
+options=validateOptions(options,obj);// Walk the document (or sub document) and find all JSON References
+walk(findAncestors(obj,options.subDocPath),findValue(obj,options.subDocPath),clone(options.subDocPath),function(ancestors,node,path){var processChildren=true;var refDetails;if(isRefLike(node)){// Pre-process the node when necessary
+if(!isType(options.refPreProcessor,'Undefined')){node=options.refPreProcessor(clone(node),path);}refDetails=getRefDetails(node);// Post-process the reference details
+if(!isType(options.refPostProcessor,'Undefined')){refDetails=options.refPostProcessor(refDetails,path);}if(options.filter(refDetails,path)){refs[pathToPtr(path)]=refDetails;}// Whenever a JSON Reference has extra children, its children should not be processed.
+//   See: http://tools.ietf.org/html/draft-pbryan-zyp-json-ref-03#section-3
+if(getExtraRefKeys(node).length>0){processChildren=false;}}return processChildren;});return refs;}/**
+ * Finds JSON References defined within the document at the provided location.
+ *
+ * This API is identical to {@link module:JsonRefs.findRefs} except this API will retrieve a remote document and then
+ * return the result of {@link module:JsonRefs.findRefs} on the retrieved document.
+ *
+ * @param {string} location - The location to retrieve *(Can be relative or absolute, just make sure you look at the
+ * {@link module:JsonRefs~JsonRefsOptions|options documentation} to see how relative references are handled.)*
+ * @param {module:JsonRefs~JsonRefsOptions} [options] - The JsonRefs options
+ *
+ * @returns {Promise} a promise that resolves a {@link module:JsonRefs~RetrievedRefsResults} and rejects with an
+ * `Error` when the input arguments fail validation, when `options.subDocPath` points to an invalid location or when
+ *  the location argument points to an unloadable resource
+ *
+ * @alias module:JsonRefs.findRefsAt
+ *
+ * @example
+ * // Example that only resolves references within a sub document
+ * JsonRefs.findRefsAt('http://petstore.swagger.io/v2/swagger.json', {
+ *     subDocPath: '#/definitions'
+ *   })
+ *   .then(function (res) {
+ *      // Do something with the response
+ *      //
+ *      // res.refs: JSON Reference locations and details
+ *      // res.value: The retrieved document
+ *   }, function (err) {
+ *     console.log(err.stack);
+ *   });
+ */function findRefsAt(location,options){var allTasks=Promise.resolve();allTasks=allTasks.then(function(){// Validate the provided location
+if(!isType(location,'String')){throw new TypeError('location must be a string');}// Validate options
+options=validateOptions(options);// Combine the location and the optional relative base
+location=combineURIs(options.relativeBase,location);return getRemoteDocument(location,options);}).then(function(res){var cacheEntry=clone(remoteCache[location]);var cOptions=clone(options);var uriDetails=parseURI(location);if(isType(cacheEntry.refs,'Undefined')){// Do not filter any references so the cache is complete
+delete cOptions.filter;delete cOptions.subDocPath;cOptions.includeInvalid=true;remoteCache[location].refs=findRefs(res,cOptions);}// Add the filter options back
+if(!isType(options.filter,'Undefined')){cOptions.filter=options.filter;}if(!isType(uriDetails.fragment,'Undefined')){cOptions.subDocPath=pathFromPtr(decodeURI(uriDetails.fragment));}else if(!isType(uriDetails.subDocPath,'Undefined')){cOptions.subDocPath=options.subDocPath;}// This will use the cache so don't worry about calling it twice
+return{refs:findRefs(res,cOptions),value:res};});return allTasks;}/**
+ * Returns detailed information about the JSON Reference.
+ *
+ * @param {object} obj - The JSON Reference definition
+ *
+ * @returns {module:JsonRefs~UnresolvedRefDetails} the detailed information
+ *
+ * @alias module:JsonRefs.getRefDetails
+ */function getRefDetails(obj){var details={def:obj};var cacheKey;var extraKeys;var uriDetails;try{if(isRefLike(obj,true)){cacheKey=obj.$ref;uriDetails=uriDetailsCache[cacheKey];if(isType(uriDetails,'Undefined')){uriDetails=uriDetailsCache[cacheKey]=parseURI(cacheKey);}details.uri=cacheKey;details.uriDetails=uriDetails;if(isType(uriDetails.error,'Undefined')){details.type=getRefType(details);}else{details.error=details.uriDetails.error;details.type='invalid';}// Identify warning
+extraKeys=getExtraRefKeys(obj);if(extraKeys.length>0){details.warning='Extra JSON Reference properties will be ignored: '+extraKeys.join(', ');}}else{details.type='invalid';}}catch(err){details.error=err.message;details.type='invalid';}return details;}/**
+ * Returns whether the argument represents a JSON Pointer.
+ *
+ * A string is a JSON Pointer if the following are all true:
+ *
+ *   * The string is of type `String`
+ *   * The string must be empty, `#` or start with a `/` or `#/`
+ *
+ * @param {string} ptr - The string to check
+ * @param {boolean} [throwWithDetails=false] - Whether or not to throw an `Error` with the details as to why the value
+ * provided is invalid
+ *
+ * @returns {boolean} the result of the check
+ *
+ * @throws {error} when the provided value is invalid and the `throwWithDetails` argument is `true`
+ *
+ * @alias module:JsonRefs.isPtr
+ *
+ * @see {@link https://tools.ietf.org/html/rfc6901#section-3}
+ *
+ * @example
+ * // Separating the different ways to invoke isPtr for demonstration purposes
+ * if (isPtr(str)) {
+ *   // Handle a valid JSON Pointer
+ * } else {
+ *   // Get the reason as to why the value is not a JSON Pointer so you can fix/report it
+ *   try {
+ *     isPtr(str, true);
+ *   } catch (err) {
+ *     // The error message contains the details as to why the provided value is not a JSON Pointer
+ *   }
+ * }
+ */function isPtr(ptr,throwWithDetails){var valid=true;var firstChar;try{if(isType(ptr,'String')){if(ptr!==''){firstChar=ptr.charAt(0);if(['#','/'].indexOf(firstChar)===-1){throw new Error('ptr must start with a / or #/');}else if(firstChar==='#'&&ptr!=='#'&&ptr.charAt(1)!=='/'){throw new Error('ptr must start with a / or #/');}else if(ptr.match(badPtrTokenRegex)){throw new Error('ptr has invalid token(s)');}}}else{throw new Error('ptr is not a String');}}catch(err){if(throwWithDetails===true){throw err;}valid=false;}return valid;}/**
+ * Returns whether the argument represents a JSON Reference.
+ *
+ * An object is a JSON Reference only if the following are all true:
+ *
+ *   * The object is of type `Object`
+ *   * The object has a `$ref` property
+ *   * The `$ref` property is a valid URI *(We do not require 100% strict URIs and will handle unescaped special
+ *     characters.)*
+ *
+ * @param {object} obj - The object to check
+ * @param {boolean} [throwWithDetails=false] - Whether or not to throw an `Error` with the details as to why the value
+ * provided is invalid
+ *
+ * @returns {boolean} the result of the check
+ *
+ * @throws {error} when the provided value is invalid and the `throwWithDetails` argument is `true`
+ *
+ * @alias module:JsonRefs.isRef
+ *
+ * @see {@link http://tools.ietf.org/html/draft-pbryan-zyp-json-ref-03#section-3}
+ *
+ * @example
+ * // Separating the different ways to invoke isRef for demonstration purposes
+ * if (isRef(obj)) {
+ *   // Handle a valid JSON Reference
+ * } else {
+ *   // Get the reason as to why the value is not a JSON Reference so you can fix/report it
+ *   try {
+ *     isRef(str, true);
+ *   } catch (err) {
+ *     // The error message contains the details as to why the provided value is not a JSON Reference
+ *   }
+ * }
+ */function isRef(obj,throwWithDetails){return isRefLike(obj,throwWithDetails)&&getRefDetails(obj,throwWithDetails).type!=='invalid';}/**
+ * Returns an array of path segments for the provided JSON Pointer.
+ *
+ * @param {string} ptr - The JSON Pointer
+ *
+ * @returns {string[]} the path segments
+ *
+ * @throws {Error} if the provided `ptr` argument is not a JSON Pointer
+ *
+ * @alias module:JsonRefs.pathFromPtr
+ */function pathFromPtr(ptr){if(!isPtr(ptr)){throw new Error('ptr must be a JSON Pointer');}var segments=ptr.split('/');// Remove the first segment
+segments.shift();return decodePath(segments);}/**
+ * Returns a JSON Pointer for the provided array of path segments.
+ *
+ * **Note:** If a path segment in `path` is not a `String`, it will be converted to one using `JSON.stringify`.
+ *
+ * @param {string[]} path - The array of path segments
+ * @param {boolean} [hashPrefix=true] - Whether or not create a hash-prefixed JSON Pointer
+ *
+ * @returns {string} the corresponding JSON Pointer
+ *
+ * @throws {Error} if the `path` argument is not an array
+ *
+ * @alias module:JsonRefs.pathToPtr
+ */function pathToPtr(path,hashPrefix){if(!isType(path,'Array')){throw new Error('path must be an Array');}// Encode each segment and return
+return(hashPrefix!==false?'#':'')+(path.length>0?'/':'')+encodePath(path).join('/');}/**
+ * Finds JSON References defined within the provided array/object and resolves them.
+ *
+ * @param {array|object} obj - The structure to find JSON References within
+ * @param {module:JsonRefs~JsonRefsOptions} [options] - The JsonRefs options
+ *
+ * @returns {Promise} a promise that resolves a {@link module:JsonRefs~ResolvedRefsResults} and rejects with an
+ * `Error` when the input arguments fail validation, when `options.subDocPath` points to an invalid location or when
+ *  the location argument points to an unloadable resource
+ *
+ * @alias module:JsonRefs.resolveRefs
+ *
+ * @example
+ * // Example that only resolves relative and remote references
+ * JsonRefs.resolveRefs(swaggerObj, {
+ *     filter: ['relative', 'remote']
+ *   })
+ *   .then(function (res) {
+ *      // Do something with the response
+ *      //
+ *      // res.refs: JSON Reference locations and details
+ *      // res.resolved: The document with the appropriate JSON References resolved
+ *   }, function (err) {
+ *     console.log(err.stack);
+ *   });
+ */function resolveRefs(obj,options){var allTasks=Promise.resolve();allTasks=allTasks.then(function(){// Validate the provided document
+if(!isType(obj,'Array')&&!isType(obj,'Object')){throw new TypeError('obj must be an Array or an Object');}// Validate options
+options=validateOptions(options,obj);// Clone the input so we do not alter it
+obj=clone(obj);}).then(function(){return findRefsRecursive(obj,options,[],[],{documents:{},refs:{}});}).then(function(allRefs){var deferredRefs={};var refs={};function pathSorter(p1,p2){return pathFromPtr(p1).length-pathFromPtr(p2).length;}// Resolve all references with a known value
+Object.keys(allRefs.refs).sort(pathSorter).forEach(function(refPtr){var refDetails=allRefs.refs[refPtr];// Record all direct references
+if(!refDetails.indirect){refs[refPtr]=refDetails;}// Delete helper property
+delete refDetails.indirect;if(isType(refDetails.error,'Undefined')&&refDetails.type!=='invalid'){if(isType(refDetails.value,'Undefined')&&refDetails.circular){refDetails.value=refDetails.def;}// We defer processing all references without a value until later
+if(isType(refDetails.value,'Undefined')){deferredRefs[refPtr]=refDetails;}else{if(refPtr==='#'){obj=refDetails.value;}else{setValue(obj,pathFromPtr(refPtr),refDetails.value);}// Delete helper property
+delete refDetails.ancestorPtrs;}}else{// Delete helper property
+delete refDetails.ancestorPtrs;}});// Resolve all deferred references
+Object.keys(deferredRefs).forEach(function(refPtr){var refDetails=deferredRefs[refPtr];// Attempt to resolve the value against all if its ancestors in order
+refDetails.ancestorPtrs.forEach(function(ancestorPtr,index){if(isType(refDetails.value,'Undefined')){try{refDetails.value=findValue(allRefs.documents[ancestorPtr],pathFromPtr(refDetails.uri));// Delete helper property
+delete refDetails.ancestorPtrs;setValue(obj,pathFromPtr(refPtr),refDetails.value);}catch(err){if(index===refDetails.ancestorPtrs.length-1){refDetails.error=err.message;refDetails.missing=true;// Delete helper property
+delete refDetails.ancestorPtrs;}}}});});return{refs:refs,resolved:obj};});return allTasks;}/**
+ * Resolves JSON References defined within the document at the provided location.
+ *
+ * This API is identical to {@link module:JsonRefs.resolveRefs} except this API will retrieve a remote document and then
+ * return the result of {@link module:JsonRefs.resolveRefs} on the retrieved document.
+ *
+ * @param {string} location - The location to retrieve *(Can be relative or absolute, just make sure you look at the
+ * {@link module:JsonRefs~JsonRefsOptions|options documentation} to see how relative references are handled.)*
+ * @param {module:JsonRefs~JsonRefsOptions} [options] - The JsonRefs options
+ *
+ * @returns {Promise} a promise that resolves a {@link module:JsonRefs~RetrievedResolvedRefsResults} and rejects with an
+ * `Error` when the input arguments fail validation, when `options.subDocPath` points to an invalid location or when
+ *  the location argument points to an unloadable resource
+ *
+ * @alias module:JsonRefs.resolveRefsAt
+ *
+ * @example
+ * // Example that loads a JSON document (No options.loaderOptions.processContent required) and resolves all references
+ * JsonRefs.resolveRefsAt('./swagger.json')
+ *   .then(function (res) {
+ *      // Do something with the response
+ *      //
+ *      // res.refs: JSON Reference locations and details
+ *      // res.resolved: The document with the appropriate JSON References resolved
+ *      // res.value: The retrieved document
+ *   }, function (err) {
+ *     console.log(err.stack);
+ *   });
+ */function resolveRefsAt(location,options){var allTasks=Promise.resolve();allTasks=allTasks.then(function(){// Validate the provided location
+if(!isType(location,'String')){throw new TypeError('location must be a string');}// Validate options
+options=validateOptions(options);// Combine the location and the optional relative base
+location=combineURIs(options.relativeBase,location);return getRemoteDocument(location,options);}).then(function(res){var cOptions=clone(options);var uriDetails=parseURI(location);// Set the sub document path if necessary
+if(!isType(uriDetails.fragment,'Undefined')){cOptions.subDocPath=pathFromPtr(decodeURI(uriDetails.fragment));}// Update the relative base based on the retrieved location
+cOptions.relativeBase=path.dirname(location);return resolveRefs(res,cOptions).then(function(res2){return{refs:res2.refs,resolved:res2.resolved,value:res};});});return allTasks;}/* Export the module members */module.exports.clearCache=clearCache;module.exports.decodePath=decodePath;module.exports.encodePath=encodePath;module.exports.findRefs=findRefs;module.exports.findRefsAt=findRefsAt;module.exports.getRefDetails=getRefDetails;module.exports.isPtr=isPtr;module.exports.isRef=isRef;module.exports.pathFromPtr=pathFromPtr;module.exports.pathToPtr=pathToPtr;module.exports.resolveRefs=resolveRefs;module.exports.resolveRefsAt=resolveRefsAt;},{"native-promise-only":3,"path":4,"path-loader":5,"querystring":11,"slash":13,"uri-js":23}],2:[function(require,module,exports){/**
+ * Expose `Emitter`.
+ */module.exports=Emitter;/**
+ * Initialize a new `Emitter`.
+ *
+ * @api public
+ */function Emitter(obj){if(obj)return mixin(obj);};/**
+ * Mixin the emitter properties.
+ *
+ * @param {Object} obj
+ * @return {Object}
+ * @api private
+ */function mixin(obj){for(var key in Emitter.prototype){obj[key]=Emitter.prototype[key];}return obj;}/**
+ * Listen on the given `event` with `fn`.
+ *
+ * @param {String} event
+ * @param {Function} fn
+ * @return {Emitter}
+ * @api public
+ */Emitter.prototype.on=Emitter.prototype.addEventListener=function(event,fn){this._callbacks=this._callbacks||{};(this._callbacks['$'+event]=this._callbacks['$'+event]||[]).push(fn);return this;};/**
+ * Adds an `event` listener that will be invoked a single
+ * time then automatically removed.
+ *
+ * @param {String} event
+ * @param {Function} fn
+ * @return {Emitter}
+ * @api public
+ */Emitter.prototype.once=function(event,fn){function on(){this.off(event,on);fn.apply(this,arguments);}on.fn=fn;this.on(event,on);return this;};/**
+ * Remove the given callback for `event` or all
+ * registered callbacks.
+ *
+ * @param {String} event
+ * @param {Function} fn
+ * @return {Emitter}
+ * @api public
+ */Emitter.prototype.off=Emitter.prototype.removeListener=Emitter.prototype.removeAllListeners=Emitter.prototype.removeEventListener=function(event,fn){this._callbacks=this._callbacks||{};// all
+if(0==arguments.length){this._callbacks={};return this;}// specific event
+var callbacks=this._callbacks['$'+event];if(!callbacks)return this;// remove all handlers
+if(1==arguments.length){delete this._callbacks['$'+event];return this;}// remove specific handler
+var cb;for(var i=0;i<callbacks.length;i++){cb=callbacks[i];if(cb===fn||cb.fn===fn){callbacks.splice(i,1);break;}}return this;};/**
+ * Emit `event` with the given args.
+ *
+ * @param {String} event
+ * @param {Mixed} ...
+ * @return {Emitter}
+ */Emitter.prototype.emit=function(event){this._callbacks=this._callbacks||{};var args=[].slice.call(arguments,1),callbacks=this._callbacks['$'+event];if(callbacks){callbacks=callbacks.slice(0);for(var i=0,len=callbacks.length;i<len;++i){callbacks[i].apply(this,args);}}return this;};/**
+ * Return array of callbacks for `event`.
+ *
+ * @param {String} event
+ * @return {Array}
+ * @api public
+ */Emitter.prototype.listeners=function(event){this._callbacks=this._callbacks||{};return this._callbacks['$'+event]||[];};/**
+ * Check if this emitter has `event` handlers.
+ *
+ * @param {String} event
+ * @return {Boolean}
+ * @api public
+ */Emitter.prototype.hasListeners=function(event){return!!this.listeners(event).length;};},{}],3:[function(require,module,exports){(function(global){/*! Native Promise Only
+    v0.8.1 (c) Kyle Simpson
+    MIT License: http://getify.mit-license.org
+*/(function UMD(name,context,definition){// special form of UMD for polyfilling across evironments
+context[name]=context[name]||definition();if(typeof module!="undefined"&&module.exports){module.exports=context[name];}else if(typeof define=="function"&&define.amd){define(function $AMD$(){return context[name];});}})("Promise",typeof global!="undefined"?global:this,function DEF(){/*jshint validthis:true */"use strict";var builtInProp,cycle,scheduling_queue,ToString=Object.prototype.toString,timer=typeof setImmediate!="undefined"?function timer(fn){return setImmediate(fn);}:setTimeout;// dammit, IE8.
+try{Object.defineProperty({},"x",{});builtInProp=function builtInProp(obj,name,val,config){return Object.defineProperty(obj,name,{value:val,writable:true,configurable:config!==false});};}catch(err){builtInProp=function builtInProp(obj,name,val){obj[name]=val;return obj;};}// Note: using a queue instead of array for efficiency
+scheduling_queue=function Queue(){var first,last,item;function Item(fn,self){this.fn=fn;this.self=self;this.next=void 0;}return{add:function add(fn,self){item=new Item(fn,self);if(last){last.next=item;}else{first=item;}last=item;item=void 0;},drain:function drain(){var f=first;first=last=cycle=void 0;while(f){f.fn.call(f.self);f=f.next;}}};}();function schedule(fn,self){scheduling_queue.add(fn,self);if(!cycle){cycle=timer(scheduling_queue.drain);}}// promise duck typing
+function isThenable(o){var _then,o_type=typeof o==="undefined"?"undefined":_typeof(o);if(o!=null&&(o_type=="object"||o_type=="function")){_then=o.then;}return typeof _then=="function"?_then:false;}function notify(){for(var i=0;i<this.chain.length;i++){notifyIsolated(this,this.state===1?this.chain[i].success:this.chain[i].failure,this.chain[i]);}this.chain.length=0;}// NOTE: This is a separate function to isolate
+// the `try..catch` so that other code can be
+// optimized better
+function notifyIsolated(self,cb,chain){var ret,_then;try{if(cb===false){chain.reject(self.msg);}else{if(cb===true){ret=self.msg;}else{ret=cb.call(void 0,self.msg);}if(ret===chain.promise){chain.reject(TypeError("Promise-chain cycle"));}else if(_then=isThenable(ret)){_then.call(ret,chain.resolve,chain.reject);}else{chain.resolve(ret);}}}catch(err){chain.reject(err);}}function resolve(msg){var _then,self=this;// already triggered?
+if(self.triggered){return;}self.triggered=true;// unwrap
+if(self.def){self=self.def;}try{if(_then=isThenable(msg)){schedule(function(){var def_wrapper=new MakeDefWrapper(self);try{_then.call(msg,function $resolve$(){resolve.apply(def_wrapper,arguments);},function $reject$(){reject.apply(def_wrapper,arguments);});}catch(err){reject.call(def_wrapper,err);}});}else{self.msg=msg;self.state=1;if(self.chain.length>0){schedule(notify,self);}}}catch(err){reject.call(new MakeDefWrapper(self),err);}}function reject(msg){var self=this;// already triggered?
+if(self.triggered){return;}self.triggered=true;// unwrap
+if(self.def){self=self.def;}self.msg=msg;self.state=2;if(self.chain.length>0){schedule(notify,self);}}function iteratePromises(Constructor,arr,resolver,rejecter){for(var idx=0;idx<arr.length;idx++){(function IIFE(idx){Constructor.resolve(arr[idx]).then(function $resolver$(msg){resolver(idx,msg);},rejecter);})(idx);}}function MakeDefWrapper(self){this.def=self;this.triggered=false;}function MakeDef(self){this.promise=self;this.state=0;this.triggered=false;this.chain=[];this.msg=void 0;}function Promise(executor){if(typeof executor!="function"){throw TypeError("Not a function");}if(this.__NPO__!==0){throw TypeError("Not a promise");}// instance shadowing the inherited "brand"
+// to signal an already "initialized" promise
+this.__NPO__=1;var def=new MakeDef(this);this["then"]=function then(success,failure){var o={success:typeof success=="function"?success:true,failure:typeof failure=="function"?failure:false};// Note: `then(..)` itself can be borrowed to be used against
+// a different promise constructor for making the chained promise,
+// by substituting a different `this` binding.
+o.promise=new this.constructor(function extractChain(resolve,reject){if(typeof resolve!="function"||typeof reject!="function"){throw TypeError("Not a function");}o.resolve=resolve;o.reject=reject;});def.chain.push(o);if(def.state!==0){schedule(notify,def);}return o.promise;};this["catch"]=function $catch$(failure){return this.then(void 0,failure);};try{executor.call(void 0,function publicResolve(msg){resolve.call(def,msg);},function publicReject(msg){reject.call(def,msg);});}catch(err){reject.call(def,err);}}var PromisePrototype=builtInProp({},"constructor",Promise,/*configurable=*/false);// Note: Android 4 cannot use `Object.defineProperty(..)` here
+Promise.prototype=PromisePrototype;// built-in "brand" to signal an "uninitialized" promise
+builtInProp(PromisePrototype,"__NPO__",0,/*configurable=*/false);builtInProp(Promise,"resolve",function Promise$resolve(msg){var Constructor=this;// spec mandated checks
+// note: best "isPromise" check that's practical for now
+if(msg&&(typeof msg==="undefined"?"undefined":_typeof(msg))=="object"&&msg.__NPO__===1){return msg;}return new Constructor(function executor(resolve,reject){if(typeof resolve!="function"||typeof reject!="function"){throw TypeError("Not a function");}resolve(msg);});});builtInProp(Promise,"reject",function Promise$reject(msg){return new this(function executor(resolve,reject){if(typeof resolve!="function"||typeof reject!="function"){throw TypeError("Not a function");}reject(msg);});});builtInProp(Promise,"all",function Promise$all(arr){var Constructor=this;// spec mandated checks
+if(ToString.call(arr)!="[object Array]"){return Constructor.reject(TypeError("Not an array"));}if(arr.length===0){return Constructor.resolve([]);}return new Constructor(function executor(resolve,reject){if(typeof resolve!="function"||typeof reject!="function"){throw TypeError("Not a function");}var len=arr.length,msgs=Array(len),count=0;iteratePromises(Constructor,arr,function resolver(idx,msg){msgs[idx]=msg;if(++count===len){resolve(msgs);}},reject);});});builtInProp(Promise,"race",function Promise$race(arr){var Constructor=this;// spec mandated checks
+if(ToString.call(arr)!="[object Array]"){return Constructor.reject(TypeError("Not an array"));}return new Constructor(function executor(resolve,reject){if(typeof resolve!="function"||typeof reject!="function"){throw TypeError("Not a function");}iteratePromises(Constructor,arr,function resolver(idx,msg){resolve(msg);},reject);});});return Promise;});}).call(this,typeof global!=="undefined"?global:typeof self!=="undefined"?self:typeof window!=="undefined"?window:{});},{}],4:[function(require,module,exports){(function(process){// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+// resolves . and .. elements in a path array with directory names there
+// must be no slashes, empty elements, or device names (c:\) in the array
+// (so also no leading and trailing slashes - it does not distinguish
+// relative and absolute paths)
+function normalizeArray(parts,allowAboveRoot){// if the path tries to go above the root, `up` ends up > 0
+var up=0;for(var i=parts.length-1;i>=0;i--){var last=parts[i];if(last==='.'){parts.splice(i,1);}else if(last==='..'){parts.splice(i,1);up++;}else if(up){parts.splice(i,1);up--;}}// if the path is allowed to go above the root, restore leading ..s
+if(allowAboveRoot){for(;up--;up){parts.unshift('..');}}return parts;}// Split a filename into [root, dir, basename, ext], unix version
+// 'root' is just a slash, or nothing.
+var splitPathRe=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/;var splitPath=function splitPath(filename){return splitPathRe.exec(filename).slice(1);};// path.resolve([from ...], to)
+// posix version
+exports.resolve=function(){var resolvedPath='',resolvedAbsolute=false;for(var i=arguments.length-1;i>=-1&&!resolvedAbsolute;i--){var path=i>=0?arguments[i]:process.cwd();// Skip empty and invalid entries
+if(typeof path!=='string'){throw new TypeError('Arguments to path.resolve must be strings');}else if(!path){continue;}resolvedPath=path+'/'+resolvedPath;resolvedAbsolute=path.charAt(0)==='/';}// At this point the path should be resolved to a full absolute path, but
+// handle relative paths to be safe (might happen when process.cwd() fails)
+// Normalize the path
+resolvedPath=normalizeArray(filter(resolvedPath.split('/'),function(p){return!!p;}),!resolvedAbsolute).join('/');return(resolvedAbsolute?'/':'')+resolvedPath||'.';};// path.normalize(path)
+// posix version
+exports.normalize=function(path){var isAbsolute=exports.isAbsolute(path),trailingSlash=substr(path,-1)==='/';// Normalize the path
+path=normalizeArray(filter(path.split('/'),function(p){return!!p;}),!isAbsolute).join('/');if(!path&&!isAbsolute){path='.';}if(path&&trailingSlash){path+='/';}return(isAbsolute?'/':'')+path;};// posix version
+exports.isAbsolute=function(path){return path.charAt(0)==='/';};// posix version
+exports.join=function(){var paths=Array.prototype.slice.call(arguments,0);return exports.normalize(filter(paths,function(p,index){if(typeof p!=='string'){throw new TypeError('Arguments to path.join must be strings');}return p;}).join('/'));};// path.relative(from, to)
+// posix version
+exports.relative=function(from,to){from=exports.resolve(from).substr(1);to=exports.resolve(to).substr(1);function trim(arr){var start=0;for(;start<arr.length;start++){if(arr[start]!=='')break;}var end=arr.length-1;for(;end>=0;end--){if(arr[end]!=='')break;}if(start>end)return[];return arr.slice(start,end-start+1);}var fromParts=trim(from.split('/'));var toParts=trim(to.split('/'));var length=Math.min(fromParts.length,toParts.length);var samePartsLength=length;for(var i=0;i<length;i++){if(fromParts[i]!==toParts[i]){samePartsLength=i;break;}}var outputParts=[];for(var i=samePartsLength;i<fromParts.length;i++){outputParts.push('..');}outputParts=outputParts.concat(toParts.slice(samePartsLength));return outputParts.join('/');};exports.sep='/';exports.delimiter=':';exports.dirname=function(path){var result=splitPath(path),root=result[0],dir=result[1];if(!root&&!dir){// No dirname whatsoever
+return'.';}if(dir){// It has a dirname, strip trailing slash
+dir=dir.substr(0,dir.length-1);}return root+dir;};exports.basename=function(path,ext){var f=splitPath(path)[2];// TODO: make this comparison case-insensitive on windows?
+if(ext&&f.substr(-1*ext.length)===ext){f=f.substr(0,f.length-ext.length);}return f;};exports.extname=function(path){return splitPath(path)[3];};function filter(xs,f){if(xs.filter)return xs.filter(f);var res=[];for(var i=0;i<xs.length;i++){if(f(xs[i],i,xs))res.push(xs[i]);}return res;}// String.prototype.substr - negative index don't work in IE8
+var substr='ab'.substr(-1)==='b'?function(str,start,len){return str.substr(start,len);}:function(str,start,len){if(start<0)start=str.length+start;return str.substr(start,len);};}).call(this,require('_process'));},{"_process":8}],5:[function(require,module,exports){/*
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 Jeremy Whitlock
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ * THE SOFTWARE.
+ */'use strict';/**
+ * Utility that provides a single API for loading the content of a path/URL.
+ *
+ * @module PathLoader
+ */var supportedLoaders={file:require('./lib/loaders/file'),http:require('./lib/loaders/http'),https:require('./lib/loaders/http')};var defaultLoader=(typeof window==="undefined"?"undefined":_typeof(window))==='object'||typeof importScripts==='function'?supportedLoaders.http:supportedLoaders.file;// Load promises polyfill if necessary
+/* istanbul ignore if */if(typeof Promise==='undefined'){require('native-promise-only');}function getScheme(location){if(typeof location!=='undefined'){location=location.indexOf('://')===-1?'':location.split('://')[0];}return location;}/**
+ * Callback used to provide access to altering a remote request prior to the request being made.
+ *
+ * @typedef {function} PrepareRequestCallback
+ *
+ * @param {object} req - The Superagent request object
+ * @param {string} location - The location being retrieved
+ * @param {function} callback - First callback
+ *
+ * @alias module:PathLoader~PrepareRequestCallback
+ *//**
+  * Callback used to provide access to processing the raw response of the request being made. *(HTTP loader only)*
+  *
+  * @typedef {function} ProcessResponseCallback
+  *
+  * @param {object} res - The Superagent response object *(For non-HTTP loaders, this object will be like the Superagent
+  * object in that it will have a `text` property whose value is the raw string value being processed.  This was done
+  * for consistency.)*
+  * @param {function} callback - Error-first callback
+  *
+  * @returns {*} the result of processing the responsexs
+  *
+  * @alias module:PathLoader~ProcessResponseCallback
+  */function getLoader(location){var scheme=getScheme(location);var loader=supportedLoaders[scheme];if(typeof loader==='undefined'){if(scheme===''){loader=defaultLoader;}else{throw new Error('Unsupported scheme: '+scheme);}}return loader;}/**
+ * Loads a document at the provided location and returns a JavaScript object representation.
+ *
+ * @param {object} location - The location to the document
+ * @param {object} [options] - The options
+ * @param {string} [options.encoding='utf-8'] - The encoding to use when loading the file *(File loader only)*
+ * @param {string} [options.method=get] - The HTTP method to use for the request *(HTTP loader only)*
+ * @param {module:PathLoader~PrepareRequestCallback} [options.prepareRequest] - The callback used to prepare the request
+ * *(HTTP loader only)*
+ * @param {module:PathLoader~ProcessResponseCallback} [options.processContent] - The callback used to process the
+ * response
+ *
+ * @returns {Promise} Always returns a promise even if there is a callback provided
+ *
+ * @example
+ * // Example using Promises
+ *
+ * PathLoader
+ *   .load('./package.json')
+ *   .then(JSON.parse)
+ *   .then(function (document) {
+ *     console.log(document.name + ' (' + document.version + '): ' + document.description);
+ *   }, function (err) {
+ *     console.error(err.stack);
+ *   });
+ *
+ * @example
+ * // Example using options.prepareRequest to provide authentication details for a remotely secure URL
+ *
+ * PathLoader
+ *   .load('https://api.github.com/repos/whitlockjc/path-loader', {
+ *     prepareRequest: function (req, callback) {
+ *       req.auth('my-username', 'my-password');
+ *       callback(undefined, req);
+ *     }
+ *   })
+ *   .then(JSON.parse)
+ *   .then(function (document) {
+ *     console.log(document.full_name + ': ' + document.description);
+ *   }, function (err) {
+ *     console.error(err.stack);
+ *   });
+ *
+ * @example
+ * // Example loading a YAML file
+ *
+ * PathLoader
+ *   .load('/Users/not-you/projects/path-loader/.travis.yml')
+ *   .then(YAML.safeLoad)
+ *   .then(function (document) {
+ *     console.log('path-loader uses the', document.language, 'language.');
+ *   }, function (err) {
+ *     console.error(err.stack);
+ *   });
+ *
+ * @example
+ * // Example loading a YAML file with options.processContent (Useful if you need information in the raw response)
+ *
+ * PathLoader
+ *   .load('/Users/not-you/projects/path-loader/.travis.yml', {
+ *     processContent: function (res, callback) {
+ *       callback(YAML.safeLoad(res.text));
+ *     }
+ *   })
+ *   .then(function (document) {
+ *     console.log('path-loader uses the', document.language, 'language.');
+ *   }, function (err) {
+ *     console.error(err.stack);
+ *   });
+ */module.exports.load=function(location,options){var allTasks=Promise.resolve();// Default options to empty object
+if(typeof options==='undefined'){options={};}// Validate arguments
+allTasks=allTasks.then(function(){if(typeof location==='undefined'){throw new TypeError('location is required');}else if(typeof location!=='string'){throw new TypeError('location must be a string');}if(typeof options!=='undefined'){if((typeof options==="undefined"?"undefined":_typeof(options))!=='object'){throw new TypeError('options must be an object');}else if(typeof options.processContent!=='undefined'&&typeof options.processContent!=='function'){throw new TypeError('options.processContent must be a function');}}});// Load the document from the provided location and process it
+allTasks=allTasks.then(function(){return new Promise(function(resolve,reject){var loader=getLoader(location);loader.load(location,options||{},function(err,document){if(err){reject(err);}else{resolve(document);}});});}).then(function(res){if(options.processContent){return new Promise(function(resolve,reject){// For consistency between file and http, always send an object with a 'text' property containing the raw
+// string value being processed.
+options.processContent((typeof res==="undefined"?"undefined":_typeof(res))==='object'?res:{text:res},function(err,processed){if(err){reject(err);}else{resolve(processed);}});});}else{// If there was no content processor, we will assume that for all objects that it is a Superagent response
+// and will return its `text` property value.  Otherwise, we will return the raw response.
+return(typeof res==="undefined"?"undefined":_typeof(res))==='object'?res.text:res;}});return allTasks;};},{"./lib/loaders/file":6,"./lib/loaders/http":7,"native-promise-only":3}],6:[function(require,module,exports){/*
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 Jeremy Whitlock
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ * THE SOFTWARE.
+ */'use strict';var unsupportedError=new TypeError('The \'file\' scheme is not supported in the browser');/**
+ * The file loader is not supported in the browser.
+ *
+ * @throws {error} the file loader is not supported in the browser
+ */module.exports.getBase=function(){throw unsupportedError;};/**
+ * The file loader is not supported in the browser.
+ */module.exports.load=function(){var fn=arguments[arguments.length-1];if(typeof fn==='function'){fn(unsupportedError);}else{throw unsupportedError;}};},{}],7:[function(require,module,exports){/* eslint-env node, browser *//*
+ * The MIT License (MIT)
+ *
+ * Copyright (c) 2015 Jeremy Whitlock
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ * THE SOFTWARE.
+ */'use strict';var request=require('superagent');var supportedHttpMethods=['delete','get','head','patch','post','put'];/**
+ * Loads a file from an http or https URL.
+ *
+ * @param {string} location - The document URL (If relative, location is relative to window.location.origin).
+ * @param {object} options - The loader options
+ * @param {string} [options.method=get] - The HTTP method to use for the request
+ * @param {module:PathLoader~PrepareRequestCallback} [options.prepareRequest] - The callback used to prepare a request
+ * @param {module:PathLoader~ProcessResponseCallback} [options.processContent] - The callback used to process the
+ * response
+ * @param {function} callback - The error-first callback
+ */module.exports.load=function(location,options,callback){var realMethod=options.method?options.method.toLowerCase():'get';var err;var realRequest;function makeRequest(err,req){if(err){callback(err);}else{// buffer() is only available in Node.js
+if(typeof req.buffer==='function'){req.buffer(true);}req.end(function(err2,res){if(err2){callback(err2);}else{callback(undefined,res);}});}}if(typeof options.method!=='undefined'){if(typeof options.method!=='string'){err=new TypeError('options.method must be a string');}else if(supportedHttpMethods.indexOf(options.method)===-1){err=new TypeError('options.method must be one of the following: '+supportedHttpMethods.slice(0,supportedHttpMethods.length-1).join(', ')+' or '+supportedHttpMethods[supportedHttpMethods.length-1]);}}else if(typeof options.prepareRequest!=='undefined'&&typeof options.prepareRequest!=='function'){err=new TypeError('options.prepareRequest must be a function');}if(!err){realRequest=request[realMethod==='delete'?'del':realMethod](location);if(options.prepareRequest){try{options.prepareRequest(realRequest,makeRequest);}catch(err2){callback(err2);}}else{makeRequest(undefined,realRequest);}}else{callback(err);}};},{"superagent":14}],8:[function(require,module,exports){// shim for using process in browser
+var process=module.exports={};var queue=[];var draining=false;var currentQueue;var queueIndex=-1;function cleanUpNextTick(){draining=false;if(currentQueue.length){queue=currentQueue.concat(queue);}else{queueIndex=-1;}if(queue.length){drainQueue();}}function drainQueue(){if(draining){return;}var timeout=setTimeout(cleanUpNextTick);draining=true;var len=queue.length;while(len){currentQueue=queue;queue=[];while(++queueIndex<len){if(currentQueue){currentQueue[queueIndex].run();}}queueIndex=-1;len=queue.length;}currentQueue=null;draining=false;clearTimeout(timeout);}process.nextTick=function(fun){var args=new Array(arguments.length-1);if(arguments.length>1){for(var i=1;i<arguments.length;i++){args[i-1]=arguments[i];}}queue.push(new Item(fun,args));if(queue.length===1&&!draining){setTimeout(drainQueue,0);}};// v8 likes predictible objects
+function Item(fun,array){this.fun=fun;this.array=array;}Item.prototype.run=function(){this.fun.apply(null,this.array);};process.title='browser';process.browser=true;process.env={};process.argv=[];process.version='';// empty string to avoid regexp issues
+process.versions={};function noop(){}process.on=noop;process.addListener=noop;process.once=noop;process.off=noop;process.removeListener=noop;process.removeAllListeners=noop;process.emit=noop;process.binding=function(name){throw new Error('process.binding is not supported');};process.cwd=function(){return'/';};process.chdir=function(dir){throw new Error('process.chdir is not supported');};process.umask=function(){return 0;};},{}],9:[function(require,module,exports){// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+'use strict';// If obj.hasOwnProperty has been overridden, then calling
+// obj.hasOwnProperty(prop) will break.
+// See: https://github.com/joyent/node/issues/1707
+function hasOwnProperty(obj,prop){return Object.prototype.hasOwnProperty.call(obj,prop);}module.exports=function(qs,sep,eq,options){sep=sep||'&';eq=eq||'=';var obj={};if(typeof qs!=='string'||qs.length===0){return obj;}var regexp=/\+/g;qs=qs.split(sep);var maxKeys=1000;if(options&&typeof options.maxKeys==='number'){maxKeys=options.maxKeys;}var len=qs.length;// maxKeys <= 0 means that we should not limit keys count
+if(maxKeys>0&&len>maxKeys){len=maxKeys;}for(var i=0;i<len;++i){var x=qs[i].replace(regexp,'%20'),idx=x.indexOf(eq),kstr,vstr,k,v;if(idx>=0){kstr=x.substr(0,idx);vstr=x.substr(idx+1);}else{kstr=x;vstr='';}k=decodeURIComponent(kstr);v=decodeURIComponent(vstr);if(!hasOwnProperty(obj,k)){obj[k]=v;}else if(isArray(obj[k])){obj[k].push(v);}else{obj[k]=[obj[k],v];}}return obj;};var isArray=Array.isArray||function(xs){return Object.prototype.toString.call(xs)==='[object Array]';};},{}],10:[function(require,module,exports){// Copyright Joyent, Inc. and other Node contributors.
+//
+// Permission is hereby granted, free of charge, to any person obtaining a
+// copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to permit
+// persons to whom the Software is furnished to do so, subject to the
+// following conditions:
+//
+// The above copyright notice and this permission notice shall be included
+// in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
+// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN
+// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
+// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR
+// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE
+// USE OR OTHER DEALINGS IN THE SOFTWARE.
+'use strict';var stringifyPrimitive=function stringifyPrimitive(v){switch(typeof v==="undefined"?"undefined":_typeof(v)){case'string':return v;case'boolean':return v?'true':'false';case'number':return isFinite(v)?v:'';default:return'';}};module.exports=function(obj,sep,eq,name){sep=sep||'&';eq=eq||'=';if(obj===null){obj=undefined;}if((typeof obj==="undefined"?"undefined":_typeof(obj))==='object'){return map(objectKeys(obj),function(k){var ks=encodeURIComponent(stringifyPrimitive(k))+eq;if(isArray(obj[k])){return map(obj[k],function(v){return ks+encodeURIComponent(stringifyPrimitive(v));}).join(sep);}else{return ks+encodeURIComponent(stringifyPrimitive(obj[k]));}}).join(sep);}if(!name)return'';return encodeURIComponent(stringifyPrimitive(name))+eq+encodeURIComponent(stringifyPrimitive(obj));};var isArray=Array.isArray||function(xs){return Object.prototype.toString.call(xs)==='[object Array]';};function map(xs,f){if(xs.map)return xs.map(f);var res=[];for(var i=0;i<xs.length;i++){res.push(f(xs[i],i));}return res;}var objectKeys=Object.keys||function(obj){var res=[];for(var key in obj){if(Object.prototype.hasOwnProperty.call(obj,key))res.push(key);}return res;};},{}],11:[function(require,module,exports){'use strict';exports.decode=exports.parse=require('./decode');exports.encode=exports.stringify=require('./encode');},{"./decode":9,"./encode":10}],12:[function(require,module,exports){/**
+ * Reduce `arr` with `fn`.
+ *
+ * @param {Array} arr
+ * @param {Function} fn
+ * @param {Mixed} initial
+ *
+ * TODO: combatible error handling?
+ */module.exports=function(arr,fn,initial){var idx=0;var len=arr.length;var curr=arguments.length==3?initial:arr[idx++];while(idx<len){curr=fn.call(null,curr,arr[idx],++idx,arr);}return curr;};},{}],13:[function(require,module,exports){'use strict';module.exports=function(str){var isExtendedLengthPath=/^\\\\\?\\/.test(str);var hasNonAscii=/[^\x00-\x80]+/.test(str);if(isExtendedLengthPath||hasNonAscii){return str;}return str.replace(/\\/g,'/');};},{}],14:[function(require,module,exports){/**
+ * Module dependencies.
+ */var Emitter=require('emitter');var reduce=require('reduce');var requestBase=require('./request-base');var isObject=require('./is-object');/**
+ * Root reference for iframes.
+ */var root;if(typeof window!=='undefined'){// Browser window
+root=window;}else if(typeof self!=='undefined'){// Web Worker
+root=self;}else{// Other environments
+root=this;}/**
+ * Noop.
+ */function noop(){};/**
+ * Check if `obj` is a host object,
+ * we don't want to serialize these :)
+ *
+ * TODO: future proof, move to compoent land
+ *
+ * @param {Object} obj
+ * @return {Boolean}
+ * @api private
+ */function isHost(obj){var str={}.toString.call(obj);switch(str){case'[object File]':case'[object Blob]':case'[object FormData]':return true;default:return false;}}/**
+ * Expose `request`.
+ */var request=module.exports=require('./request').bind(null,Request);/**
+ * Determine XHR.
+ */request.getXHR=function(){if(root.XMLHttpRequest&&(!root.location||'file:'!=root.location.protocol||!root.ActiveXObject)){return new XMLHttpRequest();}else{try{return new ActiveXObject('Microsoft.XMLHTTP');}catch(e){}try{return new ActiveXObject('Msxml2.XMLHTTP.6.0');}catch(e){}try{return new ActiveXObject('Msxml2.XMLHTTP.3.0');}catch(e){}try{return new ActiveXObject('Msxml2.XMLHTTP');}catch(e){}}return false;};/**
+ * Removes leading and trailing whitespace, added to support IE.
+ *
+ * @param {String} s
+ * @return {String}
+ * @api private
+ */var trim=''.trim?function(s){return s.trim();}:function(s){return s.replace(/(^\s*|\s*$)/g,'');};/**
+ * Serialize the given `obj`.
+ *
+ * @param {Object} obj
+ * @return {String}
+ * @api private
+ */function serialize(obj){if(!isObject(obj))return obj;var pairs=[];for(var key in obj){if(null!=obj[key]){pushEncodedKeyValuePair(pairs,key,obj[key]);}}return pairs.join('&');}/**
+ * Helps 'serialize' with serializing arrays.
+ * Mutates the pairs array.
+ *
+ * @param {Array} pairs
+ * @param {String} key
+ * @param {Mixed} val
+ */function pushEncodedKeyValuePair(pairs,key,val){if(Array.isArray(val)){return val.forEach(function(v){pushEncodedKeyValuePair(pairs,key,v);});}pairs.push(encodeURIComponent(key)+'='+encodeURIComponent(val));}/**
+ * Expose serialization method.
+ */request.serializeObject=serialize;/**
+  * Parse the given x-www-form-urlencoded `str`.
+  *
+  * @param {String} str
+  * @return {Object}
+  * @api private
+  */function parseString(str){var obj={};var pairs=str.split('&');var parts;var pair;for(var i=0,len=pairs.length;i<len;++i){pair=pairs[i];parts=pair.split('=');obj[decodeURIComponent(parts[0])]=decodeURIComponent(parts[1]);}return obj;}/**
+ * Expose parser.
+ */request.parseString=parseString;/**
+ * Default MIME type map.
+ *
+ *     superagent.types.xml = 'application/xml';
+ *
+ */request.types={html:'text/html',json:'application/json',xml:'application/xml',urlencoded:'application/x-www-form-urlencoded','form':'application/x-www-form-urlencoded','form-data':'application/x-www-form-urlencoded'};/**
+ * Default serialization map.
+ *
+ *     superagent.serialize['application/xml'] = function(obj){
+ *       return 'generated xml here';
+ *     };
+ *
+ */request.serialize={'application/x-www-form-urlencoded':serialize,'application/json':JSON.stringify};/**
+  * Default parsers.
+  *
+  *     superagent.parse['application/xml'] = function(str){
+  *       return { object parsed from str };
+  *     };
+  *
+  */request.parse={'application/x-www-form-urlencoded':parseString,'application/json':JSON.parse};/**
+ * Parse the given header `str` into
+ * an object containing the mapped fields.
+ *
+ * @param {String} str
+ * @return {Object}
+ * @api private
+ */function parseHeader(str){var lines=str.split(/\r?\n/);var fields={};var index;var line;var field;var val;lines.pop();// trailing CRLF
+for(var i=0,len=lines.length;i<len;++i){line=lines[i];index=line.indexOf(':');field=line.slice(0,index).toLowerCase();val=trim(line.slice(index+1));fields[field]=val;}return fields;}/**
+ * Check if `mime` is json or has +json structured syntax suffix.
+ *
+ * @param {String} mime
+ * @return {Boolean}
+ * @api private
+ */function isJSON(mime){return /[\/+]json\b/.test(mime);}/**
+ * Return the mime type for the given `str`.
+ *
+ * @param {String} str
+ * @return {String}
+ * @api private
+ */function type(str){return str.split(/ *; */).shift();};/**
+ * Return header field parameters.
+ *
+ * @param {String} str
+ * @return {Object}
+ * @api private
+ */function params(str){return reduce(str.split(/ *; */),function(obj,str){var parts=str.split(/ *= */),key=parts.shift(),val=parts.shift();if(key&&val)obj[key]=val;return obj;},{});};/**
+ * Initialize a new `Response` with the given `xhr`.
+ *
+ *  - set flags (.ok, .error, etc)
+ *  - parse header
+ *
+ * Examples:
+ *
+ *  Aliasing `superagent` as `request` is nice:
+ *
+ *      request = superagent;
+ *
+ *  We can use the promise-like API, or pass callbacks:
+ *
+ *      request.get('/').end(function(res){});
+ *      request.get('/', function(res){});
+ *
+ *  Sending data can be chained:
+ *
+ *      request
+ *        .post('/user')
+ *        .send({ name: 'tj' })
+ *        .end(function(res){});
+ *
+ *  Or passed to `.send()`:
+ *
+ *      request
+ *        .post('/user')
+ *        .send({ name: 'tj' }, function(res){});
+ *
+ *  Or passed to `.post()`:
+ *
+ *      request
+ *        .post('/user', { name: 'tj' })
+ *        .end(function(res){});
+ *
+ * Or further reduced to a single call for simple cases:
+ *
+ *      request
+ *        .post('/user', { name: 'tj' }, function(res){});
+ *
+ * @param {XMLHTTPRequest} xhr
+ * @param {Object} options
+ * @api private
+ */function Response(req,options){options=options||{};this.req=req;this.xhr=this.req.xhr;// responseText is accessible only if responseType is '' or 'text' and on older browsers
+this.text=this.req.method!='HEAD'&&(this.xhr.responseType===''||this.xhr.responseType==='text')||typeof this.xhr.responseType==='undefined'?this.xhr.responseText:null;this.statusText=this.req.xhr.statusText;this.setStatusProperties(this.xhr.status);this.header=this.headers=parseHeader(this.xhr.getAllResponseHeaders());// getAllResponseHeaders sometimes falsely returns "" for CORS requests, but
+// getResponseHeader still works. so we get content-type even if getting
+// other headers fails.
+this.header['content-type']=this.xhr.getResponseHeader('content-type');this.setHeaderProperties(this.header);this.body=this.req.method!='HEAD'?this.parseBody(this.text?this.text:this.xhr.response):null;}/**
+ * Get case-insensitive `field` value.
+ *
+ * @param {String} field
+ * @return {String}
+ * @api public
+ */Response.prototype.get=function(field){return this.header[field.toLowerCase()];};/**
+ * Set header related properties:
+ *
+ *   - `.type` the content type without params
+ *
+ * A response of "Content-Type: text/plain; charset=utf-8"
+ * will provide you with a `.type` of "text/plain".
+ *
+ * @param {Object} header
+ * @api private
+ */Response.prototype.setHeaderProperties=function(header){// content-type
+var ct=this.header['content-type']||'';this.type=type(ct);// params
+var obj=params(ct);for(var key in obj){this[key]=obj[key];}};/**
+ * Parse the given body `str`.
+ *
+ * Used for auto-parsing of bodies. Parsers
+ * are defined on the `superagent.parse` object.
+ *
+ * @param {String} str
+ * @return {Mixed}
+ * @api private
+ */Response.prototype.parseBody=function(str){var parse=request.parse[this.type];if(!parse&&isJSON(this.type)){parse=request.parse['application/json'];}return parse&&str&&(str.length||str instanceof Object)?parse(str):null;};/**
+ * Set flags such as `.ok` based on `status`.
+ *
+ * For example a 2xx response will give you a `.ok` of __true__
+ * whereas 5xx will be __false__ and `.error` will be __true__. The
+ * `.clientError` and `.serverError` are also available to be more
+ * specific, and `.statusType` is the class of error ranging from 1..5
+ * sometimes useful for mapping respond colors etc.
+ *
+ * "sugar" properties are also defined for common cases. Currently providing:
+ *
+ *   - .noContent
+ *   - .badRequest
+ *   - .unauthorized
+ *   - .notAcceptable
+ *   - .notFound
+ *
+ * @param {Number} status
+ * @api private
+ */Response.prototype.setStatusProperties=function(status){// handle IE9 bug: http://stackoverflow.com/questions/10046972/msie-returns-status-code-of-1223-for-ajax-request
+if(status===1223){status=204;}var type=status/100|0;// status / class
+this.status=this.statusCode=status;this.statusType=type;// basics
+this.info=1==type;this.ok=2==type;this.clientError=4==type;this.serverError=5==type;this.error=4==type||5==type?this.toError():false;// sugar
+this.accepted=202==status;this.noContent=204==status;this.badRequest=400==status;this.unauthorized=401==status;this.notAcceptable=406==status;this.notFound=404==status;this.forbidden=403==status;};/**
+ * Return an `Error` representative of this response.
+ *
+ * @return {Error}
+ * @api public
+ */Response.prototype.toError=function(){var req=this.req;var method=req.method;var url=req.url;var msg='cannot '+method+' '+url+' ('+this.status+')';var err=new Error(msg);err.status=this.status;err.method=method;err.url=url;return err;};/**
+ * Expose `Response`.
+ */request.Response=Response;/**
+ * Initialize a new `Request` with the given `method` and `url`.
+ *
+ * @param {String} method
+ * @param {String} url
+ * @api public
+ */function Request(method,url){var self=this;this._query=this._query||[];this.method=method;this.url=url;this.header={};// preserves header name case
+this._header={};// coerces header names to lowercase
+this.on('end',function(){var err=null;var res=null;try{res=new Response(self);}catch(e){err=new Error('Parser is unable to parse the response');err.parse=true;err.original=e;// issue #675: return the raw response if the response parsing fails
+err.rawResponse=self.xhr&&self.xhr.responseText?self.xhr.responseText:null;// issue #876: return the http status code if the response parsing fails
+err.statusCode=self.xhr&&self.xhr.status?self.xhr.status:null;return self.callback(err);}self.emit('response',res);if(err){return self.callback(err,res);}if(res.status>=200&&res.status<300){return self.callback(err,res);}var new_err=new Error(res.statusText||'Unsuccessful HTTP response');new_err.original=err;new_err.response=res;new_err.status=res.status;self.callback(new_err,res);});}/**
+ * Mixin `Emitter` and `requestBase`.
+ */Emitter(Request.prototype);for(var key in requestBase){Request.prototype[key]=requestBase[key];}/**
+ * Abort the request, and clear potential timeout.
+ *
+ * @return {Request}
+ * @api public
+ */Request.prototype.abort=function(){if(this.aborted)return;this.aborted=true;this.xhr.abort();this.clearTimeout();this.emit('abort');return this;};/**
+ * Set Content-Type to `type`, mapping values from `request.types`.
+ *
+ * Examples:
+ *
+ *      superagent.types.xml = 'application/xml';
+ *
+ *      request.post('/')
+ *        .type('xml')
+ *        .send(xmlstring)
+ *        .end(callback);
+ *
+ *      request.post('/')
+ *        .type('application/xml')
+ *        .send(xmlstring)
+ *        .end(callback);
+ *
+ * @param {String} type
+ * @return {Request} for chaining
+ * @api public
+ */Request.prototype.type=function(type){this.set('Content-Type',request.types[type]||type);return this;};/**
+ * Set responseType to `val`. Presently valid responseTypes are 'blob' and 
+ * 'arraybuffer'.
+ *
+ * Examples:
+ *
+ *      req.get('/')
+ *        .responseType('blob')
+ *        .end(callback);
+ *
+ * @param {String} val
+ * @return {Request} for chaining
+ * @api public
+ */Request.prototype.responseType=function(val){this._responseType=val;return this;};/**
+ * Set Accept to `type`, mapping values from `request.types`.
+ *
+ * Examples:
+ *
+ *      superagent.types.json = 'application/json';
+ *
+ *      request.get('/agent')
+ *        .accept('json')
+ *        .end(callback);
+ *
+ *      request.get('/agent')
+ *        .accept('application/json')
+ *        .end(callback);
+ *
+ * @param {String} accept
+ * @return {Request} for chaining
+ * @api public
+ */Request.prototype.accept=function(type){this.set('Accept',request.types[type]||type);return this;};/**
+ * Set Authorization field value with `user` and `pass`.
+ *
+ * @param {String} user
+ * @param {String} pass
+ * @param {Object} options with 'type' property 'auto' or 'basic' (default 'basic')
+ * @return {Request} for chaining
+ * @api public
+ */Request.prototype.auth=function(user,pass,options){if(!options){options={type:'basic'};}switch(options.type){case'basic':var str=btoa(user+':'+pass);this.set('Authorization','Basic '+str);break;case'auto':this.username=user;this.password=pass;break;}return this;};/**
+* Add query-string `val`.
+*
+* Examples:
+*
+*   request.get('/shoes')
+*     .query('size=10')
+*     .query({ color: 'blue' })
+*
+* @param {Object|String} val
+* @return {Request} for chaining
+* @api public
+*/Request.prototype.query=function(val){if('string'!=typeof val)val=serialize(val);if(val)this._query.push(val);return this;};/**
+ * Queue the given `file` as an attachment to the specified `field`,
+ * with optional `filename`.
+ *
+ * ``` js
+ * request.post('/upload')
+ *   .attach(new Blob(['<a id="a"><b id="b">hey!</b></a>'], { type: "text/html"}))
+ *   .end(callback);
+ * ```
+ *
+ * @param {String} field
+ * @param {Blob|File} file
+ * @param {String} filename
+ * @return {Request} for chaining
+ * @api public
+ */Request.prototype.attach=function(field,file,filename){this._getFormData().append(field,file,filename||file.name);return this;};Request.prototype._getFormData=function(){if(!this._formData){this._formData=new root.FormData();}return this._formData;};/**
+ * Send `data` as the request body, defaulting the `.type()` to "json" when
+ * an object is given.
+ *
+ * Examples:
+ *
+ *       // manual json
+ *       request.post('/user')
+ *         .type('json')
+ *         .send('{"name":"tj"}')
+ *         .end(callback)
+ *
+ *       // auto json
+ *       request.post('/user')
+ *         .send({ name: 'tj' })
+ *         .end(callback)
+ *
+ *       // manual x-www-form-urlencoded
+ *       request.post('/user')
+ *         .type('form')
+ *         .send('name=tj')
+ *         .end(callback)
+ *
+ *       // auto x-www-form-urlencoded
+ *       request.post('/user')
+ *         .type('form')
+ *         .send({ name: 'tj' })
+ *         .end(callback)
+ *
+ *       // defaults to x-www-form-urlencoded
+  *      request.post('/user')
+  *        .send('name=tobi')
+  *        .send('species=ferret')
+  *        .end(callback)
+ *
+ * @param {String|Object} data
+ * @return {Request} for chaining
+ * @api public
+ */Request.prototype.send=function(data){var obj=isObject(data);var type=this._header['content-type'];// merge
+if(obj&&isObject(this._data)){for(var key in data){this._data[key]=data[key];}}else if('string'==typeof data){if(!type)this.type('form');type=this._header['content-type'];if('application/x-www-form-urlencoded'==type){this._data=this._data?this._data+'&'+data:data;}else{this._data=(this._data||'')+data;}}else{this._data=data;}if(!obj||isHost(data))return this;if(!type)this.type('json');return this;};/**
+ * @deprecated
+ */Response.prototype.parse=function serialize(fn){if(root.console){console.warn("Client-side parse() method has been renamed to serialize(). This method is not compatible with superagent v2.0");}this.serialize(fn);return this;};Response.prototype.serialize=function serialize(fn){this._parser=fn;return this;};/**
+ * Invoke the callback with `err` and `res`
+ * and handle arity check.
+ *
+ * @param {Error} err
+ * @param {Response} res
+ * @api private
+ */Request.prototype.callback=function(err,res){var fn=this._callback;this.clearTimeout();fn(err,res);};/**
+ * Invoke callback with x-domain error.
+ *
+ * @api private
+ */Request.prototype.crossDomainError=function(){var err=new Error('Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.');err.crossDomain=true;err.status=this.status;err.method=this.method;err.url=this.url;this.callback(err);};/**
+ * Invoke callback with timeout error.
+ *
+ * @api private
+ */Request.prototype.timeoutError=function(){var timeout=this._timeout;var err=new Error('timeout of '+timeout+'ms exceeded');err.timeout=timeout;this.callback(err);};/**
+ * Enable transmission of cookies with x-domain requests.
+ *
+ * Note that for this to work the origin must not be
+ * using "Access-Control-Allow-Origin" with a wildcard,
+ * and also must set "Access-Control-Allow-Credentials"
+ * to "true".
+ *
+ * @api public
+ */Request.prototype.withCredentials=function(){this._withCredentials=true;return this;};/**
+ * Initiate request, invoking callback `fn(res)`
+ * with an instanceof `Response`.
+ *
+ * @param {Function} fn
+ * @return {Request} for chaining
+ * @api public
+ */Request.prototype.end=function(fn){var self=this;var xhr=this.xhr=request.getXHR();var query=this._query.join('&');var timeout=this._timeout;var data=this._formData||this._data;// store callback
+this._callback=fn||noop;// state change
+xhr.onreadystatechange=function(){if(4!=xhr.readyState)return;// In IE9, reads to any property (e.g. status) off of an aborted XHR will
+// result in the error "Could not complete the operation due to error c00c023f"
+var status;try{status=xhr.status;}catch(e){status=0;}if(0==status){if(self.timedout)return self.timeoutError();if(self.aborted)return;return self.crossDomainError();}self.emit('end');};// progress
+var handleProgress=function handleProgress(e){if(e.total>0){e.percent=e.loaded/e.total*100;}e.direction='download';self.emit('progress',e);};if(this.hasListeners('progress')){xhr.onprogress=handleProgress;}try{if(xhr.upload&&this.hasListeners('progress')){xhr.upload.onprogress=handleProgress;}}catch(e){}// Accessing xhr.upload fails in IE from a web worker, so just pretend it doesn't exist.
+// Reported here:
+// https://connect.microsoft.com/IE/feedback/details/837245/xmlhttprequest-upload-throws-invalid-argument-when-used-from-web-worker-context
+// timeout
+if(timeout&&!this._timer){this._timer=setTimeout(function(){self.timedout=true;self.abort();},timeout);}// querystring
+if(query){query=request.serializeObject(query);this.url+=~this.url.indexOf('?')?'&'+query:'?'+query;}// initiate request
+if(this.username&&this.password){xhr.open(this.method,this.url,true,this.username,this.password);}else{xhr.open(this.method,this.url,true);}// CORS
+if(this._withCredentials)xhr.withCredentials=true;// body
+if('GET'!=this.method&&'HEAD'!=this.method&&'string'!=typeof data&&!isHost(data)){// serialize stuff
+var contentType=this._header['content-type'];var serialize=this._parser||request.serialize[contentType?contentType.split(';')[0]:''];if(!serialize&&isJSON(contentType))serialize=request.serialize['application/json'];if(serialize)data=serialize(data);}// set header fields
+for(var field in this.header){if(null==this.header[field])continue;xhr.setRequestHeader(field,this.header[field]);}if(this._responseType){xhr.responseType=this._responseType;}// send stuff
+this.emit('request',this);// IE11 xhr.send(undefined) sends 'undefined' string as POST payload (instead of nothing)
+// We need null here if data is undefined
+xhr.send(typeof data!=='undefined'?data:null);return this;};/**
+ * Expose `Request`.
+ */request.Request=Request;/**
+ * GET `url` with optional callback `fn(res)`.
+ *
+ * @param {String} url
+ * @param {Mixed|Function} data or fn
+ * @param {Function} fn
+ * @return {Request}
+ * @api public
+ */request.get=function(url,data,fn){var req=request('GET',url);if('function'==typeof data)fn=data,data=null;if(data)req.query(data);if(fn)req.end(fn);return req;};/**
+ * HEAD `url` with optional callback `fn(res)`.
+ *
+ * @param {String} url
+ * @param {Mixed|Function} data or fn
+ * @param {Function} fn
+ * @return {Request}
+ * @api public
+ */request.head=function(url,data,fn){var req=request('HEAD',url);if('function'==typeof data)fn=data,data=null;if(data)req.send(data);if(fn)req.end(fn);return req;};/**
+ * DELETE `url` with optional callback `fn(res)`.
+ *
+ * @param {String} url
+ * @param {Function} fn
+ * @return {Request}
+ * @api public
+ */function del(url,fn){var req=request('DELETE',url);if(fn)req.end(fn);return req;};request['del']=del;request['delete']=del;/**
+ * PATCH `url` with optional `data` and callback `fn(res)`.
+ *
+ * @param {String} url
+ * @param {Mixed} data
+ * @param {Function} fn
+ * @return {Request}
+ * @api public
+ */request.patch=function(url,data,fn){var req=request('PATCH',url);if('function'==typeof data)fn=data,data=null;if(data)req.send(data);if(fn)req.end(fn);return req;};/**
+ * POST `url` with optional `data` and callback `fn(res)`.
+ *
+ * @param {String} url
+ * @param {Mixed} data
+ * @param {Function} fn
+ * @return {Request}
+ * @api public
+ */request.post=function(url,data,fn){var req=request('POST',url);if('function'==typeof data)fn=data,data=null;if(data)req.send(data);if(fn)req.end(fn);return req;};/**
+ * PUT `url` with optional `data` and callback `fn(res)`.
+ *
+ * @param {String} url
+ * @param {Mixed|Function} data or fn
+ * @param {Function} fn
+ * @return {Request}
+ * @api public
+ */request.put=function(url,data,fn){var req=request('PUT',url);if('function'==typeof data)fn=data,data=null;if(data)req.send(data);if(fn)req.end(fn);return req;};},{"./is-object":15,"./request":17,"./request-base":16,"emitter":2,"reduce":12}],15:[function(require,module,exports){/**
+ * Check if `obj` is an object.
+ *
+ * @param {Object} obj
+ * @return {Boolean}
+ * @api private
+ */function isObject(obj){return null!=obj&&'object'==(typeof obj==="undefined"?"undefined":_typeof(obj));}module.exports=isObject;},{}],16:[function(require,module,exports){/**
+ * Module of mixed-in functions shared between node and client code
+ */var isObject=require('./is-object');/**
+ * Clear previous timeout.
+ *
+ * @return {Request} for chaining
+ * @api public
+ */exports.clearTimeout=function _clearTimeout(){this._timeout=0;clearTimeout(this._timer);return this;};/**
+ * Force given parser
+ *
+ * Sets the body parser no matter type.
+ *
+ * @param {Function}
+ * @api public
+ */exports.parse=function parse(fn){this._parser=fn;return this;};/**
+ * Set timeout to `ms`.
+ *
+ * @param {Number} ms
+ * @return {Request} for chaining
+ * @api public
+ */exports.timeout=function timeout(ms){this._timeout=ms;return this;};/**
+ * Faux promise support
+ *
+ * @param {Function} fulfill
+ * @param {Function} reject
+ * @return {Request}
+ */exports.then=function then(fulfill,reject){return this.end(function(err,res){err?reject(err):fulfill(res);});};/**
+ * Allow for extension
+ */exports.use=function use(fn){fn(this);return this;};/**
+ * Get request header `field`.
+ * Case-insensitive.
+ *
+ * @param {String} field
+ * @return {String}
+ * @api public
+ */exports.get=function(field){return this._header[field.toLowerCase()];};/**
+ * Get case-insensitive header `field` value.
+ * This is a deprecated internal API. Use `.get(field)` instead.
+ *
+ * (getHeader is no longer used internally by the superagent code base)
+ *
+ * @param {String} field
+ * @return {String}
+ * @api private
+ * @deprecated
+ */exports.getHeader=exports.get;/**
+ * Set header `field` to `val`, or multiple fields with one object.
+ * Case-insensitive.
+ *
+ * Examples:
+ *
+ *      req.get('/')
+ *        .set('Accept', 'application/json')
+ *        .set('X-API-Key', 'foobar')
+ *        .end(callback);
+ *
+ *      req.get('/')
+ *        .set({ Accept: 'application/json', 'X-API-Key': 'foobar' })
+ *        .end(callback);
+ *
+ * @param {String|Object} field
+ * @param {String} val
+ * @return {Request} for chaining
+ * @api public
+ */exports.set=function(field,val){if(isObject(field)){for(var key in field){this.set(key,field[key]);}return this;}this._header[field.toLowerCase()]=val;this.header[field]=val;return this;};/**
+ * Remove header `field`.
+ * Case-insensitive.
+ *
+ * Example:
+ *
+ *      req.get('/')
+ *        .unset('User-Agent')
+ *        .end(callback);
+ *
+ * @param {String} field
+ */exports.unset=function(field){delete this._header[field.toLowerCase()];delete this.header[field];return this;};/**
+ * Write the field `name` and `val` for "multipart/form-data"
+ * request bodies.
+ *
+ * ``` js
+ * request.post('/upload')
+ *   .field('foo', 'bar')
+ *   .end(callback);
+ * ```
+ *
+ * @param {String} name
+ * @param {String|Blob|File|Buffer|fs.ReadStream} val
+ * @return {Request} for chaining
+ * @api public
+ */exports.field=function(name,val){this._getFormData().append(name,val);return this;};},{"./is-object":15}],17:[function(require,module,exports){// The node and browser modules expose versions of this with the
+// appropriate constructor function bound as first argument
+/**
+ * Issue a request:
+ *
+ * Examples:
+ *
+ *    request('GET', '/users').end(callback)
+ *    request('/users').end(callback)
+ *    request('/users', callback)
+ *
+ * @param {String} method
+ * @param {String|Function} url or callback
+ * @return {Request}
+ * @api public
+ */function request(RequestConstructor,method,url){// callback
+if('function'==typeof url){return new RequestConstructor('GET',method).end(url);}// url first
+if(2==arguments.length){return new RequestConstructor('GET',method);}return new RequestConstructor(method,url);}module.exports=request;},{}],18:[function(require,module,exports){/*! https://mths.be/punycode v1.3.2 by @mathias, modified for URI.js */var punycode=function(){/**
+	 * The `punycode` object.
+	 * @name punycode
+	 * @type Object
+	 */var punycode,/** Highest positive signed 32-bit float value */maxInt=2147483647,// aka. 0x7FFFFFFF or 2^31-1
+/** Bootstring parameters */base=36,tMin=1,tMax=26,skew=38,damp=700,initialBias=72,initialN=128,// 0x80
+delimiter='-',// '\x2D'
+/** Regular expressions */regexPunycode=/^xn--/,regexNonASCII=/[^\x20-\x7E]/,// unprintable ASCII chars + non-ASCII chars
+regexSeparators=/[\x2E\u3002\uFF0E\uFF61]/g,// RFC 3490 separators
+/** Error messages */errors={'overflow':'Overflow: input needs wider integers to process','not-basic':'Illegal input >= 0x80 (not a basic code point)','invalid-input':'Invalid input'},/** Convenience shortcuts */baseMinusTMin=base-tMin,floor=Math.floor,stringFromCharCode=String.fromCharCode,/** Temporary variable */key;/*--------------------------------------------------------------------------*//**
+	 * A generic error utility function.
+	 * @private
+	 * @param {String} type The error type.
+	 * @returns {Error} Throws a `RangeError` with the applicable error message.
+	 */function error(type){throw new RangeError(errors[type]);}/**
+	 * A generic `Array#map` utility function.
+	 * @private
+	 * @param {Array} array The array to iterate over.
+	 * @param {Function} callback The function that gets called for every array
+	 * item.
+	 * @returns {Array} A new array of values returned by the callback function.
+	 */function map(array,fn){var length=array.length;var result=[];while(length--){result[length]=fn(array[length]);}return result;}/**
+	 * A simple `Array#map`-like wrapper to work with domain name strings or email
+	 * addresses.
+	 * @private
+	 * @param {String} domain The domain name or email address.
+	 * @param {Function} callback The function that gets called for every
+	 * character.
+	 * @returns {Array} A new string of characters returned by the callback
+	 * function.
+	 */function mapDomain(string,fn){var parts=string.split('@');var result='';if(parts.length>1){// In email addresses, only the domain name should be punycoded. Leave
+// the local part (i.e. everything up to `@`) intact.
+result=parts[0]+'@';string=parts[1];}// Avoid `split(regex)` for IE8 compatibility. See #17.
+string=string.replace(regexSeparators,'\x2E');var labels=string.split('.');var encoded=map(labels,fn).join('.');return result+encoded;}/**
+	 * Creates an array containing the numeric code points of each Unicode
+	 * character in the string. While JavaScript uses UCS-2 internally,
+	 * this function will convert a pair of surrogate halves (each of which
+	 * UCS-2 exposes as separate characters) into a single code point,
+	 * matching UTF-16.
+	 * @see `punycode.ucs2.encode`
+	 * @see <https://mathiasbynens.be/notes/javascript-encoding>
+	 * @memberOf punycode.ucs2
+	 * @name decode
+	 * @param {String} string The Unicode input string (UCS-2).
+	 * @returns {Array} The new array of code points.
+	 */function ucs2decode(string){var output=[],counter=0,length=string.length,value,extra;while(counter<length){value=string.charCodeAt(counter++);if(value>=0xD800&&value<=0xDBFF&&counter<length){// high surrogate, and there is a next character
+extra=string.charCodeAt(counter++);if((extra&0xFC00)==0xDC00){// low surrogate
+output.push(((value&0x3FF)<<10)+(extra&0x3FF)+0x10000);}else{// unmatched surrogate; only append this code unit, in case the next
+// code unit is the high surrogate of a surrogate pair
+output.push(value);counter--;}}else{output.push(value);}}return output;}/**
+	 * Creates a string based on an array of numeric code points.
+	 * @see `punycode.ucs2.decode`
+	 * @memberOf punycode.ucs2
+	 * @name encode
+	 * @param {Array} codePoints The array of numeric code points.
+	 * @returns {String} The new Unicode string (UCS-2).
+	 */function ucs2encode(array){return map(array,function(value){var output='';if(value>0xFFFF){value-=0x10000;output+=stringFromCharCode(value>>>10&0x3FF|0xD800);value=0xDC00|value&0x3FF;}output+=stringFromCharCode(value);return output;}).join('');}/**
+	 * Converts a basic code point into a digit/integer.
+	 * @see `digitToBasic()`
+	 * @private
+	 * @param {Number} codePoint The basic numeric code point value.
+	 * @returns {Number} The numeric value of a basic code point (for use in
+	 * representing integers) in the range `0` to `base - 1`, or `base` if
+	 * the code point does not represent a value.
+	 */function basicToDigit(codePoint){if(codePoint-48<10){return codePoint-22;}if(codePoint-65<26){return codePoint-65;}if(codePoint-97<26){return codePoint-97;}return base;}/**
+	 * Converts a digit/integer into a basic code point.
+	 * @see `basicToDigit()`
+	 * @private
+	 * @param {Number} digit The numeric value of a basic code point.
+	 * @returns {Number} The basic code point whose value (when used for
+	 * representing integers) is `digit`, which needs to be in the range
+	 * `0` to `base - 1`. If `flag` is non-zero, the uppercase form is
+	 * used; else, the lowercase form is used. The behavior is undefined
+	 * if `flag` is non-zero and `digit` has no uppercase form.
+	 */function digitToBasic(digit,flag){//  0..25 map to ASCII a..z or A..Z
+// 26..35 map to ASCII 0..9
+return digit+22+75*(digit<26)-((flag!=0)<<5);}/**
+	 * Bias adaptation function as per section 3.4 of RFC 3492.
+	 * https://tools.ietf.org/html/rfc3492#section-3.4
+	 * @private
+	 */function adapt(delta,numPoints,firstTime){var k=0;delta=firstTime?floor(delta/damp):delta>>1;delta+=floor(delta/numPoints);for(;/* no initialization */delta>baseMinusTMin*tMax>>1;k+=base){delta=floor(delta/baseMinusTMin);}return floor(k+(baseMinusTMin+1)*delta/(delta+skew));}/**
+	 * Converts a Punycode string of ASCII-only symbols to a string of Unicode
+	 * symbols.
+	 * @memberOf punycode
+	 * @param {String} input The Punycode string of ASCII-only symbols.
+	 * @returns {String} The resulting string of Unicode symbols.
+	 */function decode(input){// Don't use UCS-2
+var output=[],inputLength=input.length,out,i=0,n=initialN,bias=initialBias,basic,j,index,oldi,w,k,digit,t,/** Cached calculation results */baseMinusT;// Handle the basic code points: let `basic` be the number of input code
+// points before the last delimiter, or `0` if there is none, then copy
+// the first basic code points to the output.
+basic=input.lastIndexOf(delimiter);if(basic<0){basic=0;}for(j=0;j<basic;++j){// if it's not a basic code point
+if(input.charCodeAt(j)>=0x80){error('not-basic');}output.push(input.charCodeAt(j));}// Main decoding loop: start just after the last delimiter if any basic code
+// points were copied; start at the beginning otherwise.
+for(index=basic>0?basic+1:0;index<inputLength;)/* no final expression */{// `index` is the index of the next character to be consumed.
+// Decode a generalized variable-length integer into `delta`,
+// which gets added to `i`. The overflow checking is easier
+// if we increase `i` as we go, then subtract off its starting
+// value at the end to obtain `delta`.
+for(oldi=i,w=1,k=base;;/* no condition */k+=base){if(index>=inputLength){error('invalid-input');}digit=basicToDigit(input.charCodeAt(index++));if(digit>=base||digit>floor((maxInt-i)/w)){error('overflow');}i+=digit*w;t=k<=bias?tMin:k>=bias+tMax?tMax:k-bias;if(digit<t){break;}baseMinusT=base-t;if(w>floor(maxInt/baseMinusT)){error('overflow');}w*=baseMinusT;}out=output.length+1;bias=adapt(i-oldi,out,oldi==0);// `i` was supposed to wrap around from `out` to `0`,
+// incrementing `n` each time, so we'll fix that now:
+if(floor(i/out)>maxInt-n){error('overflow');}n+=floor(i/out);i%=out;// Insert `n` at position `i` of the output
+output.splice(i++,0,n);}return ucs2encode(output);}/**
+	 * Converts a string of Unicode symbols (e.g. a domain name label) to a
+	 * Punycode string of ASCII-only symbols.
+	 * @memberOf punycode
+	 * @param {String} input The string of Unicode symbols.
+	 * @returns {String} The resulting Punycode string of ASCII-only symbols.
+	 */function encode(input){var n,delta,handledCPCount,basicLength,bias,j,m,q,k,t,currentValue,output=[],/** `inputLength` will hold the number of code points in `input`. */inputLength,/** Cached calculation results */handledCPCountPlusOne,baseMinusT,qMinusT;// Convert the input in UCS-2 to Unicode
+input=ucs2decode(input);// Cache the length
+inputLength=input.length;// Initialize the state
+n=initialN;delta=0;bias=initialBias;// Handle the basic code points
+for(j=0;j<inputLength;++j){currentValue=input[j];if(currentValue<0x80){output.push(stringFromCharCode(currentValue));}}handledCPCount=basicLength=output.length;// `handledCPCount` is the number of code points that have been handled;
+// `basicLength` is the number of basic code points.
+// Finish the basic string - if it is not empty - with a delimiter
+if(basicLength){output.push(delimiter);}// Main encoding loop:
+while(handledCPCount<inputLength){// All non-basic code points < n have been handled already. Find the next
+// larger one:
+for(m=maxInt,j=0;j<inputLength;++j){currentValue=input[j];if(currentValue>=n&&currentValue<m){m=currentValue;}}// Increase `delta` enough to advance the decoder's <n,i> state to <m,0>,
+// but guard against overflow
+handledCPCountPlusOne=handledCPCount+1;if(m-n>floor((maxInt-delta)/handledCPCountPlusOne)){error('overflow');}delta+=(m-n)*handledCPCountPlusOne;n=m;for(j=0;j<inputLength;++j){currentValue=input[j];if(currentValue<n&&++delta>maxInt){error('overflow');}if(currentValue==n){// Represent delta as a generalized variable-length integer
+for(q=delta,k=base;;/* no condition */k+=base){t=k<=bias?tMin:k>=bias+tMax?tMax:k-bias;if(q<t){break;}qMinusT=q-t;baseMinusT=base-t;output.push(stringFromCharCode(digitToBasic(t+qMinusT%baseMinusT,0)));q=floor(qMinusT/baseMinusT);}output.push(stringFromCharCode(digitToBasic(q,0)));bias=adapt(delta,handledCPCountPlusOne,handledCPCount==basicLength);delta=0;++handledCPCount;}}++delta;++n;}return output.join('');}/**
+	 * Converts a Punycode string representing a domain name or an email address
+	 * to Unicode. Only the Punycoded parts of the input will be converted, i.e.
+	 * it doesn't matter if you call it on a string that has already been
+	 * converted to Unicode.
+	 * @memberOf punycode
+	 * @param {String} input The Punycoded domain name or email address to
+	 * convert to Unicode.
+	 * @returns {String} The Unicode representation of the given Punycode
+	 * string.
+	 */function toUnicode(input){return mapDomain(input,function(string){return regexPunycode.test(string)?decode(string.slice(4).toLowerCase()):string;});}/**
+	 * Converts a Unicode string representing a domain name or an email address to
+	 * Punycode. Only the non-ASCII parts of the domain name will be converted,
+	 * i.e. it doesn't matter if you call it with a domain that's already in
+	 * ASCII.
+	 * @memberOf punycode
+	 * @param {String} input The domain name or email address to convert, as a
+	 * Unicode string.
+	 * @returns {String} The Punycode representation of the given domain name or
+	 * email address.
+	 */function toASCII(input){return mapDomain(input,function(string){return regexNonASCII.test(string)?'xn--'+encode(string):string;});}/*--------------------------------------------------------------------------*//** Define the public API */punycode={/**
+		 * A string representing the current Punycode.js version number.
+		 * @memberOf punycode
+		 * @type String
+		 */version:'1.3.2',/**
+		 * An object of methods to convert from JavaScript's internal character
+		 * representation (UCS-2) to Unicode code points, and back.
+		 * @see <https://mathiasbynens.be/notes/javascript-encoding>
+		 * @memberOf punycode
+		 * @type Object
+		 */ucs2:{decode:ucs2decode,encode:ucs2encode},decode:decode,encode:encode,toASCII:toASCII,toUnicode:toUnicode};return punycode;}();if(typeof COMPILED==="undefined"&&typeof module!=="undefined")module.exports=punycode;},{}],19:[function(require,module,exports){///<reference path="commonjs.d.ts"/>
+require("./schemes/http");require("./schemes/urn");require("./schemes/mailto");},{"./schemes/http":20,"./schemes/mailto":21,"./schemes/urn":22}],20:[function(require,module,exports){///<reference path="../uri.ts"/>
+if(typeof COMPILED==="undefined"&&typeof URI==="undefined"&&typeof require==="function")var URI=require("../uri");URI.SCHEMES["http"]=URI.SCHEMES["https"]={domainHost:true,parse:function parse(components,options){//report missing host
+if(!components.host){components.error=components.error||"HTTP URIs must have a host.";}return components;},serialize:function serialize(components,options){//normalize the default port
+if(components.port===(String(components.scheme).toLowerCase()!=="https"?80:443)||components.port===""){components.port=undefined;}//normalize the empty path
+if(!components.path){components.path="/";}//NOTE: We do not parse query strings for HTTP URIs
+//as WWW Form Url Encoded query strings are part of the HTML4+ spec,
+//and not the HTTP spec. 
+return components;}};},{"../uri":23}],21:[function(require,module,exports){///<reference path="../uri.ts"/>
+if(typeof COMPILED==="undefined"&&typeof URI==="undefined"&&typeof require==="function"){var URI=require("../uri"),punycode=require("../punycode");}(function(){function merge(){var sets=[];for(var _i=0;_i<arguments.length;_i++){sets[_i-0]=arguments[_i];}if(sets.length>1){sets[0]=sets[0].slice(0,-1);var xl=sets.length-1;for(var x=1;x<xl;++x){sets[x]=sets[x].slice(1,-1);}sets[xl]=sets[xl].slice(1);return sets.join('');}else{return sets[0];}}function subexp(str){return"(?:"+str+")";}var O={},isIRI=URI.IRI_SUPPORT,//RFC 3986
+UNRESERVED$$="[A-Za-z0-9\\-\\.\\_\\~"+(isIRI?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",HEXDIG$$="[0-9A-Fa-f]",PCT_ENCODED$=subexp(subexp("%[EFef]"+HEXDIG$$+"%"+HEXDIG$$+HEXDIG$$+"%"+HEXDIG$$+HEXDIG$$)+"|"+subexp("%[89A-Fa-f]"+HEXDIG$$+"%"+HEXDIG$$+HEXDIG$$)+"|"+subexp("%"+HEXDIG$$+HEXDIG$$)),//RFC 5322, except these symbols as per RFC 6068: @ : / ? # [ ] & ; = 
+//ATEXT$$ = "[A-Za-z0-9\\!\\#\\$\\%\\&\\'\\*\\+\\-\\/\\=\\?\\^\\_\\`\\{\\|\\}\\~]",
+//WSP$$ = "[\\x20\\x09]",
+//OBS_QTEXT$$ = "[\\x01-\\x08\\x0B\\x0C\\x0E-\\x1F\\x7F]",  //(%d1-8 / %d11-12 / %d14-31 / %d127)
+//QTEXT$$ = merge("[\\x21\\x23-\\x5B\\x5D-\\x7E]", OBS_QTEXT$$),  //%d33 / %d35-91 / %d93-126 / obs-qtext
+//VCHAR$$ = "[\\x21-\\x7E]",
+//WSP$$ = "[\\x20\\x09]",
+//OBS_QP$ = subexp("\\\\" + merge("[\\x00\\x0D\\x0A]", OBS_QTEXT$$)),  //%d0 / CR / LF / obs-qtext
+//FWS$ = subexp(subexp(WSP$$ + "*" + "\\x0D\\x0A") + "?" + WSP$$ + "+"),
+//QUOTED_PAIR$ = subexp(subexp("\\\\" + subexp(VCHAR$$ + "|" + WSP$$)) + "|" + OBS_QP$),
+//QUOTED_STRING$ = subexp('\\"' + subexp(FWS$ + "?" + QCONTENT$) + "*" + FWS$ + "?" + '\\"'),
+ATEXT$$="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",QTEXT$$="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",VCHAR$$=merge(QTEXT$$,"[\\\"\\\\]"),DOT_ATOM_TEXT$=subexp(ATEXT$$+"+"+subexp("\\."+ATEXT$$+"+")+"*"),QUOTED_PAIR$=subexp("\\\\"+VCHAR$$),QCONTENT$=subexp(QTEXT$$+"|"+QUOTED_PAIR$),QUOTED_STRING$=subexp('\\"'+QCONTENT$+"*"+'\\"'),//RFC 6068
+DTEXT_NO_OBS$$="[\\x21-\\x5A\\x5E-\\x7E]",SOME_DELIMS$$="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",QCHAR$=subexp(UNRESERVED$$+"|"+PCT_ENCODED$+"|"+SOME_DELIMS$$),DOMAIN$=subexp(DOT_ATOM_TEXT$+"|"+"\\["+DTEXT_NO_OBS$$+"*"+"\\]"),LOCAL_PART$=subexp(DOT_ATOM_TEXT$+"|"+QUOTED_STRING$),ADDR_SPEC$=subexp(LOCAL_PART$+"\\@"+DOMAIN$),TO$=subexp(ADDR_SPEC$+subexp("\\,"+ADDR_SPEC$)+"*"),HFNAME$=subexp(QCHAR$+"*"),HFVALUE$=HFNAME$,HFIELD$=subexp(HFNAME$+"\\="+HFVALUE$),HFIELDS2$=subexp(HFIELD$+subexp("\\&"+HFIELD$)+"*"),HFIELDS$=subexp("\\?"+HFIELDS2$),MAILTO_URI=URI.VALIDATE_SUPPORT&&new RegExp("^mailto\\:"+TO$+"?"+HFIELDS$+"?$"),UNRESERVED=new RegExp(UNRESERVED$$,"g"),PCT_ENCODED=new RegExp(PCT_ENCODED$,"g"),NOT_LOCAL_PART=new RegExp(merge("[^]",ATEXT$$,"[\\.]",'[\\"]',VCHAR$$),"g"),NOT_DOMAIN=new RegExp(merge("[^]",ATEXT$$,"[\\.]","[\\[]",DTEXT_NO_OBS$$,"[\\]]"),"g"),NOT_HFNAME=new RegExp(merge("[^]",UNRESERVED$$,SOME_DELIMS$$),"g"),NOT_HFVALUE=NOT_HFNAME,TO=URI.VALIDATE_SUPPORT&&new RegExp("^"+TO$+"$"),HFIELDS=URI.VALIDATE_SUPPORT&&new RegExp("^"+HFIELDS2$+"$");function toUpperCase(str){return str.toUpperCase();}function decodeUnreserved(str){var decStr=URI.pctDecChars(str);return!decStr.match(UNRESERVED)?str:decStr;}function toArray(obj){return obj!==undefined&&obj!==null?obj instanceof Array&&!obj.callee?obj:typeof obj.length!=="number"||obj.split||obj.setInterval||obj.call?[obj]:Array.prototype.slice.call(obj):[];}URI.SCHEMES["mailto"]={parse:function parse(components,options){if(URI.VALIDATE_SUPPORT&&!components.error){if(components.path&&!TO.test(components.path)){components.error="Email address is not valid";}else if(components.query&&!HFIELDS.test(components.query)){components.error="Header fields are invalid";}}var to=components.to=components.path?components.path.split(","):[];components.path=undefined;if(components.query){var unknownHeaders=false,headers={};var hfields=components.query.split("&");for(var x=0,xl=hfields.length;x<xl;++x){var hfield=hfields[x].split("=");switch(hfield[0]){case"to":var toAddrs=hfield[1].split(",");for(var x_1=0,xl_1=toAddrs.length;x_1<xl_1;++x_1){to.push(toAddrs[x_1]);}break;case"subject":components.subject=URI.unescapeComponent(hfield[1],options);break;case"body":components.body=URI.unescapeComponent(hfield[1],options);break;default:unknownHeaders=true;headers[URI.unescapeComponent(hfield[0],options)]=URI.unescapeComponent(hfield[1],options);break;}}if(unknownHeaders)components.headers=headers;}components.query=undefined;for(var x=0,xl=to.length;x<xl;++x){var addr=to[x].split("@");addr[0]=URI.unescapeComponent(addr[0]);if(typeof punycode!=="undefined"&&!options.unicodeSupport){//convert Unicode IDN -> ASCII IDN
+try{addr[1]=punycode.toASCII(URI.unescapeComponent(addr[1],options).toLowerCase());}catch(e){components.error=components.error||"Email address's domain name can not be converted to ASCII via punycode: "+e;}}else{addr[1]=URI.unescapeComponent(addr[1],options).toLowerCase();}to[x]=addr.join("@");}return components;},serialize:function serialize(components,options){var to=toArray(components.to);if(to){for(var x=0,xl=to.length;x<xl;++x){var toAddr=String(to[x]);var atIdx=toAddr.lastIndexOf("@");var localPart=toAddr.slice(0,atIdx);var domain=toAddr.slice(atIdx+1);localPart=localPart.replace(PCT_ENCODED,decodeUnreserved).replace(PCT_ENCODED,toUpperCase).replace(NOT_LOCAL_PART,URI.pctEncChar);if(typeof punycode!=="undefined"){//convert IDN via punycode
+try{domain=!options.iri?punycode.toASCII(URI.unescapeComponent(domain,options).toLowerCase()):punycode.toUnicode(domain);}catch(e){components.error=components.error||"Email address's domain name can not be converted to "+(!options.iri?"ASCII":"Unicode")+" via punycode: "+e;}}else{domain=domain.replace(PCT_ENCODED,decodeUnreserved).toLowerCase().replace(PCT_ENCODED,toUpperCase).replace(NOT_DOMAIN,URI.pctEncChar);}to[x]=localPart+"@"+domain;}components.path=to.join(",");}var headers=components.headers=components.headers||{};if(components.subject)headers["subject"]=components.subject;if(components.body)headers["body"]=components.body;var fields=[];for(var name_1 in headers){if(headers[name_1]!==O[name_1]){fields.push(name_1.replace(PCT_ENCODED,decodeUnreserved).replace(PCT_ENCODED,toUpperCase).replace(NOT_HFNAME,URI.pctEncChar)+"="+headers[name_1].replace(PCT_ENCODED,decodeUnreserved).replace(PCT_ENCODED,toUpperCase).replace(NOT_HFVALUE,URI.pctEncChar));}}if(fields.length){components.query=fields.join("&");}return components;}};})();},{"../punycode":18,"../uri":23}],22:[function(require,module,exports){///<reference path="../uri.ts"/>
+if(typeof COMPILED==="undefined"&&typeof URI==="undefined"&&typeof require==="function")var URI=require("../uri");(function(){var pctEncChar=URI.pctEncChar,NID$="(?:[0-9A-Za-z][0-9A-Za-z\\-]{1,31})",PCT_ENCODED$="(?:\\%[0-9A-Fa-f]{2})",TRANS$$="[0-9A-Za-z\\(\\)\\+\\,\\-\\.\\:\\=\\@\\;\\$\\_\\!\\*\\'\\/\\?\\#]",NSS$="(?:(?:"+PCT_ENCODED$+"|"+TRANS$$+")+)",URN_SCHEME=new RegExp("^urn\\:("+NID$+")$"),URN_PATH=new RegExp("^("+NID$+")\\:("+NSS$+")$"),URN_PARSE=/^([^\:]+)\:(.*)/,URN_EXCLUDED=/[\x00-\x20\\\"\&\<\>\[\]\^\`\{\|\}\~\x7F-\xFF]/g,UUID=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/;//RFC 2141
+URI.SCHEMES["urn"]={parse:function parse(components,options){var matches=components.path.match(URN_PATH),scheme,schemeHandler;if(!matches){if(!options.tolerant){components.error=components.error||"URN is not strictly valid.";}matches=components.path.match(URN_PARSE);}if(matches){scheme="urn:"+matches[1].toLowerCase();schemeHandler=URI.SCHEMES[scheme];//in order to serialize properly, 
+//every URN must have a serializer that calls the URN serializer 
+if(!schemeHandler){//create fake scheme handler
+schemeHandler=URI.SCHEMES[scheme]={parse:function parse(components,options){return components;},serialize:URI.SCHEMES["urn"].serialize};}components.scheme=scheme;components.path=matches[2];components=schemeHandler.parse(components,options);}else{components.error=components.error||"URN can not be parsed.";}return components;},serialize:function serialize(components,options){var scheme=components.scheme||options.scheme,matches;if(scheme&&scheme!=="urn"){var matches=scheme.match(URN_SCHEME);if(!matches){matches=["urn:"+scheme,scheme];}components.scheme="urn";components.path=matches[1]+":"+(components.path?components.path.replace(URN_EXCLUDED,pctEncChar):"");}return components;}};//RFC 4122
+URI.SCHEMES["urn:uuid"]={parse:function parse(components,options){if(!options.tolerant&&(!components.path||!components.path.match(UUID))){components.error=components.error||"UUID is not valid.";}return components;},serialize:function serialize(components,options){//ensure UUID is valid
+if(!options.tolerant&&(!components.path||!components.path.match(UUID))){//invalid UUIDs can not have this scheme
+components.scheme=undefined;}else{//normalize UUID
+components.path=(components.path||"").toLowerCase();}return URI.SCHEMES["urn"].serialize(components,options);}};})();},{"../uri":23}],23:[function(require,module,exports){/**
+ * URI.js
+ *
+ * @fileoverview An RFC 3986 compliant, scheme extendable URI parsing/validating/resolving library for JavaScript.
+ * @author <a href="mailto:gary.court@gmail.com">Gary Court</a>
+ * @version 2.0.0
+ * @see http://github.com/garycourt/uri-js
+ * @license URI.js v2.0.0 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js
+ *//**
+ * Copyright 2011 Gary Court. All rights reserved.
+ *
+ * Redistribution and use in source and binary forms, with or without modification, are
+ * permitted provided that the following conditions are met:
+ *
+ *    1. Redistributions of source code must retain the above copyright notice, this list of
+ *       conditions and the following disclaimer.
+ *
+ *    2. Redistributions in binary form must reproduce the above copyright notice, this list
+ *       of conditions and the following disclaimer in the documentation and/or other materials
+ *       provided with the distribution.
+ *
+ * THIS SOFTWARE IS PROVIDED BY GARY COURT ``AS IS'' AND ANY EXPRESS OR IMPLIED
+ * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
+ * FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL GARY COURT OR
+ * CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
+ * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
+ * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
+ * ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
+ * NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+ * ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ *
+ * The views and conclusions contained in the software and documentation are those of the
+ * authors and should not be interpreted as representing official policies, either expressed
+ * or implied, of Gary Court.
+ *////<reference path="punycode.d.ts"/>
+///<reference path="commonjs.d.ts"/>
+/**
+ * Compiler switch for indicating code is compiled
+ * @define {boolean}
+ */var COMPILED=false;/**
+ * Compiler switch for supporting IRI URIs
+ * @define {boolean}
+ */var URI__IRI_SUPPORT=true;/**
+ * Compiler switch for supporting URI validation
+ * @define {boolean}
+ */var URI__VALIDATE_SUPPORT=true;var URI=function(){function merge(){var sets=[];for(var _i=0;_i<arguments.length;_i++){sets[_i-0]=arguments[_i];}if(sets.length>1){sets[0]=sets[0].slice(0,-1);var xl=sets.length-1;for(var x=1;x<xl;++x){sets[x]=sets[x].slice(1,-1);}sets[xl]=sets[xl].slice(1);return sets.join('');}else{return sets[0];}}function subexp(str){return"(?:"+str+")";}function buildExps(isIRI){var ALPHA$$="[A-Za-z]",CR$="[\\x0D]",DIGIT$$="[0-9]",DQUOTE$$="[\\x22]",HEXDIG$$=merge(DIGIT$$,"[A-Fa-f]"),LF$$="[\\x0A]",SP$$="[\\x20]",PCT_ENCODED$=subexp(subexp("%[EFef]"+HEXDIG$$+"%"+HEXDIG$$+HEXDIG$$+"%"+HEXDIG$$+HEXDIG$$)+"|"+subexp("%[89A-Fa-f]"+HEXDIG$$+"%"+HEXDIG$$+HEXDIG$$)+"|"+subexp("%"+HEXDIG$$+HEXDIG$$)),GEN_DELIMS$$="[\\:\\/\\?\\#\\[\\]\\@]",SUB_DELIMS$$="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",RESERVED$$=merge(GEN_DELIMS$$,SUB_DELIMS$$),UCSCHAR$$=isIRI?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",IPRIVATE$$=isIRI?"[\\uE000-\\uF8FF]":"[]",UNRESERVED$$=merge(ALPHA$$,DIGIT$$,"[\\-\\.\\_\\~]",UCSCHAR$$),SCHEME$=subexp(ALPHA$$+merge(ALPHA$$,DIGIT$$,"[\\+\\-\\.]")+"*"),USERINFO$=subexp(subexp(PCT_ENCODED$+"|"+merge(UNRESERVED$$,SUB_DELIMS$$,"[\\:]"))+"*"),DEC_OCTET$=subexp(subexp("25[0-5]")+"|"+subexp("2[0-4]"+DIGIT$$)+"|"+subexp("1"+DIGIT$$+DIGIT$$)+"|"+subexp("[1-9]"+DIGIT$$)+"|"+DIGIT$$),IPV4ADDRESS$=subexp(DEC_OCTET$+"\\."+DEC_OCTET$+"\\."+DEC_OCTET$+"\\."+DEC_OCTET$),H16$=subexp(HEXDIG$$+"{1,4}"),LS32$=subexp(subexp(H16$+"\\:"+H16$)+"|"+IPV4ADDRESS$),IPV6ADDRESS$=subexp(merge(UNRESERVED$$,SUB_DELIMS$$,"[\\:]")+"+"),IPVFUTURE$=subexp("v"+HEXDIG$$+"+\\."+merge(UNRESERVED$$,SUB_DELIMS$$,"[\\:]")+"+"),IP_LITERAL$=subexp("\\["+subexp(IPV6ADDRESS$+"|"+IPVFUTURE$)+"\\]"),REG_NAME$=subexp(subexp(PCT_ENCODED$+"|"+merge(UNRESERVED$$,SUB_DELIMS$$))+"*"),HOST$=subexp(IP_LITERAL$+"|"+IPV4ADDRESS$+"(?!"+REG_NAME$+")"+"|"+REG_NAME$),PORT$=subexp(DIGIT$$+"*"),AUTHORITY$=subexp(subexp(USERINFO$+"@")+"?"+HOST$+subexp("\\:"+PORT$)+"?"),PCHAR$=subexp(PCT_ENCODED$+"|"+merge(UNRESERVED$$,SUB_DELIMS$$,"[\\:\\@]")),SEGMENT$=subexp(PCHAR$+"*"),SEGMENT_NZ$=subexp(PCHAR$+"+"),SEGMENT_NZ_NC$=subexp(subexp(PCT_ENCODED$+"|"+merge(UNRESERVED$$,SUB_DELIMS$$,"[\\@]"))+"+"),PATH_ABEMPTY$=subexp(subexp("\\/"+SEGMENT$)+"*"),PATH_ABSOLUTE$=subexp("\\/"+subexp(SEGMENT_NZ$+PATH_ABEMPTY$)+"?"),PATH_NOSCHEME$=subexp(SEGMENT_NZ_NC$+PATH_ABEMPTY$),PATH_ROOTLESS$=subexp(SEGMENT_NZ$+PATH_ABEMPTY$),PATH_EMPTY$="(?!"+PCHAR$+")",PATH$=subexp(PATH_ABEMPTY$+"|"+PATH_ABSOLUTE$+"|"+PATH_NOSCHEME$+"|"+PATH_ROOTLESS$+"|"+PATH_EMPTY$),QUERY$=subexp(subexp(PCHAR$+"|"+merge("[\\/\\?]",IPRIVATE$$))+"*"),FRAGMENT$=subexp(subexp(PCHAR$+"|[\\/\\?]")+"*"),HIER_PART$=subexp(subexp("\\/\\/"+AUTHORITY$+PATH_ABEMPTY$)+"|"+PATH_ABSOLUTE$+"|"+PATH_ROOTLESS$+"|"+PATH_EMPTY$),URI$=subexp(SCHEME$+"\\:"+HIER_PART$+subexp("\\?"+QUERY$)+"?"+subexp("\\#"+FRAGMENT$)+"?"),RELATIVE_PART$=subexp(subexp("\\/\\/"+AUTHORITY$+PATH_ABEMPTY$)+"|"+PATH_ABSOLUTE$+"|"+PATH_NOSCHEME$+"|"+PATH_EMPTY$),RELATIVE$=subexp(RELATIVE_PART$+subexp("\\?"+QUERY$)+"?"+subexp("\\#"+FRAGMENT$)+"?"),URI_REFERENCE$=subexp(URI$+"|"+RELATIVE$),ABSOLUTE_URI$=subexp(SCHEME$+"\\:"+HIER_PART$+subexp("\\?"+QUERY$)+"?"),GENERIC_REF$="^("+SCHEME$+")\\:"+subexp(subexp("\\/\\/("+subexp("("+USERINFO$+")@")+"?("+HOST$+")"+subexp("\\:("+PORT$+")")+"?)")+"?("+PATH_ABEMPTY$+"|"+PATH_ABSOLUTE$+"|"+PATH_ROOTLESS$+"|"+PATH_EMPTY$+")")+subexp("\\?("+QUERY$+")")+"?"+subexp("\\#("+FRAGMENT$+")")+"?$",RELATIVE_REF$="^(){0}"+subexp(subexp("\\/\\/("+subexp("("+USERINFO$+")@")+"?("+HOST$+")"+subexp("\\:("+PORT$+")")+"?)")+"?("+PATH_ABEMPTY$+"|"+PATH_ABSOLUTE$+"|"+PATH_NOSCHEME$+"|"+PATH_EMPTY$+")")+subexp("\\?("+QUERY$+")")+"?"+subexp("\\#("+FRAGMENT$+")")+"?$",ABSOLUTE_REF$="^("+SCHEME$+")\\:"+subexp(subexp("\\/\\/("+subexp("("+USERINFO$+")@")+"?("+HOST$+")"+subexp("\\:("+PORT$+")")+"?)")+"?("+PATH_ABEMPTY$+"|"+PATH_ABSOLUTE$+"|"+PATH_ROOTLESS$+"|"+PATH_EMPTY$+")")+subexp("\\?("+QUERY$+")")+"?$",SAMEDOC_REF$="^"+subexp("\\#("+FRAGMENT$+")")+"?$",AUTHORITY_REF$="^"+subexp("("+USERINFO$+")@")+"?("+HOST$+")"+subexp("\\:("+PORT$+")")+"?$";return{URI_REF:URI__VALIDATE_SUPPORT&&new RegExp("("+GENERIC_REF$+")|("+RELATIVE_REF$+")"),NOT_SCHEME:new RegExp(merge("[^]",ALPHA$$,DIGIT$$,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(merge("[^\\%\\:]",UNRESERVED$$,SUB_DELIMS$$),"g"),NOT_HOST:new RegExp(merge("[^\\%]",UNRESERVED$$,SUB_DELIMS$$),"g"),NOT_PATH:new RegExp(merge("[^\\%\\/\\:\\@]",UNRESERVED$$,SUB_DELIMS$$),"g"),NOT_PATH_NOSCHEME:new RegExp(merge("[^\\%\\/\\@]",UNRESERVED$$,SUB_DELIMS$$),"g"),NOT_QUERY:new RegExp(merge("[^\\%]",UNRESERVED$$,SUB_DELIMS$$,"[\\:\\@\\/\\?]",IPRIVATE$$),"g"),NOT_FRAGMENT:new RegExp(merge("[^\\%]",UNRESERVED$$,SUB_DELIMS$$,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(merge("[^]",UNRESERVED$$,SUB_DELIMS$$),"g"),UNRESERVED:new RegExp(UNRESERVED$$,"g"),OTHER_CHARS:new RegExp(merge("[^\\%]",UNRESERVED$$,RESERVED$$),"g"),PCT_ENCODED:new RegExp(PCT_ENCODED$,"g")};}var URI_PROTOCOL=buildExps(false),IRI_PROTOCOL=URI__IRI_SUPPORT?buildExps(true):undefined,URI_PARSE=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?([^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n)*))?/i,RDS1=/^\.\.?\//,RDS2=/^\/\.(\/|$)/,RDS3=/^\/\.\.(\/|$)/,RDS4=/^\.\.?$/,RDS5=/^\/?(?:.|\n)*?(?=\/|$)/,NO_MATCH_IS_UNDEFINED="".match(/(){0}/)[1]===undefined;function pctEncChar(chr){var c=chr.charCodeAt(0),e;if(c<16)e="%0"+c.toString(16).toUpperCase();else if(c<128)e="%"+c.toString(16).toUpperCase();else if(c<2048)e="%"+(c>>6|192).toString(16).toUpperCase()+"%"+(c&63|128).toString(16).toUpperCase();else e="%"+(c>>12|224).toString(16).toUpperCase()+"%"+(c>>6&63|128).toString(16).toUpperCase()+"%"+(c&63|128).toString(16).toUpperCase();return e;}function pctDecChars(str){var newStr="",i=0,il=str.length,c,c2,c3;while(i<il){c=parseInt(str.substr(i+1,2),16);if(c<128){newStr+=String.fromCharCode(c);i+=3;}else if(c>=194&&c<224){if(il-i>=6){c2=parseInt(str.substr(i+4,2),16);newStr+=String.fromCharCode((c&31)<<6|c2&63);}else{newStr+=str.substr(i,6);}i+=6;}else if(c>=224){if(il-i>=9){c2=parseInt(str.substr(i+4,2),16);c3=parseInt(str.substr(i+7,2),16);newStr+=String.fromCharCode((c&15)<<12|(c2&63)<<6|c3&63);}else{newStr+=str.substr(i,9);}i+=9;}else{newStr+=str.substr(i,3);i+=3;}}return newStr;}function typeOf(o){return o===undefined?"undefined":o===null?"null":Object.prototype.toString.call(o).split(" ").pop().split("]").shift().toLowerCase();}function toUpperCase(str){return str.toUpperCase();}var SCHEMES={};function _normalizeComponentEncoding(components,protocol){function decodeUnreserved(str){var decStr=pctDecChars(str);return!decStr.match(protocol.UNRESERVED)?str:decStr;}if(components.scheme)components.scheme=String(components.scheme).replace(protocol.PCT_ENCODED,decodeUnreserved).toLowerCase().replace(protocol.NOT_SCHEME,"");if(components.userinfo!==undefined)components.userinfo=String(components.userinfo).replace(protocol.PCT_ENCODED,decodeUnreserved).replace(protocol.NOT_USERINFO,pctEncChar).replace(protocol.PCT_ENCODED,toUpperCase);if(components.host!==undefined)components.host=String(components.host).replace(protocol.PCT_ENCODED,decodeUnreserved).toLowerCase().replace(protocol.NOT_HOST,pctEncChar).replace(protocol.PCT_ENCODED,toUpperCase);if(components.path!==undefined)components.path=String(components.path).replace(protocol.PCT_ENCODED,decodeUnreserved).replace(components.scheme?protocol.NOT_PATH:protocol.NOT_PATH_NOSCHEME,pctEncChar).replace(protocol.PCT_ENCODED,toUpperCase);if(components.query!==undefined)components.query=String(components.query).replace(protocol.PCT_ENCODED,decodeUnreserved).replace(protocol.NOT_QUERY,pctEncChar).replace(protocol.PCT_ENCODED,toUpperCase);if(components.fragment!==undefined)components.fragment=String(components.fragment).replace(protocol.PCT_ENCODED,decodeUnreserved).replace(protocol.NOT_FRAGMENT,pctEncChar).replace(protocol.PCT_ENCODED,toUpperCase);return components;};function parse(uriString,options){if(options===void 0){options={};}var protocol=URI__IRI_SUPPORT&&options.iri!==false?IRI_PROTOCOL:URI_PROTOCOL,matches,parseError=false,components={},schemeHandler;if(options.reference==="suffix")uriString=(options.scheme?options.scheme+":":"")+"//"+uriString;if(URI__VALIDATE_SUPPORT){matches=uriString.match(protocol.URI_REF);if(matches){if(matches[1]){//generic URI
+matches=matches.slice(1,10);}else{//relative URI
+matches=matches.slice(10,19);}}if(!matches){parseError=true;if(!options.tolerant)components.error=components.error||"URI is not strictly valid.";matches=uriString.match(URI_PARSE);}}else{matches=uriString.match(URI_PARSE);}if(matches){if(NO_MATCH_IS_UNDEFINED){//store each component
+components.scheme=matches[1];//components.authority = matches[2];
+components.userinfo=matches[3];components.host=matches[4];components.port=parseInt(matches[5],10);components.path=matches[6]||"";components.query=matches[7];components.fragment=matches[8];//fix port number
+if(isNaN(components.port)){components.port=matches[5];}}else{//store each component
+components.scheme=matches[1]||undefined;//components.authority = (uriString.indexOf("//") !== -1 ? matches[2] : undefined);
+components.userinfo=uriString.indexOf("@")!==-1?matches[3]:undefined;components.host=uriString.indexOf("//")!==-1?matches[4]:undefined;components.port=parseInt(matches[5],10);components.path=matches[6]||"";components.query=uriString.indexOf("?")!==-1?matches[7]:undefined;components.fragment=uriString.indexOf("#")!==-1?matches[8]:undefined;//fix port number
+if(isNaN(components.port)){components.port=uriString.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?matches[4]:undefined;}}//determine reference type
+if(components.scheme===undefined&&components.userinfo===undefined&&components.host===undefined&&components.port===undefined&&!components.path&&components.query===undefined){components.reference="same-document";}else if(components.scheme===undefined){components.reference="relative";}else if(components.fragment===undefined){components.reference="absolute";}else{components.reference="uri";}//check for reference errors
+if(options.reference&&options.reference!=="suffix"&&options.reference!==components.reference){components.error=components.error||"URI is not a "+options.reference+" reference.";}//find scheme handler
+schemeHandler=SCHEMES[(options.scheme||components.scheme||"").toLowerCase()];//check if scheme can't handle IRIs
+if(URI__IRI_SUPPORT&&typeof punycode!=="undefined"&&!options.unicodeSupport&&(!schemeHandler||!schemeHandler.unicodeSupport)){//if host component is a domain name
+if(components.host&&(options.domainHost||schemeHandler&&schemeHandler.domainHost)){//convert Unicode IDN -> ASCII IDN
+try{components.host=punycode.toASCII(components.host.replace(protocol.PCT_ENCODED,pctDecChars).toLowerCase());}catch(e){components.error=components.error||"Host's domain name can not be converted to ASCII via punycode: "+e;}}//convert IRI -> URI
+_normalizeComponentEncoding(components,URI_PROTOCOL);}else{//normalize encodings
+_normalizeComponentEncoding(components,protocol);}//perform scheme specific parsing
+if(schemeHandler&&schemeHandler.parse){schemeHandler.parse(components,options);}}else{parseError=true;components.error=components.error||"URI can not be parsed.";}return components;};function _recomposeAuthority(components,options){var uriTokens=[];if(components.userinfo!==undefined){uriTokens.push(components.userinfo);uriTokens.push("@");}if(components.host!==undefined){uriTokens.push(components.host);}if(typeof components.port==="number"){uriTokens.push(":");uriTokens.push(components.port.toString(10));}return uriTokens.length?uriTokens.join(""):undefined;};function removeDotSegments(input){var output=[],s;while(input.length){if(input.match(RDS1)){input=input.replace(RDS1,"");}else if(input.match(RDS2)){input=input.replace(RDS2,"/");}else if(input.match(RDS3)){input=input.replace(RDS3,"/");output.pop();}else if(input==="."||input===".."){input="";}else{s=input.match(RDS5)[0];input=input.slice(s.length);output.push(s);}}return output.join("");};function serialize(components,options){if(options===void 0){options={};}var protocol=URI__IRI_SUPPORT&&options.iri?IRI_PROTOCOL:URI_PROTOCOL,uriTokens=[],schemeHandler,authority,s;//find scheme handler
+schemeHandler=SCHEMES[(options.scheme||components.scheme||"").toLowerCase()];//perform scheme specific serialization
+if(schemeHandler&&schemeHandler.serialize)schemeHandler.serialize(components,options);//if host component is a domain name
+if(URI__IRI_SUPPORT&&typeof punycode!=="undefined"&&components.host&&(options.domainHost||schemeHandler&&schemeHandler.domainHost)){//convert IDN via punycode
+try{components.host=!options.iri?punycode.toASCII(components.host.replace(protocol.PCT_ENCODED,pctDecChars).toLowerCase()):punycode.toUnicode(components.host);}catch(e){components.error=components.error||"Host's domain name can not be converted to "+(!options.iri?"ASCII":"Unicode")+" via punycode: "+e;}}//normalize encoding
+_normalizeComponentEncoding(components,protocol);if(options.reference!=="suffix"&&components.scheme){uriTokens.push(components.scheme);uriTokens.push(":");}authority=_recomposeAuthority(components,options);if(authority!==undefined){if(options.reference!=="suffix"){uriTokens.push("//");}uriTokens.push(authority);if(components.path&&components.path.charAt(0)!=="/"){uriTokens.push("/");}}if(components.path!==undefined){s=components.path;if(!options.absolutePath&&(!schemeHandler||!schemeHandler.absolutePath)){s=removeDotSegments(s);}if(authority===undefined){s=s.replace(/^\/\//,"/%2F");//don't allow the path to start with "//"
+}uriTokens.push(s);}if(components.query!==undefined){uriTokens.push("?");uriTokens.push(components.query);}if(components.fragment!==undefined){uriTokens.push("#");uriTokens.push(components.fragment);}return uriTokens.join('');//merge tokens into a string
+};function resolveComponents(base,relative,options,skipNormalization){if(options===void 0){options={};}var target={};if(!skipNormalization){base=parse(serialize(base,options),options);//normalize base components
+relative=parse(serialize(relative,options),options);//normalize relative components
+}options=options||{};if(!options.tolerant&&relative.scheme){target.scheme=relative.scheme;//target.authority = relative.authority;
+target.userinfo=relative.userinfo;target.host=relative.host;target.port=relative.port;target.path=removeDotSegments(relative.path);target.query=relative.query;}else{if(relative.userinfo!==undefined||relative.host!==undefined||relative.port!==undefined){//target.authority = relative.authority;
+target.userinfo=relative.userinfo;target.host=relative.host;target.port=relative.port;target.path=removeDotSegments(relative.path);target.query=relative.query;}else{if(!relative.path){target.path=base.path;if(relative.query!==undefined){target.query=relative.query;}else{target.query=base.query;}}else{if(relative.path.charAt(0)==="/"){target.path=removeDotSegments(relative.path);}else{if((base.userinfo!==undefined||base.host!==undefined||base.port!==undefined)&&!base.path){target.path="/"+relative.path;}else if(!base.path){target.path=relative.path;}else{target.path=base.path.slice(0,base.path.lastIndexOf("/")+1)+relative.path;}target.path=removeDotSegments(target.path);}target.query=relative.query;}//target.authority = base.authority;
+target.userinfo=base.userinfo;target.host=base.host;target.port=base.port;}target.scheme=base.scheme;}target.fragment=relative.fragment;return target;};function resolve(baseURI,relativeURI,options){return serialize(resolveComponents(parse(baseURI,options),parse(relativeURI,options),options,true),options);};function normalize(uri,options){if(typeof uri==="string"){uri=serialize(parse(uri,options),options);}else if(typeOf(uri)==="object"){uri=parse(serialize(uri,options),options);}return uri;};function equal(uriA,uriB,options){if(typeof uriA==="string"){uriA=serialize(parse(uriA,options),options);}else if(typeOf(uriA)==="object"){uriA=serialize(uriA,options);}if(typeof uriB==="string"){uriB=serialize(parse(uriB,options),options);}else if(typeOf(uriB)==="object"){uriB=serialize(uriB,options);}return uriA===uriB;};function escapeComponent(str,options){return str&&str.toString().replace(!URI__IRI_SUPPORT||!options||!options.iri?URI_PROTOCOL.ESCAPE:IRI_PROTOCOL.ESCAPE,pctEncChar);};function unescapeComponent(str,options){return str&&str.toString().replace(!URI__IRI_SUPPORT||!options||!options.iri?URI_PROTOCOL.PCT_ENCODED:IRI_PROTOCOL.PCT_ENCODED,pctDecChars);};return{IRI_SUPPORT:URI__IRI_SUPPORT,VALIDATE_SUPPORT:URI__VALIDATE_SUPPORT,pctEncChar:pctEncChar,pctDecChars:pctDecChars,SCHEMES:SCHEMES,parse:parse,_recomposeAuthority:_recomposeAuthority,removeDotSegments:removeDotSegments,serialize:serialize,resolveComponents:resolveComponents,resolve:resolve,normalize:normalize,equal:equal,escapeComponent:escapeComponent,unescapeComponent:unescapeComponent};}();if(!COMPILED&&typeof module!=="undefined"&&typeof require==="function"){var punycode=require("./punycode");module.exports=URI;require("./schemes");}},{"./punycode":18,"./schemes":19}]},{},[1])(1);});
+
+/***/ }),
+/* 6 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__sf_path__ = __webpack_require__(0);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__schema_defaults__ = __webpack_require__(3);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__canonical_title_map__ = __webpack_require__(1);
-/* harmony export (immutable) */ exports["a"] = merge;
+/* harmony export (immutable) */ __webpack_exports__["a"] = merge;
 var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
 
 
@@ -982,13 +2702,17 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
 // export function merge(schema, form, schemaDefaultTypes, ignore, options, readonly, asyncTemplates) {
 function merge(lookup, form, ignore, options, readonly, asyncTemplates) {
   var formItems = [];
+  var formItemRest = [];
   form = form || [];
   var idx = form.indexOf('*');
   options = options || {};
+  var stdForm = {};
 
+  var idxRest = form.indexOf('...');
   if ((typeof lookup === 'undefined' ? 'undefined' : _typeof(lookup)) === 'object' && lookup.hasOwnProperty('properties')) {
     readonly = readonly || lookup.readonly || lookup.readOnly;
-    var stdForm = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__schema_defaults__["defaultForm"])(lookup, __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__schema_defaults__["createDefaults"])(), ignore, options);
+    stdForm = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__schema_defaults__["defaultForm"])(lookup, __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__schema_defaults__["createDefaults"])(), ignore, options);
+
     var defaultFormLookup = stdForm.lookup;
 
     lookup = defaultFormLookup || lookup;
@@ -997,6 +2721,34 @@ function merge(lookup, form, ignore, options, readonly, asyncTemplates) {
 
   if (idx !== -1) {
     form = form.slice(0, idx).concat(formItems).concat(form.slice(idx + 1));
+  }
+
+  //simple case, we have a "...", just put the formItemRest there
+  if (stdForm.form && idxRest !== -1) {
+    (function () {
+      var formKeys = form.map(function (obj) {
+        if (typeof obj === 'string') {
+          return obj;
+        } else if (obj.key) {
+          return obj.key;
+        };
+      }).filter(function (element) {
+        return element !== undefined;
+      });
+
+      formItemRest = formItemRest.concat(stdForm.form.map(function (obj) {
+        var isInside = formKeys.indexOf(obj.key[0]) !== -1;
+        if (!isInside) {
+          return obj;
+        };
+      }).filter(function (element) {
+        return element !== undefined;
+      }));
+    })();
+  };
+
+  if (idxRest !== -1) {
+    form = form.slice(0, idxRest).concat(formItemRest).concat(form.slice(idxRest + 1));
   };
 
   // ok let's merge!
@@ -1072,13 +2824,45 @@ function merge(lookup, form, ignore, options, readonly, asyncTemplates) {
   });
 }
 
-/***/ },
-/* 6 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 7 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
+
+"use strict";
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__lib_json_refs_standalone__ = __webpack_require__(5);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__lib_json_refs_standalone___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0__lib_json_refs_standalone__);
+/* harmony export (immutable) */ __webpack_exports__["a"] = jsonref;
+
+
+function jsonref(schema, callBack) {
+  var promise = new Promise(function (resolve, reject) {
+    __WEBPACK_IMPORTED_MODULE_0__lib_json_refs_standalone__["resolveRefs"](schema, {
+      "filter": ['relative', 'local', 'remote']
+    }).then(function (res) {
+      resolve(res.resolved);
+    }).catch(function (err) {
+      reject(new Error(err));
+    });
+  });
+
+  if (typeof callBack === 'function') {
+    promise.then(function (resolved) {
+      callBack(null, resolved);
+    }).catch(function (error) {
+      callBack(error);
+    });
+  } else {
+    return promise;
+  }
+};
+
+/***/ }),
+/* 8 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__sf_path__ = __webpack_require__(0);
-/* harmony export (immutable) */ exports["a"] = select;
+/* harmony export (immutable) */ __webpack_exports__["a"] = select;
 
 
 var numRe = /^\d+$/;
@@ -1154,13 +2938,13 @@ function select(projection, obj, valueToSet) {
   return value;
 };
 
-/***/ },
-/* 7 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 9 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
-/* harmony export (immutable) */ exports["a"] = traverseSchema;
-/* harmony export (immutable) */ exports["b"] = traverseForm;
+/* harmony export (immutable) */ __webpack_exports__["a"] = traverseSchema;
+/* harmony export (immutable) */ __webpack_exports__["b"] = traverseForm;
 /**
  * Traverse a schema, applying a function(schema,path) on every sub schema
  * i.e. every property of an object.
@@ -1209,14 +2993,14 @@ function traverseForm(form, fn) {
   }
 }
 
-/***/ },
-/* 8 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 10 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tv4__ = __webpack_require__(10);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tv4__ = __webpack_require__(12);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_tv4___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_tv4__);
-/* harmony export (immutable) */ exports["a"] = validate;
+/* harmony export (immutable) */ __webpack_exports__["a"] = validate;
 /*  Common code for validating a value against its form and schema definition */
 
 
@@ -1271,12 +3055,12 @@ function validate(form, value) {
   return __WEBPACK_IMPORTED_MODULE_0_tv4___default.a.validateResult(valueWrap, wrap);
 };
 
-/***/ },
-/* 9 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 11 */
+/***/ (function(module, exports, __webpack_require__) {
 
 "use strict";
-var __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
+var __WEBPACK_AMD_DEFINE_RESULT__;
 
 ;!function(undefined) {
 
@@ -1365,7 +3149,8 @@ var __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
 	if (true) {
 		!(__WEBPACK_AMD_DEFINE_RESULT__ = function() {
 			return {ObjectPath: ObjectPath};
-		}.call(exports, __webpack_require__, exports, module), __WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
+		}.call(exports, __webpack_require__, exports, module),
+				__WEBPACK_AMD_DEFINE_RESULT__ !== undefined && (module.exports = __WEBPACK_AMD_DEFINE_RESULT__));
 	}
 
 	// CommonJS
@@ -1380,45 +3165,74 @@ var __WEBPACK_AMD_DEFINE_RESULT__;'use strict';
 	
 }();
 
-/***/ },
-/* 10 */
-/***/ function(module, exports) {
+/***/ }),
+/* 12 */
+/***/ (function(module, exports) {
 
 module.exports = tv4;
 
-/***/ },
-/* 11 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 13 */
+/***/ (function(module, exports, __webpack_require__) {
 
 module.exports = __webpack_require__(4);
 
 
-/***/ }
+/***/ })
 /******/ ]);
 //# sourceMappingURL=json-schema-form-core.js.map
+/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(2), __webpack_require__(19).setImmediate))
+
+/***/ }),
+/* 2 */
+/***/ (function(module, exports) {
+
+var g;
+
+// This works in non-strict mode
+g = (function() {
+	return this;
+})();
+
+try {
+	// This works if eval is allowed (see CSP)
+	g = g || Function("return this")() || (1,eval)("this");
+} catch(e) {
+	// This works if the window reference is available
+	if(typeof window === "object")
+		g = window;
+}
+
+// g can still be undefined, but nothing to do about it...
+// We return undefined, instead of nothing here, so it's
+// easier to handle this case. if(!global) { ...}
+
+module.exports = g;
 
-/***/ },
-/* 2 */,
-/* 3 */
-/***/ function(module, exports, __webpack_require__) {
+
+/***/ }),
+/* 3 */,
+/* 4 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
+Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__ = __webpack_require__(1);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_angular__ = __webpack_require__(0);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_angular__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_sf_builder_provider__ = __webpack_require__(13);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_schema_form_decorators_provider__ = __webpack_require__(11);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_schema_form_provider__ = __webpack_require__(12);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_sf_error_message_provider__ = __webpack_require__(14);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_sf_path_provider__ = __webpack_require__(15);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__ = __webpack_require__(6);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__ = __webpack_require__(7);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__ = __webpack_require__(9);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__ = __webpack_require__(5);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__ = __webpack_require__(8);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__ = __webpack_require__(10);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__ = __webpack_require__(4);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_sf_builder_provider__ = __webpack_require__(14);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_schema_form_decorators_provider__ = __webpack_require__(12);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_schema_form_provider__ = __webpack_require__(13);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_sf_error_message_provider__ = __webpack_require__(15);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_sf_path_provider__ = __webpack_require__(16);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__ = __webpack_require__(7);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__ = __webpack_require__(8);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__ = __webpack_require__(10);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__ = __webpack_require__(6);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__ = __webpack_require__(9);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__ = __webpack_require__(11);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__ = __webpack_require__(5);
 
 
 
@@ -1463,24 +3277,24 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 
 // Providers and services
 .provider('sfPath', __WEBPACK_IMPORTED_MODULE_6_sf_path_provider__["a" /* default */]).provider('sfBuilder', ['sfPathProvider', __WEBPACK_IMPORTED_MODULE_2_sf_builder_provider__["a" /* default */]]).provider('schemaFormDecorators', ['$compileProvider', 'sfPathProvider', __WEBPACK_IMPORTED_MODULE_3_schema_form_decorators_provider__["a" /* default */]]).provider('sfErrorMessage', __WEBPACK_IMPORTED_MODULE_5_sf_error_message_provider__["a" /* default */]).provider('schemaForm', ['sfPathProvider', __WEBPACK_IMPORTED_MODULE_4_schema_form_provider__["a" /* default */]]).factory('sfSelect', function () {
-  return __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core___default.a.select;
+  return __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__["select"];
 }).factory('sfValidator', function () {
-  return __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core___default.a.validate;
+  return __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__["validate"];
 })
 
 // Directives
 .directive('sfChanged', __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__["a" /* default */]).directive('sfField', ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__["a" /* default */]]).directive('sfMessage', ['$injector', 'sfErrorMessage', __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__["a" /* default */]]).directive('sfNewArray', ['sfSelect', 'sfPath', 'schemaForm', __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__["a" /* default */]]).directive('sfSchema', ['$compile', '$http', '$templateCache', '$q', 'schemaForm', 'schemaFormDecorators', 'sfSelect', 'sfPath', 'sfBuilder', __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__["a" /* default */]]).directive('schemaValidate', ['sfValidator', '$parse', 'sfSelect', __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__["a" /* default */]]).directive('sfKeyController', ['schemaForm', 'sfPath', __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__["a" /* default */]]);
 
-/***/ },
-/* 4 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 5 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
 
 
-/* harmony default export */ exports["a"] = function (sfValidator, $parse, sfSelect) {
+/* harmony default export */ __webpack_exports__["a"] = function (sfValidator, $parse, sfSelect) {
   return {
     restrict: 'A',
     scope: false,
@@ -1658,9 +3472,9 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
   };
 };
 
-/***/ },
-/* 5 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 6 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
@@ -1670,7 +3484,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 /**
  * Directive that handles the model arrays
  */
-/* harmony default export */ exports["a"] = function (sel, sfPath, schemaForm) {
+/* harmony default export */ __webpack_exports__["a"] = function (sel, sfPath, schemaForm) {
   return {
     scope: true,
     controller: ['$scope', function SFArrayController($scope) {
@@ -1909,9 +3723,9 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
   };
 };
 
-/***/ },
-/* 6 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 7 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
@@ -1925,7 +3739,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
  * Takes the form definition as argument.
  * If the form definition has a "onChange" defined as either a function or
  */
-/* harmony default export */ exports["a"] = function () {
+/* harmony default export */ __webpack_exports__["a"] = function () {
   return {
     require: 'ngModel',
     restrict: 'AC',
@@ -1955,9 +3769,9 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
   };
 };
 
-/***/ },
-/* 7 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 8 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
@@ -1966,7 +3780,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
 
 
 
-/* harmony default export */ exports["a"] = function ($parse, $compile, $http, $templateCache, $interpolate, $q, sfErrorMessage, sfPath, sfSelect) {
+/* harmony default export */ __webpack_exports__["a"] = function ($parse, $compile, $http, $templateCache, $interpolate, $q, sfErrorMessage, sfPath, sfSelect) {
 
   var keyFormat = {
     COMPLETE: '*',
@@ -2284,15 +4098,15 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
   };
 };
 
-/***/ },
-/* 8 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 9 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /**
  * Directive that handles keys and array indexes
  */
-/* harmony default export */ exports["a"] = function (schemaForm, sfPath) {
+/* harmony default export */ __webpack_exports__["a"] = function (schemaForm, sfPath) {
   return {
     scope: true,
     require: ['?^^sfNewArray'],
@@ -2323,16 +4137,16 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
   };
 };;
 
-/***/ },
-/* 9 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 10 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
 
 
-/* harmony default export */ exports["a"] = function ($injector, sfErrorMessage) {
+/* harmony default export */ __webpack_exports__["a"] = function ($injector, sfErrorMessage) {
 
   //Inject sanitizer if it exists
   var $sanitize = $injector.has('$sanitize') ? $injector.get('$sanitize') : function (html) {
@@ -2427,9 +4241,9 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
   };
 };
 
-/***/ },
-/* 10 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 11 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
@@ -2441,7 +4255,7 @@ FIXME: real documentation
 <form sf-form="form"  sf-schema="schema" sf-decorator="foobar"></form>
 */
 
-/* harmony default export */ exports["a"] = function ($compile, $http, $templateCache, $q, schemaForm, schemaFormDecorators, sfSelect, sfPath, sfBuilder) {
+/* harmony default export */ __webpack_exports__["a"] = function ($compile, $http, $templateCache, $q, schemaForm, schemaFormDecorators, sfSelect, sfPath, sfBuilder) {
 
   return {
     scope: {
@@ -2499,7 +4313,17 @@ FIXME: real documentation
       var childScope;
 
       // Common renderer function, can either be triggered by a watch or by an event.
-      var render = function render(schema, form) {
+      scope.resolveReferences = function (schema, form) {
+        schemaForm.jsonref(schema).then(function (resolved) {
+          scope.render(resolved, form);
+        }).catch(function (err) {
+          new Error(err);
+        });
+      };
+
+      scope.render = function (schema, form) {
+        //console.log("schema:", JSON.stringify(schema));
+        //console.log("resolv:", JSON.stringify(resolved));
         var asyncTemplates = [];
         var merged = schemaForm.merge(schema, form, ignore, scope.options, undefined, asyncTemplates);
 
@@ -2510,14 +4334,14 @@ FIXME: real documentation
               form.template = res.data;
             });
           })).then(function () {
-            internalRender(schema, form, merged);
+            scope.internalRender(schema, form, merged);
           });
         } else {
-          internalRender(schema, form, merged);
+          scope.internalRender(schema, form, merged);
         };
       };
 
-      var internalRender = function internalRender(schema, form, merged) {
+      scope.internalRender = function (schema, form, merged) {
         // Create a new form and destroy the old one.
         // Not doing keeps old form elements hanging around after
         // they have been removed from the DOM
@@ -2534,7 +4358,12 @@ FIXME: real documentation
         childScope.schemaForm = { form: merged, schema: schema };
 
         //clean all but pre existing html.
-        element.children(':not(.schema-form-ignore)').remove();
+        Array.prototype.forEach.call(element.children(), function (child) {
+          var jchild = __WEBPACK_IMPORTED_MODULE_0_angular___default.a.element(child);
+          if (false === jchild.hasClass('schema-form-ignore')) {
+            jchild.remove();
+          };
+        });
 
         // Find all slots.
         var slots = {};
@@ -2591,7 +4420,7 @@ FIXME: real documentation
           lastDigest.schema = schema;
           lastDigest.form = form;
 
-          render(schema, form);
+          scope.resolveReferences(schema, form);
         }
       });
 
@@ -2601,7 +4430,7 @@ FIXME: real documentation
         var schema = scope.schema;
         var form = scope.initialForm ? __WEBPACK_IMPORTED_MODULE_0_angular___default.a.copy(scope.initialForm) : ['*'];
         if (schema) {
-          render(schema, form);
+          scope.resolveReferences(schema, form);
         }
       });
 
@@ -2630,16 +4459,16 @@ FIXME: real documentation
   };
 };
 
-/***/ },
-/* 11 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 12 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
 
 
-/* harmony default export */ exports["a"] = function ($compileProvider, sfPathProvider) {
+/* harmony default export */ __webpack_exports__["a"] = function ($compileProvider, sfPathProvider) {
   var defaultDecorator = '';
   var decorators = {};
 
@@ -3173,9 +5002,9 @@ FIXME: real documentation
   createDirective('sfDecorator');
 };;
 
-/***/ },
-/* 12 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 13 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
@@ -3189,7 +5018,7 @@ FIXME: real documentation
 /**
  * Schema form service.
  */
-/* harmony default export */ exports["a"] = function () {
+/* harmony default export */ __webpack_exports__["a"] = function () {
   var postProcessFn = function postProcessFn(form) {
     return form;
   };
@@ -3257,6 +5086,8 @@ FIXME: real documentation
     var service = {};
     var typeDefault = this.defaults;
 
+    service.jsonref = __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["jsonref"];
+
     service.merge = function (schema) {
       var form = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ['*'];
       var ignore = arguments[2];
@@ -3296,14 +5127,14 @@ FIXME: real documentation
   };
 };
 
-/***/ },
-/* 13 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 14 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 
 // FIXME: type template (using custom builder)
-/* harmony default export */ exports["a"] = function (sfPathProvider) {
+/* harmony default export */ __webpack_exports__["a"] = function (sfPathProvider) {
 
   var SNAKE_CASE_REGEXP = /[A-Z]/g;
   var snakeCase = function snakeCase(name, separator) {
@@ -3624,16 +5455,16 @@ FIXME: real documentation
   }];
 };
 
-/***/ },
-/* 14 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 15 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
 
 
-/* harmony default export */ exports["a"] = function () {
+/* harmony default export */ __webpack_exports__["a"] = function () {
 
   // The codes are tv4 error codes.
   // Not all of these can actually happen in a field, but for
@@ -3761,9 +5592,9 @@ FIXME: real documentation
   }];
 };
 
-/***/ },
-/* 15 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 16 */
+/***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__ = __webpack_require__(1);
@@ -3799,25 +5630,651 @@ var sfPathProviderClass = function () {
   return sfPathProviderClass;
 }();
 
-/* harmony default export */ exports["a"] = sfPathProviderClass;
+/* harmony default export */ __webpack_exports__["a"] = sfPathProviderClass;
 
-/***/ },
-/* 16 */
-/***/ function(module, exports, __webpack_require__) {
+/***/ }),
+/* 17 */
+/***/ (function(module, exports) {
+
+// shim for using process in browser
+var process = module.exports = {};
+
+// cached from whatever global is present so that test runners that stub it
+// don't break things.  But we need to wrap it in a try catch in case it is
+// wrapped in strict mode code which doesn't define any globals.  It's inside a
+// function because try/catches deoptimize in certain engines.
+
+var cachedSetTimeout;
+var cachedClearTimeout;
+
+function defaultSetTimout() {
+    throw new Error('setTimeout has not been defined');
+}
+function defaultClearTimeout () {
+    throw new Error('clearTimeout has not been defined');
+}
+(function () {
+    try {
+        if (typeof setTimeout === 'function') {
+            cachedSetTimeout = setTimeout;
+        } else {
+            cachedSetTimeout = defaultSetTimout;
+        }
+    } catch (e) {
+        cachedSetTimeout = defaultSetTimout;
+    }
+    try {
+        if (typeof clearTimeout === 'function') {
+            cachedClearTimeout = clearTimeout;
+        } else {
+            cachedClearTimeout = defaultClearTimeout;
+        }
+    } catch (e) {
+        cachedClearTimeout = defaultClearTimeout;
+    }
+} ())
+function runTimeout(fun) {
+    if (cachedSetTimeout === setTimeout) {
+        //normal enviroments in sane situations
+        return setTimeout(fun, 0);
+    }
+    // if setTimeout wasn't available but was latter defined
+    if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {
+        cachedSetTimeout = setTimeout;
+        return setTimeout(fun, 0);
+    }
+    try {
+        // when when somebody has screwed with setTimeout but no I.E. maddness
+        return cachedSetTimeout(fun, 0);
+    } catch(e){
+        try {
+            // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
+            return cachedSetTimeout.call(null, fun, 0);
+        } catch(e){
+            // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error
+            return cachedSetTimeout.call(this, fun, 0);
+        }
+    }
+
+
+}
+function runClearTimeout(marker) {
+    if (cachedClearTimeout === clearTimeout) {
+        //normal enviroments in sane situations
+        return clearTimeout(marker);
+    }
+    // if clearTimeout wasn't available but was latter defined
+    if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {
+        cachedClearTimeout = clearTimeout;
+        return clearTimeout(marker);
+    }
+    try {
+        // when when somebody has screwed with setTimeout but no I.E. maddness
+        return cachedClearTimeout(marker);
+    } catch (e){
+        try {
+            // When we are in I.E. but the script has been evaled so I.E. doesn't  trust the global object when called normally
+            return cachedClearTimeout.call(null, marker);
+        } catch (e){
+            // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.
+            // Some versions of I.E. have different rules for clearTimeout vs setTimeout
+            return cachedClearTimeout.call(this, marker);
+        }
+    }
+
+
+
+}
+var queue = [];
+var draining = false;
+var currentQueue;
+var queueIndex = -1;
+
+function cleanUpNextTick() {
+    if (!draining || !currentQueue) {
+        return;
+    }
+    draining = false;
+    if (currentQueue.length) {
+        queue = currentQueue.concat(queue);
+    } else {
+        queueIndex = -1;
+    }
+    if (queue.length) {
+        drainQueue();
+    }
+}
+
+function drainQueue() {
+    if (draining) {
+        return;
+    }
+    var timeout = runTimeout(cleanUpNextTick);
+    draining = true;
+
+    var len = queue.length;
+    while(len) {
+        currentQueue = queue;
+        queue = [];
+        while (++queueIndex < len) {
+            if (currentQueue) {
+                currentQueue[queueIndex].run();
+            }
+        }
+        queueIndex = -1;
+        len = queue.length;
+    }
+    currentQueue = null;
+    draining = false;
+    runClearTimeout(timeout);
+}
+
+process.nextTick = function (fun) {
+    var args = new Array(arguments.length - 1);
+    if (arguments.length > 1) {
+        for (var i = 1; i < arguments.length; i++) {
+            args[i - 1] = arguments[i];
+        }
+    }
+    queue.push(new Item(fun, args));
+    if (queue.length === 1 && !draining) {
+        runTimeout(drainQueue);
+    }
+};
+
+// v8 likes predictible objects
+function Item(fun, array) {
+    this.fun = fun;
+    this.array = array;
+}
+Item.prototype.run = function () {
+    this.fun.apply(null, this.array);
+};
+process.title = 'browser';
+process.browser = true;
+process.env = {};
+process.argv = [];
+process.version = ''; // empty string to avoid regexp issues
+process.versions = {};
+
+function noop() {}
+
+process.on = noop;
+process.addListener = noop;
+process.once = noop;
+process.off = noop;
+process.removeListener = noop;
+process.removeAllListeners = noop;
+process.emit = noop;
+
+process.binding = function (name) {
+    throw new Error('process.binding is not supported');
+};
+
+process.cwd = function () { return '/' };
+process.chdir = function (dir) {
+    throw new Error('process.chdir is not supported');
+};
+process.umask = function() { return 0; };
+
+
+/***/ }),
+/* 18 */
+/***/ (function(module, exports, __webpack_require__) {
+
+/* WEBPACK VAR INJECTION */(function(global, process) {(function (global, undefined) {
+    "use strict";
+
+    if (global.setImmediate) {
+        return;
+    }
+
+    var nextHandle = 1; // Spec says greater than zero
+    var tasksByHandle = {};
+    var currentlyRunningATask = false;
+    var doc = global.document;
+    var registerImmediate;
+
+    function setImmediate(callback) {
+      // Callback can either be a function or a string
+      if (typeof callback !== "function") {
+        callback = new Function("" + callback);
+      }
+      // Copy function arguments
+      var args = new Array(arguments.length - 1);
+      for (var i = 0; i < args.length; i++) {
+          args[i] = arguments[i + 1];
+      }
+      // Store and register the task
+      var task = { callback: callback, args: args };
+      tasksByHandle[nextHandle] = task;
+      registerImmediate(nextHandle);
+      return nextHandle++;
+    }
+
+    function clearImmediate(handle) {
+        delete tasksByHandle[handle];
+    }
+
+    function run(task) {
+        var callback = task.callback;
+        var args = task.args;
+        switch (args.length) {
+        case 0:
+            callback();
+            break;
+        case 1:
+            callback(args[0]);
+            break;
+        case 2:
+            callback(args[0], args[1]);
+            break;
+        case 3:
+            callback(args[0], args[1], args[2]);
+            break;
+        default:
+            callback.apply(undefined, args);
+            break;
+        }
+    }
+
+    function runIfPresent(handle) {
+        // From the spec: "Wait until any invocations of this algorithm started before this one have completed."
+        // So if we're currently running a task, we'll need to delay this invocation.
+        if (currentlyRunningATask) {
+            // Delay by doing a setTimeout. setImmediate was tried instead, but in Firefox 7 it generated a
+            // "too much recursion" error.
+            setTimeout(runIfPresent, 0, handle);
+        } else {
+            var task = tasksByHandle[handle];
+            if (task) {
+                currentlyRunningATask = true;
+                try {
+                    run(task);
+                } finally {
+                    clearImmediate(handle);
+                    currentlyRunningATask = false;
+                }
+            }
+        }
+    }
+
+    function installNextTickImplementation() {
+        registerImmediate = function(handle) {
+            process.nextTick(function () { runIfPresent(handle); });
+        };
+    }
+
+    function canUsePostMessage() {
+        // The test against `importScripts` prevents this implementation from being installed inside a web worker,
+        // where `global.postMessage` means something completely different and can't be used for this purpose.
+        if (global.postMessage && !global.importScripts) {
+            var postMessageIsAsynchronous = true;
+            var oldOnMessage = global.onmessage;
+            global.onmessage = function() {
+                postMessageIsAsynchronous = false;
+            };
+            global.postMessage("", "*");
+            global.onmessage = oldOnMessage;
+            return postMessageIsAsynchronous;
+        }
+    }
+
+    function installPostMessageImplementation() {
+        // Installs an event handler on `global` for the `message` event: see
+        // * https://developer.mozilla.org/en/DOM/window.postMessage
+        // * http://www.whatwg.org/specs/web-apps/current-work/multipage/comms.html#crossDocumentMessages
+
+        var messagePrefix = "setImmediate$" + Math.random() + "$";
+        var onGlobalMessage = function(event) {
+            if (event.source === global &&
+                typeof event.data === "string" &&
+                event.data.indexOf(messagePrefix) === 0) {
+                runIfPresent(+event.data.slice(messagePrefix.length));
+            }
+        };
+
+        if (global.addEventListener) {
+            global.addEventListener("message", onGlobalMessage, false);
+        } else {
+            global.attachEvent("onmessage", onGlobalMessage);
+        }
+
+        registerImmediate = function(handle) {
+            global.postMessage(messagePrefix + handle, "*");
+        };
+    }
+
+    function installMessageChannelImplementation() {
+        var channel = new MessageChannel();
+        channel.port1.onmessage = function(event) {
+            var handle = event.data;
+            runIfPresent(handle);
+        };
+
+        registerImmediate = function(handle) {
+            channel.port2.postMessage(handle);
+        };
+    }
+
+    function installReadyStateChangeImplementation() {
+        var html = doc.documentElement;
+        registerImmediate = function(handle) {
+            // Create a <script> element; its readystatechange event will be fired asynchronously once it is inserted
+            // into the document. Do so, thus queuing up the task. Remember to clean up once it's been called.
+            var script = doc.createElement("script");
+            script.onreadystatechange = function () {
+                runIfPresent(handle);
+                script.onreadystatechange = null;
+                html.removeChild(script);
+                script = null;
+            };
+            html.appendChild(script);
+        };
+    }
+
+    function installSetTimeoutImplementation() {
+        registerImmediate = function(handle) {
+            setTimeout(runIfPresent, 0, handle);
+        };
+    }
+
+    // If supported, we should attach to the prototype of global, since that is where setTimeout et al. live.
+    var attachTo = Object.getPrototypeOf && Object.getPrototypeOf(global);
+    attachTo = attachTo && attachTo.setTimeout ? attachTo : global;
+
+    // Don't get fooled by e.g. browserify environments.
+    if ({}.toString.call(global.process) === "[object process]") {
+        // For Node.js before 0.9
+        installNextTickImplementation();
+
+    } else if (canUsePostMessage()) {
+        // For non-IE10 modern browsers
+        installPostMessageImplementation();
+
+    } else if (global.MessageChannel) {
+        // For web workers, where supported
+        installMessageChannelImplementation();
+
+    } else if (doc && "onreadystatechange" in doc.createElement("script")) {
+        // For IE 6–8
+        installReadyStateChangeImplementation();
+
+    } else {
+        // For older browsers
+        installSetTimeoutImplementation();
+    }
+
+    attachTo.setImmediate = setImmediate;
+    attachTo.clearImmediate = clearImmediate;
+}(typeof self === "undefined" ? typeof global === "undefined" ? this : global : self));
+
+/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(2), __webpack_require__(17)))
+
+/***/ }),
+/* 19 */
+/***/ (function(module, exports, __webpack_require__) {
+
+var apply = Function.prototype.apply;
+
+// DOM APIs, for completeness
+
+exports.setTimeout = function() {
+  return new Timeout(apply.call(setTimeout, window, arguments), clearTimeout);
+};
+exports.setInterval = function() {
+  return new Timeout(apply.call(setInterval, window, arguments), clearInterval);
+};
+exports.clearTimeout =
+exports.clearInterval = function(timeout) {
+  if (timeout) {
+    timeout.close();
+  }
+};
+
+function Timeout(id, clearFn) {
+  this._id = id;
+  this._clearFn = clearFn;
+}
+Timeout.prototype.unref = Timeout.prototype.ref = function() {};
+Timeout.prototype.close = function() {
+  this._clearFn.call(window, this._id);
+};
+
+// Does not start the time, just sets up the members needed.
+exports.enroll = function(item, msecs) {
+  clearTimeout(item._idleTimeoutId);
+  item._idleTimeout = msecs;
+};
+
+exports.unenroll = function(item) {
+  clearTimeout(item._idleTimeoutId);
+  item._idleTimeout = -1;
+};
+
+exports._unrefActive = exports.active = function(item) {
+  clearTimeout(item._idleTimeoutId);
+
+  var msecs = item._idleTimeout;
+  if (msecs >= 0) {
+    item._idleTimeoutId = setTimeout(function onTimeout() {
+      if (item._onTimeout)
+        item._onTimeout();
+    }, msecs);
+  }
+};
+
+// setimmediate attaches itself to the global object
+__webpack_require__(18);
+exports.setImmediate = setImmediate;
+exports.clearImmediate = clearImmediate;
+
+
+/***/ }),
+/* 20 */,
+/* 21 */
+/***/ (function(module, exports, __webpack_require__) {
 
 __webpack_require__(1);
-module.exports = __webpack_require__(3);
+module.exports = __webpack_require__(4);
 
 
-/***/ }
+/***/ })
 /******/ ]);
+/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(1).setImmediate, __webpack_require__(1).clearImmediate))
 
 /***/ },
-/* 19 */,
 /* 20 */
+/***/ function(module, exports) {
+
+// shim for using process in browser
+var process = module.exports = {};
+
+// cached from whatever global is present so that test runners that stub it
+// don't break things.  But we need to wrap it in a try catch in case it is
+// wrapped in strict mode code which doesn't define any globals.  It's inside a
+// function because try/catches deoptimize in certain engines.
+
+var cachedSetTimeout;
+var cachedClearTimeout;
+
+function defaultSetTimout() {
+    throw new Error('setTimeout has not been defined');
+}
+function defaultClearTimeout () {
+    throw new Error('clearTimeout has not been defined');
+}
+(function () {
+    try {
+        if (typeof setTimeout === 'function') {
+            cachedSetTimeout = setTimeout;
+        } else {
+            cachedSetTimeout = defaultSetTimout;
+        }
+    } catch (e) {
+        cachedSetTimeout = defaultSetTimout;
+    }
+    try {
+        if (typeof clearTimeout === 'function') {
+            cachedClearTimeout = clearTimeout;
+        } else {
+            cachedClearTimeout = defaultClearTimeout;
+        }
+    } catch (e) {
+        cachedClearTimeout = defaultClearTimeout;
+    }
+} ())
+function runTimeout(fun) {
+    if (cachedSetTimeout === setTimeout) {
+        //normal enviroments in sane situations
+        return setTimeout(fun, 0);
+    }
+    // if setTimeout wasn't available but was latter defined
+    if ((cachedSetTimeout === defaultSetTimout || !cachedSetTimeout) && setTimeout) {
+        cachedSetTimeout = setTimeout;
+        return setTimeout(fun, 0);
+    }
+    try {
+        // when when somebody has screwed with setTimeout but no I.E. maddness
+        return cachedSetTimeout(fun, 0);
+    } catch(e){
+        try {
+            // When we are in I.E. but the script has been evaled so I.E. doesn't trust the global object when called normally
+            return cachedSetTimeout.call(null, fun, 0);
+        } catch(e){
+            // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error
+            return cachedSetTimeout.call(this, fun, 0);
+        }
+    }
+
+
+}
+function runClearTimeout(marker) {
+    if (cachedClearTimeout === clearTimeout) {
+        //normal enviroments in sane situations
+        return clearTimeout(marker);
+    }
+    // if clearTimeout wasn't available but was latter defined
+    if ((cachedClearTimeout === defaultClearTimeout || !cachedClearTimeout) && clearTimeout) {
+        cachedClearTimeout = clearTimeout;
+        return clearTimeout(marker);
+    }
+    try {
+        // when when somebody has screwed with setTimeout but no I.E. maddness
+        return cachedClearTimeout(marker);
+    } catch (e){
+        try {
+            // When we are in I.E. but the script has been evaled so I.E. doesn't  trust the global object when called normally
+            return cachedClearTimeout.call(null, marker);
+        } catch (e){
+            // same as above but when it's a version of I.E. that must have the global object for 'this', hopfully our context correct otherwise it will throw a global error.
+            // Some versions of I.E. have different rules for clearTimeout vs setTimeout
+            return cachedClearTimeout.call(this, marker);
+        }
+    }
+
+
+
+}
+var queue = [];
+var draining = false;
+var currentQueue;
+var queueIndex = -1;
+
+function cleanUpNextTick() {
+    if (!draining || !currentQueue) {
+        return;
+    }
+    draining = false;
+    if (currentQueue.length) {
+        queue = currentQueue.concat(queue);
+    } else {
+        queueIndex = -1;
+    }
+    if (queue.length) {
+        drainQueue();
+    }
+}
+
+function drainQueue() {
+    if (draining) {
+        return;
+    }
+    var timeout = runTimeout(cleanUpNextTick);
+    draining = true;
+
+    var len = queue.length;
+    while(len) {
+        currentQueue = queue;
+        queue = [];
+        while (++queueIndex < len) {
+            if (currentQueue) {
+                currentQueue[queueIndex].run();
+            }
+        }
+        queueIndex = -1;
+        len = queue.length;
+    }
+    currentQueue = null;
+    draining = false;
+    runClearTimeout(timeout);
+}
+
+process.nextTick = function (fun) {
+    var args = new Array(arguments.length - 1);
+    if (arguments.length > 1) {
+        for (var i = 1; i < arguments.length; i++) {
+            args[i - 1] = arguments[i];
+        }
+    }
+    queue.push(new Item(fun, args));
+    if (queue.length === 1 && !draining) {
+        runTimeout(drainQueue);
+    }
+};
+
+// v8 likes predictible objects
+function Item(fun, array) {
+    this.fun = fun;
+    this.array = array;
+}
+Item.prototype.run = function () {
+    this.fun.apply(null, this.array);
+};
+process.title = 'browser';
+process.browser = true;
+process.env = {};
+process.argv = [];
+process.version = ''; // empty string to avoid regexp issues
+process.versions = {};
+
+function noop() {}
+
+process.on = noop;
+process.addListener = noop;
+process.once = noop;
+process.off = noop;
+process.removeListener = noop;
+process.removeAllListeners = noop;
+process.emit = noop;
+
+process.binding = function (name) {
+    throw new Error('process.binding is not supported');
+};
+
+process.cwd = function () { return '/' };
+process.chdir = function (dir) {
+    throw new Error('process.chdir is not supported');
+};
+process.umask = function() { return 0; };
+
+
+/***/ },
+/* 21 */,
+/* 22 */
 /***/ function(module, exports, __webpack_require__) {
 
-__webpack_require__(18);
+__webpack_require__(19);
 module.exports = __webpack_require__(0);
 
 
diff --git a/dist/angular-schema-form-bootstrap-bundled.min.js b/dist/angular-schema-form-bootstrap-bundled.min.js
index c7ecf19..b7a717d 100644
--- a/dist/angular-schema-form-bootstrap-bundled.min.js
+++ b/dist/angular-schema-form-bootstrap-bundled.min.js
@@ -1,26 +1,39 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.1
- * @date Sat, 14 Jan 2017 17:11:45 GMT
+ * @date Tue, 21 Feb 2017 11:44:44 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function r(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,r),a.l=!0,a.exports}var t={};return r.m=e,r.c=t,r.i=function(e){return e},r.d=function(e,r,t){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:t})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=21)}([function(e,r,t){t(17)},function(e,r){var t="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r){var t="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(t,n)}]),e.exports=t},function(e,r,t){"use strict";function n(e,r,t,n,a){var o=t.builders.simpleTransclusion,l=t.builders.ngModelOptions,f=t.builders.ngModel,d=t.builders.sfField,m=t.builders.condition,h=t.builders.array,v=t.builders.numeric,b=function(e){if(e.form.tabs&&e.form.tabs.length>0){var r=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(t,n){var a="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',o=document.createElement("div");o.className="tab-pane",o.setAttribute("ng-disabled","form.readonly"),o.setAttribute("ng-show","selected.tab === "+n),o.setAttribute("ng-class","{active: selected.tab === "+n+"}"),t.condition&&o.setAttribute("ng-if",a);var i=e.build(t.items,e.path+".tabs["+n+"].items",e.state);o.appendChild(i),r.appendChild(o)})}},x=function(e){if(e.form.placeholder){var r=e.fieldFrag.querySelector("select"),t=document.createElement("option");t.setAttribute("value",""),t.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?t.setAttribute("ng-if","$$value$$ === undefined"):t.setAttribute("ng-show","$$value$$ === undefined"),t.textContent=e.form.placeholder,r.appendChild(t)}},C=[d,f,l,m];r.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,f,h,m]},button:{template:F.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:u.a,builder:[d,l,f,h,m]},conditional:{template:A.a,builder:[d,o,m]},default:{template:p.a,builder:C},fieldset:{template:g.a,builder:[d,o,m]},help:{template:y.a,builder:C},number:{template:p.a,builder:C.concat(v)},password:{template:p.a,builder:C},radios:{template:k.a,builder:C},"radios-inline":{template:M.a,builder:C},radiobuttons:{template:$.a,builder:C},section:{template:A.a,builder:[d,o,m]},select:{template:E.a,builder:C.concat(x)},submit:{template:F.a,builder:C},tabarray:{template:I.a,builder:[d,l,f,h,m]},tabs:{template:P.a,builder:[d,l,b,m]},textarea:{template:T.a,builder:C}},[])}function a(){return function(e){if(!e)return"";var r,t,n;for(n=e.slice(),t=0;t<n.length;t++)r=n[t].toLowerCase().split(""),t&&r.length&&(r[0]=r[0].toUpperCase()),n[t]=r.join("");return n.join("")}}var o=t(1),i=t.n(o),l=t(2),s=t.n(l),f=t(3),c=t.n(f),d=t(4),u=t.n(d),m=t(5),p=t.n(m),h=t(6),g=t.n(h),v=t(7),y=t.n(v),b=t(8),$=t.n(b),x=t(10),k=t.n(x),C=t(9),M=t.n(C),w=t(11),A=t.n(w),S=t(12),E=t.n(S),O=t(13),F=t.n(O),D=t(14),I=t.n(D),V=t(15),P=t.n(V),j=t(16),T=t.n(j);angular.module("schemaForm").config(n).filter("sfCamelKey",a),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,r){/*!
+!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,v=r.builders.array,g=r.builders.numeric,w=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},E=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,v,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,v,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:y.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:x.a,builder:C},"radios-inline":{template:$.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:C.concat(E)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,v,m]},tabs:{template:D.a,builder:[d,l,w,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),v=r(8),y=r.n(v),g=r(9),b=r.n(g),w=r(11),x=r.n(w),E=r(10),$=r.n(E),C=r(12),k=r.n(C),A=r(13),T=r.n(A),O=r(14),S=r.n(O),P=r(15),M=r.n(P),j=r(16),D=r.n(j),I=r(17),_=r.n(I);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
  * angular-schema-form
- * @version 1.0.0-alpha.1
- * @date Sat, 14 Jan 2017 17:09:44 GMT
+ * @version 1.0.0-alpha.2
+ * @date Sun, 19 Feb 2017 13:13:18 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function r(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,r),a.l=!0,a.exports}var t={};return r.m=e,r.c=t,r.i=function(e){return e},r.d=function(e,r,t){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:t})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=16)}([function(e,r){e.exports=angular},function(e,r){/*!
+!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=21)}([function(e,t){e.exports=angular},function(e,t,r){(function(t,r){/*!
  * json-schema-form-core
- * @version 1.0.0-alpha.1
- * @date Sat, 14 Jan 2017 17:07:51 GMT
+ * @version 1.0.0-alpha.2
+ * @date Sun, 19 Feb 2017 13:06:51 GMT
  * @link https://github.com/json-schema-form/json-schema-form-core
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-e.exports=function(e){function r(n){if(t[n])return t[n].exports;var a=t[n]={i:n,l:!1,exports:{}};return e[n].call(a.exports,a,a.exports,r),a.l=!0,a.exports}var t={};return r.m=e,r.c=t,r.i=function(e){return e},r.d=function(e,r,t){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:t})},r.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(t,"a",t),t},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=11)}([function(e,r,t){"use strict";function n(e,r){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(e){var a=e.slice(),o=r||"-";return n&&(a=a.filter(function(e){return"number"!=typeof e})),(0!==t.length?t+o:"")+a.join(o)}return""}var a=t(2);t.n(a);r.name=n,t.o(a,"parse")&&t.d(r,"parse",function(){return a.parse}),t.o(a,"stringify")&&t.d(r,"stringify",function(){return a.stringify}),t.o(a,"normalize")&&t.d(r,"normalize",function(){return a.normalize})},function(e,r,t){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};r.a=function(e,r){if(!Array.isArray(e)){var t=function(){var t=[];return r?r.forEach(function(r){t.push({name:e[r],value:r})}):Object.keys(e).forEach(function(r){t.push({name:e[r],value:r})}),{v:t}}();if("object"===("undefined"==typeof t?"undefined":n(t)))return t.v}return e}},function(e,r,t){e.exports=t(9).ObjectPath},function(e,r,t){"use strict";function n(e,r,t,a){var o=e[y(t.type)];if(o)for(var i=void 0,l=function(r,t,a){return n(e,r,t,a)},s=0;s<o.length;s++)if(i=o[s](r,t,a,l))return i.schema["x-schema-form"]&&Object.assign(i,i.schema["x-schema-form"]),i}function a(e,r,n){n=n||{};var a=n.global&&n.global.formDefaults?Object.assign({},n.global.formDefaults):{};return n.global&&n.global.supressPropertyTitles===!0?a.title=r.title:a.title=r.title||e,r.description&&(a.description=r.description),n.required!==!0&&r.required!==!0||(a.required=!0),r.maxLength&&(a.maxlength=r.maxLength),r.minLength&&(a.minlength=r.minLength),(r.readOnly||r.readonly)&&(a.readonly=!0),r.minimum&&(a.minimum=r.minimum+(r.exclusiveMinimum?1:0)),r.maximum&&(a.maximum=r.maximum-(r.exclusiveMaximum?1:0)),r.validationMessage&&(a.validationMessage=r.validationMessage),r.enumNames&&(a.titleMap=t.i(g.a)(r.enumNames,r.enum)),a.schema=r,a.ngModelOptions=a.ngModelOptions||{},a}function o(e,r,n){if("string"===y(r.type)&&!r.enum){var o=a(e,r,n);return o.key=n.path,o.type="text",n.lookup[t.i(h.stringify)(n.path)]=o,o}}function i(e,r,n){if("number"===y(r.type)){var o=a(e,r,n);return o.key=n.path,o.type="number",n.lookup[t.i(h.stringify)(n.path)]=o,o}}function l(e,r,n){if("integer"===y(r.type)){var o=a(e,r,n);return o.key=n.path,o.type="number",n.lookup[t.i(h.stringify)(n.path)]=o,o}}function s(e,r,n){if("boolean"===y(r.type)){var o=a(e,r,n);return o.key=n.path,o.type="checkbox",n.lookup[t.i(h.stringify)(n.path)]=o,o}}function f(e,r,n){if("string"===y(r.type)&&r.enum){var o=a(e,r,n);return o.key=n.path,o.type="select",o.titleMap||(o.titleMap=b(r.enum)),n.lookup[t.i(h.stringify)(n.path)]=o,o}}function c(e,r,n){if("array"===y(r.type)&&r.items&&r.items.enum){var o=a(e,r,n);return o.key=n.path,o.type="checkboxes",o.titleMap||(o.titleMap=b(r.items.enum)),n.lookup[t.i(h.stringify)(n.path)]=o,o}}function d(e,r,n,o){if("object"===y(r.type)){var i=function(){var i=a(e,r,n);return i.type="fieldset",i.key=n.path,i.items=[],n.lookup[t.i(h.stringify)(n.path)]=i,r.properties&&Object.keys(r.properties).forEach(function(e){var a=r.properties[e],l=n.path.slice();if(l.push(e),n.ignore[t.i(h.stringify)(l)]!==!0){var s=r.required&&r.required.indexOf(e)!==-1,f=o(e,a,{path:l,required:s||!1,lookup:n.lookup,ignore:n.ignore,global:n.global});f&&i.items.push(f)}}),{v:i}}();if("object"===("undefined"==typeof i?"undefined":v(i)))return i.v}}function u(e,r,n,o){if("array"===y(r.type)){var i=a(e,r,n);i.type="array",i.key=n.path,n.lookup[t.i(h.stringify)(n.path)]=i;var l=r.required&&r.required.indexOf(n.path[n.path.length-1])!==-1,s=n.path.slice();return s.push(""),i.items=[o(e,r.items,{path:s,required:l||!1,lookup:n.lookup,ignore:n.ignore,global:n.global})],i}}function m(){return{string:[f,o],object:[d],number:[i],integer:[l],boolean:[s],array:[c,u]}}function p(e,r,t,a){var o=[],i={};if(t=t||{},a=a||{},r=r||m(),!e.properties)throw new Error('Not implemented. Only type "object" allowed at root level of schema.');return Object.keys(e.properties).forEach(function(l){if(t[l]!==!0){var s=e.required&&e.required.indexOf(l)!==-1,f=n(r,l,e.properties[l],{path:[l],lookup:i,ignore:t,required:s,global:a});f&&o.push(f)}}),{form:o,lookup:i}}var h=t(0),g=t(1);r.defaultFormDefinition=n,r.stdFormObj=a,r.text=o,r.number=i,r.integer=l,r.checkbox=s,r.select=f,r.checkboxes=c,r.fieldset=d,r.array=u,r.createDefaults=m,r.defaultForm=p;var v="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},y=function(e){if(Array.isArray(e)&&2===e.length){if("null"===e[0])return e[1];if("null"===e[1])return e[0]}return e},b=function(e){var r=[];return e.forEach(function(e){r.push({name:e,value:e})}),r}},function(e,r,t){"use strict";var n=t(3),a=t(0),o=t(1),i=t(5),l=t(6),s=t(7),f=t(8);t.d(r,"sfPath",function(){return c}),t.d(r,"schemaDefaults",function(){return d}),t.d(r,"canonicalTitleMap",function(){return u}),t.d(r,"merge",function(){return i.a}),t.d(r,"select",function(){return l.a}),t.d(r,"traverseSchema",function(){return s.a}),t.d(r,"traverseForm",function(){return s.b}),t.d(r,"validate",function(){return f.a});var c=a,d=n,u=o.a},function(e,r,t){"use strict";function n(e,r,s,f,c,d){var u=[];r=r||[];var m=r.indexOf("*");if(f=f||{},"object"===("undefined"==typeof e?"undefined":l(e))&&e.hasOwnProperty("properties")){c=c||e.readonly||e.readOnly;var p=t.i(o.defaultForm)(e,t.i(o.createDefaults)(),s,f),h=p.lookup;e=h||e,u=u.concat(p.form)}return m!==-1&&(r=r.slice(0,m).concat(u).concat(r.slice(m+1))),r.map(function(r){if("string"==typeof r&&(r={key:r}),r.key&&"string"==typeof r.key&&(r.key=t.i(a.parse)(r.key)),r.titleMap&&(r.titleMap=t.i(i.a)(r.titleMap)),r.key){var o=t.i(a.stringify)(r.key);e[o]&&!function(){var t=e[o];t&&Object.keys(t).forEach(function(e){void 0===r[e]&&(r[e]=t[e])})}()}return c===!0&&(r.readonly=!0),r.items&&(r.items=n(e,r.items,s,f,r.readonly,d)),r.tabs&&r.tabs.forEach(function(t){t.items&&(t.items=n(e,t.items,s,f,r.readonly,d))}),"checkbox"===r.type&&void 0===r.schema.default&&(r.schema.default=!1),d&&"template"===r.type&&!r.template&&r.templateUrl&&d.push(r),r})}var a=t(0),o=t(3),i=t(1);r.a=n;var l="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e}},function(e,r,t){"use strict";function n(e,r,t){r||(r=this);var n="string"==typeof e?a.parse(e):e;if("undefined"!=typeof t&&1===n.length)return r[n[0]]=t,r;"undefined"!=typeof t&&"undefined"==typeof r[n[0]]&&(r[n[0]]=n.length>2&&o.test(n[1])?[]:{});for(var i=r[n[0]],l=1;l<n.length;l++){if(""===n[l])return;if("undefined"!=typeof t){if(l===n.length-1)return i[n[l]]=t,t;var s=i[n[l]];"undefined"!=typeof s&&null!==s||(s=o.test(n[l+1])?[]:{},i[n[l]]=s),i=s}else i&&(i=i[n[l]])}return i}var a=t(0);r.a=n;var o=/^\d+$/},function(e,r,t){"use strict";function n(e,r,t,n){n=void 0===n||n,t=t||[];var a=function e(r,t,a){if(t(r,a),r.properties&&Object.keys(r.properties).forEach(function(n){var o=a.slice();o.push(n),e(r.properties[n],t,o)}),!n&&r.items){var o=a.slice();o.push(""),e(r.items,t,o)}};a(e,r,t||[])}function a(e,r){r(e),e.items&&e.items.forEach(function(e){a(e,r)}),e.tabs&&e.tabs.forEach(function(e){e.items&&e.items.forEach(function(e){a(e,r)})})}r.a=n,r.b=a},function(e,r,t){"use strict";function n(e,r){if(!e)return{valid:!0};var t=e.schema;if(!t)return{valid:!0};""===r&&(r=void 0),"number"===e.type&&null===r&&(r=void 0);var n={type:"object",properties:{},required:void 0},a=e.key[e.key.length-1];n.properties[a]=t,e.required&&(n.required=[a]);var i={};return r&&(i[a]=r),o.a.validateResult(i,n)}var a=t(10),o=t.n(a);r.a=n},function(e,r,t){"use strict";var n;!function(a){var o={parse:function(e){if("string"!=typeof e)throw new TypeError("ObjectPath.parse must be passed a string");for(var r,t,n,a,o=0,i=[];o<e.length;)if(r=e.indexOf(".",o),t=e.indexOf("[",o),r===-1&&t===-1)i.push(e.slice(o,e.length)),o=e.length;else if(t===-1||r!==-1&&r<t)i.push(e.slice(o,r)),o=r+1;else if(t>o&&(i.push(e.slice(o,t)),o=t),n=e.slice(t+1,t+2),'"'!==n&&"'"!==n)a=e.indexOf("]",t),a===-1&&(a=e.length),i.push(e.slice(o+1,a)),o="."===e.slice(a+1,a+2)?a+2:a+1;else{for(a=e.indexOf(n+"]",t),a===-1&&(a=e.length);"\\"===e.slice(a-1,a)&&t<e.length;)t++,a=e.indexOf(n+"]",t);i.push(e.slice(o+2,a).replace(new RegExp("\\"+n,"g"),n)),o="."===e.slice(a+2,a+3)?a+3:a+2}return i},stringify:function(e,r){return Array.isArray(e)||(e=[e.toString()]),r='"'===r?'"':"'",e.map(function(e){return"["+r+e.toString().replace(new RegExp(r,"g"),"\\"+r)+r+"]"}).join("")},normalize:function(e,r){return o.stringify(Array.isArray(e)?e:o.parse(e),r)},registerModule:function(e){e.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=o.parse,this.stringify=o.stringify,this.normalize=o.normalize,this.$get=function(){return o}})}};n=function(){return{ObjectPath:o}}.call(r,t,r,e),!(n!==a&&(e.exports=n))}()},function(e,r){e.exports=tv4},function(e,r,t){e.exports=t(4)}])},,function(e,r,t){"use strict";var n=t(1),a=t.n(n),o=t(0),i=t.n(o),l=t(13),s=t(11),f=t(12),c=t(14),d=t(15),u=t(6),m=t(7),p=t(9),h=t(5),g=t(8),v=t(10),y=t(4),b=[];try{i.a.module("ngSanitize"),b.push("ngSanitize")}catch(e){}try{i.a.module("ui.sortable"),b.push("ui.sortable")}catch(e){}try{i.a.module("angularSpectrumColorpicker"),b.push("angularSpectrumColorpicker")}catch(e){}i.a.module("schemaForm",b).provider("sfPath",d.a).provider("sfBuilder",["sfPathProvider",l.a]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",s.a]).provider("sfErrorMessage",c.a).provider("schemaForm",["sfPathProvider",f.a]).factory("sfSelect",function(){return a.a.select}).factory("sfValidator",function(){return a.a.validate}).directive("sfChanged",u.a).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",m.a]).directive("sfMessage",["$injector","sfErrorMessage",p.a]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",h.a]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",v.a]).directive("schemaValidate",["sfValidator","$parse","sfSelect",y.a]).directive("sfKeyController",["schemaForm","sfPath",g.a])},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(e,r,t){return{restrict:"A",scope:!1,priority:500,require:"ngModel",link:function(r,n,o,i){r.$emit("schemaFormPropagateNgModelController",i);var l=null,s=r.$eval(o.schemaValidate);s.copyValueTo&&i.$viewChangeListeners.push(function(){var e=s.copyValueTo;a.a.forEach(e,function(e){t(e,r.model,i.$modelValue)})});var f=function(t){if(!s)return t;if(r.options&&r.options.tv4Validation===!1)return t;var n=e(s,t);Object.keys(i.$error).filter(function(e){return 0===e.indexOf("tv4-")}).forEach(function(e){i.$setValidity(e,!0)});{if(n.valid)return t;if(i.$setValidity("tv4-"+n.error.code,!1),l=n.error,i.$validators)return t}};"function"==typeof s.ngModel&&s.ngModel(i),["$parsers","$viewChangeListeners","$formatters"].forEach(function(e){s[e]&&i[e]&&s[e].forEach(function(r){i[e].push(r)})}),["$validators","$asyncValidators"].forEach(function(e){s[e]&&i[e]&&a.a.forEach(s[e],function(r,t){i[e][t]=r})}),i.$parsers.push(f),i.$validators&&(i.$validators.schemaForm=function(){return!Object.keys(i.$error).some(function(e){return"schemaForm"!==e})});var c=s.schema;r.validateField=function(e){void 0!=e&&i.$$parentForm.$name!==e||(c&&c.type.indexOf("array")!==-1&&f(i.$modelValue),i.$setDirty?(i.$setDirty(),i.$setViewValue(i.$viewValue),i.$commitViewValue(),"checkbox"===s.type?s.required&&void 0===i.$modelValue&&i.$setValidity("tv4-302",!1):s.required&&i.$isEmpty(i.$modelValue)&&i.$setValidity("tv4-302",!1)):i.$setViewValue(i.$viewValue))};var d=!0;i.$formatters.push(function(e){return!i.$pristine||!d||r.options&&r.options.validateOnRender===!0?(f(i.$modelValue),e):(d=!1,e)}),r.$on("schemaFormValidate",function(e,t){r.validateField(t)}),r.schemaError=function(){return l}}}}},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(e,r,t){return{scope:!0,controller:["$scope",function(e){this.key=e.form&&e.form.key?e.form.key.splice(0,-2):[]}],link:function(n,o,i){n.min=0,n.modelArray=n.$eval(i.sfNewArray);var l=function(){n.modelArray=n.$eval(i.sfNewArray),n.ngModel&&n.ngModel.$pristine&&n.firstDigest&&(!n.options||n.options.validateOnRender!==!0)||n.validateField&&n.validateField()},s=function(){n.form&&n.form.onChange&&(a.a.isFunction(n.form.onChange)?n.form.onChange(n.modelArray,n.form):n.evalExpr(n.form.onChange,{modelValue:n.modelArray,form:n.form}))},f=function(){var t=n.modelArray;if(!t){var a=r.parse(i.sfNewArray);t=[],e(a,n,t),n.modelArray=t}return t},c=n.$watch("form",function(e){if(e){if(e.titleMap||e.startEmpty===!0||n.modelArray&&0!==n.modelArray.length||n.appendToArray(),n.form&&n.form.schema&&n.form.schema.uniqueItems===!0?(n.$watch(i.sfNewArray,l,!0),n.$watch([i.sfNewArray,i.sfNewArray+".length"],s)):n.$watchGroup?n.$watchGroup([i.sfNewArray,i.sfNewArray+".length"],function(){l(),s()}):(n.$watch(i.sfNewArray,function(){l(),s()}),n.$watch(i.sfNewArray+".length",function(){l(),s()})),e.titleMap&&e.titleMap.length>0){n.titleMapValues=[];var r=function(r){n.titleMapValues=[],r=r||[],e.titleMap.forEach(function(e){n.titleMapValues.push(r.indexOf(e.value)!==-1)})};r(n.modelArray),n.$watchCollection("modelArray",r),n.$watchCollection("titleMapValues",function(r,t){if(r&&r!==t){var a=f();e.titleMap.forEach(function(e,t){var n=a.indexOf(e.value);n===-1&&r[t]&&a.push(e.value),n===-1||r[t]||a.splice(n,1)}),n.validateField&&n.validateField()}})}c()}});n.appendToArray=function(){var r,o=f();if(n.form&&n.form.schema&&n.form.schema.items){var i=n.form.schema.items;i.type&&i.type.indexOf("object")!==-1?(r={},n.options&&n.options.setSchemaDefaults===!1||(r=a.a.isDefined(i.default)?i.default:r,r&&t.traverseSchema(i,function(t,n){a.a.isDefined(t.default)&&e(n,r,t.default)}))):i.type&&i.type.indexOf("array")!==-1?(r=[],n.options&&n.options.setSchemaDefaults===!1||(r=i.default||r)):n.options&&n.options.setSchemaDefaults===!1||(r=i.default||r)}return o.push(r),o},n.deleteFromArray=function(e){var r=n.modelArray;return r&&r.splice(e,1),r};var d=function(e){return function(r){r.key&&(r.key[r.key.indexOf("")]=e)}},u={};n.copyWithIndex=function(e){var r=n.form;if(!u[e]){var o=r.items[0];if(r.items.length>1&&(o={type:"section",items:r.items.map(function(e){return e.ngModelOptions=r.ngModelOptions,a.a.isUndefined(e.readonly)&&(e.readonly=r.readonly),e})}),o){var i=a.a.copy(o);i.arrayIndex=e,t.traverseForm(i,d(e)),u[e]=i}}return u[e]}}}}},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(){return{require:"ngModel",restrict:"AC",scope:!1,link:function(e,r,t,n){var o=e.$eval(t.sfChanged);o&&o.onChange&&n.$viewChangeListeners.push(function(){a.a.isFunction(o.onChange)?o.onChange(n.$modelValue,o):e.evalExpr(o.onChange,{modelValue:n.$modelValue,form:o,arrayIndex:e.$index,arrayIndices:e.arrayIndices,path:e.path,$i:e.$i,$index:e.$index})})}}}},function(e,r,t){"use strict";var n=t(0),a=t.n(n),o="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};r.a=function(e,r,t,n,i,l,s,f,c){var d={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function(e,r,t,n){var a=n[0];n[1],n[2];e.$on("schemaFormPropagateNgModelController",function(r,t){r.stopPropagation(),r.preventDefault(),e.ngModel=t}),e.initialForm=Object.assign({},a.lookup["f"+t.sfField]),e.form=a.lookup["f"+t.sfField]},post:function(e,r,t,n){var l=n[0],u=n[1];n[2];e.getKey=function(r){var t=r||d.COMPLETE,n=e.parentKey?e.parentKey.slice(0,e.parentKey.length-1):[];if(e.completeKey!==e.form.key&&("number"==typeof e.$index&&(n=n.concat(e.$index)),e.form.key&&e.form.key.length))if("number"==typeof n[n.length-1]&&e.form.key.length>=1){var a=e.form.key.length-n.length;e.completeKey=n.concat(e.form.key.slice(-a))}else e.completeKey=e.form.key.slice();if(Array.isArray(e.completeKey))return t===d.COMPLETE?e.completeKey:e.completeKey.reduce(function(e,r,n){return-1!==[t].indexOf("undefined"==typeof r?"undefined":o(r))?e.concat(r):e},[])},e.form.key&&(e.form.key=e.completeKey=e.getKey()),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(r,t){var n=t||!1,a=r&&u&&u.$name?u.$name:void 0,o=e.completeKey;return Array.isArray(o)?f.name(o,"-",a,n):""},e.listToCheckboxValues=function(e){var r={};return a.a.forEach(e,function(e){r[e]=!0}),r},e.checkboxValuesToList=function(e){var r=[];return a.a.forEach(e,function(e,t){e&&r.push(t)}),r},e.buttonClick=function(r,t){a.a.isFunction(t.onClick)?t.onClick(r,t):a.a.isString(t.onClick)&&(l?l.evalInParentScope(t.onClick,{$event:r,form:t}):e.$eval(t.onClick,{$event:r,form:t}))},e.evalExpr=function(r,t){return l?l.evalInParentScope(r,t):e.$eval(r,t)},e.evalInScope=function(r,t){if(r)return e.$eval(r,t)},e.interp=function(e,r){return e&&i(e)(r)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.errors===!1?e.ngModel.$invalid&&!e.ngModel.$pristine:e.ngModel.$invalid)},e.errorMessage=function(r){return s.interpolate(r&&r.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)},e.form.htmlClass=e.form.htmlClass||"",e.idClass=e.fieldId(!1)+" "+e.fieldId(!1,!0);var m=e.form;m.key&&(e.$on("schemaForm.error."+m.key.join("."),function(r,t,n,a,o){o=a,n!==!0&&n!==!1||(a=n,n=void 0),void 0!=o&&e.ngModel.$$parentForm.$name!==o||e.ngModel&&t&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(m.validationMessage||(m.validationMessage={}),m.validationMessage[t]=n),e.ngModel.$setValidity(t,a===!0),a===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){var r=e.getKey();if(!e.externalDestructionInProgress){var t=m.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(r&&"retain"!==t){var n=e.model;if(r.length>1&&(n=c(r.slice(0,r.length-1),n)),void 0===n)return;var a=m.schema&&m.schema.type||"";"empty"===t&&a.indexOf("string")!==-1?n[r.slice(-1)]="":"empty"===t&&a.indexOf("object")!==-1?n[r.slice(-1)]={}:"empty"===t&&a.indexOf("array")!==-1?n[r.slice(-1)]=[]:"null"===t?n[r.slice(-1)]=null:delete n[r.slice(-1)]}}}))}}}}},function(e,r,t){"use strict";r.a=function(e,r){return{scope:!0,require:["?^^sfNewArray"],link:{pre:function(e,t,n,a){e.parentKey=e.parentKey||[];var o=r.parse(n.sfParentKey),i=o.length-e.parentKey.length;o.length>1&&(o=o.splice(-i)),e.parentKey=e.parentKey.concat(o,Number(n.sfIndex)),e.arrayIndex=Number(n.sfIndex),e.arrayIndices=e.arrayIndices||[],e.arrayIndices=e.arrayIndices.concat(e.arrayIndex),e.$i=e.arrayIndices,e.path=function(r){var t=-1;return r=r.replace(/\[\]/gi,function(r){return t++,"["+e.$i[t]+"]"}),e.evalExpr(r,e)}}}}}},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(e,r){var t=e.has("$sanitize")?e.get("$sanitize"):function(e){return e};return{scope:!1,restrict:"EA",link:function(e,n,o){var i="";o.sfMessage&&e.$watch(o.sfMessage,function(r){r&&(i=t(r),f(!!e.ngModel))});var l,s=function(e){e!==l&&(n.html(e),l=e)},f=function(t){if(t)if(e.hasError()){var n=[];a.a.forEach(e.ngModel&&e.ngModel.$error,function(e,r){e&&n.push(r)}),n=n.filter(function(e){return"schemaForm"!==e});var o=n[0];s(o?r.interpolate(o,e.ngModel.$modelValue,e.ngModel.$viewValue,e.form,e.options&&e.options.validationMessage):i)}else s(i);else s(i)};f();var c=e.$watch("ngModel",function(e){e&&(e.$parsers.push(function(e){return f(!0),e}),e.$formatters.push(function(e){return f(!0),e}),c())});e.$watchCollection("ngModel.$error",function(){f(!!e.ngModel)})}}}},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(e,r,t,n,o,i,l,s,f){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function(e){this.evalInParentScope=function(r,t){return e.$parent.$eval(r,t)};var r=this;e.lookup=function(e){return e&&(r.lookup=e),r.lookup}}],replace:!1,restrict:"A",transclude:!0,require:"?form",link:function(s,c,d,u,m){s.formCtrl=u;var p={};m(s,function(e){if(e.addClass("schema-form-ignore"),c.prepend(e),c[0].querySelectorAll){var r=c[0].querySelectorAll("[ng-model]");if(r)for(var t=0;t<r.length;t++){var n=r[t].getAttribute("ng-model");p[n.substring(n.indexOf(".")+1)]=!0}}});var h,g={},v=function(e,a){var i=[],l=o.merge(e,a,p,s.options,void 0,i);i.length>0?n.all(i.map(function(e){return r.get(e.templateUrl,{cache:t}).then(function(r){e.template=r.data})})).then(function(){y(e,a,l)}):y(e,a,l)},y=function(r,t,n){h&&(s.externalDestructionInProgress=!0,h.$destroy(),s.externalDestructionInProgress=!1),h=s.$new(),h.schemaForm={form:n,schema:r},c.children(":not(.schema-form-ignore)").remove();for(var u={},m=c[0].querySelectorAll("*[sf-insert-field]"),p=0;p<m.length;p++)u[m[p].getAttribute("sf-insert-field")]=m[p];var g=i.decorator(d.sfUseDecorator),v=Object.create(null);s.lookup(v),c[0].appendChild(f.build(n,g,u,v)),h.firstDigest=!0,setTimeout(function(){h.firstDigest=!1},0),e(c.children())(h),s.options&&s.options.setSchemaDefaults===!1||o.traverseSchema(r,function(e,r){if(a.a.isDefined(e.default)){var t=l(r,s.model);a.a.isUndefined(t)&&l(r,s.model,e.default)}}),s.$emit("sf-render-finished",c)},b=["*"];s.$watch(function(){var e=s.schema,r=s.initialForm||b;r&&e&&e.type&&(g.form!==r||g.schema!==e)&&Object.keys(e.properties).length>0&&(g.schema=e,g.form=r,v(e,r))}),s.$on("schemaFormRedraw",function(){var e=s.schema,r=s.initialForm?a.a.copy(s.initialForm):["*"];e&&v(e,r)}),s.$on("$destroy",function(){s.externalDestructionInProgress=!0}),s.evalExpr=function(e,r){return s.$parent.$eval(e,r)}}}}},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(e,r){var t="",n={},o=function(e,r){"sfDecorator"===e&&(e=t);var a=n[e];return a[r.type]?a[r.type].template:a.default.template},i=function(t){e.directive(t,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function(e,n,i,l,s,f,c,d,u){return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["?^sfSchema","?^form"],link:function(e,m,p,h){var g=h[0],v=h[1];e.$on("schemaFormPropagateNgModelController",function(r,t){r.stopPropagation(),r.preventDefault(),e.ngModel=t}),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(r,t){var n=e.parentKey||[];if(e.form.key){if("number"==typeof n[n.length-1]){var a=n.concat(e.form.key.slice(-1)),o=r&&v&&v.$name?v.$name:void 0;return d.name(a,"-",o,t)}var o=r&&v&&v.$name?v.$name:void 0;return d.name(e.form.key,"-",o,t)}return""},e.listToCheckboxValues=function(e){var r={};return a.a.forEach(e,function(e){r[e]=!0}),r},e.checkboxValuesToList=function(e){var r=[];return a.a.forEach(e,function(e,t){e&&r.push(t)}),r},e.buttonClick=function(r,t){a.a.isFunction(t.onClick)?t.onClick(r,t):a.a.isString(t.onClick)&&(g?g.evalInParentScope(t.onClick,{$event:r,form:t}):e.$eval(t.onClick,{$event:r,form:t}))},e.evalExpr=function(r,t){return g?g.evalInParentScope(r,t):e.$eval(r,t)},e.evalInScope=function(r,t){if(r)return e.$eval(r,t)},e.interp=function(e,r){return e&&s(e)(r)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.ngModel.$invalid&&!e.ngModel.$pristine)},e.errorMessage=function(r){return c.interpolate(r&&r.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)};var y=e.$watch(p.form,function(s){if(s){s.ngModelOptions=s.ngModelOptions||{},e.form=s;var c;if("template"===s.type&&s.template)c=f.when(s.template);else{var p="template"===s.type?s.templateUrl:o(t,s);c=i.get(p,{cache:l}).then(function(e){return e.data})}c.then(function(t){if(s.key){var o=s.key?r.stringify(s.key).replace(/"/g,"&quot;"):"";t=t.replace(/\$\$value\$\$/g,"model"+("["!==o[0]?".":"")+o)}if(m.html(t),s.condition){var i='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';s.key&&(i='evalExpr(form.condition, {model: model, "arrayIndex": arrayIndex, "modelValue": model'+d.stringify(s.key)+"})"),a.a.forEach(m.children(),function(e){var r=e.getAttribute("ng-if");e.setAttribute("ng-if",r?"("+r+") || ("+i+")":i)})}n(m.contents())(e)}),s.key&&(e.$on("schemaForm.error."+s.key.join("."),function(r,t,n,a,o){o=a,n!==!0&&n!==!1||(a=n,n=void 0),void 0!=o&&e.ngModel.$$parentForm.$name!==o||void 0!=o&&e.ngModel.$$parentForm.$name!==o||e.ngModel&&t&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(s.validationMessage||(s.validationMessage={}),s.validationMessage[t]=n),e.ngModel.$setValidity(t,a===!0),a===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){if(!e.externalDestructionInProgress){var r=s.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(s.key&&"retain"!==r){var t=e.model;if(s.key.length>1&&(t=u(s.key.slice(0,s.key.length-1),t)),void 0===t)return;var n=s.schema&&s.schema.type||"";"empty"===r&&n.indexOf("string")!==-1?t[s.key.slice(-1)]="":"empty"===r&&n.indexOf("object")!==-1?t[s.key.slice(-1)]={}:"empty"===r&&n.indexOf("array")!==-1?t[s.key.slice(-1)]=[]:"null"===r?t[s.key.slice(-1)]=null:delete t[s.key.slice(-1)]}}})),y()}})}}}])},l=function(r,t,n){n=!!a.a.isDefined(n)&&n,e.directive("sf"+a.a.uppercase(r[0])+r.substr(1),function(){return{restrict:"EAC",scope:!0,replace:!0,transclude:n,template:'<sf-decorator form="form"></sf-decorator>',link:function(e,t,n){var o={items:"c",titleMap:"c",schema:"c"},i={type:r},l=!0;a.a.forEach(n,function(r,t){if("$"!==t[0]&&0!==t.indexOf("ng")&&"sfField"!==t){var s=function(r){a.a.isDefined(r)&&r!==i[t]&&(i[t]=r,l&&i.type&&(i.key||a.a.isUndefined(n.key))&&(e.form=i,l=!1))};"model"===t?e.$watch(r,function(r){r&&e.model!==r&&(e.model=r)}):"c"===o[t]?e.$watchCollection(r,s):n.$observe(t,s)}})}}})};this.createDecorator=function(e,r){n[e]={__name:e},a.a.forEach(r,function(r,t){n[e][t]={template:r,replace:!1,builder:[]}}),n[t]||(t=e),i(e)},this.defineDecorator=function(e,r){n[e]={__name:e},a.a.forEach(r,function(r,t){r.builder=r.builder||[],r.replace=!a.a.isDefined(r.replace)||r.replace,n[e][t]=r}),n[t]||(t=e),i(e)},this.createDirective=l,this.createDirectives=function(e){a.a.forEach(e,function(e,r){l(r,e)})},this.decorator=function(e){return e=e||t,n[e]},this.addMapping=function(e,r,t,a,o){n[e]&&(n[e][r]={template:t,builder:a,replace:!!o})},this.defineAddOn=function(e,r,t,a){n[e]&&(n[e][r]={template:t,builder:a,replace:!0})},this.$get=function(){return{decorator:function(e){return n[e]||n[t]},defaultDecorator:t}},i("sfDecorator")}},function(e,r,t){"use strict";var n=t(0),a=(t.n(n),t(1));t.n(a);r.a=function(){var e=function(e){return e},r=a.schemaDefaults.createDefaults();this.defaults=r,this.stdFormObj=a.schemaDefaults.stdFormObj,this.defaultFormDefinition=a.schemaDefaults.defaultFormDefinition,this.postProcess=function(r){e=r},this.appendRule=function(e,r){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].push(r)},this.prependRule=function(e,r){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].unshift(r)},this.createStandardForm=a.schemaDefaults.stdFormObj,this.$get=function(){var r={},n=this.defaults;return r.merge=function(r){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["*"],o=arguments[2],i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},l=arguments.length>4&&void 0!==arguments[4]&&arguments[4],s=arguments[5],f=t.i(a.merge)(r,n,o,i,l,s);return e(f)},r.defaults=function(e,r,t,o){var i=r||n;return a.schemaDefaults.defaultForm(e,i,t,o)},r.typeDefault=n,r.traverseSchema=a.traverseSchema,r.traverseForm=a.traverseForm,r}}},function(e,r,t){"use strict";r.a=function(e){var r=/[A-Z]/g,t=function(e,t){return t=t||"_",e.replace(r,function(e,r){return(r?t:"")+e.toLowerCase()})},n=0;"firstElementChild"in document.createDocumentFragment()||Object.defineProperty(DocumentFragment.prototype,"firstElementChild",{get:function(){for(var e,r=this.childNodes,t=0,n=r.length;t<n;++t)if(e=r[t],1===e.nodeType)return e;return null}});var a={sfField:function(e){e.fieldFrag.firstElementChild.setAttribute("sf-field",n),e.lookup["f"+n]=e.form,n++},ngModel:function(r){if(r.form.key){var t=r.form.key;r.state.keyRedaction&&(t=t.slice(r.state.keyRedaction));var n;if(r.state.modelValue)n=r.state.modelValue;else{var a=e.stringify(t).replace(/"/g,"&quot;");n=r.state.modelName||"model",a&&(n+=("["!==a[0]?".":"")+a)}for(var o=r.fieldFrag.querySelectorAll("[sf-field-model]"),i=0;i<o.length;i++){var l=o[i],s=l.getAttribute("sf-field-model");if(s&&""!==s)if("replaceAll"===s)for(var f=l.attributes,c=0;c<f.length;c++)f[c].value&&f[c].value.indexOf("$$value")!==-1&&(f[c].value=f[c].value.replace(/\$\$value\$\$/g,n));else{var d=l.getAttribute(s);d&&d.indexOf("$$value$$")?l.setAttribute(s,d.replace(/\$\$value\$\$/g,n)):l.setAttribute(s,n)}else l.setAttribute("ng-model",n)}}},simpleTransclusion:function(e){var r=e.build(e.form.items,e.path+".items",e.state);e.fieldFrag.firstChild.appendChild(r)},ngModelOptions:function(e){e.form.ngModelOptions&&Object.keys(e.form.ngModelOptions).length>0&&e.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(e.form.ngModelOptions))},transclusion:function(e){var r=e.fieldFrag.querySelectorAll("[sf-field-transclude]");if(r.length)for(var t=0;t<r.length;t++){var n=r[t],a=n.getAttribute("sf-field-transclude")||"items",o=e.form[a];if(o){var i=e.build(o,e.path+"."+a,e.state);n.appendChild(i)}}},condition:function(r){var t="",n="undefined",a="";if(r.form.condition){r.form.key&&(t=e.stringify(r.form.key),n="model"+("["===t[0]?"":".")+t);for(var o="evalExpr("+r.path+'.condition, { model: model, "arrayIndex": $index, "arrayIndices": arrayIndices, "path": path, "$i": $i, "$index": $index, "modelValue": '+n+"})",i=r.fieldFrag.children||r.fieldFrag.childNodes,l=0;l<i.length;l++){var s=i[l];s.hasAttribute&&s.hasAttribute("ng-if")&&(a=s.getAttribute("ng-if")),s.setAttribute&&s.setAttribute("ng-if",a?"("+a+") || ("+o+")":o)}}},array:function(r){var t=r.fieldFrag.querySelector("[schema-form-array-items]");if(r.form.key){r.form.key.filter(function(e){return""===e}).length}if(t){var n=angular.copy(r.state);if(n.keyRedaction=0,n.keyRedaction+=r.form.key.length+1,r.form.schema&&r.form.schema.items&&r.form.schema.items.type&&r.form.schema.items.type.indexOf("object")===-1&&r.form.schema.items.type.indexOf("array")===-1){e.stringify(r.form.key).replace(/"/g,"&quot;")+"[$index]";n.modelValue="modelArray[$index]"}else n.modelName="item";n.arrayCompatFlag=!0;var a=r.build(r.form.items,r.path+".items",n);
-t.appendChild(a)}},numeric:function(e){var r=e.fieldFrag.querySelector("input"),t=e.form.maximum||!1,n=e.form.exclusiveMaximum||!1,a=e.form.minimum||!1,o=e.form.exclusiveMinimum||!1,i=e.form.multipleOf||!1;r&&(i!==!1&&r.setAttribute("step",i),t!==!1&&(n!==!1&&i!==!1&&(t-=i),r.setAttribute("max",t)),a!==!1&&(o!==!1&&i!==!1&&(a+=i),r.setAttribute("min",a)))}};this.builders=a;var o=[a.sfField,a.ngModel,a.ngModelOptions,a.condition];this.stdBuilders=o,this.$get=["$templateCache","schemaFormDecorators","sfPath",function(e,r,n){var i=function(e,r){if(e.key){var t=r[n.stringify(e.key)];if(t){for(;t.firstChild;)t.removeChild(t.firstChild);return t}}},l=function e(r,n,a,o,l,s,f){s=s||{},s=s||{},f=f||Object.create(null),l=l||"schemaForm.form";var c=document.createDocumentFragment();return r.reduce(function(r,c,d){if(!c.type)return r;var u=n[c.type]||n.default;if(u.replace){var m;s.arrayCompatFlag=!1;var p=document.createElement("div"),h=a(c,u)||a(c,n.default);for(p.innerHTML=h,m=document.createDocumentFragment();p.childNodes.length>0;)m.appendChild(p.childNodes[0]);var g={fieldFrag:m,form:c,lookup:f,state:s,path:l+"["+d+"]",build:function(r,t,i){return e(r,n,a,o,t,i,f)}},v=c.builder||u.builder;"function"==typeof v?v(g):v.forEach(function(e){e(g)}),(i(c,o)||r).appendChild(m)}else{var y=document.createElement(t(n.__name,"-"));s.arrayCompatFlag?y.setAttribute("form","copyWithIndex($index)"):y.setAttribute("form",l+"["+d+"]"),(i(c,o)||r).appendChild(y)}return r},c),c};return{build:function(r,t,n,a){return l(r,t,function(r,t){return"template"===r.type?r.template:e.get(t.template)},n,void 0,void 0,a)},builder:a,stdBuilders:o,internalBuild:l}}]}},function(e,r,t){"use strict";var n=t(0),a=t.n(n);r.a=function(){var e={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};e.number=e[105],e.required=e[302],e.min=e[101],e.max=e[103],e.maxlength=e[201],e.minlength=e[200],e.pattern=e[202],this.setDefaultMessages=function(r){e=r},this.getDefaultMessages=function(){return e},this.setDefaultMessage=function(r,t){e[r]=t},this.$get=["$interpolate",function(r){var t={};return t.defaultMessages=e,t.interpolate=function(t,n,o,i,l){l=l||{};var s=i.validationMessage||{};0===t.indexOf("tv4-")&&(t=t.substring(4));var f=s.default||l.default||"";[s,l,e].some(function(e){return a.a.isString(e)||a.a.isFunction(e)?(f=e,!0):e&&e[t]?(f=e[t],!0):void 0});var c={error:t,value:n,viewValue:o,form:i,schema:i.schema,title:i.title||i.schema&&i.schema.title};return a.a.isFunction(f)?f(c):r(f)(c)},t}]}},function(e,r,t){"use strict";function n(e,r){if(!(e instanceof r))throw new TypeError("Cannot call a class as a function")}var a=t(1),o=(t.n(a),t(0)),i=(t.n(o),function(){function e(e,r){for(var t=0;t<r.length;t++){var n=r[t];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(r,t,n){return t&&e(r.prototype,t),n&&e(r,n),r}}()),l=function(){function e(){n(this,e),this.name=a.sfPath.name,this.parse=a.sfPath.parse,this.stringify=a.sfPath.stringify,this.normalize=a.sfPath.normalize}return i(e,[{key:"$get",value:function(){return a.sfPath}}]),e}();r.a=l},function(e,r,t){t(1),e.exports=t(3)}])},,,function(e,r,t){t(18),e.exports=t(0)}]);
\ No newline at end of file
+e.exports=function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=13)}([function(e,t,r){"use strict";function n(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(e){var o=e.slice(),i=t||"-";return n&&(o=o.filter(function(e){return"number"!=typeof e})),(0!==r.length?r+i:"")+o.join(i)}return""}Object.defineProperty(t,"__esModule",{value:!0});var o=r(2);r.n(o);r.o(o,"parse")&&r.d(t,"parse",function(){return o.parse}),r.o(o,"stringify")&&r.d(t,"stringify",function(){return o.stringify}),r.o(o,"normalize")&&r.d(t,"normalize",function(){return o.normalize}),t.name=n},function(e,t,r){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t){if(!Array.isArray(e)){var r=function(){var r=[];return t?t.forEach(function(t){r.push({name:e[t],value:t})}):Object.keys(e).forEach(function(t){r.push({name:e[t],value:t})}),{v:r}}();if("object"===("undefined"==typeof r?"undefined":n(r)))return r.v}return e}},function(e,t,r){e.exports=r(11).ObjectPath},function(e,t,r){"use strict";function n(e,t,r,o){var i=e[g(r.type)];if(i)for(var a=void 0,s=function(t,r,o){return n(e,t,r,o)},l=0;l<i.length;l++)if(a=i[l](t,r,o,s))return a.schema["x-schema-form"]&&Object.assign(a,a.schema["x-schema-form"]),a}function o(e,t,n){n=n||{};var o=n.global&&n.global.formDefaults?Object.assign({},n.global.formDefaults):{};return n.global&&n.global.supressPropertyTitles===!0?o.title=t.title:o.title=t.title||e,t.description&&(o.description=t.description),n.required!==!0&&t.required!==!0||(o.required=!0),t.maxLength&&(o.maxlength=t.maxLength),t.minLength&&(o.minlength=t.minLength),(t.readOnly||t.readonly)&&(o.readonly=!0),t.minimum&&(o.minimum=t.minimum+(t.exclusiveMinimum?1:0)),t.maximum&&(o.maximum=t.maximum-(t.exclusiveMaximum?1:0)),t.validationMessage&&(o.validationMessage=t.validationMessage),t.enumNames&&(o.titleMap=r.i(v.a)(t.enumNames,t.enum)),o.schema=t,o.ngModelOptions=o.ngModelOptions||{},o}function i(e,t,n){if("string"===g(t.type)&&!t.enum){var i=o(e,t,n);return i.key=n.path,i.type="text",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function a(e,t,n){if("number"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function s(e,t,n){if("integer"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function l(e,t,n){if("boolean"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="checkbox",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function c(e,t,n){if("string"===g(t.type)&&t.enum){var i=o(e,t,n);return i.key=n.path,i.type="select",i.titleMap||(i.titleMap=b(t.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function u(e,t,n){if("array"===g(t.type)&&t.items&&t.items.enum){var i=o(e,t,n);return i.key=n.path,i.type="checkboxes",i.titleMap||(i.titleMap=b(t.items.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function f(e,t,n,i){if("object"===g(t.type)){var a=function(){var a=o(e,t,n);return a.type="fieldset",a.key=n.path,a.items=[],n.lookup[r.i(h.stringify)(n.path)]=a,t.properties&&Object.keys(t.properties).forEach(function(e){var o=t.properties[e],s=n.path.slice();if(s.push(e),n.ignore[r.i(h.stringify)(s)]!==!0){var l=t.required&&t.required.indexOf(e)!==-1,c=i(e,o,{path:s,required:l||!1,lookup:n.lookup,ignore:n.ignore,global:n.global});c&&a.items.push(c)}}),{v:a}}();if("object"===("undefined"==typeof a?"undefined":y(a)))return a.v}}function d(e,t,n,i){if("array"===g(t.type)){var a=o(e,t,n);a.type="array",a.key=n.path,n.lookup[r.i(h.stringify)(n.path)]=a;var s=t.required&&t.required.indexOf(n.path[n.path.length-1])!==-1,l=n.path.slice();return l.push(""),a.items=[i(e,t.items,{path:l,required:s||!1,lookup:n.lookup,ignore:n.ignore,global:n.global})],a}}function p(){return{string:[c,i],object:[f],number:[a],integer:[s],boolean:[l],array:[u,d]}}function m(e,t,r,o){var i=[],a={};if(r=r||{},o=o||{},t=t||p(),!e.properties)throw new Error('Not implemented. Only type "object" allowed at root level of schema.');return Object.keys(e.properties).forEach(function(s){if(r[s]!==!0){var l=e.required&&e.required.indexOf(s)!==-1,c=n(t,s,e.properties[s],{path:[s],lookup:a,ignore:r,required:l,global:o});c&&i.push(c)}}),{form:i,lookup:a}}Object.defineProperty(t,"__esModule",{value:!0});var h=r(0),v=r(1);t.defaultFormDefinition=n,t.stdFormObj=o,t.text=i,t.number=a,t.integer=s,t.checkbox=l,t.select=c,t.checkboxes=u,t.fieldset=f,t.array=d,t.createDefaults=p,t.defaultForm=m;var y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},g=function(e){if(Array.isArray(e)&&2===e.length){if("null"===e[0])return e[1];if("null"===e[1])return e[0]}return e},b=function(e){var t=[];return e.forEach(function(e){t.push({name:e,value:e})}),t}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(3),o=r(0),i=r(1),a=r(6);r.d(t,"merge",function(){return a.a});var s=r(8);r.d(t,"select",function(){return s.a});var l=r(7);r.d(t,"jsonref",function(){return l.a});var c=r(9);r.d(t,"traverseSchema",function(){return c.a}),r.d(t,"traverseForm",function(){return c.b});var u=r(10);r.d(t,"validate",function(){return u.a}),r.d(t,"sfPath",function(){return f}),r.d(t,"schemaDefaults",function(){return d}),r.d(t,"canonicalTitleMap",function(){return p});var f=o,d=n,p=i.a},function(e,n,o){var i,a,s,l,l,c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};!function(t){if("object"===c(n)&&"undefined"!=typeof e)e.exports=t();else{a=[],i=t,s="function"==typeof i?i.apply(n,a):i,!(void 0!==s&&(e.exports=s))}}(function(){var e;return function e(t,r,n){function o(a,s){if(!r[a]){if(!t[a]){var c="function"==typeof l&&l;if(!s&&c)return l(a,!0);if(i)return i(a,!0);var u=new Error("Cannot find module '"+a+"'");throw u.code="MODULE_NOT_FOUND",u}var f=r[a]={exports:{}};t[a][0].call(f.exports,function(e){var r=t[a][1][e];return o(r?r:e)},f,f.exports,e,t,r,n)}return r[a].exports}for(var i="function"==typeof l&&l,a=0;a<n.length;a++)o(n[a]);return o}({1:[function(e,t,r){"use strict";function n(e){var t;return m(e,"Array")?(t=[],e.forEach(function(e,r){t[r]=n(e)})):m(e,"Object")?(t={},Object.keys(e).forEach(function(r){t[r]=n(e[r])})):t=e,t}function o(e,t){function r(e){Object.keys(e).forEach(function(t){n[t]=e[t]})}var n={};return r(_.parse(e||"")),r(_.parse(t||"")),0===Object.keys(n).length?void 0:_.stringify(n)}function i(e,t){m(e,"String")&&(e=F(e)),m(t,"String")&&(t=F(t));var r,n,i=y(m(t,"Undefined")?"":t);return L.indexOf(i.reference)>-1?n=i:(r=m(e,"Undefined")?void 0:y(e),m(r,"Undefined")?n=i:(n=r,n.path=F(D.join(r.path,i.path)),n.query=o(r.query,i.query))),n.fragment=void 0,(L.indexOf(n.reference)===-1&&0===n.path.indexOf("../")?"../":"")+R.serialize(n)}function a(e,t){var r,n=[];return t.length>0&&(r=e,t.slice(0,t.length-1).forEach(function(e){e in r&&(r=r[e],n.push(r))})),n}function s(e,t,r,o,i,a,s,u,f){var d,p;if(r.length>0)try{d=c(t,r)}catch(t){"remote"===e&&(o.error=t.message,o.missing=!0)}else d=t;if(m(d,"Undefined")||(o.value=d),m(d,"Array")||m(d,"Object"))return p=n(i),"local"===e?(delete p.subDocPath,t=d):(p.relativeBase=D.dirname(a[a.length-1]),0===r.length?delete p.subDocPath:p.subDocPath=r),l(t,p,a,s,u,f)}function l(e,t,r,n,o,a){var l=Promise.resolve(),c=n.length?S(n[n.length-1]):[],u=C(e,t),f=t.subDocPath||[],p=P(f),h=["#"];return r.forEach(function(e,t){"#"!==e.charAt(0)&&h.push(n[t])}),h.reverse(),"#"!==(r[r.length-1]||"").charAt(0)&&(o.documents[P(c)]=e),Object.keys(u).forEach(function(v){var y,g,b,w,x=u[v];b=0===r.length?c.concat(S(v)):c.concat(S(v).slice(0===r.length?0:f.length)),w=P(b),m(o[w],"Undefined")&&(o.refs[w]=u[v],m(x.error,"Undefined")&&"invalid"!==x.type&&(N.indexOf(x.type)>-1?(y=i(t.relativeBase,x.uri),g=r.indexOf(y)):(y=x.uri,g=n.indexOf(y)),x.ancestorPtrs=h,x.indirect=a,g===-1?N.indexOf(x.type)>-1?l=l.then(function(){return d(y,t).then(function(e){return s("remote",e,m(x.uriDetails.fragment,"Undefined")?[]:S(decodeURI(x.uriDetails.fragment)),x,t,r.concat(y),n.concat(w),o,a)}).catch(function(e){x.error=e.message,x.missing=!0})}):0!==w.indexOf(y+"/")&&w!==y&&0!==p.indexOf(y+"/")&&p!==y?0!==y.indexOf(p+"/")&&(l=l.then(function(){return s("local",e,S(y),x,t,r.concat(y),n.concat(w),o,a||y.indexOf(p+"/")===-1&&y!==p)})):x.circular=!0:(n.slice(g).forEach(function(e){o.refs[e].circular=!0}),x.circular=!0)))}),l=l.then(function(){function e(i,a,s,l){Object.keys(o.refs).forEach(function(c){var u=o.refs[c];n.indexOf(l)===-1&&r.indexOf(s)===-1&&t.indexOf(l)===-1&&c!==s&&0===c.indexOf(l+"/")&&(a.indexOf(l)>-1?a.forEach(function(e){t.indexOf(l)===-1&&t.push(e)}):e(i.concat(s),a.concat(l),c,u.uri),r.push(s),n.push(l))})}var t=[],r=[],n=[];Object.keys(o.refs).forEach(function(r){var n=o.refs[r];"local"!==n.type||n.circular||t.indexOf(n.uri)!==-1||e([],[],r,n.uri)}),Object.keys(o.refs).forEach(function(e){var r=o.refs[e];t.indexOf(r.uri)>-1&&(r.circular=!0)})}).then(function(){return o})}function c(e,t){var r=e;return t.forEach(function(e){if(e=decodeURI(e),!(e in r))throw Error("JSON Pointer points to missing location: "+P(t));r=r[e]}),r}function u(e){return Object.keys(e).filter(function(e){return"$ref"!==e})}function f(e){var t;switch(e.uriDetails.reference){case"absolute":case"uri":t="remote";break;case"same-document":t="local";break;default:t=e.uriDetails.reference}return t}function d(e,t){var r=U[e],o=Promise.resolve(),i=n(t.loaderOptions||{});return m(r,"Undefined")?(m(i.processContent,"Undefined")&&(i.processContent=function(e,t){t(void 0,JSON.parse(e.text))}),o=I.load(decodeURI(e),i),o=o.then(function(t){return U[e]={value:t},t}).catch(function(t){throw U[e]={error:t},t})):o=o.then(function(){return r.value}),o=o.then(function(e){return n(e)})}function p(e,t){var r=!0;try{if(!m(e,"Object"))throw new Error("obj is not an Object");if(!m(e.$ref,"String"))throw new Error("obj.$ref is not a String")}catch(e){if(t)throw e;r=!1}return r}function m(e,t){return"Undefined"===t?"undefined"==typeof e:Object.prototype.toString.call(e)==="[object "+t+"]"}function h(e){var t,r;return m(e.filter,"Array")||m(e.filter,"String")?(r=m(e.filter,"String")?[e.filter]:e.filter,t=function(e){return r.indexOf(e.type)>-1||r.indexOf(f(e))>-1}):m(e.filter,"Function")?t=e.filter:m(e.filter,"Undefined")&&(t=function(){return!0}),function(r,n){return("invalid"!==r.type||e.includeInvalid===!0)&&t(r,n)}}function v(e){var t;return m(e.subDocPath,"Array")?t=e.subDocPath:m(e.subDocPath,"String")?t=S(e.subDocPath):m(e.subDocPath,"Undefined")&&(t=[]),t}function y(e){return R.parse(encodeURI(decodeURI(e)))}function g(e,t,r){c(e,t.slice(0,t.length-1))[decodeURI(t[t.length-1])]=r}function b(e,t,r,n){function o(t,o){r.push(o),b(e,t,r,n),r.pop()}var i=!0;m(n,"Function")&&(i=n(e,t,r)),e.indexOf(t)===-1&&(e.push(t),i!==!1&&(m(t,"Array")?t.forEach(function(e,t){o(e,t.toString())}):m(t,"Object")&&Object.keys(t).forEach(function(e){o(t[e],e)}))),e.pop()}function w(e,t){if(e=m(e,"Undefined")?{}:n(e),!m(e,"Object"))throw new TypeError("options must be an Object");if(!(m(e.filter,"Undefined")||m(e.filter,"Array")||m(e.filter,"Function")||m(e.filter,"String")))throw new TypeError("options.filter must be an Array, a Function of a String");if(!m(e.includeInvalid,"Undefined")&&!m(e.includeInvalid,"Boolean"))throw new TypeError("options.includeInvalid must be a Boolean");if(!m(e.refPreProcessor,"Undefined")&&!m(e.refPreProcessor,"Function"))throw new TypeError("options.refPreProcessor must be a Function");if(!m(e.refPostProcessor,"Undefined")&&!m(e.refPostProcessor,"Function"))throw new TypeError("options.refPostProcessor must be a Function");if(!m(e.subDocPath,"Undefined")&&!m(e.subDocPath,"Array")&&!T(e.subDocPath))throw new TypeError("options.subDocPath must be an Array of path segments or a valid JSON Pointer");if(e.filter=h(e),e.subDocPath=v(e),!m(t,"Undefined"))try{c(t,e.subDocPath)}catch(e){throw e.message=e.message.replace("JSON Pointer","options.subDocPath"),e}return e}function x(){U={}}function E(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),decodeURI(e.replace(/~1/g,"/").replace(/~0/g,"~"))})}function $(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),e.replace(/~/g,"~0").replace(/\//g,"~1")})}function C(e,t){var r={};if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");return t=w(t,e),b(a(e,t.subDocPath),c(e,t.subDocPath),n(t.subDocPath),function(e,o,i){var a,s=!0;return p(o)&&(m(t.refPreProcessor,"Undefined")||(o=t.refPreProcessor(n(o),i)),a=A(o),m(t.refPostProcessor,"Undefined")||(a=t.refPostProcessor(a,i)),t.filter(a,i)&&(r[P(i)]=a),u(o).length>0&&(s=!1)),s}),r}function k(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=w(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(U[e]),i=n(t),a=y(e);return m(o.refs,"Undefined")&&(delete i.filter,delete i.subDocPath,i.includeInvalid=!0,U[e].refs=C(r,i)),m(t.filter,"Undefined")||(i.filter=t.filter),m(a.fragment,"Undefined")?m(a.subDocPath,"Undefined")||(i.subDocPath=t.subDocPath):i.subDocPath=S(decodeURI(a.fragment)),{refs:C(r,i),value:r}})}function A(e){var t,r,n,o={def:e};try{p(e,!0)?(t=e.$ref,n=H[t],m(n,"Undefined")&&(n=H[t]=y(t)),o.uri=t,o.uriDetails=n,m(n.error,"Undefined")?o.type=f(o):(o.error=o.uriDetails.error,o.type="invalid"),r=u(e),r.length>0&&(o.warning="Extra JSON Reference properties will be ignored: "+r.join(", "))):o.type="invalid"}catch(e){o.error=e.message,o.type="invalid"}return o}function T(e,t){var r,n=!0;try{if(!m(e,"String"))throw new Error("ptr is not a String");if(""!==e){if(r=e.charAt(0),["#","/"].indexOf(r)===-1)throw new Error("ptr must start with a / or #/");if("#"===r&&"#"!==e&&"/"!==e.charAt(1))throw new Error("ptr must start with a / or #/");if(e.match(q))throw new Error("ptr has invalid token(s)")}}catch(e){if(t===!0)throw e;n=!1}return n}function O(e,t){return p(e,t)&&"invalid"!==A(e,t).type}function S(e){if(!T(e))throw new Error("ptr must be a JSON Pointer");var t=e.split("/");return t.shift(),E(t)}function P(e,t){if(!m(e,"Array"))throw new Error("path must be an Array");return(t!==!1?"#":"")+(e.length>0?"/":"")+$(e).join("/")}function M(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");t=w(t,e),e=n(e)}).then(function(){return l(e,t,[],[],{documents:{},refs:{}})}).then(function(t){function r(e,t){return S(e).length-S(t).length}var n={},o={};return Object.keys(t.refs).sort(r).forEach(function(r){var i=t.refs[r];i.indirect||(o[r]=i),delete i.indirect,m(i.error,"Undefined")&&"invalid"!==i.type?(m(i.value,"Undefined")&&i.circular&&(i.value=i.def),m(i.value,"Undefined")?n[r]=i:("#"===r?e=i.value:g(e,S(r),i.value),delete i.ancestorPtrs)):delete i.ancestorPtrs}),Object.keys(n).forEach(function(r){var o=n[r];o.ancestorPtrs.forEach(function(n,i){if(m(o.value,"Undefined"))try{o.value=c(t.documents[n],S(o.uri)),delete o.ancestorPtrs,g(e,S(r),o.value)}catch(e){i===o.ancestorPtrs.length-1&&(o.error=e.message,o.missing=!0,delete o.ancestorPtrs)}})}),{refs:o,resolved:e}})}function j(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=w(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(t),i=y(e);return m(i.fragment,"Undefined")||(o.subDocPath=S(decodeURI(i.fragment))),o.relativeBase=D.dirname(e),M(r,o).then(function(e){return{refs:e.refs,resolved:e.resolved,value:r}})})}var D=e("path"),I=e("path-loader"),_=e("querystring"),F=e("slash"),R=e("uri-js"),q=/~(?:[^01]|$)/g,U={},N=["relative","remote"],L=["absolute","uri"],H={};"undefined"==typeof Promise&&e("native-promise-only"),t.exports.clearCache=x,t.exports.decodePath=E,t.exports.encodePath=$,t.exports.findRefs=C,t.exports.findRefsAt=k,t.exports.getRefDetails=A,t.exports.isPtr=T,t.exports.isRef=O,t.exports.pathFromPtr=S,t.exports.pathToPtr=P,t.exports.resolveRefs=M,t.exports.resolveRefsAt=j},{"native-promise-only":3,path:4,"path-loader":5,querystring:11,slash:13,"uri-js":23}],2:[function(e,t,r){function n(e){if(e)return o(e)}function o(e){for(var t in n.prototype)e[t]=n.prototype[t];return e}t.exports=n,n.prototype.on=n.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},n.prototype.once=function(e,t){function r(){this.off(e,r),t.apply(this,arguments)}return r.fn=t,this.on(e,r),this},n.prototype.off=n.prototype.removeListener=n.prototype.removeAllListeners=n.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var n,o=0;o<r.length;o++)if(n=r[o],n===t||n.fn===t){r.splice(o,1);break}return this},n.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),r=this._callbacks["$"+e];if(r){r=r.slice(0);for(var n=0,o=r.length;n<o;++n)r[n].apply(this,t)}return this},n.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},n.prototype.hasListeners=function(e){return!!this.listeners(e).length}},{}],3:[function(n,o,i){(function(t){/*! Native Promise Only
+    v0.8.1 (c) Kyle Simpson
+    MIT License: http://getify.mit-license.org
+*/
+!function(t,r,n){r[t]=r[t]||n(),"undefined"!=typeof o&&o.exports?o.exports=r[t]:"function"==typeof e&&e.amd&&e(function(){return r[t]})}("Promise","undefined"!=typeof t?t:this,function(){"use strict";function e(e,t){m.add(e,t),p||(p=v(m.drain))}function t(e){var t,r="undefined"==typeof e?"undefined":c(e);return null==e||"object"!=r&&"function"!=r||(t=e.then),"function"==typeof t&&t}function n(){for(var e=0;e<this.chain.length;e++)o(this,1===this.state?this.chain[e].success:this.chain[e].failure,this.chain[e]);this.chain.length=0}function o(e,r,n){var o,i;try{r===!1?n.reject(e.msg):(o=r===!0?e.msg:r.call(void 0,e.msg),o===n.promise?n.reject(TypeError("Promise-chain cycle")):(i=t(o))?i.call(o,n.resolve,n.reject):n.resolve(o))}catch(e){n.reject(e)}}function i(r){var o,s=this;if(!s.triggered){s.triggered=!0,s.def&&(s=s.def);try{(o=t(r))?e(function(){var e=new l(s);try{o.call(r,function(){i.apply(e,arguments)},function(){a.apply(e,arguments)})}catch(t){a.call(e,t)}}):(s.msg=r,s.state=1,s.chain.length>0&&e(n,s))}catch(e){a.call(new l(s),e)}}}function a(t){var r=this;r.triggered||(r.triggered=!0,r.def&&(r=r.def),r.msg=t,r.state=2,r.chain.length>0&&e(n,r))}function s(e,t,r,n){for(var o=0;o<t.length;o++)!function(o){e.resolve(t[o]).then(function(e){r(o,e)},n)}(o)}function l(e){this.def=e,this.triggered=!1}function u(e){this.promise=e,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function f(t){if("function"!=typeof t)throw TypeError("Not a function");if(0!==this.__NPO__)throw TypeError("Not a promise");this.__NPO__=1;var r=new u(this);this.then=function(t,o){var i={success:"function"!=typeof t||t,failure:"function"==typeof o&&o};return i.promise=new this.constructor(function(e,t){if("function"!=typeof e||"function"!=typeof t)throw TypeError("Not a function");i.resolve=e,i.reject=t}),r.chain.push(i),0!==r.state&&e(n,r),i.promise},this.catch=function(e){return this.then(void 0,e)};try{t.call(void 0,function(e){i.call(r,e)},function(e){a.call(r,e)})}catch(e){a.call(r,e)}}var d,p,m,h=Object.prototype.toString,v="undefined"!=typeof r?function(e){return r(e)}:setTimeout;try{Object.defineProperty({},"x",{}),d=function(e,t,r,n){return Object.defineProperty(e,t,{value:r,writable:!0,configurable:n!==!1})}}catch(e){d=function(e,t,r){return e[t]=r,e}}m=function(){function e(e,t){this.fn=e,this.self=t,this.next=void 0}var t,r,n;return{add:function(o,i){n=new e(o,i),r?r.next=n:t=n,r=n,n=void 0},drain:function(){var e=t;for(t=r=p=void 0;e;)e.fn.call(e.self),e=e.next}}}();var y=d({},"constructor",f,!1);return f.prototype=y,d(y,"__NPO__",0,!1),d(f,"resolve",function(e){var t=this;return e&&"object"==("undefined"==typeof e?"undefined":c(e))&&1===e.__NPO__?e:new t(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");t(e)})}),d(f,"reject",function(e){return new this(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");r(e)})}),d(f,"all",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):0===e.length?t.resolve([]):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");var o=e.length,i=Array(o),a=0;s(t,e,function(e,t){i[e]=t,++a===o&&r(i)},n)})}),d(f,"race",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");s(t,e,function(e,t){r(t)},n)})}),f})}).call(this,"undefined"!=typeof t?t:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],4:[function(e,t,r){(function(e){function t(e,t){for(var r=0,n=e.length-1;n>=0;n--){var o=e[n];"."===o?e.splice(n,1):".."===o?(e.splice(n,1),r++):r&&(e.splice(n,1),r--)}if(t)for(;r--;r)e.unshift("..");return e}function n(e,t){if(e.filter)return e.filter(t);for(var r=[],n=0;n<e.length;n++)t(e[n],n,e)&&r.push(e[n]);return r}var o=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,i=function(e){return o.exec(e).slice(1)};r.resolve=function(){for(var r="",o=!1,i=arguments.length-1;i>=-1&&!o;i--){var a=i>=0?arguments[i]:e.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(r=a+"/"+r,o="/"===a.charAt(0))}return r=t(n(r.split("/"),function(e){return!!e}),!o).join("/"),(o?"/":"")+r||"."},r.normalize=function(e){var o=r.isAbsolute(e),i="/"===a(e,-1);return e=t(n(e.split("/"),function(e){return!!e}),!o).join("/"),e||o||(e="."),e&&i&&(e+="/"),(o?"/":"")+e},r.isAbsolute=function(e){return"/"===e.charAt(0)},r.join=function(){var e=Array.prototype.slice.call(arguments,0);return r.normalize(n(e,function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e}).join("/"))},r.relative=function(e,t){function n(e){for(var t=0;t<e.length&&""===e[t];t++);for(var r=e.length-1;r>=0&&""===e[r];r--);return t>r?[]:e.slice(t,r-t+1)}e=r.resolve(e).substr(1),t=r.resolve(t).substr(1);for(var o=n(e.split("/")),i=n(t.split("/")),a=Math.min(o.length,i.length),s=a,l=0;l<a;l++)if(o[l]!==i[l]){s=l;break}for(var c=[],l=s;l<o.length;l++)c.push("..");return c=c.concat(i.slice(s)),c.join("/")},r.sep="/",r.delimiter=":",r.dirname=function(e){var t=i(e),r=t[0],n=t[1];return r||n?(n&&(n=n.substr(0,n.length-1)),r+n):"."},r.basename=function(e,t){var r=i(e)[2];return t&&r.substr(-1*t.length)===t&&(r=r.substr(0,r.length-t.length)),r},r.extname=function(e){return i(e)[3]};var a="b"==="ab".substr(-1)?function(e,t,r){return e.substr(t,r)}:function(e,t,r){return t<0&&(t=e.length+t),e.substr(t,r)}}).call(this,e("_process"))},{_process:8}],5:[function(e,t,r){"use strict";function n(e){return"undefined"!=typeof e&&(e=e.indexOf("://")===-1?"":e.split("://")[0]),e}function o(e){var t=n(e),r=i[t];if("undefined"==typeof r){if(""!==t)throw new Error("Unsupported scheme: "+t);r=a}return r}var i={file:e("./lib/loaders/file"),http:e("./lib/loaders/http"),https:e("./lib/loaders/http")},a="object"===("undefined"==typeof window?"undefined":c(window))||"function"==typeof importScripts?i.http:i.file;"undefined"==typeof Promise&&e("native-promise-only"),t.exports.load=function(e,t){var r=Promise.resolve();return"undefined"==typeof t&&(t={}),r=r.then(function(){if("undefined"==typeof e)throw new TypeError("location is required");if("string"!=typeof e)throw new TypeError("location must be a string");if("undefined"!=typeof t){if("object"!==("undefined"==typeof t?"undefined":c(t)))throw new TypeError("options must be an object");if("undefined"!=typeof t.processContent&&"function"!=typeof t.processContent)throw new TypeError("options.processContent must be a function")}}),r=r.then(function(){return new Promise(function(r,n){var i=o(e);i.load(e,t||{},function(e,t){e?n(e):r(t)})})}).then(function(e){return t.processContent?new Promise(function(r,n){t.processContent("object"===("undefined"==typeof e?"undefined":c(e))?e:{text:e},function(e,t){e?n(e):r(t)})}):"object"===("undefined"==typeof e?"undefined":c(e))?e.text:e})}},{"./lib/loaders/file":6,"./lib/loaders/http":7,"native-promise-only":3}],6:[function(e,t,r){"use strict";var n=new TypeError("The 'file' scheme is not supported in the browser");t.exports.getBase=function(){throw n},t.exports.load=function(){var e=arguments[arguments.length-1];if("function"!=typeof e)throw n;e(n)}},{}],7:[function(e,t,r){"use strict";var n=e("superagent"),o=["delete","get","head","patch","post","put"];t.exports.load=function(e,t,r){function i(e,t){e?r(e):("function"==typeof t.buffer&&t.buffer(!0),t.end(function(e,t){e?r(e):r(void 0,t)}))}var a,s,l=t.method?t.method.toLowerCase():"get";if("undefined"!=typeof t.method?"string"!=typeof t.method?a=new TypeError("options.method must be a string"):o.indexOf(t.method)===-1&&(a=new TypeError("options.method must be one of the following: "+o.slice(0,o.length-1).join(", ")+" or "+o[o.length-1])):"undefined"!=typeof t.prepareRequest&&"function"!=typeof t.prepareRequest&&(a=new TypeError("options.prepareRequest must be a function")),a)r(a);else if(s=n["delete"===l?"del":l](e),t.prepareRequest)try{t.prepareRequest(s,i)}catch(e){r(e)}else i(void 0,s)}},{superagent:14}],8:[function(e,t,r){function n(){u=!1,s.length?c=s.concat(c):f=-1,c.length&&o()}function o(){if(!u){var e=setTimeout(n);u=!0;for(var t=c.length;t;){for(s=c,c=[];++f<t;)s&&s[f].run();f=-1,t=c.length}s=null,u=!1,clearTimeout(e)}}function i(e,t){this.fun=e,this.array=t}function a(){}var s,l=t.exports={},c=[],u=!1,f=-1;l.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];c.push(new i(e,t)),1!==c.length||u||setTimeout(o,0)},i.prototype.run=function(){this.fun.apply(null,this.array)},l.title="browser",l.browser=!0,l.env={},l.argv=[],l.version="",l.versions={},l.on=a,l.addListener=a,l.once=a,l.off=a,l.removeListener=a,l.removeAllListeners=a,l.emit=a,l.binding=function(e){throw new Error("process.binding is not supported")},l.cwd=function(){return"/"},l.chdir=function(e){throw new Error("process.chdir is not supported")},l.umask=function(){return 0}},{}],9:[function(e,t,r){"use strict";function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.exports=function(e,t,r,i){t=t||"&",r=r||"=";var a={};if("string"!=typeof e||0===e.length)return a;var s=/\+/g;e=e.split(t);var l=1e3;i&&"number"==typeof i.maxKeys&&(l=i.maxKeys);var c=e.length;l>0&&c>l&&(c=l);for(var u=0;u<c;++u){var f,d,p,m,h=e[u].replace(s,"%20"),v=h.indexOf(r);v>=0?(f=h.substr(0,v),d=h.substr(v+1)):(f=h,d=""),p=decodeURIComponent(f),m=decodeURIComponent(d),n(a,p)?o(a[p])?a[p].push(m):a[p]=[a[p],m]:a[p]=m}return a};var o=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},{}],10:[function(e,t,r){"use strict";function n(e,t){if(e.map)return e.map(t);for(var r=[],n=0;n<e.length;n++)r.push(t(e[n],n));return r}var o=function(e){switch("undefined"==typeof e?"undefined":c(e)){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};t.exports=function(e,t,r,s){return t=t||"&",r=r||"=",null===e&&(e=void 0),"object"===("undefined"==typeof e?"undefined":c(e))?n(a(e),function(a){var s=encodeURIComponent(o(a))+r;return i(e[a])?n(e[a],function(e){return s+encodeURIComponent(o(e))}).join(t):s+encodeURIComponent(o(e[a]))}).join(t):s?encodeURIComponent(o(s))+r+encodeURIComponent(o(e)):""};var i=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},a=Object.keys||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t}},{}],11:[function(e,t,r){"use strict";r.decode=r.parse=e("./decode"),r.encode=r.stringify=e("./encode")},{"./decode":9,"./encode":10}],12:[function(e,t,r){t.exports=function(e,t,r){for(var n=0,o=e.length,i=3==arguments.length?r:e[n++];n<o;)i=t.call(null,i,e[n],++n,e);return i}},{}],13:[function(e,t,r){"use strict";t.exports=function(e){var t=/^\\\\\?\\/.test(e),r=/[^\x00-\x80]+/.test(e);return t||r?e:e.replace(/\\/g,"/")}},{}],14:[function(e,t,r){function n(){}function o(e){var t={}.toString.call(e);switch(t){case"[object File]":case"[object Blob]":case"[object FormData]":return!0;default:return!1}}function i(e){if(!b(e))return e;var t=[];for(var r in e)null!=e[r]&&a(t,r,e[r]);return t.join("&")}function a(e,t,r){return Array.isArray(r)?r.forEach(function(r){a(e,t,r)}):void e.push(encodeURIComponent(t)+"="+encodeURIComponent(r))}function s(e){for(var t,r,n={},o=e.split("&"),i=0,a=o.length;i<a;++i)r=o[i],t=r.split("="),n[decodeURIComponent(t[0])]=decodeURIComponent(t[1]);return n}function l(e){var t,r,n,o,i=e.split(/\r?\n/),a={};i.pop();for(var s=0,l=i.length;s<l;++s)r=i[s],t=r.indexOf(":"),n=r.slice(0,t).toLowerCase(),o=x(r.slice(t+1)),a[n]=o;return a}function c(e){return/[\/+]json\b/.test(e)}function u(e){return e.split(/ *; */).shift()}function f(e){return y(e.split(/ *; */),function(e,t){var r=t.split(/ *= */),n=r.shift(),o=r.shift();return n&&o&&(e[n]=o),e},{})}function d(e,t){t=t||{},this.req=e,this.xhr=this.req.xhr,this.text="HEAD"!=this.req.method&&(""===this.xhr.responseType||"text"===this.xhr.responseType)||"undefined"==typeof this.xhr.responseType?this.xhr.responseText:null,this.statusText=this.req.xhr.statusText,this.setStatusProperties(this.xhr.status),this.header=this.headers=l(this.xhr.getAllResponseHeaders()),this.header["content-type"]=this.xhr.getResponseHeader("content-type"),this.setHeaderProperties(this.header),this.body="HEAD"!=this.req.method?this.parseBody(this.text?this.text:this.xhr.response):null}function p(e,t){var r=this;this._query=this._query||[],this.method=e,this.url=t,this.header={},this._header={},this.on("end",function(){var e=null,t=null;try{t=new d(r)}catch(t){return e=new Error("Parser is unable to parse the response"),e.parse=!0,e.original=t,e.rawResponse=r.xhr&&r.xhr.responseText?r.xhr.responseText:null,e.statusCode=r.xhr&&r.xhr.status?r.xhr.status:null,r.callback(e)}if(r.emit("response",t),e)return r.callback(e,t);if(t.status>=200&&t.status<300)return r.callback(e,t);var n=new Error(t.statusText||"Unsuccessful HTTP response");n.original=e,n.response=t,n.status=t.status,r.callback(n,t)})}function m(e,t){var r=w("DELETE",e);return t&&r.end(t),r}var h,v=e("emitter"),y=e("reduce"),g=e("./request-base"),b=e("./is-object");h="undefined"!=typeof window?window:"undefined"!=typeof self?self:this;var w=t.exports=e("./request").bind(null,p);w.getXHR=function(){if(!(!h.XMLHttpRequest||h.location&&"file:"==h.location.protocol&&h.ActiveXObject))return new XMLHttpRequest;try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(e){}return!1};var x="".trim?function(e){return e.trim()}:function(e){return e.replace(/(^\s*|\s*$)/g,"")};w.serializeObject=i,w.parseString=s,w.types={html:"text/html",json:"application/json",xml:"application/xml",urlencoded:"application/x-www-form-urlencoded",form:"application/x-www-form-urlencoded","form-data":"application/x-www-form-urlencoded"},w.serialize={"application/x-www-form-urlencoded":i,"application/json":JSON.stringify},w.parse={"application/x-www-form-urlencoded":s,"application/json":JSON.parse},d.prototype.get=function(e){return this.header[e.toLowerCase()]},d.prototype.setHeaderProperties=function(e){var t=this.header["content-type"]||"";this.type=u(t);var r=f(t);for(var n in r)this[n]=r[n]},d.prototype.parseBody=function(e){var t=w.parse[this.type];return!t&&c(this.type)&&(t=w.parse["application/json"]),t&&e&&(e.length||e instanceof Object)?t(e):null},d.prototype.setStatusProperties=function(e){1223===e&&(e=204);var t=e/100|0;this.status=this.statusCode=e,this.statusType=t,this.info=1==t,this.ok=2==t,this.clientError=4==t,this.serverError=5==t,this.error=(4==t||5==t)&&this.toError(),this.accepted=202==e,this.noContent=204==e,this.badRequest=400==e,this.unauthorized=401==e,this.notAcceptable=406==e,this.notFound=404==e,this.forbidden=403==e},d.prototype.toError=function(){var e=this.req,t=e.method,r=e.url,n="cannot "+t+" "+r+" ("+this.status+")",o=new Error(n);return o.status=this.status,o.method=t,o.url=r,o},w.Response=d,v(p.prototype);for(var E in g)p.prototype[E]=g[E];p.prototype.abort=function(){if(!this.aborted)return this.aborted=!0,this.xhr.abort(),this.clearTimeout(),this.emit("abort"),this},p.prototype.type=function(e){return this.set("Content-Type",w.types[e]||e),this},p.prototype.responseType=function(e){return this._responseType=e,this},p.prototype.accept=function(e){return this.set("Accept",w.types[e]||e),this},p.prototype.auth=function(e,t,r){switch(r||(r={type:"basic"}),r.type){case"basic":var n=btoa(e+":"+t);this.set("Authorization","Basic "+n);break;case"auto":this.username=e,this.password=t}return this},p.prototype.query=function(e){return"string"!=typeof e&&(e=i(e)),e&&this._query.push(e),this},p.prototype.attach=function(e,t,r){return this._getFormData().append(e,t,r||t.name),this},p.prototype._getFormData=function(){return this._formData||(this._formData=new h.FormData),this._formData},p.prototype.send=function(e){var t=b(e),r=this._header["content-type"];if(t&&b(this._data))for(var n in e)this._data[n]=e[n];else"string"==typeof e?(r||this.type("form"),r=this._header["content-type"],"application/x-www-form-urlencoded"==r?this._data=this._data?this._data+"&"+e:e:this._data=(this._data||"")+e):this._data=e;return!t||o(e)?this:(r||this.type("json"),this)},d.prototype.parse=function(e){return h.console&&console.warn("Client-side parse() method has been renamed to serialize(). This method is not compatible with superagent v2.0"),this.serialize(e),this},d.prototype.serialize=function(e){return this._parser=e,this},p.prototype.callback=function(e,t){var r=this._callback;this.clearTimeout(),r(e,t)},p.prototype.crossDomainError=function(){var e=new Error("Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.");e.crossDomain=!0,e.status=this.status,e.method=this.method,e.url=this.url,this.callback(e)},p.prototype.timeoutError=function(){var e=this._timeout,t=new Error("timeout of "+e+"ms exceeded");t.timeout=e,this.callback(t)},p.prototype.withCredentials=function(){return this._withCredentials=!0,this},p.prototype.end=function(e){var t=this,r=this.xhr=w.getXHR(),i=this._query.join("&"),a=this._timeout,s=this._formData||this._data;this._callback=e||n,r.onreadystatechange=function(){if(4==r.readyState){var e;try{e=r.status}catch(t){e=0}if(0==e){if(t.timedout)return t.timeoutError();if(t.aborted)return;return t.crossDomainError()}t.emit("end")}};var l=function(e){e.total>0&&(e.percent=e.loaded/e.total*100),e.direction="download",t.emit("progress",e)};this.hasListeners("progress")&&(r.onprogress=l);try{r.upload&&this.hasListeners("progress")&&(r.upload.onprogress=l)}catch(e){}if(a&&!this._timer&&(this._timer=setTimeout(function(){t.timedout=!0,t.abort()},a)),i&&(i=w.serializeObject(i),this.url+=~this.url.indexOf("?")?"&"+i:"?"+i),this.username&&this.password?r.open(this.method,this.url,!0,this.username,this.password):r.open(this.method,this.url,!0),this._withCredentials&&(r.withCredentials=!0),"GET"!=this.method&&"HEAD"!=this.method&&"string"!=typeof s&&!o(s)){var u=this._header["content-type"],f=this._parser||w.serialize[u?u.split(";")[0]:""];!f&&c(u)&&(f=w.serialize["application/json"]),f&&(s=f(s))}for(var d in this.header)null!=this.header[d]&&r.setRequestHeader(d,this.header[d]);return this._responseType&&(r.responseType=this._responseType),this.emit("request",this),r.send("undefined"!=typeof s?s:null),this},w.Request=p,w.get=function(e,t,r){var n=w("GET",e);return"function"==typeof t&&(r=t,t=null),t&&n.query(t),r&&n.end(r),n},w.head=function(e,t,r){var n=w("HEAD",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},w.del=m,w.delete=m,w.patch=function(e,t,r){var n=w("PATCH",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},w.post=function(e,t,r){var n=w("POST",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},w.put=function(e,t,r){var n=w("PUT",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n}},{"./is-object":15,"./request":17,"./request-base":16,emitter:2,reduce:12}],15:[function(e,t,r){function n(e){return null!=e&&"object"==("undefined"==typeof e?"undefined":c(e))}t.exports=n},{}],16:[function(e,t,r){var n=e("./is-object");r.clearTimeout=function(){return this._timeout=0,clearTimeout(this._timer),this},r.parse=function(e){return this._parser=e,this},r.timeout=function(e){return this._timeout=e,this},r.then=function(e,t){return this.end(function(r,n){r?t(r):e(n)})},r.use=function(e){return e(this),this},r.get=function(e){return this._header[e.toLowerCase()]},r.getHeader=r.get,r.set=function(e,t){if(n(e)){for(var r in e)this.set(r,e[r]);return this}return this._header[e.toLowerCase()]=t,this.header[e]=t,this},r.unset=function(e){return delete this._header[e.toLowerCase()],delete this.header[e],this},r.field=function(e,t){return this._getFormData().append(e,t),this}},{"./is-object":15}],17:[function(e,t,r){function n(e,t,r){return"function"==typeof r?new e("GET",t).end(r):2==arguments.length?new e("GET",t):new e(t,r)}t.exports=n},{}],18:[function(e,t,r){/*! https://mths.be/punycode v1.3.2 by @mathias, modified for URI.js */var n=function(){function e(e){throw new RangeError(k[e])}function t(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function r(e,r){var n=e.split("@"),o="";n.length>1&&(o=n[0]+"@",e=n[1]),e=e.replace(C,".");var i=e.split("."),a=t(i,r).join(".");return o+a}function n(e){for(var t,r,n=[],o=0,i=e.length;o<i;)t=e.charCodeAt(o++),t>=55296&&t<=56319&&o<i?(r=e.charCodeAt(o++),56320==(64512&r)?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),o--)):n.push(t);return n}function o(e){return t(e,function(e){var t="";return e>65535&&(e-=65536,t+=O(e>>>10&1023|55296),e=56320|1023&e),t+=O(e)}).join("")}function i(e){return e-48<10?e-22:e-65<26?e-65:e-97<26?e-97:m}function a(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function s(e,t,r){var n=0;for(e=r?T(e/g):e>>1,e+=T(e/t);e>A*v>>1;n+=m)e=T(e/A);return T(n+(A+1)*e/(e+y))}function l(t){var r,n,a,l,c,u,f,d,y,g,E=[],$=t.length,C=0,k=w,A=b;for(n=t.lastIndexOf(x),n<0&&(n=0),a=0;a<n;++a)t.charCodeAt(a)>=128&&e("not-basic"),E.push(t.charCodeAt(a));for(l=n>0?n+1:0;l<$;){for(c=C,u=1,f=m;l>=$&&e("invalid-input"),d=i(t.charCodeAt(l++)),(d>=m||d>T((p-C)/u))&&e("overflow"),C+=d*u,y=f<=A?h:f>=A+v?v:f-A,!(d<y);f+=m)g=m-y,u>T(p/g)&&e("overflow"),u*=g;r=E.length+1,A=s(C-c,r,0==c),T(C/r)>p-k&&e("overflow"),k+=T(C/r),C%=r,E.splice(C++,0,k)}return o(E)}function c(t){var r,o,i,l,c,u,f,d,y,g,E,$,C,k,A,S=[];for(t=n(t),$=t.length,r=w,o=0,c=b,u=0;u<$;++u)E=t[u],E<128&&S.push(O(E));for(i=l=S.length,l&&S.push(x);i<$;){for(f=p,u=0;u<$;++u)E=t[u],E>=r&&E<f&&(f=E);for(C=i+1,f-r>T((p-o)/C)&&e("overflow"),o+=(f-r)*C,r=f,u=0;u<$;++u)if(E=t[u],E<r&&++o>p&&e("overflow"),E==r){for(d=o,y=m;g=y<=c?h:y>=c+v?v:y-c,!(d<g);y+=m)A=d-g,k=m-g,S.push(O(a(g+A%k,0))),d=T(A/k);S.push(O(a(d,0))),c=s(o,C,i==l),o=0,++i}++o,++r}return S.join("")}function u(e){return r(e,function(e){return E.test(e)?l(e.slice(4).toLowerCase()):e})}function f(e){return r(e,function(e){return $.test(e)?"xn--"+c(e):e})}var d,p=2147483647,m=36,h=1,v=26,y=38,g=700,b=72,w=128,x="-",E=/^xn--/,$=/[^\x20-\x7E]/,C=/[\x2E\u3002\uFF0E\uFF61]/g,k={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},A=m-h,T=Math.floor,O=String.fromCharCode;return d={version:"1.3.2",ucs2:{decode:n,encode:o},decode:l,encode:c,toASCII:f,toUnicode:u}}();"undefined"==typeof COMPILED&&"undefined"!=typeof t&&(t.exports=n)},{}],19:[function(e,t,r){e("./schemes/http"),e("./schemes/urn"),e("./schemes/mailto")},{"./schemes/http":20,"./schemes/mailto":21,"./schemes/urn":22}],20:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");n.SCHEMES.http=n.SCHEMES.https={domainHost:!0,parse:function(e,t){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e},serialize:function(e,t){return e.port!==("https"!==String(e.scheme).toLowerCase()?80:443)&&""!==e.port||(e.port=void 0),e.path||(e.path="/"),e}}},{"../uri":23}],21:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri"),o=e("../punycode");!function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(e){return e.toUpperCase()}function i(e){var t=n.pctDecChars(e);return t.match(M)?t:e}function a(e){return void 0!==e&&null!==e?e instanceof Array&&!e.callee?e:"number"!=typeof e.length||e.split||e.setInterval||e.call?[e]:Array.prototype.slice.call(e):[]}var s={},l=n.IRI_SUPPORT,c="[A-Za-z0-9\\-\\.\\_\\~"+(l?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",u="[0-9A-Fa-f]",f=t(t("%[EFef]"+u+"%"+u+u+"%"+u+u)+"|"+t("%[89A-Fa-f]"+u+"%"+u+u)+"|"+t("%"+u+u)),d="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",p="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",m=e(p,'[\\"\\\\]'),h=t(d+"+"+t("\\."+d+"+")+"*"),v=t("\\\\"+m),y=t(p+"|"+v),g=t('\\"'+y+'*\\"'),b="[\\x21-\\x5A\\x5E-\\x7E]",w="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",x=t(c+"|"+f+"|"+w),E=t(h+"|\\["+b+"*\\]"),$=t(h+"|"+g),C=t($+"\\@"+E),k=t(C+t("\\,"+C)+"*"),A=t(x+"*"),T=A,O=t(A+"\\="+T),S=t(O+t("\\&"+O)+"*"),P=t("\\?"+S),M=(n.VALIDATE_SUPPORT&&new RegExp("^mailto\\:"+k+"?"+P+"?$"),new RegExp(c,"g")),j=new RegExp(f,"g"),D=new RegExp(e("[^]",d,"[\\.]",'[\\"]',m),"g"),I=new RegExp(e("[^]",d,"[\\.]","[\\[]",b,"[\\]]"),"g"),_=new RegExp(e("[^]",c,w),"g"),F=_,R=n.VALIDATE_SUPPORT&&new RegExp("^"+k+"$"),q=n.VALIDATE_SUPPORT&&new RegExp("^"+S+"$");n.SCHEMES.mailto={parse:function(e,t){n.VALIDATE_SUPPORT&&!e.error&&(e.path&&!R.test(e.path)?e.error="Email address is not valid":e.query&&!q.test(e.query)&&(e.error="Header fields are invalid"));var r=e.to=e.path?e.path.split(","):[];if(e.path=void 0,e.query){for(var i=!1,a={},s=e.query.split("&"),l=0,c=s.length;l<c;++l){var u=s[l].split("=");switch(u[0]){case"to":for(var f=u[1].split(","),d=0,p=f.length;d<p;++d)r.push(f[d]);break;case"subject":e.subject=n.unescapeComponent(u[1],t);break;case"body":e.body=n.unescapeComponent(u[1],t);break;default:i=!0,a[n.unescapeComponent(u[0],t)]=n.unescapeComponent(u[1],t)}}i&&(e.headers=a)}e.query=void 0;for(var l=0,c=r.length;l<c;++l){var m=r[l].split("@");if(m[0]=n.unescapeComponent(m[0]),"undefined"==typeof o||t.unicodeSupport)m[1]=n.unescapeComponent(m[1],t).toLowerCase();else try{m[1]=o.toASCII(n.unescapeComponent(m[1],t).toLowerCase())}catch(t){e.error=e.error||"Email address's domain name can not be converted to ASCII via punycode: "+t}r[l]=m.join("@")}return e},serialize:function(e,t){var l=a(e.to);if(l){for(var c=0,u=l.length;c<u;++c){var f=String(l[c]),d=f.lastIndexOf("@"),p=f.slice(0,d),m=f.slice(d+1);if(p=p.replace(j,i).replace(j,r).replace(D,n.pctEncChar),"undefined"!=typeof o)try{m=t.iri?o.toUnicode(m):o.toASCII(n.unescapeComponent(m,t).toLowerCase())}catch(r){e.error=e.error||"Email address's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}else m=m.replace(j,i).toLowerCase().replace(j,r).replace(I,n.pctEncChar);l[c]=p+"@"+m}e.path=l.join(",")}var h=e.headers=e.headers||{};e.subject&&(h.subject=e.subject),e.body&&(h.body=e.body);var v=[];for(var y in h)h[y]!==s[y]&&v.push(y.replace(j,i).replace(j,r).replace(_,n.pctEncChar)+"="+h[y].replace(j,i).replace(j,r).replace(F,n.pctEncChar));return v.length&&(e.query=v.join("&")),e}}}()},{"../punycode":18,"../uri":23}],22:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");!function(){var e=n.pctEncChar,t="(?:[0-9A-Za-z][0-9A-Za-z\\-]{1,31})",r="(?:\\%[0-9A-Fa-f]{2})",o="[0-9A-Za-z\\(\\)\\+\\,\\-\\.\\:\\=\\@\\;\\$\\_\\!\\*\\'\\/\\?\\#]",i="(?:(?:"+r+"|"+o+")+)",a=new RegExp("^urn\\:("+t+")$"),s=new RegExp("^("+t+")\\:("+i+")$"),l=/^([^\:]+)\:(.*)/,c=/[\x00-\x20\\\"\&\<\>\[\]\^\`\{\|\}\~\x7F-\xFF]/g,u=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/;n.SCHEMES.urn={parse:function(e,t){var r,o,i=e.path.match(s);return i||(t.tolerant||(e.error=e.error||"URN is not strictly valid."),i=e.path.match(l)),i?(r="urn:"+i[1].toLowerCase(),o=n.SCHEMES[r],o||(o=n.SCHEMES[r]={parse:function(e,t){return e},serialize:n.SCHEMES.urn.serialize}),e.scheme=r,e.path=i[2],e=o.parse(e,t)):e.error=e.error||"URN can not be parsed.",e},serialize:function(t,r){var n,o=t.scheme||r.scheme;if(o&&"urn"!==o){var n=o.match(a);n||(n=["urn:"+o,o]),t.scheme="urn",t.path=n[1]+":"+(t.path?t.path.replace(c,e):"")}return t}},n.SCHEMES["urn:uuid"]={parse:function(e,t){return t.tolerant||e.path&&e.path.match(u)||(e.error=e.error||"UUID is not valid."),e},serialize:function(e,t){return t.tolerant||e.path&&e.path.match(u)?e.path=(e.path||"").toLowerCase():e.scheme=void 0,n.SCHEMES.urn.serialize(e,t)}}}()},{"../uri":23}],23:[function(e,t,r){/**
+ * URI.js
+ *
+ * @fileoverview An RFC 3986 compliant, scheme extendable URI parsing/validating/resolving library for JavaScript.
+ * @author <a href="mailto:gary.court@gmail.com">Gary Court</a>
+ * @version 2.0.0
+ * @see http://github.com/garycourt/uri-js
+ * @license URI.js v2.0.0 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js
+ */
+var n=!1,o=!0,i=!0,a=function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(r){var n="[A-Za-z]",o="[0-9]",a=e(o,"[A-Fa-f]"),s=t(t("%[EFef]"+a+"%"+a+a+"%"+a+a)+"|"+t("%[89A-Fa-f]"+a+"%"+a+a)+"|"+t("%"+a+a)),l="[\\:\\/\\?\\#\\[\\]\\@]",c="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",u=e(l,c),f=r?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",d=r?"[\\uE000-\\uF8FF]":"[]",p=e(n,o,"[\\-\\.\\_\\~]",f),m=t(n+e(n,o,"[\\+\\-\\.]")+"*"),h=t(t(s+"|"+e(p,c,"[\\:]"))+"*"),v=t(t("25[0-5]")+"|"+t("2[0-4]"+o)+"|"+t("1"+o+o)+"|"+t("[1-9]"+o)+"|"+o),y=t(v+"\\."+v+"\\."+v+"\\."+v),g=t(a+"{1,4}"),b=(t(t(g+"\\:"+g)+"|"+y),t(e(p,c,"[\\:]")+"+")),w=t("v"+a+"+\\."+e(p,c,"[\\:]")+"+"),x=t("\\["+t(b+"|"+w)+"\\]"),E=t(t(s+"|"+e(p,c))+"*"),$=t(x+"|"+y+"(?!"+E+")|"+E),C=t(o+"*"),k=t(t(h+"@")+"?"+$+t("\\:"+C)+"?"),A=t(s+"|"+e(p,c,"[\\:\\@]")),T=t(A+"*"),O=t(A+"+"),S=t(t(s+"|"+e(p,c,"[\\@]"))+"+"),P=t(t("\\/"+T)+"*"),M=t("\\/"+t(O+P)+"?"),j=t(S+P),D=t(O+P),I="(?!"+A+")",_=(t(P+"|"+M+"|"+j+"|"+D+"|"+I),t(t(A+"|"+e("[\\/\\?]",d))+"*")),F=t(t(A+"|[\\/\\?]")+"*"),R=t(t("\\/\\/"+k+P)+"|"+M+"|"+D+"|"+I),q=t(m+"\\:"+R+t("\\?"+_)+"?"+t("\\#"+F)+"?"),U=t(t("\\/\\/"+k+P)+"|"+M+"|"+j+"|"+I),N=t(U+t("\\?"+_)+"?"+t("\\#"+F)+"?"),L=(t(q+"|"+N),t(m+"\\:"+R+t("\\?"+_)+"?"),"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+D+"|"+I+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$"),H="^(){0}"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+j+"|"+I+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$";"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+D+"|"+I+")")+t("\\?("+_+")")+"?$","^"+t("\\#("+F+")")+"?$","^"+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?$";return{URI_REF:i&&new RegExp("("+L+")|("+H+")"),NOT_SCHEME:new RegExp(e("[^]",n,o,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(e("[^\\%\\:]",p,c),"g"),NOT_HOST:new RegExp(e("[^\\%]",p,c),"g"),NOT_PATH:new RegExp(e("[^\\%\\/\\:\\@]",p,c),"g"),NOT_PATH_NOSCHEME:new RegExp(e("[^\\%\\/\\@]",p,c),"g"),NOT_QUERY:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]",d),"g"),NOT_FRAGMENT:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(e("[^]",p,c),"g"),UNRESERVED:new RegExp(p,"g"),OTHER_CHARS:new RegExp(e("[^\\%]",p,u),"g"),PCT_ENCODED:new RegExp(s,"g")}}function n(e){var t,r=e.charCodeAt(0);return t=r<16?"%0"+r.toString(16).toUpperCase():r<128?"%"+r.toString(16).toUpperCase():r<2048?"%"+(r>>6|192).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase():"%"+(r>>12|224).toString(16).toUpperCase()+"%"+(r>>6&63|128).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase()}function a(e){for(var t,r,n,o="",i=0,a=e.length;i<a;)t=parseInt(e.substr(i+1,2),16),t<128?(o+=String.fromCharCode(t),i+=3):t>=194&&t<224?(a-i>=6?(r=parseInt(e.substr(i+4,2),16),o+=String.fromCharCode((31&t)<<6|63&r)):o+=e.substr(i,6),i+=6):t>=224?(a-i>=9?(r=parseInt(e.substr(i+4,2),16),n=parseInt(e.substr(i+7,2),16),o+=String.fromCharCode((15&t)<<12|(63&r)<<6|63&n)):o+=e.substr(i,9),i+=9):(o+=e.substr(i,3),i+=3);return o}function l(e){return void 0===e?"undefined":null===e?"null":Object.prototype.toString.call(e).split(" ").pop().split("]").shift().toLowerCase()}function c(e){return e.toUpperCase()}function u(e,t){function r(e){var r=a(e);return r.match(t.UNRESERVED)?r:e}return e.scheme&&(e.scheme=String(e.scheme).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_SCHEME,"")),void 0!==e.userinfo&&(e.userinfo=String(e.userinfo).replace(t.PCT_ENCODED,r).replace(t.NOT_USERINFO,n).replace(t.PCT_ENCODED,c)),void 0!==e.host&&(e.host=String(e.host).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_HOST,n).replace(t.PCT_ENCODED,c)),void 0!==e.path&&(e.path=String(e.path).replace(t.PCT_ENCODED,r).replace(e.scheme?t.NOT_PATH:t.NOT_PATH_NOSCHEME,n).replace(t.PCT_ENCODED,c)),void 0!==e.query&&(e.query=String(e.query).replace(t.PCT_ENCODED,r).replace(t.NOT_QUERY,n).replace(t.PCT_ENCODED,c)),void 0!==e.fragment&&(e.fragment=String(e.fragment).replace(t.PCT_ENCODED,r).replace(t.NOT_FRAGMENT,n).replace(t.PCT_ENCODED,c)),e}function f(e,t){void 0===t&&(t={});var r,n,l=o&&t.iri!==!1?E:x,c=!1,f={};if("suffix"===t.reference&&(e=(t.scheme?t.scheme+":":"")+"//"+e),i?(r=e.match(l.URI_REF),r&&(r=r[1]?r.slice(1,10):r.slice(10,19)),r||(c=!0,t.tolerant||(f.error=f.error||"URI is not strictly valid."),r=e.match($))):r=e.match($),r){if(O?(f.scheme=r[1],f.userinfo=r[3],f.host=r[4],f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=r[7],f.fragment=r[8],isNaN(f.port)&&(f.port=r[5])):(f.scheme=r[1]||void 0,f.userinfo=e.indexOf("@")!==-1?r[3]:void 0,f.host=e.indexOf("//")!==-1?r[4]:void 0,f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=e.indexOf("?")!==-1?r[7]:void 0,f.fragment=e.indexOf("#")!==-1?r[8]:void 0,isNaN(f.port)&&(f.port=e.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?r[4]:void 0)),void 0!==f.scheme||void 0!==f.userinfo||void 0!==f.host||void 0!==f.port||f.path||void 0!==f.query?void 0===f.scheme?f.reference="relative":void 0===f.fragment?f.reference="absolute":f.reference="uri":f.reference="same-document",t.reference&&"suffix"!==t.reference&&t.reference!==f.reference&&(f.error=f.error||"URI is not a "+t.reference+" reference."),n=S[(t.scheme||f.scheme||"").toLowerCase()],!o||"undefined"==typeof s||t.unicodeSupport||n&&n.unicodeSupport)u(f,l);else{if(f.host&&(t.domainHost||n&&n.domainHost))try{f.host=s.toASCII(f.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(e){f.error=f.error||"Host's domain name can not be converted to ASCII via punycode: "+e}u(f,x)}n&&n.parse&&n.parse(f,t)}else c=!0,f.error=f.error||"URI can not be parsed.";return f}function d(e,t){var r=[];return void 0!==e.userinfo&&(r.push(e.userinfo),r.push("@")),void 0!==e.host&&r.push(e.host),"number"==typeof e.port&&(r.push(":"),r.push(e.port.toString(10))),r.length?r.join(""):void 0}function p(e){for(var t,r=[];e.length;)e.match(C)?e=e.replace(C,""):e.match(k)?e=e.replace(k,"/"):e.match(A)?(e=e.replace(A,"/"),r.pop()):"."===e||".."===e?e="":(t=e.match(T)[0],e=e.slice(t.length),r.push(t));return r.join("")}function m(e,t){void 0===t&&(t={});var r,n,i,l=o&&t.iri?E:x,c=[];if(r=S[(t.scheme||e.scheme||"").toLowerCase()],r&&r.serialize&&r.serialize(e,t),o&&"undefined"!=typeof s&&e.host&&(t.domainHost||r&&r.domainHost))try{e.host=t.iri?s.toUnicode(e.host):s.toASCII(e.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(r){e.error=e.error||"Host's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}return u(e,l),"suffix"!==t.reference&&e.scheme&&(c.push(e.scheme),c.push(":")),n=d(e,t),void 0!==n&&("suffix"!==t.reference&&c.push("//"),c.push(n),e.path&&"/"!==e.path.charAt(0)&&c.push("/")),void 0!==e.path&&(i=e.path,t.absolutePath||r&&r.absolutePath||(i=p(i)),void 0===n&&(i=i.replace(/^\/\//,"/%2F")),c.push(i)),void 0!==e.query&&(c.push("?"),c.push(e.query)),void 0!==e.fragment&&(c.push("#"),c.push(e.fragment)),c.join("")}function h(e,t,r,n){void 0===r&&(r={});var o={};return n||(e=f(m(e,r),r),t=f(m(t,r),r)),r=r||{},!r.tolerant&&t.scheme?(o.scheme=t.scheme,o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(t.path?("/"===t.path.charAt(0)?o.path=p(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?o.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:o.path=t.path:o.path="/"+t.path,o.path=p(o.path)),o.query=t.query):(o.path=e.path,void 0!==t.query?o.query=t.query:o.query=e.query),o.userinfo=e.userinfo,o.host=e.host,o.port=e.port),o.scheme=e.scheme),o.fragment=t.fragment,o}function v(e,t,r){return m(h(f(e,r),f(t,r),r,!0),r)}function y(e,t){return"string"==typeof e?e=m(f(e,t),t):"object"===l(e)&&(e=f(m(e,t),t)),e}function g(e,t,r){return"string"==typeof e?e=m(f(e,r),r):"object"===l(e)&&(e=m(e,r)),"string"==typeof t?t=m(f(t,r),r):"object"===l(t)&&(t=m(t,r)),e===t}function b(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.ESCAPE:x.ESCAPE,n)}function w(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.PCT_ENCODED:x.PCT_ENCODED,a)}var x=r(!1),E=o?r(!0):void 0,$=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?([^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n)*))?/i,C=/^\.\.?\//,k=/^\/\.(\/|$)/,A=/^\/\.\.(\/|$)/,T=/^\/?(?:.|\n)*?(?=\/|$)/,O=void 0==="".match(/(){0}/)[1],S={};return{IRI_SUPPORT:o,VALIDATE_SUPPORT:i,pctEncChar:n,pctDecChars:a,SCHEMES:S,parse:f,_recomposeAuthority:d,removeDotSegments:p,serialize:m,resolveComponents:h,resolve:v,normalize:y,equal:g,escapeComponent:b,unescapeComponent:w}}();if(!n&&"undefined"!=typeof t&&"function"==typeof e){var s=e("./punycode");t.exports=a,e("./schemes")}},{"./punycode":18,"./schemes":19}]},{},[1])(1)})},function(e,t,r){"use strict";function n(e,t,l,c,u,f){var d=[],p=[];t=t||[];var m=t.indexOf("*");c=c||{};var h={},v=t.indexOf("...");if("object"===("undefined"==typeof e?"undefined":s(e))&&e.hasOwnProperty("properties")){u=u||e.readonly||e.readOnly,h=r.i(i.defaultForm)(e,r.i(i.createDefaults)(),l,c);var y=h.lookup;e=y||e,d=d.concat(h.form)}return m!==-1&&(t=t.slice(0,m).concat(d).concat(t.slice(m+1))),h.form&&v!==-1&&!function(){var e=t.map(function(e){return"string"==typeof e?e:e.key?e.key:void 0}).filter(function(e){return void 0!==e});p=p.concat(h.form.map(function(t){var r=e.indexOf(t.key[0])!==-1;if(!r)return t}).filter(function(e){return void 0!==e}))}(),v!==-1&&(t=t.slice(0,v).concat(p).concat(t.slice(v+1))),t.map(function(t){if("string"==typeof t&&(t={key:t}),t.key&&"string"==typeof t.key&&(t.key=r.i(o.parse)(t.key)),t.titleMap&&(t.titleMap=r.i(a.a)(t.titleMap)),t.key){var i=r.i(o.stringify)(t.key);e[i]&&!function(){var r=e[i];r&&Object.keys(r).forEach(function(e){void 0===t[e]&&(t[e]=r[e])})}()}return u===!0&&(t.readonly=!0),t.items&&(t.items=n(e,t.items,l,c,t.readonly,f)),t.tabs&&t.tabs.forEach(function(r){r.items&&(r.items=n(e,r.items,l,c,t.readonly,f))}),"checkbox"===t.type&&void 0===t.schema.default&&(t.schema.default=!1),f&&"template"===t.type&&!t.template&&t.templateUrl&&f.push(t),t})}var o=r(0),i=r(3),a=r(1);t.a=n;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e}},function(e,t,r){"use strict";function n(e,t){var r=new Promise(function(t,r){o.resolveRefs(e,{filter:["relative","local","remote"]}).then(function(e){t(e.resolved)}).catch(function(e){r(new Error(e))})});return"function"!=typeof t?r:void r.then(function(e){t(null,e)}).catch(function(e){t(e)})}var o=r(5);r.n(o);t.a=n},function(e,t,r){"use strict";function n(e,t,r){t||(t=this);var n="string"==typeof e?o.parse(e):e;if("undefined"!=typeof r&&1===n.length)return t[n[0]]=r,t;"undefined"!=typeof r&&"undefined"==typeof t[n[0]]&&(t[n[0]]=n.length>2&&i.test(n[1])?[]:{});for(var a=t[n[0]],s=1;s<n.length;s++){if(""===n[s])return;if("undefined"!=typeof r){if(s===n.length-1)return a[n[s]]=r,r;var l=a[n[s]];"undefined"!=typeof l&&null!==l||(l=i.test(n[s+1])?[]:{},a[n[s]]=l),a=l}else a&&(a=a[n[s]])}return a}var o=r(0);t.a=n;var i=/^\d+$/},function(e,t,r){"use strict";function n(e,t,r,n){n=void 0===n||n,r=r||[];var o=function e(t,r,o){if(r(t,o),t.properties&&Object.keys(t.properties).forEach(function(n){var i=o.slice();i.push(n),e(t.properties[n],r,i)}),!n&&t.items){var i=o.slice();i.push(""),e(t.items,r,i)}};o(e,t,r||[])}function o(e,t){t(e),e.items&&e.items.forEach(function(e){o(e,t)}),e.tabs&&e.tabs.forEach(function(e){e.items&&e.items.forEach(function(e){o(e,t)})})}t.a=n,t.b=o},function(e,t,r){"use strict";function n(e,t){if(!e)return{valid:!0};var r=e.schema;if(!r)return{valid:!0};""===t&&(t=void 0),"number"===e.type&&null===t&&(t=void 0);var n={type:"object",properties:{},required:void 0},o=e.key[e.key.length-1];n.properties[o]=r,e.required&&(n.required=[o]);var a={};return t&&(a[o]=t),i.a.validateResult(a,n)}var o=r(12),i=r.n(o);t.a=n},function(e,t,r){"use strict";var n;!function(o){var i={parse:function(e){if("string"!=typeof e)throw new TypeError("ObjectPath.parse must be passed a string");for(var t,r,n,o,i=0,a=[];i<e.length;)if(t=e.indexOf(".",i),r=e.indexOf("[",i),t===-1&&r===-1)a.push(e.slice(i,e.length)),i=e.length;else if(r===-1||t!==-1&&t<r)a.push(e.slice(i,t)),i=t+1;else if(r>i&&(a.push(e.slice(i,r)),i=r),n=e.slice(r+1,r+2),'"'!==n&&"'"!==n)o=e.indexOf("]",r),o===-1&&(o=e.length),a.push(e.slice(i+1,o)),i="."===e.slice(o+1,o+2)?o+2:o+1;else{for(o=e.indexOf(n+"]",r),o===-1&&(o=e.length);"\\"===e.slice(o-1,o)&&r<e.length;)r++,o=e.indexOf(n+"]",r);a.push(e.slice(i+2,o).replace(new RegExp("\\"+n,"g"),n)),i="."===e.slice(o+2,o+3)?o+3:o+2}return a},stringify:function(e,t){return Array.isArray(e)||(e=[e.toString()]),t='"'===t?'"':"'",e.map(function(e){return"["+t+e.toString().replace(new RegExp(t,"g"),"\\"+t)+t+"]"}).join("")},normalize:function(e,t){return i.stringify(Array.isArray(e)?e:i.parse(e),t)},registerModule:function(e){e.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=i.parse,this.stringify=i.stringify,this.normalize=i.normalize,this.$get=function(){return i}})}};n=function(){return{ObjectPath:i}}.call(t,r,t,e),!(n!==o&&(e.exports=n))}()},function(e,t){e.exports=tv4},function(e,t,r){e.exports=r(4)}])}).call(t,r(2),r(19).setImmediate)},function(e,t){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(r=window)}e.exports=r},,function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(1),o=(r.n(n),r(0)),i=r.n(o),a=r(14),s=r(12),l=r(13),c=r(15),u=r(16),f=r(7),d=r(8),p=r(10),m=r(6),h=r(9),v=r(11),y=r(5),g=[];try{i.a.module("ngSanitize"),g.push("ngSanitize")}catch(e){}try{i.a.module("ui.sortable"),g.push("ui.sortable")}catch(e){}try{i.a.module("angularSpectrumColorpicker"),g.push("angularSpectrumColorpicker")}catch(e){}i.a.module("schemaForm",g).provider("sfPath",u.a).provider("sfBuilder",["sfPathProvider",a.a]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",s.a]).provider("sfErrorMessage",c.a).provider("schemaForm",["sfPathProvider",l.a]).factory("sfSelect",function(){return n.select}).factory("sfValidator",function(){return n.validate}).directive("sfChanged",f.a).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",d.a]).directive("sfMessage",["$injector","sfErrorMessage",p.a]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",m.a]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",v.a]).directive("schemaValidate",["sfValidator","$parse","sfSelect",y.a]).directive("sfKeyController",["schemaForm","sfPath",h.a])},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r){return{restrict:"A",scope:!1,priority:500,require:"ngModel",link:function(t,n,i,a){t.$emit("schemaFormPropagateNgModelController",a);var s=null,l=t.$eval(i.schemaValidate);l.copyValueTo&&a.$viewChangeListeners.push(function(){var e=l.copyValueTo;o.a.forEach(e,function(e){r(e,t.model,a.$modelValue)})});var c=function(r){if(!l)return r;if(t.options&&t.options.tv4Validation===!1)return r;var n=e(l,r);Object.keys(a.$error).filter(function(e){return 0===e.indexOf("tv4-")}).forEach(function(e){a.$setValidity(e,!0)});{if(n.valid)return r;if(a.$setValidity("tv4-"+n.error.code,!1),s=n.error,a.$validators)return r}};"function"==typeof l.ngModel&&l.ngModel(a),["$parsers","$viewChangeListeners","$formatters"].forEach(function(e){l[e]&&a[e]&&l[e].forEach(function(t){a[e].push(t)})}),["$validators","$asyncValidators"].forEach(function(e){l[e]&&a[e]&&o.a.forEach(l[e],function(t,r){a[e][r]=t})}),a.$parsers.push(c),a.$validators&&(a.$validators.schemaForm=function(){return!Object.keys(a.$error).some(function(e){return"schemaForm"!==e})});var u=l.schema;t.validateField=function(e){var t=void 0===e;(t||a.$$parentForm.$name===e)&&((t||u&&u.type.indexOf("array")!==-1)&&c(a.$modelValue),a.$setDirty?(a.$setDirty(),a.$setViewValue(a.$viewValue),a.$commitViewValue(),"checkbox"===l.type?l.required&&void 0===a.$modelValue&&a.$setValidity("tv4-302",!1):l.required&&a.$isEmpty(a.$modelValue)&&a.$setValidity("tv4-302",!1)):a.$setViewValue(a.$viewValue))};var f=!0;a.$formatters.push(function(e){return!a.$pristine||!f||t.options&&t.options.validateOnRender===!0?(c(a.$modelValue),e):(f=!1,e)}),t.$on("schemaFormValidate",function(e,r){t.validateField(r)}),t.schemaError=function(){return s}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r){return{scope:!0,controller:["$scope",function(e){this.key=e.form&&e.form.key?e.form.key.splice(0,-2):[]}],link:function(n,i,a){n.min=0,n.modelArray=n.$eval(a.sfNewArray);var s=function(){n.modelArray=n.$eval(a.sfNewArray),n.ngModel&&n.ngModel.$pristine&&n.firstDigest&&(!n.options||n.options.validateOnRender!==!0)||n.validateField&&n.validateField()},l=function(){n.form&&n.form.onChange&&(o.a.isFunction(n.form.onChange)?n.form.onChange(n.modelArray,n.form):n.evalExpr(n.form.onChange,{modelValue:n.modelArray,form:n.form}))},c=function(){var r=n.modelArray;if(!r){var o=t.parse(a.sfNewArray);r=[],e(o,n,r),n.modelArray=r}return r},u=n.$watch("form",function(e){if(e){if(e.titleMap||e.startEmpty===!0||n.modelArray&&0!==n.modelArray.length||n.appendToArray(),n.form&&n.form.schema&&n.form.schema.uniqueItems===!0?(n.$watch(a.sfNewArray,s,!0),n.$watch([a.sfNewArray,a.sfNewArray+".length"],l)):n.$watchGroup?n.$watchGroup([a.sfNewArray,a.sfNewArray+".length"],function(){s(),l()}):(n.$watch(a.sfNewArray,function(){s(),l()}),n.$watch(a.sfNewArray+".length",function(){s(),l()})),e.titleMap&&e.titleMap.length>0){n.titleMapValues=[];var t=function(t){n.titleMapValues=[],t=t||[],e.titleMap.forEach(function(e){n.titleMapValues.push(t.indexOf(e.value)!==-1)})};t(n.modelArray),n.$watchCollection("modelArray",t),n.$watchCollection("titleMapValues",function(t,r){if(t&&t!==r){var o=c();e.titleMap.forEach(function(e,r){var n=o.indexOf(e.value);n===-1&&t[r]&&o.push(e.value),n===-1||t[r]||o.splice(n,1)}),n.validateField&&n.validateField()}})}u()}});n.appendToArray=function(){var t,i=c();if(n.form&&n.form.schema&&n.form.schema.items){var a=n.form.schema.items;a.type&&a.type.indexOf("object")!==-1?(t={},n.options&&n.options.setSchemaDefaults===!1||(t=o.a.isDefined(a.default)?a.default:t,t&&r.traverseSchema(a,function(r,n){o.a.isDefined(r.default)&&e(n,t,r.default)}))):a.type&&a.type.indexOf("array")!==-1?(t=[],n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t)):n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t)}return i.push(t),i},n.deleteFromArray=function(e){var t=n.modelArray;return t&&t.splice(e,1),t};var f=function(e){return function(t){t.key&&(t.key[t.key.indexOf("")]=e)}},d={};n.copyWithIndex=function(e){var t=n.form;if(!d[e]){var i=t.items[0];if(t.items.length>1&&(i={type:"section",items:t.items.map(function(e){return e.ngModelOptions=t.ngModelOptions,o.a.isUndefined(e.readonly)&&(e.readonly=t.readonly),e})}),i){var a=o.a.copy(i);a.arrayIndex=e,r.traverseForm(a,f(e)),d[e]=a}}return d[e]}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){return{require:"ngModel",restrict:"AC",scope:!1,link:function(e,t,r,n){var i=e.$eval(r.sfChanged);i&&i.onChange&&n.$viewChangeListeners.push(function(){o.a.isFunction(i.onChange)?i.onChange(n.$modelValue,i):e.evalExpr(i.onChange,{modelValue:n.$modelValue,form:i,arrayIndex:e.$index,arrayIndices:e.arrayIndices,path:e.path,$i:e.$i,$index:e.$index})})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r,n,a,s,l,c,u){var f={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function(e,t,r,n){var o=n[0];n[1],n[2];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.initialForm=Object.assign({},o.lookup["f"+r.sfField]),e.form=o.lookup["f"+r.sfField]},post:function(e,t,r,n){var s=n[0],d=n[1];n[2];e.getKey=function(t){var r=t||f.COMPLETE,n=e.parentKey?e.parentKey.slice(0,e.parentKey.length-1):[];if(e.completeKey!==e.form.key&&("number"==typeof e.$index&&(n=n.concat(e.$index)),e.form.key&&e.form.key.length))if("number"==typeof n[n.length-1]&&e.form.key.length>=1){var o=e.form.key.length-n.length;e.completeKey=n.concat(e.form.key.slice(-o))}else e.completeKey=e.form.key.slice();if(Array.isArray(e.completeKey))return r===f.COMPLETE?e.completeKey:e.completeKey.reduce(function(e,t,n){return-1!==[r].indexOf("undefined"==typeof t?"undefined":i(t))?e.concat(t):e},[])},e.form.key&&(e.form.key=e.completeKey=e.getKey()),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=r||!1,o=t&&d&&d.$name?d.$name:void 0,i=e.completeKey;return Array.isArray(i)?c.name(i,"-",o,n):""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(s?s.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return s?s.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&a(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.errors===!1?e.ngModel.$invalid&&!e.ngModel.$pristine:e.ngModel.$invalid)},e.errorMessage=function(t){return l.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)},e.form.htmlClass=e.form.htmlClass||"",e.idClass=e.fieldId(!1)+" "+e.fieldId(!1,!0);var p=e.form;p.key&&(e.$on("schemaForm.error."+p.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(p.validationMessage||(p.validationMessage={}),p.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){var t=e.getKey();if(!e.externalDestructionInProgress){var r=p.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(t&&"retain"!==r){var n=e.model;if(t.length>1&&(n=u(t.slice(0,t.length-1),n)),void 0===n)return;var o=p.schema&&p.schema.type||"";"empty"===r&&o.indexOf("string")!==-1?n[t.slice(-1)]="":"empty"===r&&o.indexOf("object")!==-1?n[t.slice(-1)]={}:"empty"===r&&o.indexOf("array")!==-1?n[t.slice(-1)]=[]:"null"===r?n[t.slice(-1)]=null:delete n[t.slice(-1)]}}}))}}}}},function(e,t,r){"use strict";t.a=function(e,t){return{scope:!0,require:["?^^sfNewArray"],link:{pre:function(e,r,n,o){e.parentKey=e.parentKey||[];var i=t.parse(n.sfParentKey),a=i.length-e.parentKey.length;i.length>1&&(i=i.splice(-a)),e.parentKey=e.parentKey.concat(i,Number(n.sfIndex)),e.arrayIndex=Number(n.sfIndex),e.arrayIndices=e.arrayIndices||[],e.arrayIndices=e.arrayIndices.concat(e.arrayIndex),e.$i=e.arrayIndices,e.path=function(t){var r=-1;return t=t.replace(/\[\]/gi,function(t){return r++,"["+e.$i[r]+"]"}),e.evalExpr(t,e)}}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r=e.has("$sanitize")?e.get("$sanitize"):function(e){return e};return{scope:!1,restrict:"EA",link:function(e,n,i){var a="";i.sfMessage&&e.$watch(i.sfMessage,function(t){t&&(a=r(t),c(!!e.ngModel))});var s,l=function(e){e!==s&&(n.html(e),s=e)},c=function(r){if(r)if(e.hasError()){var n=[];o.a.forEach(e.ngModel&&e.ngModel.$error,function(e,t){e&&n.push(t)}),n=n.filter(function(e){return"schemaForm"!==e});var i=n[0];l(i?t.interpolate(i,e.ngModel.$modelValue,e.ngModel.$viewValue,e.form,e.options&&e.options.validationMessage):a)}else l(a);else l(a)};c();var u=e.$watch("ngModel",function(e){e&&(e.$parsers.push(function(e){return c(!0),e}),e.$formatters.push(function(e){return c(!0),e}),u())});e.$watchCollection("ngModel.$error",function(){c(!!e.ngModel)})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r,n,i,a,s,l,c){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function(e){this.evalInParentScope=function(t,r){return e.$parent.$eval(t,r)};var t=this;e.lookup=function(e){return e&&(t.lookup=e),t.lookup}}],replace:!1,restrict:"A",transclude:!0,require:"?form",link:function(l,u,f,d,p){l.formCtrl=d;var m={};p(l,function(e){if(e.addClass("schema-form-ignore"),u.prepend(e),u[0].querySelectorAll){var t=u[0].querySelectorAll("[ng-model]");if(t)for(var r=0;r<t.length;r++){var n=t[r].getAttribute("ng-model");m[n.substring(n.indexOf(".")+1)]=!0}}});var h,v={};l.resolveReferences=function(e,t){i.jsonref(e).then(function(e){l.render(e,t)}).catch(function(e){new Error(e)})},l.render=function(e,o){var a=[],s=i.merge(e,o,m,l.options,void 0,a);a.length>0?n.all(a.map(function(e){return t.get(e.templateUrl,{cache:r}).then(function(t){e.template=t.data})})).then(function(){l.internalRender(e,o,s)}):l.internalRender(e,o,s)},l.internalRender=function(t,r,n){h&&(l.externalDestructionInProgress=!0,h.$destroy(),l.externalDestructionInProgress=!1),h=l.$new(),h.schemaForm={form:n,schema:t},Array.prototype.forEach.call(u.children(),function(e){var t=o.a.element(e);!1===t.hasClass("schema-form-ignore")&&t.remove()});for(var d={},p=u[0].querySelectorAll("*[sf-insert-field]"),m=0;m<p.length;m++)d[p[m].getAttribute("sf-insert-field")]=p[m];var v=a.decorator(f.sfUseDecorator),y=Object.create(null);l.lookup(y),u[0].appendChild(c.build(n,v,d,y)),h.firstDigest=!0,setTimeout(function(){h.firstDigest=!1},0),e(u.children())(h),l.options&&l.options.setSchemaDefaults===!1||i.traverseSchema(t,function(e,t){if(o.a.isDefined(e.default)){var r=s(t,l.model);o.a.isUndefined(r)&&s(t,l.model,e.default)}}),l.$emit("sf-render-finished",u)};var y=["*"];l.$watch(function(){var e=l.schema,t=l.initialForm||y;t&&e&&e.type&&(v.form!==t||v.schema!==e)&&Object.keys(e.properties).length>0&&(v.schema=e,v.form=t,l.resolveReferences(e,t))}),l.$on("schemaFormRedraw",function(){var e=l.schema,t=l.initialForm?o.a.copy(l.initialForm):["*"];e&&l.resolveReferences(e,t)}),l.$on("$destroy",function(){l.externalDestructionInProgress=!0}),l.evalExpr=function(e,t){return l.$parent.$eval(e,t)}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r="",n={},i=function(e,t){"sfDecorator"===e&&(e=r);var o=n[e];return o[t.type]?o[t.type].template:o.default.template},a=function(r){e.directive(r,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function(e,n,a,s,l,c,u,f,d){return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["?^sfSchema","?^form"],link:function(e,p,m,h){var v=h[0],y=h[1];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=e.parentKey||[];if(e.form.key){if("number"==typeof n[n.length-1]){var o=n.concat(e.form.key.slice(-1)),i=t&&y&&y.$name?y.$name:void 0;return f.name(o,"-",i,r)}var i=t&&y&&y.$name?y.$name:void 0;return f.name(e.form.key,"-",i,r)}return""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(v?v.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return v?v.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&l(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.ngModel.$invalid&&!e.ngModel.$pristine)},e.errorMessage=function(t){return u.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)};var g=e.$watch(m.form,function(l){if(l){l.ngModelOptions=l.ngModelOptions||{},e.form=l;var u;if("template"===l.type&&l.template)u=c.when(l.template);else{var m="template"===l.type?l.templateUrl:i(r,l);u=a.get(m,{cache:s}).then(function(e){return e.data})}u.then(function(r){if(l.key){var i=l.key?t.stringify(l.key).replace(/"/g,"&quot;"):"";r=r.replace(/\$\$value\$\$/g,"model"+("["!==i[0]?".":"")+i)}if(p.html(r),l.condition){var a='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';l.key&&(a='evalExpr(form.condition, {model: model, "arrayIndex": arrayIndex, "modelValue": model'+f.stringify(l.key)+"})"),o.a.forEach(p.children(),function(e){var t=e.getAttribute("ng-if");e.setAttribute("ng-if",t?"("+t+") || ("+a+")":a)})}n(p.contents())(e)}),l.key&&(e.$on("schemaForm.error."+l.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(l.validationMessage||(l.validationMessage={}),l.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){if(!e.externalDestructionInProgress){var t=l.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(l.key&&"retain"!==t){var r=e.model;if(l.key.length>1&&(r=d(l.key.slice(0,l.key.length-1),r)),void 0===r)return;var n=l.schema&&l.schema.type||"";"empty"===t&&n.indexOf("string")!==-1?r[l.key.slice(-1)]="":"empty"===t&&n.indexOf("object")!==-1?r[l.key.slice(-1)]={}:"empty"===t&&n.indexOf("array")!==-1?r[l.key.slice(-1)]=[]:"null"===t?r[l.key.slice(-1)]=null:delete r[l.key.slice(-1)]}}})),g()}})}}}])},s=function(t,r,n){n=!!o.a.isDefined(n)&&n,e.directive("sf"+o.a.uppercase(t[0])+t.substr(1),function(){return{restrict:"EAC",scope:!0,replace:!0,transclude:n,template:'<sf-decorator form="form"></sf-decorator>',link:function(e,r,n){var i={items:"c",titleMap:"c",schema:"c"},a={type:t},s=!0;o.a.forEach(n,function(t,r){if("$"!==r[0]&&0!==r.indexOf("ng")&&"sfField"!==r){var l=function(t){o.a.isDefined(t)&&t!==a[r]&&(a[r]=t,s&&a.type&&(a.key||o.a.isUndefined(n.key))&&(e.form=a,s=!1))};"model"===r?e.$watch(t,function(t){t&&e.model!==t&&(e.model=t)}):"c"===i[r]?e.$watchCollection(t,l):n.$observe(r,l)}})}}})};this.createDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){n[e][r]={template:t,replace:!1,builder:[]}}),n[r]||(r=e),a(e)},this.defineDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){t.builder=t.builder||[],t.replace=!o.a.isDefined(t.replace)||t.replace,n[e][r]=t;
+}),n[r]||(r=e),a(e)},this.createDirective=s,this.createDirectives=function(e){o.a.forEach(e,function(e,t){s(t,e)})},this.decorator=function(e){return e=e||r,n[e]},this.addMapping=function(e,t,r,o,i){n[e]&&(n[e][t]={template:r,builder:o,replace:!!i})},this.defineAddOn=function(e,t,r,o){n[e]&&(n[e][t]={template:r,builder:o,replace:!0})},this.$get=function(){return{decorator:function(e){return n[e]||n[r]},defaultDecorator:r}},a("sfDecorator")}},function(e,t,r){"use strict";var n=r(0),o=(r.n(n),r(1));r.n(o);t.a=function(){var e=function(e){return e},t=o.schemaDefaults.createDefaults();this.defaults=t,this.stdFormObj=o.schemaDefaults.stdFormObj,this.defaultFormDefinition=o.schemaDefaults.defaultFormDefinition,this.postProcess=function(t){e=t},this.appendRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].push(t)},this.prependRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].unshift(t)},this.createStandardForm=o.schemaDefaults.stdFormObj,this.$get=function(){var t={},n=this.defaults;return t.jsonref=o.jsonref,t.merge=function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["*"],i=arguments[2],a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},s=arguments.length>4&&void 0!==arguments[4]&&arguments[4],l=arguments[5],c=r.i(o.merge)(t,n,i,a,s,l);return e(c)},t.defaults=function(e,t,r,i){var a=t||n;return o.schemaDefaults.defaultForm(e,a,r,i)},t.typeDefault=n,t.traverseSchema=o.traverseSchema,t.traverseForm=o.traverseForm,t}}},function(e,t,r){"use strict";t.a=function(e){var t=/[A-Z]/g,r=function(e,r){return r=r||"_",e.replace(t,function(e,t){return(t?r:"")+e.toLowerCase()})},n=0;"firstElementChild"in document.createDocumentFragment()||Object.defineProperty(DocumentFragment.prototype,"firstElementChild",{get:function(){for(var e,t=this.childNodes,r=0,n=t.length;r<n;++r)if(e=t[r],1===e.nodeType)return e;return null}});var o={sfField:function(e){e.fieldFrag.firstElementChild.setAttribute("sf-field",n),e.lookup["f"+n]=e.form,n++},ngModel:function(t){if(t.form.key){var r=t.form.key;t.state.keyRedaction&&(r=r.slice(t.state.keyRedaction));var n;if(t.state.modelValue)n=t.state.modelValue;else{var o=e.stringify(r).replace(/"/g,"&quot;");n=t.state.modelName||"model",o&&(n+=("["!==o[0]?".":"")+o)}for(var i=t.fieldFrag.querySelectorAll("[sf-field-model]"),a=0;a<i.length;a++){var s=i[a],l=s.getAttribute("sf-field-model");if(l&&""!==l)if("replaceAll"===l)for(var c=s.attributes,u=0;u<c.length;u++)c[u].value&&c[u].value.indexOf("$$value")!==-1&&(c[u].value=c[u].value.replace(/\$\$value\$\$/g,n));else{var f=s.getAttribute(l);f&&f.indexOf("$$value$$")?s.setAttribute(l,f.replace(/\$\$value\$\$/g,n)):s.setAttribute(l,n)}else s.setAttribute("ng-model",n)}}},simpleTransclusion:function(e){var t=e.build(e.form.items,e.path+".items",e.state);e.fieldFrag.firstChild.appendChild(t)},ngModelOptions:function(e){e.form.ngModelOptions&&Object.keys(e.form.ngModelOptions).length>0&&e.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(e.form.ngModelOptions))},transclusion:function(e){var t=e.fieldFrag.querySelectorAll("[sf-field-transclude]");if(t.length)for(var r=0;r<t.length;r++){var n=t[r],o=n.getAttribute("sf-field-transclude")||"items",i=e.form[o];if(i){var a=e.build(i,e.path+"."+o,e.state);n.appendChild(a)}}},condition:function(t){var r="",n="undefined",o="";if(t.form.condition){t.form.key&&(r=e.stringify(t.form.key),n="model"+("["===r[0]?"":".")+r);for(var i="evalExpr("+t.path+'.condition, { model: model, "arrayIndex": $index, "arrayIndices": arrayIndices, "path": path, "$i": $i, "$index": $index, "modelValue": '+n+"})",a=t.fieldFrag.children||t.fieldFrag.childNodes,s=0;s<a.length;s++){var l=a[s];l.hasAttribute&&l.hasAttribute("ng-if")&&(o=l.getAttribute("ng-if")),l.setAttribute&&l.setAttribute("ng-if",o?"("+o+") || ("+i+")":i)}}},array:function(t){var r=t.fieldFrag.querySelector("[schema-form-array-items]");if(t.form.key){t.form.key.filter(function(e){return""===e}).length}if(r){var n=angular.copy(t.state);if(n.keyRedaction=0,n.keyRedaction+=t.form.key.length+1,t.form.schema&&t.form.schema.items&&t.form.schema.items.type&&t.form.schema.items.type.indexOf("object")===-1&&t.form.schema.items.type.indexOf("array")===-1){e.stringify(t.form.key).replace(/"/g,"&quot;")+"[$index]";n.modelValue="modelArray[$index]"}else n.modelName="item";n.arrayCompatFlag=!0;var o=t.build(t.form.items,t.path+".items",n);r.appendChild(o)}},numeric:function(e){var t=e.fieldFrag.querySelector("input"),r=e.form.maximum||!1,n=e.form.exclusiveMaximum||!1,o=e.form.minimum||!1,i=e.form.exclusiveMinimum||!1,a=e.form.multipleOf||!1;t&&(a!==!1&&t.setAttribute("step",a),r!==!1&&(n!==!1&&a!==!1&&(r-=a),t.setAttribute("max",r)),o!==!1&&(i!==!1&&a!==!1&&(o+=a),t.setAttribute("min",o)))}};this.builders=o;var i=[o.sfField,o.ngModel,o.ngModelOptions,o.condition];this.stdBuilders=i,this.$get=["$templateCache","schemaFormDecorators","sfPath",function(e,t,n){var a=function(e,t){if(e.key){var r=t[n.stringify(e.key)];if(r){for(;r.firstChild;)r.removeChild(r.firstChild);return r}}},s=function e(t,n,o,i,s,l,c){l=l||{},l=l||{},c=c||Object.create(null),s=s||"schemaForm.form";var u=document.createDocumentFragment();return t.reduce(function(t,u,f){if(!u.type)return t;var d=n[u.type]||n.default;if(d.replace){var p;l.arrayCompatFlag=!1;var m=document.createElement("div"),h=o(u,d)||o(u,n.default);for(m.innerHTML=h,p=document.createDocumentFragment();m.childNodes.length>0;)p.appendChild(m.childNodes[0]);var v={fieldFrag:p,form:u,lookup:c,state:l,path:s+"["+f+"]",build:function(t,r,a){return e(t,n,o,i,r,a,c)}},y=u.builder||d.builder;"function"==typeof y?y(v):y.forEach(function(e){e(v)}),(a(u,i)||t).appendChild(p)}else{var g=document.createElement(r(n.__name,"-"));l.arrayCompatFlag?g.setAttribute("form","copyWithIndex($index)"):g.setAttribute("form",s+"["+f+"]"),(a(u,i)||t).appendChild(g)}return t},u),u};return{build:function(t,r,n,o){return s(t,r,function(t,r){return"template"===t.type?t.template:e.get(r.template)},n,void 0,void 0,o)},builder:o,stdBuilders:i,internalBuild:s}}]}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){var e={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};e.number=e[105],e.required=e[302],e.min=e[101],e.max=e[103],e.maxlength=e[201],e.minlength=e[200],e.pattern=e[202],this.setDefaultMessages=function(t){e=t},this.getDefaultMessages=function(){return e},this.setDefaultMessage=function(t,r){e[t]=r},this.$get=["$interpolate",function(t){var r={};return r.defaultMessages=e,r.interpolate=function(r,n,i,a,s){s=s||{};var l=a.validationMessage||{};0===r.indexOf("tv4-")&&(r=r.substring(4));var c=l.default||s.default||"";[l,s,e].some(function(e){return o.a.isString(e)||o.a.isFunction(e)?(c=e,!0):e&&e[r]?(c=e[r],!0):void 0});var u={error:r,value:n,viewValue:i,form:a,schema:a.schema,title:a.title||a.schema&&a.schema.title};return o.a.isFunction(c)?c(u):t(c)(u)},r}]}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=r(1),i=(r.n(o),r(0)),a=(r.n(i),function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}()),s=function(){function e(){n(this,e),this.name=o.sfPath.name,this.parse=o.sfPath.parse,this.stringify=o.sfPath.stringify,this.normalize=o.sfPath.normalize}return a(e,[{key:"$get",value:function(){return o.sfPath}}]),e}();t.a=s},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):v=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++v<t;)p&&p[v].run();v=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,v=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},function(e,t,r){(function(e,t){!function(e,r){"use strict";function n(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var n={callback:e,args:t};return h[m]=n,p(m),m++}function o(e){delete h[e]}function i(e){var t=e.callback,n=e.args;switch(n.length){case 0:t();break;case 1:t(n[0]);break;case 2:t(n[0],n[1]);break;case 3:t(n[0],n[1],n[2]);break;default:t.apply(r,n)}}function a(e){if(v)setTimeout(a,0,e);else{var t=h[e];if(t){v=!0;try{i(t)}finally{o(e),v=!1}}}}function s(){p=function(e){t.nextTick(function(){a(e)})}}function l(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}function c(){var t="setImmediate$"+Math.random()+"$",r=function(r){r.source===e&&"string"==typeof r.data&&0===r.data.indexOf(t)&&a(+r.data.slice(t.length))};e.addEventListener?e.addEventListener("message",r,!1):e.attachEvent("onmessage",r),p=function(r){e.postMessage(t+r,"*")}}function u(){var e=new MessageChannel;e.port1.onmessage=function(e){var t=e.data;a(t)},p=function(t){e.port2.postMessage(t)}}function f(){var e=y.documentElement;p=function(t){var r=y.createElement("script");r.onreadystatechange=function(){a(t),r.onreadystatechange=null,e.removeChild(r),r=null},e.appendChild(r)}}function d(){p=function(e){setTimeout(a,0,e)}}if(!e.setImmediate){var p,m=1,h={},v=!1,y=e.document,g=Object.getPrototypeOf&&Object.getPrototypeOf(e);g=g&&g.setTimeout?g:e,"[object process]"==={}.toString.call(e.process)?s():l()?c():e.MessageChannel?u():y&&"onreadystatechange"in y.createElement("script")?f():d(),g.setImmediate=n,g.clearImmediate=o}}("undefined"==typeof self?"undefined"==typeof e?this:e:self)}).call(t,r(2),r(17))},function(r,n,o){function i(e,t){this._id=e,this._clearFn=t}var a=Function.prototype.apply;n.setTimeout=function(){return new i(a.call(setTimeout,window,arguments),clearTimeout)},n.setInterval=function(){return new i(a.call(setInterval,window,arguments),clearInterval)},n.clearTimeout=n.clearInterval=function(e){e&&e.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(window,this._id)},n.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},n.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},n._unrefActive=n.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},o(18),n.setImmediate=e,n.clearImmediate=t},,function(e,t,r){r(1),e.exports=r(4)}])}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):v=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++v<t;)p&&p[v].run();v=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,v=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},,,function(e,t,r){r(19),e.exports=r(0)}]);
\ No newline at end of file
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index e174e31..1e4c0dc 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.1
- * @date Sun, 29 Jan 2017 00:45:28 GMT
+ * @date Tue, 21 Feb 2017 11:44:44 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -69,18 +69,19 @@
 /******/ 	__webpack_require__.p = "";
 
 /******/ 	// Load entry module and return exports
-/******/ 	return __webpack_require__(__webpack_require__.s = 19);
+/******/ 	return __webpack_require__(__webpack_require__.s = 21);
 /******/ })
 /************************************************************************/
 /******/ ([
 /* 0 */
 /***/ function(module, exports, __webpack_require__) {
 
-__webpack_require__(17);
+__webpack_require__(18);
 
 
 /***/ },
-/* 1 */
+/* 1 */,
+/* 2 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/actions.html';
@@ -89,7 +90,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 2 */
+/* 3 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/array.html';
@@ -98,7 +99,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 3 */
+/* 4 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/checkbox.html';
@@ -107,7 +108,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 4 */
+/* 5 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/checkboxes.html';
@@ -116,7 +117,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 5 */
+/* 6 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/default.html';
@@ -125,7 +126,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 6 */
+/* 7 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/fieldset.html';
@@ -134,7 +135,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 7 */
+/* 8 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/help.html';
@@ -143,7 +144,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 8 */
+/* 9 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/radio-buttons.html';
@@ -152,7 +153,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 9 */
+/* 10 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/radios-inline.html';
@@ -161,7 +162,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 10 */
+/* 11 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/radios.html';
@@ -170,7 +171,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 11 */
+/* 12 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/section.html';
@@ -179,7 +180,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 12 */
+/* 13 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/select.html';
@@ -188,7 +189,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 13 */
+/* 14 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/submit.html';
@@ -197,7 +198,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 14 */
+/* 15 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/tabarray.html';
@@ -206,7 +207,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 15 */
+/* 16 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/tabs.html';
@@ -215,7 +216,7 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 16 */
+/* 17 */
 /***/ function(module, exports) {
 
 var path = '/bootstrap/textarea.html';
@@ -224,41 +225,41 @@ window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, htm
 module.exports = path;
 
 /***/ },
-/* 17 */
+/* 18 */
 /***/ function(module, exports, __webpack_require__) {
 
 "use strict";
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html__ = __webpack_require__(1);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html__ = __webpack_require__(2);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html__ = __webpack_require__(2);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html__ = __webpack_require__(3);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html__ = __webpack_require__(3);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html__ = __webpack_require__(4);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html__ = __webpack_require__(4);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html__ = __webpack_require__(5);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html__ = __webpack_require__(5);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html__ = __webpack_require__(6);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html__ = __webpack_require__(6);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html__ = __webpack_require__(7);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html__ = __webpack_require__(7);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html__ = __webpack_require__(8);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html__ = __webpack_require__(8);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html__ = __webpack_require__(9);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html__ = __webpack_require__(10);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html__ = __webpack_require__(11);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html__ = __webpack_require__(9);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html__ = __webpack_require__(10);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html__ = __webpack_require__(11);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html__ = __webpack_require__(12);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html__ = __webpack_require__(12);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html__ = __webpack_require__(13);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html__ = __webpack_require__(13);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html__ = __webpack_require__(14);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html__ = __webpack_require__(14);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html__ = __webpack_require__(15);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html__ = __webpack_require__(15);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html__ = __webpack_require__(16);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html__ = __webpack_require__(16);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html__ = __webpack_require__(17);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html__);
 // ngtemplate-loader embeds the html on build
 
@@ -376,8 +377,9 @@ function bootstrapDecoratorConfig(
 
 
 /***/ },
-/* 18 */,
-/* 19 */
+/* 19 */,
+/* 20 */,
+/* 21 */
 /***/ function(module, exports, __webpack_require__) {
 
 module.exports = __webpack_require__(0);
diff --git a/dist/angular-schema-form-bootstrap.min.js b/dist/angular-schema-form-bootstrap.min.js
index 4a05f9a..8be19e0 100644
--- a/dist/angular-schema-form-bootstrap.min.js
+++ b/dist/angular-schema-form-bootstrap.min.js
@@ -1,9 +1,9 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.1
- * @date Sat, 14 Jan 2017 17:11:45 GMT
+ * @date Tue, 21 Feb 2017 11:44:44 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function r(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return e[a].call(l.exports,l,l.exports,r),l.l=!0,l.exports}var n={};return r.m=e,r.c=n,r.i=function(e){return e},r.d=function(e,r,n){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=22)}([function(e,r,n){n(17)},function(e,r){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r,n){"use strict";function a(e,r,n,a,l){var t=n.builders.simpleTransclusion,o=n.builders.ngModelOptions,d=n.builders.ngModel,f=n.builders.sfField,u=n.builders.condition,b=n.builders.array,g=n.builders.numeric,y=function(e){if(e.form.tabs&&e.form.tabs.length>0){var r=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(n,a){var l="(evalExpr("+e.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=e.build(n.items,e.path+".tabs["+a+"].items",e.state);t.appendChild(s),r.appendChild(t)})}},$=function(e){if(e.form.placeholder){var r=e.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=e.form.placeholder,r.appendChild(n)}},w=[f,d,o,u];r.defineDecorator("bootstrapDecorator",{actions:{template:s.a,builder:w},array:{template:i.a,builder:[f,o,d,b,u]},button:{template:T.a,builder:w},checkbox:{template:m.a,builder:w},checkboxes:{template:c.a,builder:[f,o,d,b,u]},conditional:{template:S.a,builder:[f,t,u]},default:{template:p.a,builder:w},fieldset:{template:h.a,builder:[f,t,u]},help:{template:v.a,builder:w},number:{template:p.a,builder:w.concat(g)},password:{template:p.a,builder:w},radios:{template:C.a,builder:w},"radios-inline":{template:k.a,builder:w},radiobuttons:{template:x.a,builder:w},section:{template:S.a,builder:[f,t,u]},select:{template:I.a,builder:w.concat($)},submit:{template:T.a,builder:w},tabarray:{template:j.a,builder:[f,o,d,b,u]},tabs:{template:R.a,builder:[f,o,y,u]},textarea:{template:F.a,builder:w}},[])}function l(){return function(e){if(!e)return"";var r,n,a;for(a=e.slice(),n=0;n<a.length;n++)r=a[n].toLowerCase().split(""),n&&r.length&&(r[0]=r[0].toUpperCase()),a[n]=r.join("");return a.join("")}}var t=n(1),s=n.n(t),o=n(2),i=n.n(o),d=n(3),m=n.n(d),f=n(4),c=n.n(f),u=n(5),p=n.n(u),b=n(6),h=n.n(b),g=n(7),v=n.n(g),y=n(8),x=n.n(y),$=n(10),C=n.n($),w=n(9),k=n.n(w),A=n(11),S=n.n(A),E=n(12),I=n.n(E),H=n(13),T=n.n(H),M=n(14),j=n.n(M),L=n(15),R=n.n(L),D=n(16),F=n.n(D);angular.module("schemaForm").config(a).filter("sfCamelKey",l),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,function(e,r,n){e.exports=n(0)}]);
\ No newline at end of file
+!function(e){function r(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return e[a].call(l.exports,l,l.exports,r),l.l=!0,l.exports}var n={};return r.m=e,r.c=n,r.i=function(e){return e},r.d=function(e,r,n){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=24)}([function(e,r,n){n(18)},,function(e,r){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r,n){"use strict";function a(e,r,n,a,l){var s=n.builders.simpleTransclusion,i=n.builders.ngModelOptions,m=n.builders.ngModel,c=n.builders.sfField,p=n.builders.condition,h=n.builders.array,v=n.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var r=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(n,a){var l="(evalExpr("+e.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=e.build(n.items,e.path+".tabs["+a+"].items",e.state);t.appendChild(s),r.appendChild(t)})}},C=function(e){if(e.form.placeholder){var r=e.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=e.form.placeholder,r.appendChild(n)}},k=[c,m,i,p];r.defineDecorator("bootstrapDecorator",{actions:{template:t.a,builder:k},array:{template:o.a,builder:[c,i,m,h,p]},button:{template:H.a,builder:k},checkbox:{template:d.a,builder:k},checkboxes:{template:f.a,builder:[c,i,m,h,p]},conditional:{template:A.a,builder:[c,s,p]},default:{template:u.a,builder:k},fieldset:{template:b.a,builder:[c,s,p]},help:{template:g.a,builder:k},number:{template:u.a,builder:k.concat(v)},password:{template:u.a,builder:k},radios:{template:$.a,builder:k},"radios-inline":{template:w.a,builder:k},radiobuttons:{template:y.a,builder:k},section:{template:A.a,builder:[c,s,p]},select:{template:E.a,builder:k.concat(C)},submit:{template:H.a,builder:k},tabarray:{template:M.a,builder:[c,i,m,h,p]},tabs:{template:L.a,builder:[c,i,x,p]},textarea:{template:D.a,builder:k}},[])}var l=n(2),t=n.n(l),s=n(3),o=n.n(s),i=n(4),d=n.n(i),m=n(5),f=n.n(m),c=n(6),u=n.n(c),p=n(7),b=n.n(p),h=n(8),g=n.n(h),v=n(9),y=n.n(v),x=n(11),$=n.n(x),C=n(10),w=n.n(C),k=n(12),A=n.n(k),S=n(13),E=n.n(S),I=n(14),H=n.n(I),T=n(15),M=n.n(T),R=n(16),L=n.n(R),j=n(17),D=n.n(j);angular.module("schemaForm").config(a),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,,function(e,r,n){e.exports=n(0)}]);
\ No newline at end of file

From 92993bea2150d437df47e863a6469ba32ec1f147 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Thu, 30 Mar 2017 21:53:17 +1100
Subject: [PATCH 40/50] Updates for dist

---
 dist/angular-schema-form-bootstrap-bundled.js | 210 ++++++++++--------
 ...gular-schema-form-bootstrap-bundled.min.js |  20 +-
 dist/angular-schema-form-bootstrap.js         |   2 +-
 dist/angular-schema-form-bootstrap.min.js     |   2 +-
 4 files changed, 127 insertions(+), 107 deletions(-)

diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index dc57104..915e4fd 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.1
- * @date Tue, 21 Feb 2017 11:44:44 GMT
+ * @date Thu, 30 Mar 2017 10:51:56 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -463,8 +463,8 @@ function bootstrapDecoratorConfig(
 
 /* WEBPACK VAR INJECTION */(function(setImmediate, clearImmediate) {/*!
  * angular-schema-form
- * @version 1.0.0-alpha.2
- * @date Sun, 19 Feb 2017 13:13:18 GMT
+ * @version 1.0.0-alpha.3
+ * @date Thu, 30 Mar 2017 07:57:38 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -472,41 +472,41 @@ function bootstrapDecoratorConfig(
 /******/ (function(modules) { // webpackBootstrap
 /******/ 	// The module cache
 /******/ 	var installedModules = {};
-
+/******/
 /******/ 	// The require function
 /******/ 	function __webpack_require__(moduleId) {
-
+/******/
 /******/ 		// Check if module is in cache
 /******/ 		if(installedModules[moduleId])
 /******/ 			return installedModules[moduleId].exports;
-
+/******/
 /******/ 		// Create a new module (and put it into the cache)
 /******/ 		var module = installedModules[moduleId] = {
 /******/ 			i: moduleId,
 /******/ 			l: false,
 /******/ 			exports: {}
 /******/ 		};
-
+/******/
 /******/ 		// Execute the module function
 /******/ 		modules[moduleId].call(module.exports, module, module.exports, __webpack_require__);
-
+/******/
 /******/ 		// Flag the module as loaded
 /******/ 		module.l = true;
-
+/******/
 /******/ 		// Return the exports of the module
 /******/ 		return module.exports;
 /******/ 	}
-
-
+/******/
+/******/
 /******/ 	// expose the modules object (__webpack_modules__)
 /******/ 	__webpack_require__.m = modules;
-
+/******/
 /******/ 	// expose the module cache
 /******/ 	__webpack_require__.c = installedModules;
-
+/******/
 /******/ 	// identity function for calling harmony imports with the correct context
 /******/ 	__webpack_require__.i = function(value) { return value; };
-
+/******/
 /******/ 	// define getter function for harmony exports
 /******/ 	__webpack_require__.d = function(exports, name, getter) {
 /******/ 		if(!__webpack_require__.o(exports, name)) {
@@ -517,7 +517,7 @@ function bootstrapDecoratorConfig(
 /******/ 			});
 /******/ 		}
 /******/ 	};
-
+/******/
 /******/ 	// getDefaultExport function for compatibility with non-harmony modules
 /******/ 	__webpack_require__.n = function(module) {
 /******/ 		var getter = module && module.__esModule ?
@@ -526,13 +526,13 @@ function bootstrapDecoratorConfig(
 /******/ 		__webpack_require__.d(getter, 'a', getter);
 /******/ 		return getter;
 /******/ 	};
-
+/******/
 /******/ 	// Object.prototype.hasOwnProperty.call
 /******/ 	__webpack_require__.o = function(object, property) { return Object.prototype.hasOwnProperty.call(object, property); };
-
+/******/
 /******/ 	// __webpack_public_path__
 /******/ 	__webpack_require__.p = "";
-
+/******/
 /******/ 	// Load entry module and return exports
 /******/ 	return __webpack_require__(__webpack_require__.s = 21);
 /******/ })
@@ -549,8 +549,8 @@ module.exports = angular;
 
 /* WEBPACK VAR INJECTION */(function(global, setImmediate) {/*!
  * json-schema-form-core
- * @version 1.0.0-alpha.2
- * @date Sun, 19 Feb 2017 13:06:51 GMT
+ * @version 1.0.0-alpha.3
+ * @date Mon, 27 Mar 2017 13:05:31 GMT
  * @link https://github.com/json-schema-form/json-schema-form-core
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -2700,7 +2700,13 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
 
 
 // export function merge(schema, form, schemaDefaultTypes, ignore, options, readonly, asyncTemplates) {
-function merge(lookup, form, ignore, options, readonly, asyncTemplates) {
+function merge(lookup, form) {
+  var typeDefaults = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__schema_defaults__["createDefaults"])();
+  var ignore = arguments[3];
+  var options = arguments[4];
+  var readonly = arguments[5];
+  var asyncTemplates = arguments[6];
+
   var formItems = [];
   var formItemRest = [];
   form = form || [];
@@ -2711,7 +2717,7 @@ function merge(lookup, form, ignore, options, readonly, asyncTemplates) {
   var idxRest = form.indexOf('...');
   if ((typeof lookup === 'undefined' ? 'undefined' : _typeof(lookup)) === 'object' && lookup.hasOwnProperty('properties')) {
     readonly = readonly || lookup.readonly || lookup.readOnly;
-    stdForm = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__schema_defaults__["defaultForm"])(lookup, __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__schema_defaults__["createDefaults"])(), ignore, options);
+    stdForm = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__schema_defaults__["defaultForm"])(lookup, typeDefaults, ignore, options);
 
     var defaultFormLookup = stdForm.lookup;
 
@@ -2795,22 +2801,27 @@ function merge(lookup, form, ignore, options, readonly, asyncTemplates) {
 
     // if it's a type with items, merge 'em!
     if (obj.items) {
-      obj.items = merge(lookup, obj.items, ignore, options, obj.readonly, asyncTemplates);
+      obj.items = merge(lookup, obj.items, typeDefaults, ignore, options, obj.readonly, asyncTemplates);
     }
 
     // if its has tabs, merge them also!
     if (obj.tabs) {
       obj.tabs.forEach(function (tab) {
         if (tab.items) {
-          tab.items = merge(lookup, tab.items, ignore, options, obj.readonly, asyncTemplates);
+          tab.items = merge(lookup, tab.items, typeDefaults, ignore, options, obj.readonly, asyncTemplates);
         }
       });
     }
 
     // Special case: checkbox
     // Since have to ternary state we need a default
-    if (obj.type === 'checkbox' && obj.schema['default'] === undefined) {
-      obj.schema['default'] = false;
+    if (obj.type === 'checkbox') {
+      // Check for schema property, as the checkbox may be part of the explicitly defined form
+      if (obj.schema === undefined) {
+        obj.schema = { default: false };
+      } else if (obj.schema['default'] === undefined) {
+        obj.schema['default'] = false;
+      };
     };
 
     // Special case: template type with tempplateUrl that's needs to be loaded before rendering
@@ -2818,7 +2829,7 @@ function merge(lookup, form, ignore, options, readonly, asyncTemplates) {
     // is introduced since we need to go async then anyway
     if (asyncTemplates && obj.type === 'template' && !obj.template && obj.templateUrl) {
       asyncTemplates.push(obj);
-    }
+    };
 
     return obj;
   });
@@ -3322,7 +3333,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 
       // Validate against the schema.
 
-      var validate = function validate(viewValue) {
+      var validate = function validate(viewValue, triggered) {
         //Still might be undefined
         if (!form) {
           return viewValue;
@@ -3343,7 +3354,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
           ngModel.$setValidity(k, true);
         });
 
-        if (!result.valid) {
+        if (!result.valid && (!ngModel.$pristine || triggered)) {
           // it is invalid, return undefined (no model update)
           ngModel.$setValidity('tv4-' + result.error.code, false);
           error = result.error;
@@ -3354,10 +3365,12 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
           // later.
           if (ngModel.$validators) {
             return viewValue;
-          }
+          };
+
           // Angular 1.2 on the other hand lacks $validators and don't add a 'parse' error.
           return undefined;
-        }
+        };
+
         return viewValue;
       };
 
@@ -3378,7 +3391,9 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
         // Check if our version of angular has validators, i.e. 1.3+
         if (form[attr] && ngModel[attr]) {
           __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(form[attr], function (fn, name) {
-            ngModel[attr][name] = fn;
+            ngModel[attr][name] = function (modelValue, viewValue) {
+              return fn(modelValue, viewValue, scope.model, form);
+            };
           });
         }
       });
@@ -3402,13 +3417,13 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
       var schema = form.schema;
 
       // A bit ugly but useful.
-      scope.validateField = function (formName) {
+      scope.validateField = function (formName, triggered) {
         var noField = formName === undefined;
         // If we have specified a form name, and this model is not within
         // that form, then leave things be.
         if (!noField && ngModel.$$parentForm.$name !== formName) {
           return;
-        }
+        };
 
         // Special case: arrays
         // TODO: Can this be generalized in a way that works consistently?
@@ -3416,14 +3431,13 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
         // since it's the same value. This will be better when we drop
         // 1.2 support.
         if (noField || schema && schema.type.indexOf('array') !== -1) {
-          validate(ngModel.$modelValue);
+          validate(ngModel.$modelValue, triggered);
         };
 
         // We set the viewValue to trigger parsers,
         // since modelValue might be empty and validating just that
         // might change an existing error to a "required" error message.
         if (ngModel.$setDirty) {
-
           // Angular 1.3+
           ngModel.$setDirty();
           ngModel.$setViewValue(ngModel.$viewValue);
@@ -3436,10 +3450,10 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
           if (form.type === 'checkbox') {
             if (form.required && ngModel.$modelValue === undefined) {
               ngModel.$setValidity('tv4-302', false);
-            }
+            };
           } else if (form.required && ngModel.$isEmpty(ngModel.$modelValue)) {
             ngModel.$setValidity('tv4-302', false);
-          }
+          };
         } else {
           // Angular 1.2
           // In angular 1.2 setting a viewValue of undefined will trigger the parser.
@@ -3462,7 +3476,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 
       // Listen to an event so we can validate the input on request
       scope.$on('schemaFormValidate', function (event, formName) {
-        scope.validateField(formName);
+        scope.validateField(formName, true);
       });
 
       scope.schemaError = function () {
@@ -3484,7 +3498,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 /**
  * Directive that handles the model arrays
  */
-/* harmony default export */ __webpack_exports__["a"] = function (sel, sfPath, schemaForm) {
+/* harmony default export */ __webpack_exports__["a"] = function (sfSelect, sfPath, schemaForm) {
   return {
     scope: true,
     controller: ['$scope', function SFArrayController($scope) {
@@ -3526,7 +3540,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
         if (!model) {
           var selection = sfPath.parse(attrs.sfNewArray);
           model = [];
-          sel(selection, scope, model);
+          sfSelect(selection, scope, model);
           scope.modelArray = model;
         }
         return model;
@@ -3544,32 +3558,11 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
           scope.appendToArray();
         }
 
-        // If we have "uniqueItems" set to true, we must deep watch for changes.
-        if (scope.form && scope.form.schema && scope.form.schema.uniqueItems === true) {
-          scope.$watch(attrs.sfNewArray, watchFn, true);
-
-          // We still need to trigger onChange though.
-          scope.$watch([attrs.sfNewArray, attrs.sfNewArray + '.length'], onChangeFn);
-        } else {
-          // Otherwise we like to check if the instance of the array has changed, or if something
-          // has been added/removed.
-          if (scope.$watchGroup) {
-            scope.$watchGroup([attrs.sfNewArray, attrs.sfNewArray + '.length'], function () {
-              watchFn();
-              onChangeFn();
-            });
-          } else {
-            // Angular 1.2 support
-            scope.$watch(attrs.sfNewArray, function () {
-              watchFn();
-              onChangeFn();
-            });
-            scope.$watch(attrs.sfNewArray + '.length', function () {
-              watchFn();
-              onChangeFn();
-            });
-          }
-        }
+        scope.$watch(function ($scope) {
+          return JSON.stringify($scope.modelArray);
+        }, function () {
+          watchFn();onChangeFn();
+        });
 
         // Title Map handling
         // If form has a titleMap configured we'd like to enable looping over
@@ -3591,6 +3584,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
               scope.titleMapValues.push(arr.indexOf(item.value) !== -1);
             });
           };
+
           //Catch default values
           updateTitleMapValues(scope.modelArray);
 
@@ -3648,7 +3642,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
               if (empty) {
                 schemaForm.traverseSchema(items, function (prop, path) {
                   if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.isDefined(prop['default'])) {
-                    sel(path, empty, prop['default']);
+                    sfSelect(path, empty, prop['default']);
                   }
                 });
               }
@@ -4265,18 +4259,26 @@ FIXME: real documentation
       options: '=sfOptions'
     },
     controller: ['$scope', function ($scope) {
-      this.evalInParentScope = function (expr, locals) {
-        return $scope.$parent.$eval(expr, locals);
-      };
+      this.$onInit = function () {
+        this.evalInParentScope = function (expr, locals) {
+          return $scope.$parent.$eval(expr, locals);
+        };
 
-      // Set up form lookup map
-      var that = this;
-      $scope.lookup = function (lookup) {
-        if (lookup) {
-          that.lookup = lookup;
-        }
-        return that.lookup;
+        // Set up form lookup map
+        var that = this;
+        $scope.lookup = function (lookup) {
+          if (lookup) {
+            that.lookup = lookup;
+          }
+          return that.lookup;
+        };
       };
+
+      // Prior to v1.5, we need to call `$onInit()` manually.
+      // (Bindings will always be pre-assigned in these versions.)
+      if (__WEBPACK_IMPORTED_MODULE_0_angular___default.a.version.major === 1 && __WEBPACK_IMPORTED_MODULE_0_angular___default.a.version.minor < 5) {
+        this.$onInit();
+      }
     }],
     replace: false,
     restrict: 'A',
@@ -4322,10 +4324,8 @@ FIXME: real documentation
       };
 
       scope.render = function (schema, form) {
-        //console.log("schema:", JSON.stringify(schema));
-        //console.log("resolv:", JSON.stringify(resolved));
         var asyncTemplates = [];
-        var merged = schemaForm.merge(schema, form, ignore, scope.options, undefined, asyncTemplates);
+        var merged = schemaForm.merge(schema, form, undefined, ignore, scope.options, undefined, asyncTemplates);
 
         if (asyncTemplates.length > 0) {
           // Pre load all async templates and put them on the form for the builder to use.
@@ -4387,6 +4387,7 @@ FIXME: real documentation
         // We use a ordinary timeout since we don't need a digest after this.
         setTimeout(function () {
           childScope.firstDigest = false;
+          scope.$apply();
         }, 0);
 
         //compile only children
@@ -4416,7 +4417,12 @@ FIXME: real documentation
         var form = scope.initialForm || defaultForm;
 
         //The check for schema.type is to ensure that schema is not {}
-        if (form && schema && schema.type && (lastDigest.form !== form || lastDigest.schema !== schema) && Object.keys(schema.properties).length > 0) {
+        if (form && schema && schema.type && ( //schema.properties &&
+        lastDigest.form !== form || lastDigest.schema !== schema)) {
+          if ((!schema.properties || Object.keys(schema.properties).length === 0) && (form.indexOf("*") || form.indexOf("..."))) {
+            //form.unshift({"key":"submit", "type": "hidden"});
+          };
+
           lastDigest.schema = schema;
           lastDigest.form = form;
 
@@ -5088,26 +5094,40 @@ FIXME: real documentation
 
     service.jsonref = __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["jsonref"];
 
+    /**
+    * Create form defaults from schema
+    */
+    service.defaults = function (schema, types, ignore, options) {
+      var defaultTypes = types || typeDefault;
+      return __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["schemaDefaults"].defaultForm(schema, defaultTypes, ignore, options);
+    };
+
+    /**
+     * merge
+     *
+     * @param  {Object}  schema                             [description]
+     * @param  {Array}   [form=['*']]                       [description]
+     * @param  {Object}  [typeDefaults=service.typeDefault] [description]
+     * @param  {boolean} ignore                             [description]
+     * @param  {Object}  [options={}]                       [description]
+     * @param  {Boolean} [readonly=false]                   [description]
+     * @param  {[type]}  asyncTemplates                     [description]
+     *
+     * @return {[type]}                                     [description]
+     */
     service.merge = function (schema) {
       var form = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ['*'];
-      var ignore = arguments[2];
-      var options = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};
-      var readonly = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : false;
-      var asyncTemplates = arguments[5];
+      var typeDefaults = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : service.typeDefault;
+      var ignore = arguments[3];
+      var options = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : {};
+      var readonly = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : false;
+      var asyncTemplates = arguments[6];
 
       //We look at the supplied form and extend it with schema standards
-      var canonical = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["merge"])(schema, form, ignore, options, readonly, asyncTemplates);
+      var canonical = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["merge"])(schema, form, typeDefaults, ignore, options, readonly, asyncTemplates);
       return postProcessFn(canonical);
     };
 
-    /**
-     * Create form defaults from schema
-     */
-    service.defaults = function (schema, types, ignore, options) {
-      var defaultTypes = types || typeDefault;
-      return __WEBPACK_IMPORTED_MODULE_1_json_schema_form_core__["schemaDefaults"].defaultForm(schema, defaultTypes, ignore, options);
-    };
-
     //Utility functions
     /**
      * Form defaults for schema by type
diff --git a/dist/angular-schema-form-bootstrap-bundled.min.js b/dist/angular-schema-form-bootstrap-bundled.min.js
index b7a717d..751f77a 100644
--- a/dist/angular-schema-form-bootstrap-bundled.min.js
+++ b/dist/angular-schema-form-bootstrap-bundled.min.js
@@ -1,32 +1,32 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.1
- * @date Tue, 21 Feb 2017 11:44:44 GMT
+ * @date Thu, 30 Mar 2017 10:51:56 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,v=r.builders.array,g=r.builders.numeric,w=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},E=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,v,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,v,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:y.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:x.a,builder:C},"radios-inline":{template:$.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:C.concat(E)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,v,m]},tabs:{template:D.a,builder:[d,l,w,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),v=r(8),y=r.n(v),g=r(9),b=r.n(g),w=r(11),x=r.n(w),E=r(10),$=r.n(E),C=r(12),k=r.n(C),A=r(13),T=r.n(A),O=r(14),S=r.n(O),P=r(15),M=r.n(P),j=r(16),D=r.n(j),I=r(17),_=r.n(I);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
+!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,v=r.builders.array,g=r.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},E=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,v,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,v,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:y.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:w.a,builder:C},"radios-inline":{template:$.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:C.concat(E)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,v,m]},tabs:{template:D.a,builder:[d,l,x,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),v=r(8),y=r.n(v),g=r(9),b=r.n(g),x=r(11),w=r.n(x),E=r(10),$=r.n(E),C=r(12),k=r.n(C),O=r(13),T=r.n(O),A=r(14),S=r.n(A),P=r(15),M=r.n(P),j=r(16),D=r.n(j),I=r(17),_=r.n(I);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
  * angular-schema-form
- * @version 1.0.0-alpha.2
- * @date Sun, 19 Feb 2017 13:13:18 GMT
+ * @version 1.0.0-alpha.3
+ * @date Thu, 30 Mar 2017 07:57:38 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
 !function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=21)}([function(e,t){e.exports=angular},function(e,t,r){(function(t,r){/*!
  * json-schema-form-core
- * @version 1.0.0-alpha.2
- * @date Sun, 19 Feb 2017 13:06:51 GMT
+ * @version 1.0.0-alpha.3
+ * @date Mon, 27 Mar 2017 13:05:31 GMT
  * @link https://github.com/json-schema-form/json-schema-form-core
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-e.exports=function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=13)}([function(e,t,r){"use strict";function n(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(e){var o=e.slice(),i=t||"-";return n&&(o=o.filter(function(e){return"number"!=typeof e})),(0!==r.length?r+i:"")+o.join(i)}return""}Object.defineProperty(t,"__esModule",{value:!0});var o=r(2);r.n(o);r.o(o,"parse")&&r.d(t,"parse",function(){return o.parse}),r.o(o,"stringify")&&r.d(t,"stringify",function(){return o.stringify}),r.o(o,"normalize")&&r.d(t,"normalize",function(){return o.normalize}),t.name=n},function(e,t,r){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t){if(!Array.isArray(e)){var r=function(){var r=[];return t?t.forEach(function(t){r.push({name:e[t],value:t})}):Object.keys(e).forEach(function(t){r.push({name:e[t],value:t})}),{v:r}}();if("object"===("undefined"==typeof r?"undefined":n(r)))return r.v}return e}},function(e,t,r){e.exports=r(11).ObjectPath},function(e,t,r){"use strict";function n(e,t,r,o){var i=e[g(r.type)];if(i)for(var a=void 0,s=function(t,r,o){return n(e,t,r,o)},l=0;l<i.length;l++)if(a=i[l](t,r,o,s))return a.schema["x-schema-form"]&&Object.assign(a,a.schema["x-schema-form"]),a}function o(e,t,n){n=n||{};var o=n.global&&n.global.formDefaults?Object.assign({},n.global.formDefaults):{};return n.global&&n.global.supressPropertyTitles===!0?o.title=t.title:o.title=t.title||e,t.description&&(o.description=t.description),n.required!==!0&&t.required!==!0||(o.required=!0),t.maxLength&&(o.maxlength=t.maxLength),t.minLength&&(o.minlength=t.minLength),(t.readOnly||t.readonly)&&(o.readonly=!0),t.minimum&&(o.minimum=t.minimum+(t.exclusiveMinimum?1:0)),t.maximum&&(o.maximum=t.maximum-(t.exclusiveMaximum?1:0)),t.validationMessage&&(o.validationMessage=t.validationMessage),t.enumNames&&(o.titleMap=r.i(v.a)(t.enumNames,t.enum)),o.schema=t,o.ngModelOptions=o.ngModelOptions||{},o}function i(e,t,n){if("string"===g(t.type)&&!t.enum){var i=o(e,t,n);return i.key=n.path,i.type="text",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function a(e,t,n){if("number"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function s(e,t,n){if("integer"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function l(e,t,n){if("boolean"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="checkbox",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function c(e,t,n){if("string"===g(t.type)&&t.enum){var i=o(e,t,n);return i.key=n.path,i.type="select",i.titleMap||(i.titleMap=b(t.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function u(e,t,n){if("array"===g(t.type)&&t.items&&t.items.enum){var i=o(e,t,n);return i.key=n.path,i.type="checkboxes",i.titleMap||(i.titleMap=b(t.items.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function f(e,t,n,i){if("object"===g(t.type)){var a=function(){var a=o(e,t,n);return a.type="fieldset",a.key=n.path,a.items=[],n.lookup[r.i(h.stringify)(n.path)]=a,t.properties&&Object.keys(t.properties).forEach(function(e){var o=t.properties[e],s=n.path.slice();if(s.push(e),n.ignore[r.i(h.stringify)(s)]!==!0){var l=t.required&&t.required.indexOf(e)!==-1,c=i(e,o,{path:s,required:l||!1,lookup:n.lookup,ignore:n.ignore,global:n.global});c&&a.items.push(c)}}),{v:a}}();if("object"===("undefined"==typeof a?"undefined":y(a)))return a.v}}function d(e,t,n,i){if("array"===g(t.type)){var a=o(e,t,n);a.type="array",a.key=n.path,n.lookup[r.i(h.stringify)(n.path)]=a;var s=t.required&&t.required.indexOf(n.path[n.path.length-1])!==-1,l=n.path.slice();return l.push(""),a.items=[i(e,t.items,{path:l,required:s||!1,lookup:n.lookup,ignore:n.ignore,global:n.global})],a}}function p(){return{string:[c,i],object:[f],number:[a],integer:[s],boolean:[l],array:[u,d]}}function m(e,t,r,o){var i=[],a={};if(r=r||{},o=o||{},t=t||p(),!e.properties)throw new Error('Not implemented. Only type "object" allowed at root level of schema.');return Object.keys(e.properties).forEach(function(s){if(r[s]!==!0){var l=e.required&&e.required.indexOf(s)!==-1,c=n(t,s,e.properties[s],{path:[s],lookup:a,ignore:r,required:l,global:o});c&&i.push(c)}}),{form:i,lookup:a}}Object.defineProperty(t,"__esModule",{value:!0});var h=r(0),v=r(1);t.defaultFormDefinition=n,t.stdFormObj=o,t.text=i,t.number=a,t.integer=s,t.checkbox=l,t.select=c,t.checkboxes=u,t.fieldset=f,t.array=d,t.createDefaults=p,t.defaultForm=m;var y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},g=function(e){if(Array.isArray(e)&&2===e.length){if("null"===e[0])return e[1];if("null"===e[1])return e[0]}return e},b=function(e){var t=[];return e.forEach(function(e){t.push({name:e,value:e})}),t}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(3),o=r(0),i=r(1),a=r(6);r.d(t,"merge",function(){return a.a});var s=r(8);r.d(t,"select",function(){return s.a});var l=r(7);r.d(t,"jsonref",function(){return l.a});var c=r(9);r.d(t,"traverseSchema",function(){return c.a}),r.d(t,"traverseForm",function(){return c.b});var u=r(10);r.d(t,"validate",function(){return u.a}),r.d(t,"sfPath",function(){return f}),r.d(t,"schemaDefaults",function(){return d}),r.d(t,"canonicalTitleMap",function(){return p});var f=o,d=n,p=i.a},function(e,n,o){var i,a,s,l,l,c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};!function(t){if("object"===c(n)&&"undefined"!=typeof e)e.exports=t();else{a=[],i=t,s="function"==typeof i?i.apply(n,a):i,!(void 0!==s&&(e.exports=s))}}(function(){var e;return function e(t,r,n){function o(a,s){if(!r[a]){if(!t[a]){var c="function"==typeof l&&l;if(!s&&c)return l(a,!0);if(i)return i(a,!0);var u=new Error("Cannot find module '"+a+"'");throw u.code="MODULE_NOT_FOUND",u}var f=r[a]={exports:{}};t[a][0].call(f.exports,function(e){var r=t[a][1][e];return o(r?r:e)},f,f.exports,e,t,r,n)}return r[a].exports}for(var i="function"==typeof l&&l,a=0;a<n.length;a++)o(n[a]);return o}({1:[function(e,t,r){"use strict";function n(e){var t;return m(e,"Array")?(t=[],e.forEach(function(e,r){t[r]=n(e)})):m(e,"Object")?(t={},Object.keys(e).forEach(function(r){t[r]=n(e[r])})):t=e,t}function o(e,t){function r(e){Object.keys(e).forEach(function(t){n[t]=e[t]})}var n={};return r(_.parse(e||"")),r(_.parse(t||"")),0===Object.keys(n).length?void 0:_.stringify(n)}function i(e,t){m(e,"String")&&(e=F(e)),m(t,"String")&&(t=F(t));var r,n,i=y(m(t,"Undefined")?"":t);return L.indexOf(i.reference)>-1?n=i:(r=m(e,"Undefined")?void 0:y(e),m(r,"Undefined")?n=i:(n=r,n.path=F(D.join(r.path,i.path)),n.query=o(r.query,i.query))),n.fragment=void 0,(L.indexOf(n.reference)===-1&&0===n.path.indexOf("../")?"../":"")+R.serialize(n)}function a(e,t){var r,n=[];return t.length>0&&(r=e,t.slice(0,t.length-1).forEach(function(e){e in r&&(r=r[e],n.push(r))})),n}function s(e,t,r,o,i,a,s,u,f){var d,p;if(r.length>0)try{d=c(t,r)}catch(t){"remote"===e&&(o.error=t.message,o.missing=!0)}else d=t;if(m(d,"Undefined")||(o.value=d),m(d,"Array")||m(d,"Object"))return p=n(i),"local"===e?(delete p.subDocPath,t=d):(p.relativeBase=D.dirname(a[a.length-1]),0===r.length?delete p.subDocPath:p.subDocPath=r),l(t,p,a,s,u,f)}function l(e,t,r,n,o,a){var l=Promise.resolve(),c=n.length?S(n[n.length-1]):[],u=C(e,t),f=t.subDocPath||[],p=P(f),h=["#"];return r.forEach(function(e,t){"#"!==e.charAt(0)&&h.push(n[t])}),h.reverse(),"#"!==(r[r.length-1]||"").charAt(0)&&(o.documents[P(c)]=e),Object.keys(u).forEach(function(v){var y,g,b,w,x=u[v];b=0===r.length?c.concat(S(v)):c.concat(S(v).slice(0===r.length?0:f.length)),w=P(b),m(o[w],"Undefined")&&(o.refs[w]=u[v],m(x.error,"Undefined")&&"invalid"!==x.type&&(N.indexOf(x.type)>-1?(y=i(t.relativeBase,x.uri),g=r.indexOf(y)):(y=x.uri,g=n.indexOf(y)),x.ancestorPtrs=h,x.indirect=a,g===-1?N.indexOf(x.type)>-1?l=l.then(function(){return d(y,t).then(function(e){return s("remote",e,m(x.uriDetails.fragment,"Undefined")?[]:S(decodeURI(x.uriDetails.fragment)),x,t,r.concat(y),n.concat(w),o,a)}).catch(function(e){x.error=e.message,x.missing=!0})}):0!==w.indexOf(y+"/")&&w!==y&&0!==p.indexOf(y+"/")&&p!==y?0!==y.indexOf(p+"/")&&(l=l.then(function(){return s("local",e,S(y),x,t,r.concat(y),n.concat(w),o,a||y.indexOf(p+"/")===-1&&y!==p)})):x.circular=!0:(n.slice(g).forEach(function(e){o.refs[e].circular=!0}),x.circular=!0)))}),l=l.then(function(){function e(i,a,s,l){Object.keys(o.refs).forEach(function(c){var u=o.refs[c];n.indexOf(l)===-1&&r.indexOf(s)===-1&&t.indexOf(l)===-1&&c!==s&&0===c.indexOf(l+"/")&&(a.indexOf(l)>-1?a.forEach(function(e){t.indexOf(l)===-1&&t.push(e)}):e(i.concat(s),a.concat(l),c,u.uri),r.push(s),n.push(l))})}var t=[],r=[],n=[];Object.keys(o.refs).forEach(function(r){var n=o.refs[r];"local"!==n.type||n.circular||t.indexOf(n.uri)!==-1||e([],[],r,n.uri)}),Object.keys(o.refs).forEach(function(e){var r=o.refs[e];t.indexOf(r.uri)>-1&&(r.circular=!0)})}).then(function(){return o})}function c(e,t){var r=e;return t.forEach(function(e){if(e=decodeURI(e),!(e in r))throw Error("JSON Pointer points to missing location: "+P(t));r=r[e]}),r}function u(e){return Object.keys(e).filter(function(e){return"$ref"!==e})}function f(e){var t;switch(e.uriDetails.reference){case"absolute":case"uri":t="remote";break;case"same-document":t="local";break;default:t=e.uriDetails.reference}return t}function d(e,t){var r=U[e],o=Promise.resolve(),i=n(t.loaderOptions||{});return m(r,"Undefined")?(m(i.processContent,"Undefined")&&(i.processContent=function(e,t){t(void 0,JSON.parse(e.text))}),o=I.load(decodeURI(e),i),o=o.then(function(t){return U[e]={value:t},t}).catch(function(t){throw U[e]={error:t},t})):o=o.then(function(){return r.value}),o=o.then(function(e){return n(e)})}function p(e,t){var r=!0;try{if(!m(e,"Object"))throw new Error("obj is not an Object");if(!m(e.$ref,"String"))throw new Error("obj.$ref is not a String")}catch(e){if(t)throw e;r=!1}return r}function m(e,t){return"Undefined"===t?"undefined"==typeof e:Object.prototype.toString.call(e)==="[object "+t+"]"}function h(e){var t,r;return m(e.filter,"Array")||m(e.filter,"String")?(r=m(e.filter,"String")?[e.filter]:e.filter,t=function(e){return r.indexOf(e.type)>-1||r.indexOf(f(e))>-1}):m(e.filter,"Function")?t=e.filter:m(e.filter,"Undefined")&&(t=function(){return!0}),function(r,n){return("invalid"!==r.type||e.includeInvalid===!0)&&t(r,n)}}function v(e){var t;return m(e.subDocPath,"Array")?t=e.subDocPath:m(e.subDocPath,"String")?t=S(e.subDocPath):m(e.subDocPath,"Undefined")&&(t=[]),t}function y(e){return R.parse(encodeURI(decodeURI(e)))}function g(e,t,r){c(e,t.slice(0,t.length-1))[decodeURI(t[t.length-1])]=r}function b(e,t,r,n){function o(t,o){r.push(o),b(e,t,r,n),r.pop()}var i=!0;m(n,"Function")&&(i=n(e,t,r)),e.indexOf(t)===-1&&(e.push(t),i!==!1&&(m(t,"Array")?t.forEach(function(e,t){o(e,t.toString())}):m(t,"Object")&&Object.keys(t).forEach(function(e){o(t[e],e)}))),e.pop()}function w(e,t){if(e=m(e,"Undefined")?{}:n(e),!m(e,"Object"))throw new TypeError("options must be an Object");if(!(m(e.filter,"Undefined")||m(e.filter,"Array")||m(e.filter,"Function")||m(e.filter,"String")))throw new TypeError("options.filter must be an Array, a Function of a String");if(!m(e.includeInvalid,"Undefined")&&!m(e.includeInvalid,"Boolean"))throw new TypeError("options.includeInvalid must be a Boolean");if(!m(e.refPreProcessor,"Undefined")&&!m(e.refPreProcessor,"Function"))throw new TypeError("options.refPreProcessor must be a Function");if(!m(e.refPostProcessor,"Undefined")&&!m(e.refPostProcessor,"Function"))throw new TypeError("options.refPostProcessor must be a Function");if(!m(e.subDocPath,"Undefined")&&!m(e.subDocPath,"Array")&&!T(e.subDocPath))throw new TypeError("options.subDocPath must be an Array of path segments or a valid JSON Pointer");if(e.filter=h(e),e.subDocPath=v(e),!m(t,"Undefined"))try{c(t,e.subDocPath)}catch(e){throw e.message=e.message.replace("JSON Pointer","options.subDocPath"),e}return e}function x(){U={}}function E(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),decodeURI(e.replace(/~1/g,"/").replace(/~0/g,"~"))})}function $(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),e.replace(/~/g,"~0").replace(/\//g,"~1")})}function C(e,t){var r={};if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");return t=w(t,e),b(a(e,t.subDocPath),c(e,t.subDocPath),n(t.subDocPath),function(e,o,i){var a,s=!0;return p(o)&&(m(t.refPreProcessor,"Undefined")||(o=t.refPreProcessor(n(o),i)),a=A(o),m(t.refPostProcessor,"Undefined")||(a=t.refPostProcessor(a,i)),t.filter(a,i)&&(r[P(i)]=a),u(o).length>0&&(s=!1)),s}),r}function k(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=w(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(U[e]),i=n(t),a=y(e);return m(o.refs,"Undefined")&&(delete i.filter,delete i.subDocPath,i.includeInvalid=!0,U[e].refs=C(r,i)),m(t.filter,"Undefined")||(i.filter=t.filter),m(a.fragment,"Undefined")?m(a.subDocPath,"Undefined")||(i.subDocPath=t.subDocPath):i.subDocPath=S(decodeURI(a.fragment)),{refs:C(r,i),value:r}})}function A(e){var t,r,n,o={def:e};try{p(e,!0)?(t=e.$ref,n=H[t],m(n,"Undefined")&&(n=H[t]=y(t)),o.uri=t,o.uriDetails=n,m(n.error,"Undefined")?o.type=f(o):(o.error=o.uriDetails.error,o.type="invalid"),r=u(e),r.length>0&&(o.warning="Extra JSON Reference properties will be ignored: "+r.join(", "))):o.type="invalid"}catch(e){o.error=e.message,o.type="invalid"}return o}function T(e,t){var r,n=!0;try{if(!m(e,"String"))throw new Error("ptr is not a String");if(""!==e){if(r=e.charAt(0),["#","/"].indexOf(r)===-1)throw new Error("ptr must start with a / or #/");if("#"===r&&"#"!==e&&"/"!==e.charAt(1))throw new Error("ptr must start with a / or #/");if(e.match(q))throw new Error("ptr has invalid token(s)")}}catch(e){if(t===!0)throw e;n=!1}return n}function O(e,t){return p(e,t)&&"invalid"!==A(e,t).type}function S(e){if(!T(e))throw new Error("ptr must be a JSON Pointer");var t=e.split("/");return t.shift(),E(t)}function P(e,t){if(!m(e,"Array"))throw new Error("path must be an Array");return(t!==!1?"#":"")+(e.length>0?"/":"")+$(e).join("/")}function M(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");t=w(t,e),e=n(e)}).then(function(){return l(e,t,[],[],{documents:{},refs:{}})}).then(function(t){function r(e,t){return S(e).length-S(t).length}var n={},o={};return Object.keys(t.refs).sort(r).forEach(function(r){var i=t.refs[r];i.indirect||(o[r]=i),delete i.indirect,m(i.error,"Undefined")&&"invalid"!==i.type?(m(i.value,"Undefined")&&i.circular&&(i.value=i.def),m(i.value,"Undefined")?n[r]=i:("#"===r?e=i.value:g(e,S(r),i.value),delete i.ancestorPtrs)):delete i.ancestorPtrs}),Object.keys(n).forEach(function(r){var o=n[r];o.ancestorPtrs.forEach(function(n,i){if(m(o.value,"Undefined"))try{o.value=c(t.documents[n],S(o.uri)),delete o.ancestorPtrs,g(e,S(r),o.value)}catch(e){i===o.ancestorPtrs.length-1&&(o.error=e.message,o.missing=!0,delete o.ancestorPtrs)}})}),{refs:o,resolved:e}})}function j(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=w(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(t),i=y(e);return m(i.fragment,"Undefined")||(o.subDocPath=S(decodeURI(i.fragment))),o.relativeBase=D.dirname(e),M(r,o).then(function(e){return{refs:e.refs,resolved:e.resolved,value:r}})})}var D=e("path"),I=e("path-loader"),_=e("querystring"),F=e("slash"),R=e("uri-js"),q=/~(?:[^01]|$)/g,U={},N=["relative","remote"],L=["absolute","uri"],H={};"undefined"==typeof Promise&&e("native-promise-only"),t.exports.clearCache=x,t.exports.decodePath=E,t.exports.encodePath=$,t.exports.findRefs=C,t.exports.findRefsAt=k,t.exports.getRefDetails=A,t.exports.isPtr=T,t.exports.isRef=O,t.exports.pathFromPtr=S,t.exports.pathToPtr=P,t.exports.resolveRefs=M,t.exports.resolveRefsAt=j},{"native-promise-only":3,path:4,"path-loader":5,querystring:11,slash:13,"uri-js":23}],2:[function(e,t,r){function n(e){if(e)return o(e)}function o(e){for(var t in n.prototype)e[t]=n.prototype[t];return e}t.exports=n,n.prototype.on=n.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},n.prototype.once=function(e,t){function r(){this.off(e,r),t.apply(this,arguments)}return r.fn=t,this.on(e,r),this},n.prototype.off=n.prototype.removeListener=n.prototype.removeAllListeners=n.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var n,o=0;o<r.length;o++)if(n=r[o],n===t||n.fn===t){r.splice(o,1);break}return this},n.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),r=this._callbacks["$"+e];if(r){r=r.slice(0);for(var n=0,o=r.length;n<o;++n)r[n].apply(this,t)}return this},n.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},n.prototype.hasListeners=function(e){return!!this.listeners(e).length}},{}],3:[function(n,o,i){(function(t){/*! Native Promise Only
+e.exports=function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=13)}([function(e,t,r){"use strict";function n(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(e){var o=e.slice(),i=t||"-";return n&&(o=o.filter(function(e){return"number"!=typeof e})),(0!==r.length?r+i:"")+o.join(i)}return""}Object.defineProperty(t,"__esModule",{value:!0});var o=r(2);r.n(o);r.o(o,"parse")&&r.d(t,"parse",function(){return o.parse}),r.o(o,"stringify")&&r.d(t,"stringify",function(){return o.stringify}),r.o(o,"normalize")&&r.d(t,"normalize",function(){return o.normalize}),t.name=n},function(e,t,r){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t){if(!Array.isArray(e)){var r=function(){var r=[];return t?t.forEach(function(t){r.push({name:e[t],value:t})}):Object.keys(e).forEach(function(t){r.push({name:e[t],value:t})}),{v:r}}();if("object"===("undefined"==typeof r?"undefined":n(r)))return r.v}return e}},function(e,t,r){e.exports=r(11).ObjectPath},function(e,t,r){"use strict";function n(e,t,r,o){var i=e[g(r.type)];if(i)for(var a=void 0,s=function(t,r,o){return n(e,t,r,o)},l=0;l<i.length;l++)if(a=i[l](t,r,o,s))return a.schema["x-schema-form"]&&Object.assign(a,a.schema["x-schema-form"]),a}function o(e,t,n){n=n||{};var o=n.global&&n.global.formDefaults?Object.assign({},n.global.formDefaults):{};return n.global&&n.global.supressPropertyTitles===!0?o.title=t.title:o.title=t.title||e,t.description&&(o.description=t.description),n.required!==!0&&t.required!==!0||(o.required=!0),t.maxLength&&(o.maxlength=t.maxLength),t.minLength&&(o.minlength=t.minLength),(t.readOnly||t.readonly)&&(o.readonly=!0),t.minimum&&(o.minimum=t.minimum+(t.exclusiveMinimum?1:0)),t.maximum&&(o.maximum=t.maximum-(t.exclusiveMaximum?1:0)),t.validationMessage&&(o.validationMessage=t.validationMessage),t.enumNames&&(o.titleMap=r.i(v.a)(t.enumNames,t.enum)),o.schema=t,o.ngModelOptions=o.ngModelOptions||{},o}function i(e,t,n){if("string"===g(t.type)&&!t.enum){var i=o(e,t,n);return i.key=n.path,i.type="text",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function a(e,t,n){if("number"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function s(e,t,n){if("integer"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function l(e,t,n){if("boolean"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="checkbox",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function c(e,t,n){if("string"===g(t.type)&&t.enum){var i=o(e,t,n);return i.key=n.path,i.type="select",i.titleMap||(i.titleMap=b(t.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function u(e,t,n){if("array"===g(t.type)&&t.items&&t.items.enum){var i=o(e,t,n);return i.key=n.path,i.type="checkboxes",i.titleMap||(i.titleMap=b(t.items.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function f(e,t,n,i){if("object"===g(t.type)){var a=function(){var a=o(e,t,n);return a.type="fieldset",a.key=n.path,a.items=[],n.lookup[r.i(h.stringify)(n.path)]=a,t.properties&&Object.keys(t.properties).forEach(function(e){var o=t.properties[e],s=n.path.slice();if(s.push(e),n.ignore[r.i(h.stringify)(s)]!==!0){var l=t.required&&t.required.indexOf(e)!==-1,c=i(e,o,{path:s,required:l||!1,lookup:n.lookup,ignore:n.ignore,global:n.global});c&&a.items.push(c)}}),{v:a}}();if("object"===("undefined"==typeof a?"undefined":y(a)))return a.v}}function d(e,t,n,i){if("array"===g(t.type)){var a=o(e,t,n);a.type="array",a.key=n.path,n.lookup[r.i(h.stringify)(n.path)]=a;var s=t.required&&t.required.indexOf(n.path[n.path.length-1])!==-1,l=n.path.slice();return l.push(""),a.items=[i(e,t.items,{path:l,required:s||!1,lookup:n.lookup,ignore:n.ignore,global:n.global})],a}}function p(){return{string:[c,i],object:[f],number:[a],integer:[s],boolean:[l],array:[u,d]}}function m(e,t,r,o){var i=[],a={};if(r=r||{},o=o||{},t=t||p(),!e.properties)throw new Error('Not implemented. Only type "object" allowed at root level of schema.');return Object.keys(e.properties).forEach(function(s){if(r[s]!==!0){var l=e.required&&e.required.indexOf(s)!==-1,c=n(t,s,e.properties[s],{path:[s],lookup:a,ignore:r,required:l,global:o});c&&i.push(c)}}),{form:i,lookup:a}}Object.defineProperty(t,"__esModule",{value:!0});var h=r(0),v=r(1);t.defaultFormDefinition=n,t.stdFormObj=o,t.text=i,t.number=a,t.integer=s,t.checkbox=l,t.select=c,t.checkboxes=u,t.fieldset=f,t.array=d,t.createDefaults=p,t.defaultForm=m;var y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},g=function(e){if(Array.isArray(e)&&2===e.length){if("null"===e[0])return e[1];if("null"===e[1])return e[0]}return e},b=function(e){var t=[];return e.forEach(function(e){t.push({name:e,value:e})}),t}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(3),o=r(0),i=r(1),a=r(6);r.d(t,"merge",function(){return a.a});var s=r(8);r.d(t,"select",function(){return s.a});var l=r(7);r.d(t,"jsonref",function(){return l.a});var c=r(9);r.d(t,"traverseSchema",function(){return c.a}),r.d(t,"traverseForm",function(){return c.b});var u=r(10);r.d(t,"validate",function(){return u.a}),r.d(t,"sfPath",function(){return f}),r.d(t,"schemaDefaults",function(){return d}),r.d(t,"canonicalTitleMap",function(){return p});var f=o,d=n,p=i.a},function(e,n,o){var i,a,s,l,l,c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};!function(t){if("object"===c(n)&&"undefined"!=typeof e)e.exports=t();else{a=[],i=t,s="function"==typeof i?i.apply(n,a):i,!(void 0!==s&&(e.exports=s))}}(function(){var e;return function e(t,r,n){function o(a,s){if(!r[a]){if(!t[a]){var c="function"==typeof l&&l;if(!s&&c)return l(a,!0);if(i)return i(a,!0);var u=new Error("Cannot find module '"+a+"'");throw u.code="MODULE_NOT_FOUND",u}var f=r[a]={exports:{}};t[a][0].call(f.exports,function(e){var r=t[a][1][e];return o(r?r:e)},f,f.exports,e,t,r,n)}return r[a].exports}for(var i="function"==typeof l&&l,a=0;a<n.length;a++)o(n[a]);return o}({1:[function(e,t,r){"use strict";function n(e){var t;return m(e,"Array")?(t=[],e.forEach(function(e,r){t[r]=n(e)})):m(e,"Object")?(t={},Object.keys(e).forEach(function(r){t[r]=n(e[r])})):t=e,t}function o(e,t){function r(e){Object.keys(e).forEach(function(t){n[t]=e[t]})}var n={};return r(_.parse(e||"")),r(_.parse(t||"")),0===Object.keys(n).length?void 0:_.stringify(n)}function i(e,t){m(e,"String")&&(e=F(e)),m(t,"String")&&(t=F(t));var r,n,i=y(m(t,"Undefined")?"":t);return L.indexOf(i.reference)>-1?n=i:(r=m(e,"Undefined")?void 0:y(e),m(r,"Undefined")?n=i:(n=r,n.path=F(D.join(r.path,i.path)),n.query=o(r.query,i.query))),n.fragment=void 0,(L.indexOf(n.reference)===-1&&0===n.path.indexOf("../")?"../":"")+R.serialize(n)}function a(e,t){var r,n=[];return t.length>0&&(r=e,t.slice(0,t.length-1).forEach(function(e){e in r&&(r=r[e],n.push(r))})),n}function s(e,t,r,o,i,a,s,u,f){var d,p;if(r.length>0)try{d=c(t,r)}catch(t){"remote"===e&&(o.error=t.message,o.missing=!0)}else d=t;if(m(d,"Undefined")||(o.value=d),m(d,"Array")||m(d,"Object"))return p=n(i),"local"===e?(delete p.subDocPath,t=d):(p.relativeBase=D.dirname(a[a.length-1]),0===r.length?delete p.subDocPath:p.subDocPath=r),l(t,p,a,s,u,f)}function l(e,t,r,n,o,a){var l=Promise.resolve(),c=n.length?S(n[n.length-1]):[],u=C(e,t),f=t.subDocPath||[],p=P(f),h=["#"];return r.forEach(function(e,t){"#"!==e.charAt(0)&&h.push(n[t])}),h.reverse(),"#"!==(r[r.length-1]||"").charAt(0)&&(o.documents[P(c)]=e),Object.keys(u).forEach(function(v){var y,g,b,x,w=u[v];b=0===r.length?c.concat(S(v)):c.concat(S(v).slice(0===r.length?0:f.length)),x=P(b),m(o[x],"Undefined")&&(o.refs[x]=u[v],m(w.error,"Undefined")&&"invalid"!==w.type&&(N.indexOf(w.type)>-1?(y=i(t.relativeBase,w.uri),g=r.indexOf(y)):(y=w.uri,g=n.indexOf(y)),w.ancestorPtrs=h,w.indirect=a,g===-1?N.indexOf(w.type)>-1?l=l.then(function(){return d(y,t).then(function(e){return s("remote",e,m(w.uriDetails.fragment,"Undefined")?[]:S(decodeURI(w.uriDetails.fragment)),w,t,r.concat(y),n.concat(x),o,a)}).catch(function(e){w.error=e.message,w.missing=!0})}):0!==x.indexOf(y+"/")&&x!==y&&0!==p.indexOf(y+"/")&&p!==y?0!==y.indexOf(p+"/")&&(l=l.then(function(){return s("local",e,S(y),w,t,r.concat(y),n.concat(x),o,a||y.indexOf(p+"/")===-1&&y!==p)})):w.circular=!0:(n.slice(g).forEach(function(e){o.refs[e].circular=!0}),w.circular=!0)))}),l=l.then(function(){function e(i,a,s,l){Object.keys(o.refs).forEach(function(c){var u=o.refs[c];n.indexOf(l)===-1&&r.indexOf(s)===-1&&t.indexOf(l)===-1&&c!==s&&0===c.indexOf(l+"/")&&(a.indexOf(l)>-1?a.forEach(function(e){t.indexOf(l)===-1&&t.push(e)}):e(i.concat(s),a.concat(l),c,u.uri),r.push(s),n.push(l))})}var t=[],r=[],n=[];Object.keys(o.refs).forEach(function(r){var n=o.refs[r];"local"!==n.type||n.circular||t.indexOf(n.uri)!==-1||e([],[],r,n.uri)}),Object.keys(o.refs).forEach(function(e){var r=o.refs[e];t.indexOf(r.uri)>-1&&(r.circular=!0)})}).then(function(){return o})}function c(e,t){var r=e;return t.forEach(function(e){if(e=decodeURI(e),!(e in r))throw Error("JSON Pointer points to missing location: "+P(t));r=r[e]}),r}function u(e){return Object.keys(e).filter(function(e){return"$ref"!==e})}function f(e){var t;switch(e.uriDetails.reference){case"absolute":case"uri":t="remote";break;case"same-document":t="local";break;default:t=e.uriDetails.reference}return t}function d(e,t){var r=U[e],o=Promise.resolve(),i=n(t.loaderOptions||{});return m(r,"Undefined")?(m(i.processContent,"Undefined")&&(i.processContent=function(e,t){t(void 0,JSON.parse(e.text))}),o=I.load(decodeURI(e),i),o=o.then(function(t){return U[e]={value:t},t}).catch(function(t){throw U[e]={error:t},t})):o=o.then(function(){return r.value}),o=o.then(function(e){return n(e)})}function p(e,t){var r=!0;try{if(!m(e,"Object"))throw new Error("obj is not an Object");if(!m(e.$ref,"String"))throw new Error("obj.$ref is not a String")}catch(e){if(t)throw e;r=!1}return r}function m(e,t){return"Undefined"===t?"undefined"==typeof e:Object.prototype.toString.call(e)==="[object "+t+"]"}function h(e){var t,r;return m(e.filter,"Array")||m(e.filter,"String")?(r=m(e.filter,"String")?[e.filter]:e.filter,t=function(e){return r.indexOf(e.type)>-1||r.indexOf(f(e))>-1}):m(e.filter,"Function")?t=e.filter:m(e.filter,"Undefined")&&(t=function(){return!0}),function(r,n){return("invalid"!==r.type||e.includeInvalid===!0)&&t(r,n)}}function v(e){var t;return m(e.subDocPath,"Array")?t=e.subDocPath:m(e.subDocPath,"String")?t=S(e.subDocPath):m(e.subDocPath,"Undefined")&&(t=[]),t}function y(e){return R.parse(encodeURI(decodeURI(e)))}function g(e,t,r){c(e,t.slice(0,t.length-1))[decodeURI(t[t.length-1])]=r}function b(e,t,r,n){function o(t,o){r.push(o),b(e,t,r,n),r.pop()}var i=!0;m(n,"Function")&&(i=n(e,t,r)),e.indexOf(t)===-1&&(e.push(t),i!==!1&&(m(t,"Array")?t.forEach(function(e,t){o(e,t.toString())}):m(t,"Object")&&Object.keys(t).forEach(function(e){o(t[e],e)}))),e.pop()}function x(e,t){if(e=m(e,"Undefined")?{}:n(e),!m(e,"Object"))throw new TypeError("options must be an Object");if(!(m(e.filter,"Undefined")||m(e.filter,"Array")||m(e.filter,"Function")||m(e.filter,"String")))throw new TypeError("options.filter must be an Array, a Function of a String");if(!m(e.includeInvalid,"Undefined")&&!m(e.includeInvalid,"Boolean"))throw new TypeError("options.includeInvalid must be a Boolean");if(!m(e.refPreProcessor,"Undefined")&&!m(e.refPreProcessor,"Function"))throw new TypeError("options.refPreProcessor must be a Function");if(!m(e.refPostProcessor,"Undefined")&&!m(e.refPostProcessor,"Function"))throw new TypeError("options.refPostProcessor must be a Function");if(!m(e.subDocPath,"Undefined")&&!m(e.subDocPath,"Array")&&!T(e.subDocPath))throw new TypeError("options.subDocPath must be an Array of path segments or a valid JSON Pointer");if(e.filter=h(e),e.subDocPath=v(e),!m(t,"Undefined"))try{c(t,e.subDocPath)}catch(e){throw e.message=e.message.replace("JSON Pointer","options.subDocPath"),e}return e}function w(){U={}}function E(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),decodeURI(e.replace(/~1/g,"/").replace(/~0/g,"~"))})}function $(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),e.replace(/~/g,"~0").replace(/\//g,"~1")})}function C(e,t){var r={};if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");return t=x(t,e),b(a(e,t.subDocPath),c(e,t.subDocPath),n(t.subDocPath),function(e,o,i){var a,s=!0;return p(o)&&(m(t.refPreProcessor,"Undefined")||(o=t.refPreProcessor(n(o),i)),a=O(o),m(t.refPostProcessor,"Undefined")||(a=t.refPostProcessor(a,i)),t.filter(a,i)&&(r[P(i)]=a),u(o).length>0&&(s=!1)),s}),r}function k(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=x(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(U[e]),i=n(t),a=y(e);return m(o.refs,"Undefined")&&(delete i.filter,delete i.subDocPath,i.includeInvalid=!0,U[e].refs=C(r,i)),m(t.filter,"Undefined")||(i.filter=t.filter),m(a.fragment,"Undefined")?m(a.subDocPath,"Undefined")||(i.subDocPath=t.subDocPath):i.subDocPath=S(decodeURI(a.fragment)),{refs:C(r,i),value:r}})}function O(e){var t,r,n,o={def:e};try{p(e,!0)?(t=e.$ref,n=H[t],m(n,"Undefined")&&(n=H[t]=y(t)),o.uri=t,o.uriDetails=n,m(n.error,"Undefined")?o.type=f(o):(o.error=o.uriDetails.error,o.type="invalid"),r=u(e),r.length>0&&(o.warning="Extra JSON Reference properties will be ignored: "+r.join(", "))):o.type="invalid"}catch(e){o.error=e.message,o.type="invalid"}return o}function T(e,t){var r,n=!0;try{if(!m(e,"String"))throw new Error("ptr is not a String");if(""!==e){if(r=e.charAt(0),["#","/"].indexOf(r)===-1)throw new Error("ptr must start with a / or #/");if("#"===r&&"#"!==e&&"/"!==e.charAt(1))throw new Error("ptr must start with a / or #/");if(e.match(q))throw new Error("ptr has invalid token(s)")}}catch(e){if(t===!0)throw e;n=!1}return n}function A(e,t){return p(e,t)&&"invalid"!==O(e,t).type}function S(e){if(!T(e))throw new Error("ptr must be a JSON Pointer");var t=e.split("/");return t.shift(),E(t)}function P(e,t){if(!m(e,"Array"))throw new Error("path must be an Array");return(t!==!1?"#":"")+(e.length>0?"/":"")+$(e).join("/")}function M(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");t=x(t,e),e=n(e)}).then(function(){return l(e,t,[],[],{documents:{},refs:{}})}).then(function(t){function r(e,t){return S(e).length-S(t).length}var n={},o={};return Object.keys(t.refs).sort(r).forEach(function(r){var i=t.refs[r];i.indirect||(o[r]=i),delete i.indirect,m(i.error,"Undefined")&&"invalid"!==i.type?(m(i.value,"Undefined")&&i.circular&&(i.value=i.def),m(i.value,"Undefined")?n[r]=i:("#"===r?e=i.value:g(e,S(r),i.value),delete i.ancestorPtrs)):delete i.ancestorPtrs}),Object.keys(n).forEach(function(r){var o=n[r];o.ancestorPtrs.forEach(function(n,i){if(m(o.value,"Undefined"))try{o.value=c(t.documents[n],S(o.uri)),delete o.ancestorPtrs,g(e,S(r),o.value)}catch(e){i===o.ancestorPtrs.length-1&&(o.error=e.message,o.missing=!0,delete o.ancestorPtrs)}})}),{refs:o,resolved:e}})}function j(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=x(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(t),i=y(e);return m(i.fragment,"Undefined")||(o.subDocPath=S(decodeURI(i.fragment))),o.relativeBase=D.dirname(e),M(r,o).then(function(e){return{refs:e.refs,resolved:e.resolved,value:r}})})}var D=e("path"),I=e("path-loader"),_=e("querystring"),F=e("slash"),R=e("uri-js"),q=/~(?:[^01]|$)/g,U={},N=["relative","remote"],L=["absolute","uri"],H={};"undefined"==typeof Promise&&e("native-promise-only"),t.exports.clearCache=w,t.exports.decodePath=E,t.exports.encodePath=$,t.exports.findRefs=C,t.exports.findRefsAt=k,t.exports.getRefDetails=O,t.exports.isPtr=T,t.exports.isRef=A,t.exports.pathFromPtr=S,t.exports.pathToPtr=P,t.exports.resolveRefs=M,t.exports.resolveRefsAt=j},{"native-promise-only":3,path:4,"path-loader":5,querystring:11,slash:13,"uri-js":23}],2:[function(e,t,r){function n(e){if(e)return o(e)}function o(e){for(var t in n.prototype)e[t]=n.prototype[t];return e}t.exports=n,n.prototype.on=n.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},n.prototype.once=function(e,t){function r(){this.off(e,r),t.apply(this,arguments)}return r.fn=t,this.on(e,r),this},n.prototype.off=n.prototype.removeListener=n.prototype.removeAllListeners=n.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var n,o=0;o<r.length;o++)if(n=r[o],n===t||n.fn===t){r.splice(o,1);break}return this},n.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),r=this._callbacks["$"+e];if(r){r=r.slice(0);for(var n=0,o=r.length;n<o;++n)r[n].apply(this,t)}return this},n.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},n.prototype.hasListeners=function(e){return!!this.listeners(e).length}},{}],3:[function(n,o,i){(function(t){/*! Native Promise Only
     v0.8.1 (c) Kyle Simpson
     MIT License: http://getify.mit-license.org
 */
-!function(t,r,n){r[t]=r[t]||n(),"undefined"!=typeof o&&o.exports?o.exports=r[t]:"function"==typeof e&&e.amd&&e(function(){return r[t]})}("Promise","undefined"!=typeof t?t:this,function(){"use strict";function e(e,t){m.add(e,t),p||(p=v(m.drain))}function t(e){var t,r="undefined"==typeof e?"undefined":c(e);return null==e||"object"!=r&&"function"!=r||(t=e.then),"function"==typeof t&&t}function n(){for(var e=0;e<this.chain.length;e++)o(this,1===this.state?this.chain[e].success:this.chain[e].failure,this.chain[e]);this.chain.length=0}function o(e,r,n){var o,i;try{r===!1?n.reject(e.msg):(o=r===!0?e.msg:r.call(void 0,e.msg),o===n.promise?n.reject(TypeError("Promise-chain cycle")):(i=t(o))?i.call(o,n.resolve,n.reject):n.resolve(o))}catch(e){n.reject(e)}}function i(r){var o,s=this;if(!s.triggered){s.triggered=!0,s.def&&(s=s.def);try{(o=t(r))?e(function(){var e=new l(s);try{o.call(r,function(){i.apply(e,arguments)},function(){a.apply(e,arguments)})}catch(t){a.call(e,t)}}):(s.msg=r,s.state=1,s.chain.length>0&&e(n,s))}catch(e){a.call(new l(s),e)}}}function a(t){var r=this;r.triggered||(r.triggered=!0,r.def&&(r=r.def),r.msg=t,r.state=2,r.chain.length>0&&e(n,r))}function s(e,t,r,n){for(var o=0;o<t.length;o++)!function(o){e.resolve(t[o]).then(function(e){r(o,e)},n)}(o)}function l(e){this.def=e,this.triggered=!1}function u(e){this.promise=e,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function f(t){if("function"!=typeof t)throw TypeError("Not a function");if(0!==this.__NPO__)throw TypeError("Not a promise");this.__NPO__=1;var r=new u(this);this.then=function(t,o){var i={success:"function"!=typeof t||t,failure:"function"==typeof o&&o};return i.promise=new this.constructor(function(e,t){if("function"!=typeof e||"function"!=typeof t)throw TypeError("Not a function");i.resolve=e,i.reject=t}),r.chain.push(i),0!==r.state&&e(n,r),i.promise},this.catch=function(e){return this.then(void 0,e)};try{t.call(void 0,function(e){i.call(r,e)},function(e){a.call(r,e)})}catch(e){a.call(r,e)}}var d,p,m,h=Object.prototype.toString,v="undefined"!=typeof r?function(e){return r(e)}:setTimeout;try{Object.defineProperty({},"x",{}),d=function(e,t,r,n){return Object.defineProperty(e,t,{value:r,writable:!0,configurable:n!==!1})}}catch(e){d=function(e,t,r){return e[t]=r,e}}m=function(){function e(e,t){this.fn=e,this.self=t,this.next=void 0}var t,r,n;return{add:function(o,i){n=new e(o,i),r?r.next=n:t=n,r=n,n=void 0},drain:function(){var e=t;for(t=r=p=void 0;e;)e.fn.call(e.self),e=e.next}}}();var y=d({},"constructor",f,!1);return f.prototype=y,d(y,"__NPO__",0,!1),d(f,"resolve",function(e){var t=this;return e&&"object"==("undefined"==typeof e?"undefined":c(e))&&1===e.__NPO__?e:new t(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");t(e)})}),d(f,"reject",function(e){return new this(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");r(e)})}),d(f,"all",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):0===e.length?t.resolve([]):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");var o=e.length,i=Array(o),a=0;s(t,e,function(e,t){i[e]=t,++a===o&&r(i)},n)})}),d(f,"race",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");s(t,e,function(e,t){r(t)},n)})}),f})}).call(this,"undefined"!=typeof t?t:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],4:[function(e,t,r){(function(e){function t(e,t){for(var r=0,n=e.length-1;n>=0;n--){var o=e[n];"."===o?e.splice(n,1):".."===o?(e.splice(n,1),r++):r&&(e.splice(n,1),r--)}if(t)for(;r--;r)e.unshift("..");return e}function n(e,t){if(e.filter)return e.filter(t);for(var r=[],n=0;n<e.length;n++)t(e[n],n,e)&&r.push(e[n]);return r}var o=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,i=function(e){return o.exec(e).slice(1)};r.resolve=function(){for(var r="",o=!1,i=arguments.length-1;i>=-1&&!o;i--){var a=i>=0?arguments[i]:e.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(r=a+"/"+r,o="/"===a.charAt(0))}return r=t(n(r.split("/"),function(e){return!!e}),!o).join("/"),(o?"/":"")+r||"."},r.normalize=function(e){var o=r.isAbsolute(e),i="/"===a(e,-1);return e=t(n(e.split("/"),function(e){return!!e}),!o).join("/"),e||o||(e="."),e&&i&&(e+="/"),(o?"/":"")+e},r.isAbsolute=function(e){return"/"===e.charAt(0)},r.join=function(){var e=Array.prototype.slice.call(arguments,0);return r.normalize(n(e,function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e}).join("/"))},r.relative=function(e,t){function n(e){for(var t=0;t<e.length&&""===e[t];t++);for(var r=e.length-1;r>=0&&""===e[r];r--);return t>r?[]:e.slice(t,r-t+1)}e=r.resolve(e).substr(1),t=r.resolve(t).substr(1);for(var o=n(e.split("/")),i=n(t.split("/")),a=Math.min(o.length,i.length),s=a,l=0;l<a;l++)if(o[l]!==i[l]){s=l;break}for(var c=[],l=s;l<o.length;l++)c.push("..");return c=c.concat(i.slice(s)),c.join("/")},r.sep="/",r.delimiter=":",r.dirname=function(e){var t=i(e),r=t[0],n=t[1];return r||n?(n&&(n=n.substr(0,n.length-1)),r+n):"."},r.basename=function(e,t){var r=i(e)[2];return t&&r.substr(-1*t.length)===t&&(r=r.substr(0,r.length-t.length)),r},r.extname=function(e){return i(e)[3]};var a="b"==="ab".substr(-1)?function(e,t,r){return e.substr(t,r)}:function(e,t,r){return t<0&&(t=e.length+t),e.substr(t,r)}}).call(this,e("_process"))},{_process:8}],5:[function(e,t,r){"use strict";function n(e){return"undefined"!=typeof e&&(e=e.indexOf("://")===-1?"":e.split("://")[0]),e}function o(e){var t=n(e),r=i[t];if("undefined"==typeof r){if(""!==t)throw new Error("Unsupported scheme: "+t);r=a}return r}var i={file:e("./lib/loaders/file"),http:e("./lib/loaders/http"),https:e("./lib/loaders/http")},a="object"===("undefined"==typeof window?"undefined":c(window))||"function"==typeof importScripts?i.http:i.file;"undefined"==typeof Promise&&e("native-promise-only"),t.exports.load=function(e,t){var r=Promise.resolve();return"undefined"==typeof t&&(t={}),r=r.then(function(){if("undefined"==typeof e)throw new TypeError("location is required");if("string"!=typeof e)throw new TypeError("location must be a string");if("undefined"!=typeof t){if("object"!==("undefined"==typeof t?"undefined":c(t)))throw new TypeError("options must be an object");if("undefined"!=typeof t.processContent&&"function"!=typeof t.processContent)throw new TypeError("options.processContent must be a function")}}),r=r.then(function(){return new Promise(function(r,n){var i=o(e);i.load(e,t||{},function(e,t){e?n(e):r(t)})})}).then(function(e){return t.processContent?new Promise(function(r,n){t.processContent("object"===("undefined"==typeof e?"undefined":c(e))?e:{text:e},function(e,t){e?n(e):r(t)})}):"object"===("undefined"==typeof e?"undefined":c(e))?e.text:e})}},{"./lib/loaders/file":6,"./lib/loaders/http":7,"native-promise-only":3}],6:[function(e,t,r){"use strict";var n=new TypeError("The 'file' scheme is not supported in the browser");t.exports.getBase=function(){throw n},t.exports.load=function(){var e=arguments[arguments.length-1];if("function"!=typeof e)throw n;e(n)}},{}],7:[function(e,t,r){"use strict";var n=e("superagent"),o=["delete","get","head","patch","post","put"];t.exports.load=function(e,t,r){function i(e,t){e?r(e):("function"==typeof t.buffer&&t.buffer(!0),t.end(function(e,t){e?r(e):r(void 0,t)}))}var a,s,l=t.method?t.method.toLowerCase():"get";if("undefined"!=typeof t.method?"string"!=typeof t.method?a=new TypeError("options.method must be a string"):o.indexOf(t.method)===-1&&(a=new TypeError("options.method must be one of the following: "+o.slice(0,o.length-1).join(", ")+" or "+o[o.length-1])):"undefined"!=typeof t.prepareRequest&&"function"!=typeof t.prepareRequest&&(a=new TypeError("options.prepareRequest must be a function")),a)r(a);else if(s=n["delete"===l?"del":l](e),t.prepareRequest)try{t.prepareRequest(s,i)}catch(e){r(e)}else i(void 0,s)}},{superagent:14}],8:[function(e,t,r){function n(){u=!1,s.length?c=s.concat(c):f=-1,c.length&&o()}function o(){if(!u){var e=setTimeout(n);u=!0;for(var t=c.length;t;){for(s=c,c=[];++f<t;)s&&s[f].run();f=-1,t=c.length}s=null,u=!1,clearTimeout(e)}}function i(e,t){this.fun=e,this.array=t}function a(){}var s,l=t.exports={},c=[],u=!1,f=-1;l.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];c.push(new i(e,t)),1!==c.length||u||setTimeout(o,0)},i.prototype.run=function(){this.fun.apply(null,this.array)},l.title="browser",l.browser=!0,l.env={},l.argv=[],l.version="",l.versions={},l.on=a,l.addListener=a,l.once=a,l.off=a,l.removeListener=a,l.removeAllListeners=a,l.emit=a,l.binding=function(e){throw new Error("process.binding is not supported")},l.cwd=function(){return"/"},l.chdir=function(e){throw new Error("process.chdir is not supported")},l.umask=function(){return 0}},{}],9:[function(e,t,r){"use strict";function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.exports=function(e,t,r,i){t=t||"&",r=r||"=";var a={};if("string"!=typeof e||0===e.length)return a;var s=/\+/g;e=e.split(t);var l=1e3;i&&"number"==typeof i.maxKeys&&(l=i.maxKeys);var c=e.length;l>0&&c>l&&(c=l);for(var u=0;u<c;++u){var f,d,p,m,h=e[u].replace(s,"%20"),v=h.indexOf(r);v>=0?(f=h.substr(0,v),d=h.substr(v+1)):(f=h,d=""),p=decodeURIComponent(f),m=decodeURIComponent(d),n(a,p)?o(a[p])?a[p].push(m):a[p]=[a[p],m]:a[p]=m}return a};var o=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},{}],10:[function(e,t,r){"use strict";function n(e,t){if(e.map)return e.map(t);for(var r=[],n=0;n<e.length;n++)r.push(t(e[n],n));return r}var o=function(e){switch("undefined"==typeof e?"undefined":c(e)){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};t.exports=function(e,t,r,s){return t=t||"&",r=r||"=",null===e&&(e=void 0),"object"===("undefined"==typeof e?"undefined":c(e))?n(a(e),function(a){var s=encodeURIComponent(o(a))+r;return i(e[a])?n(e[a],function(e){return s+encodeURIComponent(o(e))}).join(t):s+encodeURIComponent(o(e[a]))}).join(t):s?encodeURIComponent(o(s))+r+encodeURIComponent(o(e)):""};var i=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},a=Object.keys||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t}},{}],11:[function(e,t,r){"use strict";r.decode=r.parse=e("./decode"),r.encode=r.stringify=e("./encode")},{"./decode":9,"./encode":10}],12:[function(e,t,r){t.exports=function(e,t,r){for(var n=0,o=e.length,i=3==arguments.length?r:e[n++];n<o;)i=t.call(null,i,e[n],++n,e);return i}},{}],13:[function(e,t,r){"use strict";t.exports=function(e){var t=/^\\\\\?\\/.test(e),r=/[^\x00-\x80]+/.test(e);return t||r?e:e.replace(/\\/g,"/")}},{}],14:[function(e,t,r){function n(){}function o(e){var t={}.toString.call(e);switch(t){case"[object File]":case"[object Blob]":case"[object FormData]":return!0;default:return!1}}function i(e){if(!b(e))return e;var t=[];for(var r in e)null!=e[r]&&a(t,r,e[r]);return t.join("&")}function a(e,t,r){return Array.isArray(r)?r.forEach(function(r){a(e,t,r)}):void e.push(encodeURIComponent(t)+"="+encodeURIComponent(r))}function s(e){for(var t,r,n={},o=e.split("&"),i=0,a=o.length;i<a;++i)r=o[i],t=r.split("="),n[decodeURIComponent(t[0])]=decodeURIComponent(t[1]);return n}function l(e){var t,r,n,o,i=e.split(/\r?\n/),a={};i.pop();for(var s=0,l=i.length;s<l;++s)r=i[s],t=r.indexOf(":"),n=r.slice(0,t).toLowerCase(),o=x(r.slice(t+1)),a[n]=o;return a}function c(e){return/[\/+]json\b/.test(e)}function u(e){return e.split(/ *; */).shift()}function f(e){return y(e.split(/ *; */),function(e,t){var r=t.split(/ *= */),n=r.shift(),o=r.shift();return n&&o&&(e[n]=o),e},{})}function d(e,t){t=t||{},this.req=e,this.xhr=this.req.xhr,this.text="HEAD"!=this.req.method&&(""===this.xhr.responseType||"text"===this.xhr.responseType)||"undefined"==typeof this.xhr.responseType?this.xhr.responseText:null,this.statusText=this.req.xhr.statusText,this.setStatusProperties(this.xhr.status),this.header=this.headers=l(this.xhr.getAllResponseHeaders()),this.header["content-type"]=this.xhr.getResponseHeader("content-type"),this.setHeaderProperties(this.header),this.body="HEAD"!=this.req.method?this.parseBody(this.text?this.text:this.xhr.response):null}function p(e,t){var r=this;this._query=this._query||[],this.method=e,this.url=t,this.header={},this._header={},this.on("end",function(){var e=null,t=null;try{t=new d(r)}catch(t){return e=new Error("Parser is unable to parse the response"),e.parse=!0,e.original=t,e.rawResponse=r.xhr&&r.xhr.responseText?r.xhr.responseText:null,e.statusCode=r.xhr&&r.xhr.status?r.xhr.status:null,r.callback(e)}if(r.emit("response",t),e)return r.callback(e,t);if(t.status>=200&&t.status<300)return r.callback(e,t);var n=new Error(t.statusText||"Unsuccessful HTTP response");n.original=e,n.response=t,n.status=t.status,r.callback(n,t)})}function m(e,t){var r=w("DELETE",e);return t&&r.end(t),r}var h,v=e("emitter"),y=e("reduce"),g=e("./request-base"),b=e("./is-object");h="undefined"!=typeof window?window:"undefined"!=typeof self?self:this;var w=t.exports=e("./request").bind(null,p);w.getXHR=function(){if(!(!h.XMLHttpRequest||h.location&&"file:"==h.location.protocol&&h.ActiveXObject))return new XMLHttpRequest;try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(e){}return!1};var x="".trim?function(e){return e.trim()}:function(e){return e.replace(/(^\s*|\s*$)/g,"")};w.serializeObject=i,w.parseString=s,w.types={html:"text/html",json:"application/json",xml:"application/xml",urlencoded:"application/x-www-form-urlencoded",form:"application/x-www-form-urlencoded","form-data":"application/x-www-form-urlencoded"},w.serialize={"application/x-www-form-urlencoded":i,"application/json":JSON.stringify},w.parse={"application/x-www-form-urlencoded":s,"application/json":JSON.parse},d.prototype.get=function(e){return this.header[e.toLowerCase()]},d.prototype.setHeaderProperties=function(e){var t=this.header["content-type"]||"";this.type=u(t);var r=f(t);for(var n in r)this[n]=r[n]},d.prototype.parseBody=function(e){var t=w.parse[this.type];return!t&&c(this.type)&&(t=w.parse["application/json"]),t&&e&&(e.length||e instanceof Object)?t(e):null},d.prototype.setStatusProperties=function(e){1223===e&&(e=204);var t=e/100|0;this.status=this.statusCode=e,this.statusType=t,this.info=1==t,this.ok=2==t,this.clientError=4==t,this.serverError=5==t,this.error=(4==t||5==t)&&this.toError(),this.accepted=202==e,this.noContent=204==e,this.badRequest=400==e,this.unauthorized=401==e,this.notAcceptable=406==e,this.notFound=404==e,this.forbidden=403==e},d.prototype.toError=function(){var e=this.req,t=e.method,r=e.url,n="cannot "+t+" "+r+" ("+this.status+")",o=new Error(n);return o.status=this.status,o.method=t,o.url=r,o},w.Response=d,v(p.prototype);for(var E in g)p.prototype[E]=g[E];p.prototype.abort=function(){if(!this.aborted)return this.aborted=!0,this.xhr.abort(),this.clearTimeout(),this.emit("abort"),this},p.prototype.type=function(e){return this.set("Content-Type",w.types[e]||e),this},p.prototype.responseType=function(e){return this._responseType=e,this},p.prototype.accept=function(e){return this.set("Accept",w.types[e]||e),this},p.prototype.auth=function(e,t,r){switch(r||(r={type:"basic"}),r.type){case"basic":var n=btoa(e+":"+t);this.set("Authorization","Basic "+n);break;case"auto":this.username=e,this.password=t}return this},p.prototype.query=function(e){return"string"!=typeof e&&(e=i(e)),e&&this._query.push(e),this},p.prototype.attach=function(e,t,r){return this._getFormData().append(e,t,r||t.name),this},p.prototype._getFormData=function(){return this._formData||(this._formData=new h.FormData),this._formData},p.prototype.send=function(e){var t=b(e),r=this._header["content-type"];if(t&&b(this._data))for(var n in e)this._data[n]=e[n];else"string"==typeof e?(r||this.type("form"),r=this._header["content-type"],"application/x-www-form-urlencoded"==r?this._data=this._data?this._data+"&"+e:e:this._data=(this._data||"")+e):this._data=e;return!t||o(e)?this:(r||this.type("json"),this)},d.prototype.parse=function(e){return h.console&&console.warn("Client-side parse() method has been renamed to serialize(). This method is not compatible with superagent v2.0"),this.serialize(e),this},d.prototype.serialize=function(e){return this._parser=e,this},p.prototype.callback=function(e,t){var r=this._callback;this.clearTimeout(),r(e,t)},p.prototype.crossDomainError=function(){var e=new Error("Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.");e.crossDomain=!0,e.status=this.status,e.method=this.method,e.url=this.url,this.callback(e)},p.prototype.timeoutError=function(){var e=this._timeout,t=new Error("timeout of "+e+"ms exceeded");t.timeout=e,this.callback(t)},p.prototype.withCredentials=function(){return this._withCredentials=!0,this},p.prototype.end=function(e){var t=this,r=this.xhr=w.getXHR(),i=this._query.join("&"),a=this._timeout,s=this._formData||this._data;this._callback=e||n,r.onreadystatechange=function(){if(4==r.readyState){var e;try{e=r.status}catch(t){e=0}if(0==e){if(t.timedout)return t.timeoutError();if(t.aborted)return;return t.crossDomainError()}t.emit("end")}};var l=function(e){e.total>0&&(e.percent=e.loaded/e.total*100),e.direction="download",t.emit("progress",e)};this.hasListeners("progress")&&(r.onprogress=l);try{r.upload&&this.hasListeners("progress")&&(r.upload.onprogress=l)}catch(e){}if(a&&!this._timer&&(this._timer=setTimeout(function(){t.timedout=!0,t.abort()},a)),i&&(i=w.serializeObject(i),this.url+=~this.url.indexOf("?")?"&"+i:"?"+i),this.username&&this.password?r.open(this.method,this.url,!0,this.username,this.password):r.open(this.method,this.url,!0),this._withCredentials&&(r.withCredentials=!0),"GET"!=this.method&&"HEAD"!=this.method&&"string"!=typeof s&&!o(s)){var u=this._header["content-type"],f=this._parser||w.serialize[u?u.split(";")[0]:""];!f&&c(u)&&(f=w.serialize["application/json"]),f&&(s=f(s))}for(var d in this.header)null!=this.header[d]&&r.setRequestHeader(d,this.header[d]);return this._responseType&&(r.responseType=this._responseType),this.emit("request",this),r.send("undefined"!=typeof s?s:null),this},w.Request=p,w.get=function(e,t,r){var n=w("GET",e);return"function"==typeof t&&(r=t,t=null),t&&n.query(t),r&&n.end(r),n},w.head=function(e,t,r){var n=w("HEAD",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},w.del=m,w.delete=m,w.patch=function(e,t,r){var n=w("PATCH",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},w.post=function(e,t,r){var n=w("POST",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},w.put=function(e,t,r){var n=w("PUT",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n}},{"./is-object":15,"./request":17,"./request-base":16,emitter:2,reduce:12}],15:[function(e,t,r){function n(e){return null!=e&&"object"==("undefined"==typeof e?"undefined":c(e))}t.exports=n},{}],16:[function(e,t,r){var n=e("./is-object");r.clearTimeout=function(){return this._timeout=0,clearTimeout(this._timer),this},r.parse=function(e){return this._parser=e,this},r.timeout=function(e){return this._timeout=e,this},r.then=function(e,t){return this.end(function(r,n){r?t(r):e(n)})},r.use=function(e){return e(this),this},r.get=function(e){return this._header[e.toLowerCase()]},r.getHeader=r.get,r.set=function(e,t){if(n(e)){for(var r in e)this.set(r,e[r]);return this}return this._header[e.toLowerCase()]=t,this.header[e]=t,this},r.unset=function(e){return delete this._header[e.toLowerCase()],delete this.header[e],this},r.field=function(e,t){return this._getFormData().append(e,t),this}},{"./is-object":15}],17:[function(e,t,r){function n(e,t,r){return"function"==typeof r?new e("GET",t).end(r):2==arguments.length?new e("GET",t):new e(t,r)}t.exports=n},{}],18:[function(e,t,r){/*! https://mths.be/punycode v1.3.2 by @mathias, modified for URI.js */var n=function(){function e(e){throw new RangeError(k[e])}function t(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function r(e,r){var n=e.split("@"),o="";n.length>1&&(o=n[0]+"@",e=n[1]),e=e.replace(C,".");var i=e.split("."),a=t(i,r).join(".");return o+a}function n(e){for(var t,r,n=[],o=0,i=e.length;o<i;)t=e.charCodeAt(o++),t>=55296&&t<=56319&&o<i?(r=e.charCodeAt(o++),56320==(64512&r)?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),o--)):n.push(t);return n}function o(e){return t(e,function(e){var t="";return e>65535&&(e-=65536,t+=O(e>>>10&1023|55296),e=56320|1023&e),t+=O(e)}).join("")}function i(e){return e-48<10?e-22:e-65<26?e-65:e-97<26?e-97:m}function a(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function s(e,t,r){var n=0;for(e=r?T(e/g):e>>1,e+=T(e/t);e>A*v>>1;n+=m)e=T(e/A);return T(n+(A+1)*e/(e+y))}function l(t){var r,n,a,l,c,u,f,d,y,g,E=[],$=t.length,C=0,k=w,A=b;for(n=t.lastIndexOf(x),n<0&&(n=0),a=0;a<n;++a)t.charCodeAt(a)>=128&&e("not-basic"),E.push(t.charCodeAt(a));for(l=n>0?n+1:0;l<$;){for(c=C,u=1,f=m;l>=$&&e("invalid-input"),d=i(t.charCodeAt(l++)),(d>=m||d>T((p-C)/u))&&e("overflow"),C+=d*u,y=f<=A?h:f>=A+v?v:f-A,!(d<y);f+=m)g=m-y,u>T(p/g)&&e("overflow"),u*=g;r=E.length+1,A=s(C-c,r,0==c),T(C/r)>p-k&&e("overflow"),k+=T(C/r),C%=r,E.splice(C++,0,k)}return o(E)}function c(t){var r,o,i,l,c,u,f,d,y,g,E,$,C,k,A,S=[];for(t=n(t),$=t.length,r=w,o=0,c=b,u=0;u<$;++u)E=t[u],E<128&&S.push(O(E));for(i=l=S.length,l&&S.push(x);i<$;){for(f=p,u=0;u<$;++u)E=t[u],E>=r&&E<f&&(f=E);for(C=i+1,f-r>T((p-o)/C)&&e("overflow"),o+=(f-r)*C,r=f,u=0;u<$;++u)if(E=t[u],E<r&&++o>p&&e("overflow"),E==r){for(d=o,y=m;g=y<=c?h:y>=c+v?v:y-c,!(d<g);y+=m)A=d-g,k=m-g,S.push(O(a(g+A%k,0))),d=T(A/k);S.push(O(a(d,0))),c=s(o,C,i==l),o=0,++i}++o,++r}return S.join("")}function u(e){return r(e,function(e){return E.test(e)?l(e.slice(4).toLowerCase()):e})}function f(e){return r(e,function(e){return $.test(e)?"xn--"+c(e):e})}var d,p=2147483647,m=36,h=1,v=26,y=38,g=700,b=72,w=128,x="-",E=/^xn--/,$=/[^\x20-\x7E]/,C=/[\x2E\u3002\uFF0E\uFF61]/g,k={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},A=m-h,T=Math.floor,O=String.fromCharCode;return d={version:"1.3.2",ucs2:{decode:n,encode:o},decode:l,encode:c,toASCII:f,toUnicode:u}}();"undefined"==typeof COMPILED&&"undefined"!=typeof t&&(t.exports=n)},{}],19:[function(e,t,r){e("./schemes/http"),e("./schemes/urn"),e("./schemes/mailto")},{"./schemes/http":20,"./schemes/mailto":21,"./schemes/urn":22}],20:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");n.SCHEMES.http=n.SCHEMES.https={domainHost:!0,parse:function(e,t){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e},serialize:function(e,t){return e.port!==("https"!==String(e.scheme).toLowerCase()?80:443)&&""!==e.port||(e.port=void 0),e.path||(e.path="/"),e}}},{"../uri":23}],21:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri"),o=e("../punycode");!function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(e){return e.toUpperCase()}function i(e){var t=n.pctDecChars(e);return t.match(M)?t:e}function a(e){return void 0!==e&&null!==e?e instanceof Array&&!e.callee?e:"number"!=typeof e.length||e.split||e.setInterval||e.call?[e]:Array.prototype.slice.call(e):[]}var s={},l=n.IRI_SUPPORT,c="[A-Za-z0-9\\-\\.\\_\\~"+(l?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",u="[0-9A-Fa-f]",f=t(t("%[EFef]"+u+"%"+u+u+"%"+u+u)+"|"+t("%[89A-Fa-f]"+u+"%"+u+u)+"|"+t("%"+u+u)),d="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",p="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",m=e(p,'[\\"\\\\]'),h=t(d+"+"+t("\\."+d+"+")+"*"),v=t("\\\\"+m),y=t(p+"|"+v),g=t('\\"'+y+'*\\"'),b="[\\x21-\\x5A\\x5E-\\x7E]",w="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",x=t(c+"|"+f+"|"+w),E=t(h+"|\\["+b+"*\\]"),$=t(h+"|"+g),C=t($+"\\@"+E),k=t(C+t("\\,"+C)+"*"),A=t(x+"*"),T=A,O=t(A+"\\="+T),S=t(O+t("\\&"+O)+"*"),P=t("\\?"+S),M=(n.VALIDATE_SUPPORT&&new RegExp("^mailto\\:"+k+"?"+P+"?$"),new RegExp(c,"g")),j=new RegExp(f,"g"),D=new RegExp(e("[^]",d,"[\\.]",'[\\"]',m),"g"),I=new RegExp(e("[^]",d,"[\\.]","[\\[]",b,"[\\]]"),"g"),_=new RegExp(e("[^]",c,w),"g"),F=_,R=n.VALIDATE_SUPPORT&&new RegExp("^"+k+"$"),q=n.VALIDATE_SUPPORT&&new RegExp("^"+S+"$");n.SCHEMES.mailto={parse:function(e,t){n.VALIDATE_SUPPORT&&!e.error&&(e.path&&!R.test(e.path)?e.error="Email address is not valid":e.query&&!q.test(e.query)&&(e.error="Header fields are invalid"));var r=e.to=e.path?e.path.split(","):[];if(e.path=void 0,e.query){for(var i=!1,a={},s=e.query.split("&"),l=0,c=s.length;l<c;++l){var u=s[l].split("=");switch(u[0]){case"to":for(var f=u[1].split(","),d=0,p=f.length;d<p;++d)r.push(f[d]);break;case"subject":e.subject=n.unescapeComponent(u[1],t);break;case"body":e.body=n.unescapeComponent(u[1],t);break;default:i=!0,a[n.unescapeComponent(u[0],t)]=n.unescapeComponent(u[1],t)}}i&&(e.headers=a)}e.query=void 0;for(var l=0,c=r.length;l<c;++l){var m=r[l].split("@");if(m[0]=n.unescapeComponent(m[0]),"undefined"==typeof o||t.unicodeSupport)m[1]=n.unescapeComponent(m[1],t).toLowerCase();else try{m[1]=o.toASCII(n.unescapeComponent(m[1],t).toLowerCase())}catch(t){e.error=e.error||"Email address's domain name can not be converted to ASCII via punycode: "+t}r[l]=m.join("@")}return e},serialize:function(e,t){var l=a(e.to);if(l){for(var c=0,u=l.length;c<u;++c){var f=String(l[c]),d=f.lastIndexOf("@"),p=f.slice(0,d),m=f.slice(d+1);if(p=p.replace(j,i).replace(j,r).replace(D,n.pctEncChar),"undefined"!=typeof o)try{m=t.iri?o.toUnicode(m):o.toASCII(n.unescapeComponent(m,t).toLowerCase())}catch(r){e.error=e.error||"Email address's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}else m=m.replace(j,i).toLowerCase().replace(j,r).replace(I,n.pctEncChar);l[c]=p+"@"+m}e.path=l.join(",")}var h=e.headers=e.headers||{};e.subject&&(h.subject=e.subject),e.body&&(h.body=e.body);var v=[];for(var y in h)h[y]!==s[y]&&v.push(y.replace(j,i).replace(j,r).replace(_,n.pctEncChar)+"="+h[y].replace(j,i).replace(j,r).replace(F,n.pctEncChar));return v.length&&(e.query=v.join("&")),e}}}()},{"../punycode":18,"../uri":23}],22:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");!function(){var e=n.pctEncChar,t="(?:[0-9A-Za-z][0-9A-Za-z\\-]{1,31})",r="(?:\\%[0-9A-Fa-f]{2})",o="[0-9A-Za-z\\(\\)\\+\\,\\-\\.\\:\\=\\@\\;\\$\\_\\!\\*\\'\\/\\?\\#]",i="(?:(?:"+r+"|"+o+")+)",a=new RegExp("^urn\\:("+t+")$"),s=new RegExp("^("+t+")\\:("+i+")$"),l=/^([^\:]+)\:(.*)/,c=/[\x00-\x20\\\"\&\<\>\[\]\^\`\{\|\}\~\x7F-\xFF]/g,u=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/;n.SCHEMES.urn={parse:function(e,t){var r,o,i=e.path.match(s);return i||(t.tolerant||(e.error=e.error||"URN is not strictly valid."),i=e.path.match(l)),i?(r="urn:"+i[1].toLowerCase(),o=n.SCHEMES[r],o||(o=n.SCHEMES[r]={parse:function(e,t){return e},serialize:n.SCHEMES.urn.serialize}),e.scheme=r,e.path=i[2],e=o.parse(e,t)):e.error=e.error||"URN can not be parsed.",e},serialize:function(t,r){var n,o=t.scheme||r.scheme;if(o&&"urn"!==o){var n=o.match(a);n||(n=["urn:"+o,o]),t.scheme="urn",t.path=n[1]+":"+(t.path?t.path.replace(c,e):"")}return t}},n.SCHEMES["urn:uuid"]={parse:function(e,t){return t.tolerant||e.path&&e.path.match(u)||(e.error=e.error||"UUID is not valid."),e},serialize:function(e,t){return t.tolerant||e.path&&e.path.match(u)?e.path=(e.path||"").toLowerCase():e.scheme=void 0,n.SCHEMES.urn.serialize(e,t)}}}()},{"../uri":23}],23:[function(e,t,r){/**
+!function(t,r,n){r[t]=r[t]||n(),"undefined"!=typeof o&&o.exports?o.exports=r[t]:"function"==typeof e&&e.amd&&e(function(){return r[t]})}("Promise","undefined"!=typeof t?t:this,function(){"use strict";function e(e,t){m.add(e,t),p||(p=v(m.drain))}function t(e){var t,r="undefined"==typeof e?"undefined":c(e);return null==e||"object"!=r&&"function"!=r||(t=e.then),"function"==typeof t&&t}function n(){for(var e=0;e<this.chain.length;e++)o(this,1===this.state?this.chain[e].success:this.chain[e].failure,this.chain[e]);this.chain.length=0}function o(e,r,n){var o,i;try{r===!1?n.reject(e.msg):(o=r===!0?e.msg:r.call(void 0,e.msg),o===n.promise?n.reject(TypeError("Promise-chain cycle")):(i=t(o))?i.call(o,n.resolve,n.reject):n.resolve(o))}catch(e){n.reject(e)}}function i(r){var o,s=this;if(!s.triggered){s.triggered=!0,s.def&&(s=s.def);try{(o=t(r))?e(function(){var e=new l(s);try{o.call(r,function(){i.apply(e,arguments)},function(){a.apply(e,arguments)})}catch(t){a.call(e,t)}}):(s.msg=r,s.state=1,s.chain.length>0&&e(n,s))}catch(e){a.call(new l(s),e)}}}function a(t){var r=this;r.triggered||(r.triggered=!0,r.def&&(r=r.def),r.msg=t,r.state=2,r.chain.length>0&&e(n,r))}function s(e,t,r,n){for(var o=0;o<t.length;o++)!function(o){e.resolve(t[o]).then(function(e){r(o,e)},n)}(o)}function l(e){this.def=e,this.triggered=!1}function u(e){this.promise=e,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function f(t){if("function"!=typeof t)throw TypeError("Not a function");if(0!==this.__NPO__)throw TypeError("Not a promise");this.__NPO__=1;var r=new u(this);this.then=function(t,o){var i={success:"function"!=typeof t||t,failure:"function"==typeof o&&o};return i.promise=new this.constructor(function(e,t){if("function"!=typeof e||"function"!=typeof t)throw TypeError("Not a function");i.resolve=e,i.reject=t}),r.chain.push(i),0!==r.state&&e(n,r),i.promise},this.catch=function(e){return this.then(void 0,e)};try{t.call(void 0,function(e){i.call(r,e)},function(e){a.call(r,e)})}catch(e){a.call(r,e)}}var d,p,m,h=Object.prototype.toString,v="undefined"!=typeof r?function(e){return r(e)}:setTimeout;try{Object.defineProperty({},"x",{}),d=function(e,t,r,n){return Object.defineProperty(e,t,{value:r,writable:!0,configurable:n!==!1})}}catch(e){d=function(e,t,r){return e[t]=r,e}}m=function(){function e(e,t){this.fn=e,this.self=t,this.next=void 0}var t,r,n;return{add:function(o,i){n=new e(o,i),r?r.next=n:t=n,r=n,n=void 0},drain:function(){var e=t;for(t=r=p=void 0;e;)e.fn.call(e.self),e=e.next}}}();var y=d({},"constructor",f,!1);return f.prototype=y,d(y,"__NPO__",0,!1),d(f,"resolve",function(e){var t=this;return e&&"object"==("undefined"==typeof e?"undefined":c(e))&&1===e.__NPO__?e:new t(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");t(e)})}),d(f,"reject",function(e){return new this(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");r(e)})}),d(f,"all",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):0===e.length?t.resolve([]):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");var o=e.length,i=Array(o),a=0;s(t,e,function(e,t){i[e]=t,++a===o&&r(i)},n)})}),d(f,"race",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");s(t,e,function(e,t){r(t)},n)})}),f})}).call(this,"undefined"!=typeof t?t:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],4:[function(e,t,r){(function(e){function t(e,t){for(var r=0,n=e.length-1;n>=0;n--){var o=e[n];"."===o?e.splice(n,1):".."===o?(e.splice(n,1),r++):r&&(e.splice(n,1),r--)}if(t)for(;r--;r)e.unshift("..");return e}function n(e,t){if(e.filter)return e.filter(t);for(var r=[],n=0;n<e.length;n++)t(e[n],n,e)&&r.push(e[n]);return r}var o=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,i=function(e){return o.exec(e).slice(1)};r.resolve=function(){for(var r="",o=!1,i=arguments.length-1;i>=-1&&!o;i--){var a=i>=0?arguments[i]:e.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(r=a+"/"+r,o="/"===a.charAt(0))}return r=t(n(r.split("/"),function(e){return!!e}),!o).join("/"),(o?"/":"")+r||"."},r.normalize=function(e){var o=r.isAbsolute(e),i="/"===a(e,-1);return e=t(n(e.split("/"),function(e){return!!e}),!o).join("/"),e||o||(e="."),e&&i&&(e+="/"),(o?"/":"")+e},r.isAbsolute=function(e){return"/"===e.charAt(0)},r.join=function(){var e=Array.prototype.slice.call(arguments,0);return r.normalize(n(e,function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e}).join("/"))},r.relative=function(e,t){function n(e){for(var t=0;t<e.length&&""===e[t];t++);for(var r=e.length-1;r>=0&&""===e[r];r--);return t>r?[]:e.slice(t,r-t+1)}e=r.resolve(e).substr(1),t=r.resolve(t).substr(1);for(var o=n(e.split("/")),i=n(t.split("/")),a=Math.min(o.length,i.length),s=a,l=0;l<a;l++)if(o[l]!==i[l]){s=l;break}for(var c=[],l=s;l<o.length;l++)c.push("..");return c=c.concat(i.slice(s)),c.join("/")},r.sep="/",r.delimiter=":",r.dirname=function(e){var t=i(e),r=t[0],n=t[1];return r||n?(n&&(n=n.substr(0,n.length-1)),r+n):"."},r.basename=function(e,t){var r=i(e)[2];return t&&r.substr(-1*t.length)===t&&(r=r.substr(0,r.length-t.length)),r},r.extname=function(e){return i(e)[3]};var a="b"==="ab".substr(-1)?function(e,t,r){return e.substr(t,r)}:function(e,t,r){return t<0&&(t=e.length+t),e.substr(t,r)}}).call(this,e("_process"))},{_process:8}],5:[function(e,t,r){"use strict";function n(e){return"undefined"!=typeof e&&(e=e.indexOf("://")===-1?"":e.split("://")[0]),e}function o(e){var t=n(e),r=i[t];if("undefined"==typeof r){if(""!==t)throw new Error("Unsupported scheme: "+t);r=a}return r}var i={file:e("./lib/loaders/file"),http:e("./lib/loaders/http"),https:e("./lib/loaders/http")},a="object"===("undefined"==typeof window?"undefined":c(window))||"function"==typeof importScripts?i.http:i.file;"undefined"==typeof Promise&&e("native-promise-only"),t.exports.load=function(e,t){var r=Promise.resolve();return"undefined"==typeof t&&(t={}),r=r.then(function(){if("undefined"==typeof e)throw new TypeError("location is required");if("string"!=typeof e)throw new TypeError("location must be a string");if("undefined"!=typeof t){if("object"!==("undefined"==typeof t?"undefined":c(t)))throw new TypeError("options must be an object");if("undefined"!=typeof t.processContent&&"function"!=typeof t.processContent)throw new TypeError("options.processContent must be a function")}}),r=r.then(function(){return new Promise(function(r,n){var i=o(e);i.load(e,t||{},function(e,t){e?n(e):r(t)})})}).then(function(e){return t.processContent?new Promise(function(r,n){t.processContent("object"===("undefined"==typeof e?"undefined":c(e))?e:{text:e},function(e,t){e?n(e):r(t)})}):"object"===("undefined"==typeof e?"undefined":c(e))?e.text:e})}},{"./lib/loaders/file":6,"./lib/loaders/http":7,"native-promise-only":3}],6:[function(e,t,r){"use strict";var n=new TypeError("The 'file' scheme is not supported in the browser");t.exports.getBase=function(){throw n},t.exports.load=function(){var e=arguments[arguments.length-1];if("function"!=typeof e)throw n;e(n)}},{}],7:[function(e,t,r){"use strict";var n=e("superagent"),o=["delete","get","head","patch","post","put"];t.exports.load=function(e,t,r){function i(e,t){e?r(e):("function"==typeof t.buffer&&t.buffer(!0),t.end(function(e,t){e?r(e):r(void 0,t)}))}var a,s,l=t.method?t.method.toLowerCase():"get";if("undefined"!=typeof t.method?"string"!=typeof t.method?a=new TypeError("options.method must be a string"):o.indexOf(t.method)===-1&&(a=new TypeError("options.method must be one of the following: "+o.slice(0,o.length-1).join(", ")+" or "+o[o.length-1])):"undefined"!=typeof t.prepareRequest&&"function"!=typeof t.prepareRequest&&(a=new TypeError("options.prepareRequest must be a function")),a)r(a);else if(s=n["delete"===l?"del":l](e),t.prepareRequest)try{t.prepareRequest(s,i)}catch(e){r(e)}else i(void 0,s)}},{superagent:14}],8:[function(e,t,r){function n(){u=!1,s.length?c=s.concat(c):f=-1,c.length&&o()}function o(){if(!u){var e=setTimeout(n);u=!0;for(var t=c.length;t;){for(s=c,c=[];++f<t;)s&&s[f].run();f=-1,t=c.length}s=null,u=!1,clearTimeout(e)}}function i(e,t){this.fun=e,this.array=t}function a(){}var s,l=t.exports={},c=[],u=!1,f=-1;l.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];c.push(new i(e,t)),1!==c.length||u||setTimeout(o,0)},i.prototype.run=function(){this.fun.apply(null,this.array)},l.title="browser",l.browser=!0,l.env={},l.argv=[],l.version="",l.versions={},l.on=a,l.addListener=a,l.once=a,l.off=a,l.removeListener=a,l.removeAllListeners=a,l.emit=a,l.binding=function(e){throw new Error("process.binding is not supported")},l.cwd=function(){return"/"},l.chdir=function(e){throw new Error("process.chdir is not supported")},l.umask=function(){return 0}},{}],9:[function(e,t,r){"use strict";function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.exports=function(e,t,r,i){t=t||"&",r=r||"=";var a={};if("string"!=typeof e||0===e.length)return a;var s=/\+/g;e=e.split(t);var l=1e3;i&&"number"==typeof i.maxKeys&&(l=i.maxKeys);var c=e.length;l>0&&c>l&&(c=l);for(var u=0;u<c;++u){var f,d,p,m,h=e[u].replace(s,"%20"),v=h.indexOf(r);v>=0?(f=h.substr(0,v),d=h.substr(v+1)):(f=h,d=""),p=decodeURIComponent(f),m=decodeURIComponent(d),n(a,p)?o(a[p])?a[p].push(m):a[p]=[a[p],m]:a[p]=m}return a};var o=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},{}],10:[function(e,t,r){"use strict";function n(e,t){if(e.map)return e.map(t);for(var r=[],n=0;n<e.length;n++)r.push(t(e[n],n));return r}var o=function(e){switch("undefined"==typeof e?"undefined":c(e)){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};t.exports=function(e,t,r,s){return t=t||"&",r=r||"=",null===e&&(e=void 0),"object"===("undefined"==typeof e?"undefined":c(e))?n(a(e),function(a){var s=encodeURIComponent(o(a))+r;return i(e[a])?n(e[a],function(e){return s+encodeURIComponent(o(e))}).join(t):s+encodeURIComponent(o(e[a]))}).join(t):s?encodeURIComponent(o(s))+r+encodeURIComponent(o(e)):""};var i=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},a=Object.keys||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t}},{}],11:[function(e,t,r){"use strict";r.decode=r.parse=e("./decode"),r.encode=r.stringify=e("./encode")},{"./decode":9,"./encode":10}],12:[function(e,t,r){t.exports=function(e,t,r){for(var n=0,o=e.length,i=3==arguments.length?r:e[n++];n<o;)i=t.call(null,i,e[n],++n,e);return i}},{}],13:[function(e,t,r){"use strict";t.exports=function(e){var t=/^\\\\\?\\/.test(e),r=/[^\x00-\x80]+/.test(e);return t||r?e:e.replace(/\\/g,"/")}},{}],14:[function(e,t,r){function n(){}function o(e){var t={}.toString.call(e);switch(t){case"[object File]":case"[object Blob]":case"[object FormData]":return!0;default:return!1}}function i(e){if(!b(e))return e;var t=[];for(var r in e)null!=e[r]&&a(t,r,e[r]);return t.join("&")}function a(e,t,r){return Array.isArray(r)?r.forEach(function(r){a(e,t,r)}):void e.push(encodeURIComponent(t)+"="+encodeURIComponent(r))}function s(e){for(var t,r,n={},o=e.split("&"),i=0,a=o.length;i<a;++i)r=o[i],t=r.split("="),n[decodeURIComponent(t[0])]=decodeURIComponent(t[1]);return n}function l(e){var t,r,n,o,i=e.split(/\r?\n/),a={};i.pop();for(var s=0,l=i.length;s<l;++s)r=i[s],t=r.indexOf(":"),n=r.slice(0,t).toLowerCase(),o=w(r.slice(t+1)),a[n]=o;return a}function c(e){return/[\/+]json\b/.test(e)}function u(e){return e.split(/ *; */).shift()}function f(e){return y(e.split(/ *; */),function(e,t){var r=t.split(/ *= */),n=r.shift(),o=r.shift();return n&&o&&(e[n]=o),e},{})}function d(e,t){t=t||{},this.req=e,this.xhr=this.req.xhr,this.text="HEAD"!=this.req.method&&(""===this.xhr.responseType||"text"===this.xhr.responseType)||"undefined"==typeof this.xhr.responseType?this.xhr.responseText:null,this.statusText=this.req.xhr.statusText,this.setStatusProperties(this.xhr.status),this.header=this.headers=l(this.xhr.getAllResponseHeaders()),this.header["content-type"]=this.xhr.getResponseHeader("content-type"),this.setHeaderProperties(this.header),this.body="HEAD"!=this.req.method?this.parseBody(this.text?this.text:this.xhr.response):null}function p(e,t){var r=this;this._query=this._query||[],this.method=e,this.url=t,this.header={},this._header={},this.on("end",function(){var e=null,t=null;try{t=new d(r)}catch(t){return e=new Error("Parser is unable to parse the response"),e.parse=!0,e.original=t,e.rawResponse=r.xhr&&r.xhr.responseText?r.xhr.responseText:null,e.statusCode=r.xhr&&r.xhr.status?r.xhr.status:null,r.callback(e)}if(r.emit("response",t),e)return r.callback(e,t);if(t.status>=200&&t.status<300)return r.callback(e,t);var n=new Error(t.statusText||"Unsuccessful HTTP response");n.original=e,n.response=t,n.status=t.status,r.callback(n,t)})}function m(e,t){var r=x("DELETE",e);return t&&r.end(t),r}var h,v=e("emitter"),y=e("reduce"),g=e("./request-base"),b=e("./is-object");h="undefined"!=typeof window?window:"undefined"!=typeof self?self:this;var x=t.exports=e("./request").bind(null,p);x.getXHR=function(){if(!(!h.XMLHttpRequest||h.location&&"file:"==h.location.protocol&&h.ActiveXObject))return new XMLHttpRequest;try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(e){}return!1};var w="".trim?function(e){return e.trim()}:function(e){return e.replace(/(^\s*|\s*$)/g,"")};x.serializeObject=i,x.parseString=s,x.types={html:"text/html",json:"application/json",xml:"application/xml",urlencoded:"application/x-www-form-urlencoded",form:"application/x-www-form-urlencoded","form-data":"application/x-www-form-urlencoded"},x.serialize={"application/x-www-form-urlencoded":i,"application/json":JSON.stringify},x.parse={"application/x-www-form-urlencoded":s,"application/json":JSON.parse},d.prototype.get=function(e){return this.header[e.toLowerCase()]},d.prototype.setHeaderProperties=function(e){var t=this.header["content-type"]||"";this.type=u(t);var r=f(t);for(var n in r)this[n]=r[n]},d.prototype.parseBody=function(e){var t=x.parse[this.type];return!t&&c(this.type)&&(t=x.parse["application/json"]),t&&e&&(e.length||e instanceof Object)?t(e):null},d.prototype.setStatusProperties=function(e){1223===e&&(e=204);var t=e/100|0;this.status=this.statusCode=e,this.statusType=t,this.info=1==t,this.ok=2==t,this.clientError=4==t,this.serverError=5==t,this.error=(4==t||5==t)&&this.toError(),this.accepted=202==e,this.noContent=204==e,this.badRequest=400==e,this.unauthorized=401==e,this.notAcceptable=406==e,this.notFound=404==e,this.forbidden=403==e},d.prototype.toError=function(){var e=this.req,t=e.method,r=e.url,n="cannot "+t+" "+r+" ("+this.status+")",o=new Error(n);return o.status=this.status,o.method=t,o.url=r,o},x.Response=d,v(p.prototype);for(var E in g)p.prototype[E]=g[E];p.prototype.abort=function(){if(!this.aborted)return this.aborted=!0,this.xhr.abort(),this.clearTimeout(),this.emit("abort"),this},p.prototype.type=function(e){return this.set("Content-Type",x.types[e]||e),this},p.prototype.responseType=function(e){return this._responseType=e,this},p.prototype.accept=function(e){return this.set("Accept",x.types[e]||e),this},p.prototype.auth=function(e,t,r){switch(r||(r={type:"basic"}),r.type){case"basic":var n=btoa(e+":"+t);this.set("Authorization","Basic "+n);break;case"auto":this.username=e,this.password=t}return this},p.prototype.query=function(e){return"string"!=typeof e&&(e=i(e)),e&&this._query.push(e),this},p.prototype.attach=function(e,t,r){return this._getFormData().append(e,t,r||t.name),this},p.prototype._getFormData=function(){return this._formData||(this._formData=new h.FormData),this._formData},p.prototype.send=function(e){var t=b(e),r=this._header["content-type"];if(t&&b(this._data))for(var n in e)this._data[n]=e[n];else"string"==typeof e?(r||this.type("form"),r=this._header["content-type"],"application/x-www-form-urlencoded"==r?this._data=this._data?this._data+"&"+e:e:this._data=(this._data||"")+e):this._data=e;return!t||o(e)?this:(r||this.type("json"),this)},d.prototype.parse=function(e){return h.console&&console.warn("Client-side parse() method has been renamed to serialize(). This method is not compatible with superagent v2.0"),this.serialize(e),this},d.prototype.serialize=function(e){return this._parser=e,this},p.prototype.callback=function(e,t){var r=this._callback;this.clearTimeout(),r(e,t)},p.prototype.crossDomainError=function(){var e=new Error("Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.");e.crossDomain=!0,e.status=this.status,e.method=this.method,e.url=this.url,this.callback(e)},p.prototype.timeoutError=function(){var e=this._timeout,t=new Error("timeout of "+e+"ms exceeded");t.timeout=e,this.callback(t)},p.prototype.withCredentials=function(){return this._withCredentials=!0,this},p.prototype.end=function(e){var t=this,r=this.xhr=x.getXHR(),i=this._query.join("&"),a=this._timeout,s=this._formData||this._data;this._callback=e||n,r.onreadystatechange=function(){if(4==r.readyState){var e;try{e=r.status}catch(t){e=0}if(0==e){if(t.timedout)return t.timeoutError();if(t.aborted)return;return t.crossDomainError()}t.emit("end")}};var l=function(e){e.total>0&&(e.percent=e.loaded/e.total*100),e.direction="download",t.emit("progress",e)};this.hasListeners("progress")&&(r.onprogress=l);try{r.upload&&this.hasListeners("progress")&&(r.upload.onprogress=l)}catch(e){}if(a&&!this._timer&&(this._timer=setTimeout(function(){t.timedout=!0,t.abort()},a)),i&&(i=x.serializeObject(i),this.url+=~this.url.indexOf("?")?"&"+i:"?"+i),this.username&&this.password?r.open(this.method,this.url,!0,this.username,this.password):r.open(this.method,this.url,!0),this._withCredentials&&(r.withCredentials=!0),"GET"!=this.method&&"HEAD"!=this.method&&"string"!=typeof s&&!o(s)){var u=this._header["content-type"],f=this._parser||x.serialize[u?u.split(";")[0]:""];!f&&c(u)&&(f=x.serialize["application/json"]),f&&(s=f(s))}for(var d in this.header)null!=this.header[d]&&r.setRequestHeader(d,this.header[d]);return this._responseType&&(r.responseType=this._responseType),this.emit("request",this),r.send("undefined"!=typeof s?s:null),this},x.Request=p,x.get=function(e,t,r){var n=x("GET",e);return"function"==typeof t&&(r=t,t=null),t&&n.query(t),r&&n.end(r),n},x.head=function(e,t,r){var n=x("HEAD",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.del=m,x.delete=m,x.patch=function(e,t,r){var n=x("PATCH",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.post=function(e,t,r){var n=x("POST",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.put=function(e,t,r){var n=x("PUT",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n}},{"./is-object":15,"./request":17,"./request-base":16,emitter:2,reduce:12}],15:[function(e,t,r){function n(e){return null!=e&&"object"==("undefined"==typeof e?"undefined":c(e))}t.exports=n},{}],16:[function(e,t,r){var n=e("./is-object");r.clearTimeout=function(){return this._timeout=0,clearTimeout(this._timer),this},r.parse=function(e){return this._parser=e,this},r.timeout=function(e){return this._timeout=e,this},r.then=function(e,t){return this.end(function(r,n){r?t(r):e(n)})},r.use=function(e){return e(this),this},r.get=function(e){return this._header[e.toLowerCase()]},r.getHeader=r.get,r.set=function(e,t){if(n(e)){for(var r in e)this.set(r,e[r]);return this}return this._header[e.toLowerCase()]=t,this.header[e]=t,this},r.unset=function(e){return delete this._header[e.toLowerCase()],delete this.header[e],this},r.field=function(e,t){return this._getFormData().append(e,t),this}},{"./is-object":15}],17:[function(e,t,r){function n(e,t,r){return"function"==typeof r?new e("GET",t).end(r):2==arguments.length?new e("GET",t):new e(t,r)}t.exports=n},{}],18:[function(e,t,r){/*! https://mths.be/punycode v1.3.2 by @mathias, modified for URI.js */var n=function(){function e(e){throw new RangeError(k[e])}function t(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function r(e,r){var n=e.split("@"),o="";n.length>1&&(o=n[0]+"@",e=n[1]),e=e.replace(C,".");var i=e.split("."),a=t(i,r).join(".");return o+a}function n(e){for(var t,r,n=[],o=0,i=e.length;o<i;)t=e.charCodeAt(o++),t>=55296&&t<=56319&&o<i?(r=e.charCodeAt(o++),56320==(64512&r)?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),o--)):n.push(t);return n}function o(e){return t(e,function(e){var t="";return e>65535&&(e-=65536,t+=A(e>>>10&1023|55296),e=56320|1023&e),t+=A(e)}).join("")}function i(e){return e-48<10?e-22:e-65<26?e-65:e-97<26?e-97:m}function a(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function s(e,t,r){var n=0;for(e=r?T(e/g):e>>1,e+=T(e/t);e>O*v>>1;n+=m)e=T(e/O);return T(n+(O+1)*e/(e+y))}function l(t){var r,n,a,l,c,u,f,d,y,g,E=[],$=t.length,C=0,k=x,O=b;for(n=t.lastIndexOf(w),n<0&&(n=0),a=0;a<n;++a)t.charCodeAt(a)>=128&&e("not-basic"),E.push(t.charCodeAt(a));for(l=n>0?n+1:0;l<$;){for(c=C,u=1,f=m;l>=$&&e("invalid-input"),d=i(t.charCodeAt(l++)),(d>=m||d>T((p-C)/u))&&e("overflow"),C+=d*u,y=f<=O?h:f>=O+v?v:f-O,!(d<y);f+=m)g=m-y,u>T(p/g)&&e("overflow"),u*=g;r=E.length+1,O=s(C-c,r,0==c),T(C/r)>p-k&&e("overflow"),k+=T(C/r),C%=r,E.splice(C++,0,k)}return o(E)}function c(t){var r,o,i,l,c,u,f,d,y,g,E,$,C,k,O,S=[];for(t=n(t),$=t.length,r=x,o=0,c=b,u=0;u<$;++u)E=t[u],E<128&&S.push(A(E));for(i=l=S.length,l&&S.push(w);i<$;){for(f=p,u=0;u<$;++u)E=t[u],E>=r&&E<f&&(f=E);for(C=i+1,f-r>T((p-o)/C)&&e("overflow"),o+=(f-r)*C,r=f,u=0;u<$;++u)if(E=t[u],E<r&&++o>p&&e("overflow"),E==r){for(d=o,y=m;g=y<=c?h:y>=c+v?v:y-c,!(d<g);y+=m)O=d-g,k=m-g,S.push(A(a(g+O%k,0))),d=T(O/k);S.push(A(a(d,0))),c=s(o,C,i==l),o=0,++i}++o,++r}return S.join("")}function u(e){return r(e,function(e){return E.test(e)?l(e.slice(4).toLowerCase()):e})}function f(e){return r(e,function(e){return $.test(e)?"xn--"+c(e):e})}var d,p=2147483647,m=36,h=1,v=26,y=38,g=700,b=72,x=128,w="-",E=/^xn--/,$=/[^\x20-\x7E]/,C=/[\x2E\u3002\uFF0E\uFF61]/g,k={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},O=m-h,T=Math.floor,A=String.fromCharCode;return d={version:"1.3.2",ucs2:{decode:n,encode:o},decode:l,encode:c,toASCII:f,toUnicode:u}}();"undefined"==typeof COMPILED&&"undefined"!=typeof t&&(t.exports=n)},{}],19:[function(e,t,r){e("./schemes/http"),e("./schemes/urn"),e("./schemes/mailto")},{"./schemes/http":20,"./schemes/mailto":21,"./schemes/urn":22}],20:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");n.SCHEMES.http=n.SCHEMES.https={domainHost:!0,parse:function(e,t){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e},serialize:function(e,t){return e.port!==("https"!==String(e.scheme).toLowerCase()?80:443)&&""!==e.port||(e.port=void 0),e.path||(e.path="/"),e}}},{"../uri":23}],21:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri"),o=e("../punycode");!function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(e){return e.toUpperCase()}function i(e){var t=n.pctDecChars(e);return t.match(M)?t:e}function a(e){return void 0!==e&&null!==e?e instanceof Array&&!e.callee?e:"number"!=typeof e.length||e.split||e.setInterval||e.call?[e]:Array.prototype.slice.call(e):[]}var s={},l=n.IRI_SUPPORT,c="[A-Za-z0-9\\-\\.\\_\\~"+(l?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",u="[0-9A-Fa-f]",f=t(t("%[EFef]"+u+"%"+u+u+"%"+u+u)+"|"+t("%[89A-Fa-f]"+u+"%"+u+u)+"|"+t("%"+u+u)),d="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",p="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",m=e(p,'[\\"\\\\]'),h=t(d+"+"+t("\\."+d+"+")+"*"),v=t("\\\\"+m),y=t(p+"|"+v),g=t('\\"'+y+'*\\"'),b="[\\x21-\\x5A\\x5E-\\x7E]",x="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",w=t(c+"|"+f+"|"+x),E=t(h+"|\\["+b+"*\\]"),$=t(h+"|"+g),C=t($+"\\@"+E),k=t(C+t("\\,"+C)+"*"),O=t(w+"*"),T=O,A=t(O+"\\="+T),S=t(A+t("\\&"+A)+"*"),P=t("\\?"+S),M=(n.VALIDATE_SUPPORT&&new RegExp("^mailto\\:"+k+"?"+P+"?$"),new RegExp(c,"g")),j=new RegExp(f,"g"),D=new RegExp(e("[^]",d,"[\\.]",'[\\"]',m),"g"),I=new RegExp(e("[^]",d,"[\\.]","[\\[]",b,"[\\]]"),"g"),_=new RegExp(e("[^]",c,x),"g"),F=_,R=n.VALIDATE_SUPPORT&&new RegExp("^"+k+"$"),q=n.VALIDATE_SUPPORT&&new RegExp("^"+S+"$");n.SCHEMES.mailto={parse:function(e,t){n.VALIDATE_SUPPORT&&!e.error&&(e.path&&!R.test(e.path)?e.error="Email address is not valid":e.query&&!q.test(e.query)&&(e.error="Header fields are invalid"));var r=e.to=e.path?e.path.split(","):[];if(e.path=void 0,e.query){for(var i=!1,a={},s=e.query.split("&"),l=0,c=s.length;l<c;++l){var u=s[l].split("=");switch(u[0]){case"to":for(var f=u[1].split(","),d=0,p=f.length;d<p;++d)r.push(f[d]);break;case"subject":e.subject=n.unescapeComponent(u[1],t);break;case"body":e.body=n.unescapeComponent(u[1],t);break;default:i=!0,a[n.unescapeComponent(u[0],t)]=n.unescapeComponent(u[1],t)}}i&&(e.headers=a)}e.query=void 0;for(var l=0,c=r.length;l<c;++l){var m=r[l].split("@");if(m[0]=n.unescapeComponent(m[0]),"undefined"==typeof o||t.unicodeSupport)m[1]=n.unescapeComponent(m[1],t).toLowerCase();else try{m[1]=o.toASCII(n.unescapeComponent(m[1],t).toLowerCase())}catch(t){e.error=e.error||"Email address's domain name can not be converted to ASCII via punycode: "+t}r[l]=m.join("@")}return e},serialize:function(e,t){var l=a(e.to);if(l){for(var c=0,u=l.length;c<u;++c){var f=String(l[c]),d=f.lastIndexOf("@"),p=f.slice(0,d),m=f.slice(d+1);if(p=p.replace(j,i).replace(j,r).replace(D,n.pctEncChar),"undefined"!=typeof o)try{m=t.iri?o.toUnicode(m):o.toASCII(n.unescapeComponent(m,t).toLowerCase())}catch(r){e.error=e.error||"Email address's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}else m=m.replace(j,i).toLowerCase().replace(j,r).replace(I,n.pctEncChar);l[c]=p+"@"+m}e.path=l.join(",")}var h=e.headers=e.headers||{};e.subject&&(h.subject=e.subject),e.body&&(h.body=e.body);var v=[];for(var y in h)h[y]!==s[y]&&v.push(y.replace(j,i).replace(j,r).replace(_,n.pctEncChar)+"="+h[y].replace(j,i).replace(j,r).replace(F,n.pctEncChar));return v.length&&(e.query=v.join("&")),e}}}()},{"../punycode":18,"../uri":23}],22:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");!function(){var e=n.pctEncChar,t="(?:[0-9A-Za-z][0-9A-Za-z\\-]{1,31})",r="(?:\\%[0-9A-Fa-f]{2})",o="[0-9A-Za-z\\(\\)\\+\\,\\-\\.\\:\\=\\@\\;\\$\\_\\!\\*\\'\\/\\?\\#]",i="(?:(?:"+r+"|"+o+")+)",a=new RegExp("^urn\\:("+t+")$"),s=new RegExp("^("+t+")\\:("+i+")$"),l=/^([^\:]+)\:(.*)/,c=/[\x00-\x20\\\"\&\<\>\[\]\^\`\{\|\}\~\x7F-\xFF]/g,u=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/;n.SCHEMES.urn={parse:function(e,t){var r,o,i=e.path.match(s);return i||(t.tolerant||(e.error=e.error||"URN is not strictly valid."),i=e.path.match(l)),i?(r="urn:"+i[1].toLowerCase(),o=n.SCHEMES[r],o||(o=n.SCHEMES[r]={parse:function(e,t){return e},serialize:n.SCHEMES.urn.serialize}),e.scheme=r,e.path=i[2],e=o.parse(e,t)):e.error=e.error||"URN can not be parsed.",e},serialize:function(t,r){var n,o=t.scheme||r.scheme;if(o&&"urn"!==o){var n=o.match(a);n||(n=["urn:"+o,o]),t.scheme="urn",t.path=n[1]+":"+(t.path?t.path.replace(c,e):"")}return t}},n.SCHEMES["urn:uuid"]={parse:function(e,t){return t.tolerant||e.path&&e.path.match(u)||(e.error=e.error||"UUID is not valid."),e},serialize:function(e,t){return t.tolerant||e.path&&e.path.match(u)?e.path=(e.path||"").toLowerCase():e.scheme=void 0,n.SCHEMES.urn.serialize(e,t)}}}()},{"../uri":23}],23:[function(e,t,r){/**
  * URI.js
  *
  * @fileoverview An RFC 3986 compliant, scheme extendable URI parsing/validating/resolving library for JavaScript.
@@ -35,5 +35,5 @@ e.exports=function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,
  * @see http://github.com/garycourt/uri-js
  * @license URI.js v2.0.0 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js
  */
-var n=!1,o=!0,i=!0,a=function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(r){var n="[A-Za-z]",o="[0-9]",a=e(o,"[A-Fa-f]"),s=t(t("%[EFef]"+a+"%"+a+a+"%"+a+a)+"|"+t("%[89A-Fa-f]"+a+"%"+a+a)+"|"+t("%"+a+a)),l="[\\:\\/\\?\\#\\[\\]\\@]",c="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",u=e(l,c),f=r?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",d=r?"[\\uE000-\\uF8FF]":"[]",p=e(n,o,"[\\-\\.\\_\\~]",f),m=t(n+e(n,o,"[\\+\\-\\.]")+"*"),h=t(t(s+"|"+e(p,c,"[\\:]"))+"*"),v=t(t("25[0-5]")+"|"+t("2[0-4]"+o)+"|"+t("1"+o+o)+"|"+t("[1-9]"+o)+"|"+o),y=t(v+"\\."+v+"\\."+v+"\\."+v),g=t(a+"{1,4}"),b=(t(t(g+"\\:"+g)+"|"+y),t(e(p,c,"[\\:]")+"+")),w=t("v"+a+"+\\."+e(p,c,"[\\:]")+"+"),x=t("\\["+t(b+"|"+w)+"\\]"),E=t(t(s+"|"+e(p,c))+"*"),$=t(x+"|"+y+"(?!"+E+")|"+E),C=t(o+"*"),k=t(t(h+"@")+"?"+$+t("\\:"+C)+"?"),A=t(s+"|"+e(p,c,"[\\:\\@]")),T=t(A+"*"),O=t(A+"+"),S=t(t(s+"|"+e(p,c,"[\\@]"))+"+"),P=t(t("\\/"+T)+"*"),M=t("\\/"+t(O+P)+"?"),j=t(S+P),D=t(O+P),I="(?!"+A+")",_=(t(P+"|"+M+"|"+j+"|"+D+"|"+I),t(t(A+"|"+e("[\\/\\?]",d))+"*")),F=t(t(A+"|[\\/\\?]")+"*"),R=t(t("\\/\\/"+k+P)+"|"+M+"|"+D+"|"+I),q=t(m+"\\:"+R+t("\\?"+_)+"?"+t("\\#"+F)+"?"),U=t(t("\\/\\/"+k+P)+"|"+M+"|"+j+"|"+I),N=t(U+t("\\?"+_)+"?"+t("\\#"+F)+"?"),L=(t(q+"|"+N),t(m+"\\:"+R+t("\\?"+_)+"?"),"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+D+"|"+I+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$"),H="^(){0}"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+j+"|"+I+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$";"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+D+"|"+I+")")+t("\\?("+_+")")+"?$","^"+t("\\#("+F+")")+"?$","^"+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?$";return{URI_REF:i&&new RegExp("("+L+")|("+H+")"),NOT_SCHEME:new RegExp(e("[^]",n,o,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(e("[^\\%\\:]",p,c),"g"),NOT_HOST:new RegExp(e("[^\\%]",p,c),"g"),NOT_PATH:new RegExp(e("[^\\%\\/\\:\\@]",p,c),"g"),NOT_PATH_NOSCHEME:new RegExp(e("[^\\%\\/\\@]",p,c),"g"),NOT_QUERY:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]",d),"g"),NOT_FRAGMENT:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(e("[^]",p,c),"g"),UNRESERVED:new RegExp(p,"g"),OTHER_CHARS:new RegExp(e("[^\\%]",p,u),"g"),PCT_ENCODED:new RegExp(s,"g")}}function n(e){var t,r=e.charCodeAt(0);return t=r<16?"%0"+r.toString(16).toUpperCase():r<128?"%"+r.toString(16).toUpperCase():r<2048?"%"+(r>>6|192).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase():"%"+(r>>12|224).toString(16).toUpperCase()+"%"+(r>>6&63|128).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase()}function a(e){for(var t,r,n,o="",i=0,a=e.length;i<a;)t=parseInt(e.substr(i+1,2),16),t<128?(o+=String.fromCharCode(t),i+=3):t>=194&&t<224?(a-i>=6?(r=parseInt(e.substr(i+4,2),16),o+=String.fromCharCode((31&t)<<6|63&r)):o+=e.substr(i,6),i+=6):t>=224?(a-i>=9?(r=parseInt(e.substr(i+4,2),16),n=parseInt(e.substr(i+7,2),16),o+=String.fromCharCode((15&t)<<12|(63&r)<<6|63&n)):o+=e.substr(i,9),i+=9):(o+=e.substr(i,3),i+=3);return o}function l(e){return void 0===e?"undefined":null===e?"null":Object.prototype.toString.call(e).split(" ").pop().split("]").shift().toLowerCase()}function c(e){return e.toUpperCase()}function u(e,t){function r(e){var r=a(e);return r.match(t.UNRESERVED)?r:e}return e.scheme&&(e.scheme=String(e.scheme).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_SCHEME,"")),void 0!==e.userinfo&&(e.userinfo=String(e.userinfo).replace(t.PCT_ENCODED,r).replace(t.NOT_USERINFO,n).replace(t.PCT_ENCODED,c)),void 0!==e.host&&(e.host=String(e.host).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_HOST,n).replace(t.PCT_ENCODED,c)),void 0!==e.path&&(e.path=String(e.path).replace(t.PCT_ENCODED,r).replace(e.scheme?t.NOT_PATH:t.NOT_PATH_NOSCHEME,n).replace(t.PCT_ENCODED,c)),void 0!==e.query&&(e.query=String(e.query).replace(t.PCT_ENCODED,r).replace(t.NOT_QUERY,n).replace(t.PCT_ENCODED,c)),void 0!==e.fragment&&(e.fragment=String(e.fragment).replace(t.PCT_ENCODED,r).replace(t.NOT_FRAGMENT,n).replace(t.PCT_ENCODED,c)),e}function f(e,t){void 0===t&&(t={});var r,n,l=o&&t.iri!==!1?E:x,c=!1,f={};if("suffix"===t.reference&&(e=(t.scheme?t.scheme+":":"")+"//"+e),i?(r=e.match(l.URI_REF),r&&(r=r[1]?r.slice(1,10):r.slice(10,19)),r||(c=!0,t.tolerant||(f.error=f.error||"URI is not strictly valid."),r=e.match($))):r=e.match($),r){if(O?(f.scheme=r[1],f.userinfo=r[3],f.host=r[4],f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=r[7],f.fragment=r[8],isNaN(f.port)&&(f.port=r[5])):(f.scheme=r[1]||void 0,f.userinfo=e.indexOf("@")!==-1?r[3]:void 0,f.host=e.indexOf("//")!==-1?r[4]:void 0,f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=e.indexOf("?")!==-1?r[7]:void 0,f.fragment=e.indexOf("#")!==-1?r[8]:void 0,isNaN(f.port)&&(f.port=e.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?r[4]:void 0)),void 0!==f.scheme||void 0!==f.userinfo||void 0!==f.host||void 0!==f.port||f.path||void 0!==f.query?void 0===f.scheme?f.reference="relative":void 0===f.fragment?f.reference="absolute":f.reference="uri":f.reference="same-document",t.reference&&"suffix"!==t.reference&&t.reference!==f.reference&&(f.error=f.error||"URI is not a "+t.reference+" reference."),n=S[(t.scheme||f.scheme||"").toLowerCase()],!o||"undefined"==typeof s||t.unicodeSupport||n&&n.unicodeSupport)u(f,l);else{if(f.host&&(t.domainHost||n&&n.domainHost))try{f.host=s.toASCII(f.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(e){f.error=f.error||"Host's domain name can not be converted to ASCII via punycode: "+e}u(f,x)}n&&n.parse&&n.parse(f,t)}else c=!0,f.error=f.error||"URI can not be parsed.";return f}function d(e,t){var r=[];return void 0!==e.userinfo&&(r.push(e.userinfo),r.push("@")),void 0!==e.host&&r.push(e.host),"number"==typeof e.port&&(r.push(":"),r.push(e.port.toString(10))),r.length?r.join(""):void 0}function p(e){for(var t,r=[];e.length;)e.match(C)?e=e.replace(C,""):e.match(k)?e=e.replace(k,"/"):e.match(A)?(e=e.replace(A,"/"),r.pop()):"."===e||".."===e?e="":(t=e.match(T)[0],e=e.slice(t.length),r.push(t));return r.join("")}function m(e,t){void 0===t&&(t={});var r,n,i,l=o&&t.iri?E:x,c=[];if(r=S[(t.scheme||e.scheme||"").toLowerCase()],r&&r.serialize&&r.serialize(e,t),o&&"undefined"!=typeof s&&e.host&&(t.domainHost||r&&r.domainHost))try{e.host=t.iri?s.toUnicode(e.host):s.toASCII(e.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(r){e.error=e.error||"Host's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}return u(e,l),"suffix"!==t.reference&&e.scheme&&(c.push(e.scheme),c.push(":")),n=d(e,t),void 0!==n&&("suffix"!==t.reference&&c.push("//"),c.push(n),e.path&&"/"!==e.path.charAt(0)&&c.push("/")),void 0!==e.path&&(i=e.path,t.absolutePath||r&&r.absolutePath||(i=p(i)),void 0===n&&(i=i.replace(/^\/\//,"/%2F")),c.push(i)),void 0!==e.query&&(c.push("?"),c.push(e.query)),void 0!==e.fragment&&(c.push("#"),c.push(e.fragment)),c.join("")}function h(e,t,r,n){void 0===r&&(r={});var o={};return n||(e=f(m(e,r),r),t=f(m(t,r),r)),r=r||{},!r.tolerant&&t.scheme?(o.scheme=t.scheme,o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(t.path?("/"===t.path.charAt(0)?o.path=p(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?o.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:o.path=t.path:o.path="/"+t.path,o.path=p(o.path)),o.query=t.query):(o.path=e.path,void 0!==t.query?o.query=t.query:o.query=e.query),o.userinfo=e.userinfo,o.host=e.host,o.port=e.port),o.scheme=e.scheme),o.fragment=t.fragment,o}function v(e,t,r){return m(h(f(e,r),f(t,r),r,!0),r)}function y(e,t){return"string"==typeof e?e=m(f(e,t),t):"object"===l(e)&&(e=f(m(e,t),t)),e}function g(e,t,r){return"string"==typeof e?e=m(f(e,r),r):"object"===l(e)&&(e=m(e,r)),"string"==typeof t?t=m(f(t,r),r):"object"===l(t)&&(t=m(t,r)),e===t}function b(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.ESCAPE:x.ESCAPE,n)}function w(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.PCT_ENCODED:x.PCT_ENCODED,a)}var x=r(!1),E=o?r(!0):void 0,$=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?([^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n)*))?/i,C=/^\.\.?\//,k=/^\/\.(\/|$)/,A=/^\/\.\.(\/|$)/,T=/^\/?(?:.|\n)*?(?=\/|$)/,O=void 0==="".match(/(){0}/)[1],S={};return{IRI_SUPPORT:o,VALIDATE_SUPPORT:i,pctEncChar:n,pctDecChars:a,SCHEMES:S,parse:f,_recomposeAuthority:d,removeDotSegments:p,serialize:m,resolveComponents:h,resolve:v,normalize:y,equal:g,escapeComponent:b,unescapeComponent:w}}();if(!n&&"undefined"!=typeof t&&"function"==typeof e){var s=e("./punycode");t.exports=a,e("./schemes")}},{"./punycode":18,"./schemes":19}]},{},[1])(1)})},function(e,t,r){"use strict";function n(e,t,l,c,u,f){var d=[],p=[];t=t||[];var m=t.indexOf("*");c=c||{};var h={},v=t.indexOf("...");if("object"===("undefined"==typeof e?"undefined":s(e))&&e.hasOwnProperty("properties")){u=u||e.readonly||e.readOnly,h=r.i(i.defaultForm)(e,r.i(i.createDefaults)(),l,c);var y=h.lookup;e=y||e,d=d.concat(h.form)}return m!==-1&&(t=t.slice(0,m).concat(d).concat(t.slice(m+1))),h.form&&v!==-1&&!function(){var e=t.map(function(e){return"string"==typeof e?e:e.key?e.key:void 0}).filter(function(e){return void 0!==e});p=p.concat(h.form.map(function(t){var r=e.indexOf(t.key[0])!==-1;if(!r)return t}).filter(function(e){return void 0!==e}))}(),v!==-1&&(t=t.slice(0,v).concat(p).concat(t.slice(v+1))),t.map(function(t){if("string"==typeof t&&(t={key:t}),t.key&&"string"==typeof t.key&&(t.key=r.i(o.parse)(t.key)),t.titleMap&&(t.titleMap=r.i(a.a)(t.titleMap)),t.key){var i=r.i(o.stringify)(t.key);e[i]&&!function(){var r=e[i];r&&Object.keys(r).forEach(function(e){void 0===t[e]&&(t[e]=r[e])})}()}return u===!0&&(t.readonly=!0),t.items&&(t.items=n(e,t.items,l,c,t.readonly,f)),t.tabs&&t.tabs.forEach(function(r){r.items&&(r.items=n(e,r.items,l,c,t.readonly,f))}),"checkbox"===t.type&&void 0===t.schema.default&&(t.schema.default=!1),f&&"template"===t.type&&!t.template&&t.templateUrl&&f.push(t),t})}var o=r(0),i=r(3),a=r(1);t.a=n;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e}},function(e,t,r){"use strict";function n(e,t){var r=new Promise(function(t,r){o.resolveRefs(e,{filter:["relative","local","remote"]}).then(function(e){t(e.resolved)}).catch(function(e){r(new Error(e))})});return"function"!=typeof t?r:void r.then(function(e){t(null,e)}).catch(function(e){t(e)})}var o=r(5);r.n(o);t.a=n},function(e,t,r){"use strict";function n(e,t,r){t||(t=this);var n="string"==typeof e?o.parse(e):e;if("undefined"!=typeof r&&1===n.length)return t[n[0]]=r,t;"undefined"!=typeof r&&"undefined"==typeof t[n[0]]&&(t[n[0]]=n.length>2&&i.test(n[1])?[]:{});for(var a=t[n[0]],s=1;s<n.length;s++){if(""===n[s])return;if("undefined"!=typeof r){if(s===n.length-1)return a[n[s]]=r,r;var l=a[n[s]];"undefined"!=typeof l&&null!==l||(l=i.test(n[s+1])?[]:{},a[n[s]]=l),a=l}else a&&(a=a[n[s]])}return a}var o=r(0);t.a=n;var i=/^\d+$/},function(e,t,r){"use strict";function n(e,t,r,n){n=void 0===n||n,r=r||[];var o=function e(t,r,o){if(r(t,o),t.properties&&Object.keys(t.properties).forEach(function(n){var i=o.slice();i.push(n),e(t.properties[n],r,i)}),!n&&t.items){var i=o.slice();i.push(""),e(t.items,r,i)}};o(e,t,r||[])}function o(e,t){t(e),e.items&&e.items.forEach(function(e){o(e,t)}),e.tabs&&e.tabs.forEach(function(e){e.items&&e.items.forEach(function(e){o(e,t)})})}t.a=n,t.b=o},function(e,t,r){"use strict";function n(e,t){if(!e)return{valid:!0};var r=e.schema;if(!r)return{valid:!0};""===t&&(t=void 0),"number"===e.type&&null===t&&(t=void 0);var n={type:"object",properties:{},required:void 0},o=e.key[e.key.length-1];n.properties[o]=r,e.required&&(n.required=[o]);var a={};return t&&(a[o]=t),i.a.validateResult(a,n)}var o=r(12),i=r.n(o);t.a=n},function(e,t,r){"use strict";var n;!function(o){var i={parse:function(e){if("string"!=typeof e)throw new TypeError("ObjectPath.parse must be passed a string");for(var t,r,n,o,i=0,a=[];i<e.length;)if(t=e.indexOf(".",i),r=e.indexOf("[",i),t===-1&&r===-1)a.push(e.slice(i,e.length)),i=e.length;else if(r===-1||t!==-1&&t<r)a.push(e.slice(i,t)),i=t+1;else if(r>i&&(a.push(e.slice(i,r)),i=r),n=e.slice(r+1,r+2),'"'!==n&&"'"!==n)o=e.indexOf("]",r),o===-1&&(o=e.length),a.push(e.slice(i+1,o)),i="."===e.slice(o+1,o+2)?o+2:o+1;else{for(o=e.indexOf(n+"]",r),o===-1&&(o=e.length);"\\"===e.slice(o-1,o)&&r<e.length;)r++,o=e.indexOf(n+"]",r);a.push(e.slice(i+2,o).replace(new RegExp("\\"+n,"g"),n)),i="."===e.slice(o+2,o+3)?o+3:o+2}return a},stringify:function(e,t){return Array.isArray(e)||(e=[e.toString()]),t='"'===t?'"':"'",e.map(function(e){return"["+t+e.toString().replace(new RegExp(t,"g"),"\\"+t)+t+"]"}).join("")},normalize:function(e,t){return i.stringify(Array.isArray(e)?e:i.parse(e),t)},registerModule:function(e){e.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=i.parse,this.stringify=i.stringify,this.normalize=i.normalize,this.$get=function(){return i}})}};n=function(){return{ObjectPath:i}}.call(t,r,t,e),!(n!==o&&(e.exports=n))}()},function(e,t){e.exports=tv4},function(e,t,r){e.exports=r(4)}])}).call(t,r(2),r(19).setImmediate)},function(e,t){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(r=window)}e.exports=r},,function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(1),o=(r.n(n),r(0)),i=r.n(o),a=r(14),s=r(12),l=r(13),c=r(15),u=r(16),f=r(7),d=r(8),p=r(10),m=r(6),h=r(9),v=r(11),y=r(5),g=[];try{i.a.module("ngSanitize"),g.push("ngSanitize")}catch(e){}try{i.a.module("ui.sortable"),g.push("ui.sortable")}catch(e){}try{i.a.module("angularSpectrumColorpicker"),g.push("angularSpectrumColorpicker")}catch(e){}i.a.module("schemaForm",g).provider("sfPath",u.a).provider("sfBuilder",["sfPathProvider",a.a]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",s.a]).provider("sfErrorMessage",c.a).provider("schemaForm",["sfPathProvider",l.a]).factory("sfSelect",function(){return n.select}).factory("sfValidator",function(){return n.validate}).directive("sfChanged",f.a).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",d.a]).directive("sfMessage",["$injector","sfErrorMessage",p.a]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",m.a]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",v.a]).directive("schemaValidate",["sfValidator","$parse","sfSelect",y.a]).directive("sfKeyController",["schemaForm","sfPath",h.a])},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r){return{restrict:"A",scope:!1,priority:500,require:"ngModel",link:function(t,n,i,a){t.$emit("schemaFormPropagateNgModelController",a);var s=null,l=t.$eval(i.schemaValidate);l.copyValueTo&&a.$viewChangeListeners.push(function(){var e=l.copyValueTo;o.a.forEach(e,function(e){r(e,t.model,a.$modelValue)})});var c=function(r){if(!l)return r;if(t.options&&t.options.tv4Validation===!1)return r;var n=e(l,r);Object.keys(a.$error).filter(function(e){return 0===e.indexOf("tv4-")}).forEach(function(e){a.$setValidity(e,!0)});{if(n.valid)return r;if(a.$setValidity("tv4-"+n.error.code,!1),s=n.error,a.$validators)return r}};"function"==typeof l.ngModel&&l.ngModel(a),["$parsers","$viewChangeListeners","$formatters"].forEach(function(e){l[e]&&a[e]&&l[e].forEach(function(t){a[e].push(t)})}),["$validators","$asyncValidators"].forEach(function(e){l[e]&&a[e]&&o.a.forEach(l[e],function(t,r){a[e][r]=t})}),a.$parsers.push(c),a.$validators&&(a.$validators.schemaForm=function(){return!Object.keys(a.$error).some(function(e){return"schemaForm"!==e})});var u=l.schema;t.validateField=function(e){var t=void 0===e;(t||a.$$parentForm.$name===e)&&((t||u&&u.type.indexOf("array")!==-1)&&c(a.$modelValue),a.$setDirty?(a.$setDirty(),a.$setViewValue(a.$viewValue),a.$commitViewValue(),"checkbox"===l.type?l.required&&void 0===a.$modelValue&&a.$setValidity("tv4-302",!1):l.required&&a.$isEmpty(a.$modelValue)&&a.$setValidity("tv4-302",!1)):a.$setViewValue(a.$viewValue))};var f=!0;a.$formatters.push(function(e){return!a.$pristine||!f||t.options&&t.options.validateOnRender===!0?(c(a.$modelValue),e):(f=!1,e)}),t.$on("schemaFormValidate",function(e,r){t.validateField(r)}),t.schemaError=function(){return s}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r){return{scope:!0,controller:["$scope",function(e){this.key=e.form&&e.form.key?e.form.key.splice(0,-2):[]}],link:function(n,i,a){n.min=0,n.modelArray=n.$eval(a.sfNewArray);var s=function(){n.modelArray=n.$eval(a.sfNewArray),n.ngModel&&n.ngModel.$pristine&&n.firstDigest&&(!n.options||n.options.validateOnRender!==!0)||n.validateField&&n.validateField()},l=function(){n.form&&n.form.onChange&&(o.a.isFunction(n.form.onChange)?n.form.onChange(n.modelArray,n.form):n.evalExpr(n.form.onChange,{modelValue:n.modelArray,form:n.form}))},c=function(){var r=n.modelArray;if(!r){var o=t.parse(a.sfNewArray);r=[],e(o,n,r),n.modelArray=r}return r},u=n.$watch("form",function(e){if(e){if(e.titleMap||e.startEmpty===!0||n.modelArray&&0!==n.modelArray.length||n.appendToArray(),n.form&&n.form.schema&&n.form.schema.uniqueItems===!0?(n.$watch(a.sfNewArray,s,!0),n.$watch([a.sfNewArray,a.sfNewArray+".length"],l)):n.$watchGroup?n.$watchGroup([a.sfNewArray,a.sfNewArray+".length"],function(){s(),l()}):(n.$watch(a.sfNewArray,function(){s(),l()}),n.$watch(a.sfNewArray+".length",function(){s(),l()})),e.titleMap&&e.titleMap.length>0){n.titleMapValues=[];var t=function(t){n.titleMapValues=[],t=t||[],e.titleMap.forEach(function(e){n.titleMapValues.push(t.indexOf(e.value)!==-1)})};t(n.modelArray),n.$watchCollection("modelArray",t),n.$watchCollection("titleMapValues",function(t,r){if(t&&t!==r){var o=c();e.titleMap.forEach(function(e,r){var n=o.indexOf(e.value);n===-1&&t[r]&&o.push(e.value),n===-1||t[r]||o.splice(n,1)}),n.validateField&&n.validateField()}})}u()}});n.appendToArray=function(){var t,i=c();if(n.form&&n.form.schema&&n.form.schema.items){var a=n.form.schema.items;a.type&&a.type.indexOf("object")!==-1?(t={},n.options&&n.options.setSchemaDefaults===!1||(t=o.a.isDefined(a.default)?a.default:t,t&&r.traverseSchema(a,function(r,n){o.a.isDefined(r.default)&&e(n,t,r.default)}))):a.type&&a.type.indexOf("array")!==-1?(t=[],n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t)):n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t)}return i.push(t),i},n.deleteFromArray=function(e){var t=n.modelArray;return t&&t.splice(e,1),t};var f=function(e){return function(t){t.key&&(t.key[t.key.indexOf("")]=e)}},d={};n.copyWithIndex=function(e){var t=n.form;if(!d[e]){var i=t.items[0];if(t.items.length>1&&(i={type:"section",items:t.items.map(function(e){return e.ngModelOptions=t.ngModelOptions,o.a.isUndefined(e.readonly)&&(e.readonly=t.readonly),e})}),i){var a=o.a.copy(i);a.arrayIndex=e,r.traverseForm(a,f(e)),d[e]=a}}return d[e]}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){return{require:"ngModel",restrict:"AC",scope:!1,link:function(e,t,r,n){var i=e.$eval(r.sfChanged);i&&i.onChange&&n.$viewChangeListeners.push(function(){o.a.isFunction(i.onChange)?i.onChange(n.$modelValue,i):e.evalExpr(i.onChange,{modelValue:n.$modelValue,form:i,arrayIndex:e.$index,arrayIndices:e.arrayIndices,path:e.path,$i:e.$i,$index:e.$index})})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r,n,a,s,l,c,u){var f={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function(e,t,r,n){var o=n[0];n[1],n[2];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.initialForm=Object.assign({},o.lookup["f"+r.sfField]),e.form=o.lookup["f"+r.sfField]},post:function(e,t,r,n){var s=n[0],d=n[1];n[2];e.getKey=function(t){var r=t||f.COMPLETE,n=e.parentKey?e.parentKey.slice(0,e.parentKey.length-1):[];if(e.completeKey!==e.form.key&&("number"==typeof e.$index&&(n=n.concat(e.$index)),e.form.key&&e.form.key.length))if("number"==typeof n[n.length-1]&&e.form.key.length>=1){var o=e.form.key.length-n.length;e.completeKey=n.concat(e.form.key.slice(-o))}else e.completeKey=e.form.key.slice();if(Array.isArray(e.completeKey))return r===f.COMPLETE?e.completeKey:e.completeKey.reduce(function(e,t,n){return-1!==[r].indexOf("undefined"==typeof t?"undefined":i(t))?e.concat(t):e},[])},e.form.key&&(e.form.key=e.completeKey=e.getKey()),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=r||!1,o=t&&d&&d.$name?d.$name:void 0,i=e.completeKey;return Array.isArray(i)?c.name(i,"-",o,n):""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(s?s.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return s?s.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&a(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.errors===!1?e.ngModel.$invalid&&!e.ngModel.$pristine:e.ngModel.$invalid)},e.errorMessage=function(t){return l.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)},e.form.htmlClass=e.form.htmlClass||"",e.idClass=e.fieldId(!1)+" "+e.fieldId(!1,!0);var p=e.form;p.key&&(e.$on("schemaForm.error."+p.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(p.validationMessage||(p.validationMessage={}),p.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){var t=e.getKey();if(!e.externalDestructionInProgress){var r=p.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(t&&"retain"!==r){var n=e.model;if(t.length>1&&(n=u(t.slice(0,t.length-1),n)),void 0===n)return;var o=p.schema&&p.schema.type||"";"empty"===r&&o.indexOf("string")!==-1?n[t.slice(-1)]="":"empty"===r&&o.indexOf("object")!==-1?n[t.slice(-1)]={}:"empty"===r&&o.indexOf("array")!==-1?n[t.slice(-1)]=[]:"null"===r?n[t.slice(-1)]=null:delete n[t.slice(-1)]}}}))}}}}},function(e,t,r){"use strict";t.a=function(e,t){return{scope:!0,require:["?^^sfNewArray"],link:{pre:function(e,r,n,o){e.parentKey=e.parentKey||[];var i=t.parse(n.sfParentKey),a=i.length-e.parentKey.length;i.length>1&&(i=i.splice(-a)),e.parentKey=e.parentKey.concat(i,Number(n.sfIndex)),e.arrayIndex=Number(n.sfIndex),e.arrayIndices=e.arrayIndices||[],e.arrayIndices=e.arrayIndices.concat(e.arrayIndex),e.$i=e.arrayIndices,e.path=function(t){var r=-1;return t=t.replace(/\[\]/gi,function(t){return r++,"["+e.$i[r]+"]"}),e.evalExpr(t,e)}}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r=e.has("$sanitize")?e.get("$sanitize"):function(e){return e};return{scope:!1,restrict:"EA",link:function(e,n,i){var a="";i.sfMessage&&e.$watch(i.sfMessage,function(t){t&&(a=r(t),c(!!e.ngModel))});var s,l=function(e){e!==s&&(n.html(e),s=e)},c=function(r){if(r)if(e.hasError()){var n=[];o.a.forEach(e.ngModel&&e.ngModel.$error,function(e,t){e&&n.push(t)}),n=n.filter(function(e){return"schemaForm"!==e});var i=n[0];l(i?t.interpolate(i,e.ngModel.$modelValue,e.ngModel.$viewValue,e.form,e.options&&e.options.validationMessage):a)}else l(a);else l(a)};c();var u=e.$watch("ngModel",function(e){e&&(e.$parsers.push(function(e){return c(!0),e}),e.$formatters.push(function(e){return c(!0),e}),u())});e.$watchCollection("ngModel.$error",function(){c(!!e.ngModel)})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r,n,i,a,s,l,c){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function(e){this.evalInParentScope=function(t,r){return e.$parent.$eval(t,r)};var t=this;e.lookup=function(e){return e&&(t.lookup=e),t.lookup}}],replace:!1,restrict:"A",transclude:!0,require:"?form",link:function(l,u,f,d,p){l.formCtrl=d;var m={};p(l,function(e){if(e.addClass("schema-form-ignore"),u.prepend(e),u[0].querySelectorAll){var t=u[0].querySelectorAll("[ng-model]");if(t)for(var r=0;r<t.length;r++){var n=t[r].getAttribute("ng-model");m[n.substring(n.indexOf(".")+1)]=!0}}});var h,v={};l.resolveReferences=function(e,t){i.jsonref(e).then(function(e){l.render(e,t)}).catch(function(e){new Error(e)})},l.render=function(e,o){var a=[],s=i.merge(e,o,m,l.options,void 0,a);a.length>0?n.all(a.map(function(e){return t.get(e.templateUrl,{cache:r}).then(function(t){e.template=t.data})})).then(function(){l.internalRender(e,o,s)}):l.internalRender(e,o,s)},l.internalRender=function(t,r,n){h&&(l.externalDestructionInProgress=!0,h.$destroy(),l.externalDestructionInProgress=!1),h=l.$new(),h.schemaForm={form:n,schema:t},Array.prototype.forEach.call(u.children(),function(e){var t=o.a.element(e);!1===t.hasClass("schema-form-ignore")&&t.remove()});for(var d={},p=u[0].querySelectorAll("*[sf-insert-field]"),m=0;m<p.length;m++)d[p[m].getAttribute("sf-insert-field")]=p[m];var v=a.decorator(f.sfUseDecorator),y=Object.create(null);l.lookup(y),u[0].appendChild(c.build(n,v,d,y)),h.firstDigest=!0,setTimeout(function(){h.firstDigest=!1},0),e(u.children())(h),l.options&&l.options.setSchemaDefaults===!1||i.traverseSchema(t,function(e,t){if(o.a.isDefined(e.default)){var r=s(t,l.model);o.a.isUndefined(r)&&s(t,l.model,e.default)}}),l.$emit("sf-render-finished",u)};var y=["*"];l.$watch(function(){var e=l.schema,t=l.initialForm||y;t&&e&&e.type&&(v.form!==t||v.schema!==e)&&Object.keys(e.properties).length>0&&(v.schema=e,v.form=t,l.resolveReferences(e,t))}),l.$on("schemaFormRedraw",function(){var e=l.schema,t=l.initialForm?o.a.copy(l.initialForm):["*"];e&&l.resolveReferences(e,t)}),l.$on("$destroy",function(){l.externalDestructionInProgress=!0}),l.evalExpr=function(e,t){return l.$parent.$eval(e,t)}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r="",n={},i=function(e,t){"sfDecorator"===e&&(e=r);var o=n[e];return o[t.type]?o[t.type].template:o.default.template},a=function(r){e.directive(r,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function(e,n,a,s,l,c,u,f,d){return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["?^sfSchema","?^form"],link:function(e,p,m,h){var v=h[0],y=h[1];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=e.parentKey||[];if(e.form.key){if("number"==typeof n[n.length-1]){var o=n.concat(e.form.key.slice(-1)),i=t&&y&&y.$name?y.$name:void 0;return f.name(o,"-",i,r)}var i=t&&y&&y.$name?y.$name:void 0;return f.name(e.form.key,"-",i,r)}return""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(v?v.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return v?v.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&l(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.ngModel.$invalid&&!e.ngModel.$pristine)},e.errorMessage=function(t){return u.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)};var g=e.$watch(m.form,function(l){if(l){l.ngModelOptions=l.ngModelOptions||{},e.form=l;var u;if("template"===l.type&&l.template)u=c.when(l.template);else{var m="template"===l.type?l.templateUrl:i(r,l);u=a.get(m,{cache:s}).then(function(e){return e.data})}u.then(function(r){if(l.key){var i=l.key?t.stringify(l.key).replace(/"/g,"&quot;"):"";r=r.replace(/\$\$value\$\$/g,"model"+("["!==i[0]?".":"")+i)}if(p.html(r),l.condition){var a='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';l.key&&(a='evalExpr(form.condition, {model: model, "arrayIndex": arrayIndex, "modelValue": model'+f.stringify(l.key)+"})"),o.a.forEach(p.children(),function(e){var t=e.getAttribute("ng-if");e.setAttribute("ng-if",t?"("+t+") || ("+a+")":a)})}n(p.contents())(e)}),l.key&&(e.$on("schemaForm.error."+l.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(l.validationMessage||(l.validationMessage={}),l.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){if(!e.externalDestructionInProgress){var t=l.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(l.key&&"retain"!==t){var r=e.model;if(l.key.length>1&&(r=d(l.key.slice(0,l.key.length-1),r)),void 0===r)return;var n=l.schema&&l.schema.type||"";"empty"===t&&n.indexOf("string")!==-1?r[l.key.slice(-1)]="":"empty"===t&&n.indexOf("object")!==-1?r[l.key.slice(-1)]={}:"empty"===t&&n.indexOf("array")!==-1?r[l.key.slice(-1)]=[]:"null"===t?r[l.key.slice(-1)]=null:delete r[l.key.slice(-1)]}}})),g()}})}}}])},s=function(t,r,n){n=!!o.a.isDefined(n)&&n,e.directive("sf"+o.a.uppercase(t[0])+t.substr(1),function(){return{restrict:"EAC",scope:!0,replace:!0,transclude:n,template:'<sf-decorator form="form"></sf-decorator>',link:function(e,r,n){var i={items:"c",titleMap:"c",schema:"c"},a={type:t},s=!0;o.a.forEach(n,function(t,r){if("$"!==r[0]&&0!==r.indexOf("ng")&&"sfField"!==r){var l=function(t){o.a.isDefined(t)&&t!==a[r]&&(a[r]=t,s&&a.type&&(a.key||o.a.isUndefined(n.key))&&(e.form=a,s=!1))};"model"===r?e.$watch(t,function(t){t&&e.model!==t&&(e.model=t)}):"c"===i[r]?e.$watchCollection(t,l):n.$observe(r,l)}})}}})};this.createDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){n[e][r]={template:t,replace:!1,builder:[]}}),n[r]||(r=e),a(e)},this.defineDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){t.builder=t.builder||[],t.replace=!o.a.isDefined(t.replace)||t.replace,n[e][r]=t;
-}),n[r]||(r=e),a(e)},this.createDirective=s,this.createDirectives=function(e){o.a.forEach(e,function(e,t){s(t,e)})},this.decorator=function(e){return e=e||r,n[e]},this.addMapping=function(e,t,r,o,i){n[e]&&(n[e][t]={template:r,builder:o,replace:!!i})},this.defineAddOn=function(e,t,r,o){n[e]&&(n[e][t]={template:r,builder:o,replace:!0})},this.$get=function(){return{decorator:function(e){return n[e]||n[r]},defaultDecorator:r}},a("sfDecorator")}},function(e,t,r){"use strict";var n=r(0),o=(r.n(n),r(1));r.n(o);t.a=function(){var e=function(e){return e},t=o.schemaDefaults.createDefaults();this.defaults=t,this.stdFormObj=o.schemaDefaults.stdFormObj,this.defaultFormDefinition=o.schemaDefaults.defaultFormDefinition,this.postProcess=function(t){e=t},this.appendRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].push(t)},this.prependRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].unshift(t)},this.createStandardForm=o.schemaDefaults.stdFormObj,this.$get=function(){var t={},n=this.defaults;return t.jsonref=o.jsonref,t.merge=function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["*"],i=arguments[2],a=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},s=arguments.length>4&&void 0!==arguments[4]&&arguments[4],l=arguments[5],c=r.i(o.merge)(t,n,i,a,s,l);return e(c)},t.defaults=function(e,t,r,i){var a=t||n;return o.schemaDefaults.defaultForm(e,a,r,i)},t.typeDefault=n,t.traverseSchema=o.traverseSchema,t.traverseForm=o.traverseForm,t}}},function(e,t,r){"use strict";t.a=function(e){var t=/[A-Z]/g,r=function(e,r){return r=r||"_",e.replace(t,function(e,t){return(t?r:"")+e.toLowerCase()})},n=0;"firstElementChild"in document.createDocumentFragment()||Object.defineProperty(DocumentFragment.prototype,"firstElementChild",{get:function(){for(var e,t=this.childNodes,r=0,n=t.length;r<n;++r)if(e=t[r],1===e.nodeType)return e;return null}});var o={sfField:function(e){e.fieldFrag.firstElementChild.setAttribute("sf-field",n),e.lookup["f"+n]=e.form,n++},ngModel:function(t){if(t.form.key){var r=t.form.key;t.state.keyRedaction&&(r=r.slice(t.state.keyRedaction));var n;if(t.state.modelValue)n=t.state.modelValue;else{var o=e.stringify(r).replace(/"/g,"&quot;");n=t.state.modelName||"model",o&&(n+=("["!==o[0]?".":"")+o)}for(var i=t.fieldFrag.querySelectorAll("[sf-field-model]"),a=0;a<i.length;a++){var s=i[a],l=s.getAttribute("sf-field-model");if(l&&""!==l)if("replaceAll"===l)for(var c=s.attributes,u=0;u<c.length;u++)c[u].value&&c[u].value.indexOf("$$value")!==-1&&(c[u].value=c[u].value.replace(/\$\$value\$\$/g,n));else{var f=s.getAttribute(l);f&&f.indexOf("$$value$$")?s.setAttribute(l,f.replace(/\$\$value\$\$/g,n)):s.setAttribute(l,n)}else s.setAttribute("ng-model",n)}}},simpleTransclusion:function(e){var t=e.build(e.form.items,e.path+".items",e.state);e.fieldFrag.firstChild.appendChild(t)},ngModelOptions:function(e){e.form.ngModelOptions&&Object.keys(e.form.ngModelOptions).length>0&&e.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(e.form.ngModelOptions))},transclusion:function(e){var t=e.fieldFrag.querySelectorAll("[sf-field-transclude]");if(t.length)for(var r=0;r<t.length;r++){var n=t[r],o=n.getAttribute("sf-field-transclude")||"items",i=e.form[o];if(i){var a=e.build(i,e.path+"."+o,e.state);n.appendChild(a)}}},condition:function(t){var r="",n="undefined",o="";if(t.form.condition){t.form.key&&(r=e.stringify(t.form.key),n="model"+("["===r[0]?"":".")+r);for(var i="evalExpr("+t.path+'.condition, { model: model, "arrayIndex": $index, "arrayIndices": arrayIndices, "path": path, "$i": $i, "$index": $index, "modelValue": '+n+"})",a=t.fieldFrag.children||t.fieldFrag.childNodes,s=0;s<a.length;s++){var l=a[s];l.hasAttribute&&l.hasAttribute("ng-if")&&(o=l.getAttribute("ng-if")),l.setAttribute&&l.setAttribute("ng-if",o?"("+o+") || ("+i+")":i)}}},array:function(t){var r=t.fieldFrag.querySelector("[schema-form-array-items]");if(t.form.key){t.form.key.filter(function(e){return""===e}).length}if(r){var n=angular.copy(t.state);if(n.keyRedaction=0,n.keyRedaction+=t.form.key.length+1,t.form.schema&&t.form.schema.items&&t.form.schema.items.type&&t.form.schema.items.type.indexOf("object")===-1&&t.form.schema.items.type.indexOf("array")===-1){e.stringify(t.form.key).replace(/"/g,"&quot;")+"[$index]";n.modelValue="modelArray[$index]"}else n.modelName="item";n.arrayCompatFlag=!0;var o=t.build(t.form.items,t.path+".items",n);r.appendChild(o)}},numeric:function(e){var t=e.fieldFrag.querySelector("input"),r=e.form.maximum||!1,n=e.form.exclusiveMaximum||!1,o=e.form.minimum||!1,i=e.form.exclusiveMinimum||!1,a=e.form.multipleOf||!1;t&&(a!==!1&&t.setAttribute("step",a),r!==!1&&(n!==!1&&a!==!1&&(r-=a),t.setAttribute("max",r)),o!==!1&&(i!==!1&&a!==!1&&(o+=a),t.setAttribute("min",o)))}};this.builders=o;var i=[o.sfField,o.ngModel,o.ngModelOptions,o.condition];this.stdBuilders=i,this.$get=["$templateCache","schemaFormDecorators","sfPath",function(e,t,n){var a=function(e,t){if(e.key){var r=t[n.stringify(e.key)];if(r){for(;r.firstChild;)r.removeChild(r.firstChild);return r}}},s=function e(t,n,o,i,s,l,c){l=l||{},l=l||{},c=c||Object.create(null),s=s||"schemaForm.form";var u=document.createDocumentFragment();return t.reduce(function(t,u,f){if(!u.type)return t;var d=n[u.type]||n.default;if(d.replace){var p;l.arrayCompatFlag=!1;var m=document.createElement("div"),h=o(u,d)||o(u,n.default);for(m.innerHTML=h,p=document.createDocumentFragment();m.childNodes.length>0;)p.appendChild(m.childNodes[0]);var v={fieldFrag:p,form:u,lookup:c,state:l,path:s+"["+f+"]",build:function(t,r,a){return e(t,n,o,i,r,a,c)}},y=u.builder||d.builder;"function"==typeof y?y(v):y.forEach(function(e){e(v)}),(a(u,i)||t).appendChild(p)}else{var g=document.createElement(r(n.__name,"-"));l.arrayCompatFlag?g.setAttribute("form","copyWithIndex($index)"):g.setAttribute("form",s+"["+f+"]"),(a(u,i)||t).appendChild(g)}return t},u),u};return{build:function(t,r,n,o){return s(t,r,function(t,r){return"template"===t.type?t.template:e.get(r.template)},n,void 0,void 0,o)},builder:o,stdBuilders:i,internalBuild:s}}]}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){var e={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};e.number=e[105],e.required=e[302],e.min=e[101],e.max=e[103],e.maxlength=e[201],e.minlength=e[200],e.pattern=e[202],this.setDefaultMessages=function(t){e=t},this.getDefaultMessages=function(){return e},this.setDefaultMessage=function(t,r){e[t]=r},this.$get=["$interpolate",function(t){var r={};return r.defaultMessages=e,r.interpolate=function(r,n,i,a,s){s=s||{};var l=a.validationMessage||{};0===r.indexOf("tv4-")&&(r=r.substring(4));var c=l.default||s.default||"";[l,s,e].some(function(e){return o.a.isString(e)||o.a.isFunction(e)?(c=e,!0):e&&e[r]?(c=e[r],!0):void 0});var u={error:r,value:n,viewValue:i,form:a,schema:a.schema,title:a.title||a.schema&&a.schema.title};return o.a.isFunction(c)?c(u):t(c)(u)},r}]}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=r(1),i=(r.n(o),r(0)),a=(r.n(i),function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}()),s=function(){function e(){n(this,e),this.name=o.sfPath.name,this.parse=o.sfPath.parse,this.stringify=o.sfPath.stringify,this.normalize=o.sfPath.normalize}return a(e,[{key:"$get",value:function(){return o.sfPath}}]),e}();t.a=s},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):v=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++v<t;)p&&p[v].run();v=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,v=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},function(e,t,r){(function(e,t){!function(e,r){"use strict";function n(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var n={callback:e,args:t};return h[m]=n,p(m),m++}function o(e){delete h[e]}function i(e){var t=e.callback,n=e.args;switch(n.length){case 0:t();break;case 1:t(n[0]);break;case 2:t(n[0],n[1]);break;case 3:t(n[0],n[1],n[2]);break;default:t.apply(r,n)}}function a(e){if(v)setTimeout(a,0,e);else{var t=h[e];if(t){v=!0;try{i(t)}finally{o(e),v=!1}}}}function s(){p=function(e){t.nextTick(function(){a(e)})}}function l(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}function c(){var t="setImmediate$"+Math.random()+"$",r=function(r){r.source===e&&"string"==typeof r.data&&0===r.data.indexOf(t)&&a(+r.data.slice(t.length))};e.addEventListener?e.addEventListener("message",r,!1):e.attachEvent("onmessage",r),p=function(r){e.postMessage(t+r,"*")}}function u(){var e=new MessageChannel;e.port1.onmessage=function(e){var t=e.data;a(t)},p=function(t){e.port2.postMessage(t)}}function f(){var e=y.documentElement;p=function(t){var r=y.createElement("script");r.onreadystatechange=function(){a(t),r.onreadystatechange=null,e.removeChild(r),r=null},e.appendChild(r)}}function d(){p=function(e){setTimeout(a,0,e)}}if(!e.setImmediate){var p,m=1,h={},v=!1,y=e.document,g=Object.getPrototypeOf&&Object.getPrototypeOf(e);g=g&&g.setTimeout?g:e,"[object process]"==={}.toString.call(e.process)?s():l()?c():e.MessageChannel?u():y&&"onreadystatechange"in y.createElement("script")?f():d(),g.setImmediate=n,g.clearImmediate=o}}("undefined"==typeof self?"undefined"==typeof e?this:e:self)}).call(t,r(2),r(17))},function(r,n,o){function i(e,t){this._id=e,this._clearFn=t}var a=Function.prototype.apply;n.setTimeout=function(){return new i(a.call(setTimeout,window,arguments),clearTimeout)},n.setInterval=function(){return new i(a.call(setInterval,window,arguments),clearInterval)},n.clearTimeout=n.clearInterval=function(e){e&&e.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(window,this._id)},n.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},n.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},n._unrefActive=n.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},o(18),n.setImmediate=e,n.clearImmediate=t},,function(e,t,r){r(1),e.exports=r(4)}])}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):v=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++v<t;)p&&p[v].run();v=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,v=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},,,function(e,t,r){r(19),e.exports=r(0)}]);
\ No newline at end of file
+var n=!1,o=!0,i=!0,a=function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(r){var n="[A-Za-z]",o="[0-9]",a=e(o,"[A-Fa-f]"),s=t(t("%[EFef]"+a+"%"+a+a+"%"+a+a)+"|"+t("%[89A-Fa-f]"+a+"%"+a+a)+"|"+t("%"+a+a)),l="[\\:\\/\\?\\#\\[\\]\\@]",c="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",u=e(l,c),f=r?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",d=r?"[\\uE000-\\uF8FF]":"[]",p=e(n,o,"[\\-\\.\\_\\~]",f),m=t(n+e(n,o,"[\\+\\-\\.]")+"*"),h=t(t(s+"|"+e(p,c,"[\\:]"))+"*"),v=t(t("25[0-5]")+"|"+t("2[0-4]"+o)+"|"+t("1"+o+o)+"|"+t("[1-9]"+o)+"|"+o),y=t(v+"\\."+v+"\\."+v+"\\."+v),g=t(a+"{1,4}"),b=(t(t(g+"\\:"+g)+"|"+y),t(e(p,c,"[\\:]")+"+")),x=t("v"+a+"+\\."+e(p,c,"[\\:]")+"+"),w=t("\\["+t(b+"|"+x)+"\\]"),E=t(t(s+"|"+e(p,c))+"*"),$=t(w+"|"+y+"(?!"+E+")|"+E),C=t(o+"*"),k=t(t(h+"@")+"?"+$+t("\\:"+C)+"?"),O=t(s+"|"+e(p,c,"[\\:\\@]")),T=t(O+"*"),A=t(O+"+"),S=t(t(s+"|"+e(p,c,"[\\@]"))+"+"),P=t(t("\\/"+T)+"*"),M=t("\\/"+t(A+P)+"?"),j=t(S+P),D=t(A+P),I="(?!"+O+")",_=(t(P+"|"+M+"|"+j+"|"+D+"|"+I),t(t(O+"|"+e("[\\/\\?]",d))+"*")),F=t(t(O+"|[\\/\\?]")+"*"),R=t(t("\\/\\/"+k+P)+"|"+M+"|"+D+"|"+I),q=t(m+"\\:"+R+t("\\?"+_)+"?"+t("\\#"+F)+"?"),U=t(t("\\/\\/"+k+P)+"|"+M+"|"+j+"|"+I),N=t(U+t("\\?"+_)+"?"+t("\\#"+F)+"?"),L=(t(q+"|"+N),t(m+"\\:"+R+t("\\?"+_)+"?"),"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+D+"|"+I+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$"),H="^(){0}"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+j+"|"+I+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$";"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+D+"|"+I+")")+t("\\?("+_+")")+"?$","^"+t("\\#("+F+")")+"?$","^"+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?$";return{URI_REF:i&&new RegExp("("+L+")|("+H+")"),NOT_SCHEME:new RegExp(e("[^]",n,o,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(e("[^\\%\\:]",p,c),"g"),NOT_HOST:new RegExp(e("[^\\%]",p,c),"g"),NOT_PATH:new RegExp(e("[^\\%\\/\\:\\@]",p,c),"g"),NOT_PATH_NOSCHEME:new RegExp(e("[^\\%\\/\\@]",p,c),"g"),NOT_QUERY:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]",d),"g"),NOT_FRAGMENT:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(e("[^]",p,c),"g"),UNRESERVED:new RegExp(p,"g"),OTHER_CHARS:new RegExp(e("[^\\%]",p,u),"g"),PCT_ENCODED:new RegExp(s,"g")}}function n(e){var t,r=e.charCodeAt(0);return t=r<16?"%0"+r.toString(16).toUpperCase():r<128?"%"+r.toString(16).toUpperCase():r<2048?"%"+(r>>6|192).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase():"%"+(r>>12|224).toString(16).toUpperCase()+"%"+(r>>6&63|128).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase()}function a(e){for(var t,r,n,o="",i=0,a=e.length;i<a;)t=parseInt(e.substr(i+1,2),16),t<128?(o+=String.fromCharCode(t),i+=3):t>=194&&t<224?(a-i>=6?(r=parseInt(e.substr(i+4,2),16),o+=String.fromCharCode((31&t)<<6|63&r)):o+=e.substr(i,6),i+=6):t>=224?(a-i>=9?(r=parseInt(e.substr(i+4,2),16),n=parseInt(e.substr(i+7,2),16),o+=String.fromCharCode((15&t)<<12|(63&r)<<6|63&n)):o+=e.substr(i,9),i+=9):(o+=e.substr(i,3),i+=3);return o}function l(e){return void 0===e?"undefined":null===e?"null":Object.prototype.toString.call(e).split(" ").pop().split("]").shift().toLowerCase()}function c(e){return e.toUpperCase()}function u(e,t){function r(e){var r=a(e);return r.match(t.UNRESERVED)?r:e}return e.scheme&&(e.scheme=String(e.scheme).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_SCHEME,"")),void 0!==e.userinfo&&(e.userinfo=String(e.userinfo).replace(t.PCT_ENCODED,r).replace(t.NOT_USERINFO,n).replace(t.PCT_ENCODED,c)),void 0!==e.host&&(e.host=String(e.host).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_HOST,n).replace(t.PCT_ENCODED,c)),void 0!==e.path&&(e.path=String(e.path).replace(t.PCT_ENCODED,r).replace(e.scheme?t.NOT_PATH:t.NOT_PATH_NOSCHEME,n).replace(t.PCT_ENCODED,c)),void 0!==e.query&&(e.query=String(e.query).replace(t.PCT_ENCODED,r).replace(t.NOT_QUERY,n).replace(t.PCT_ENCODED,c)),void 0!==e.fragment&&(e.fragment=String(e.fragment).replace(t.PCT_ENCODED,r).replace(t.NOT_FRAGMENT,n).replace(t.PCT_ENCODED,c)),e}function f(e,t){void 0===t&&(t={});var r,n,l=o&&t.iri!==!1?E:w,c=!1,f={};if("suffix"===t.reference&&(e=(t.scheme?t.scheme+":":"")+"//"+e),i?(r=e.match(l.URI_REF),r&&(r=r[1]?r.slice(1,10):r.slice(10,19)),r||(c=!0,t.tolerant||(f.error=f.error||"URI is not strictly valid."),r=e.match($))):r=e.match($),r){if(A?(f.scheme=r[1],f.userinfo=r[3],f.host=r[4],f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=r[7],f.fragment=r[8],isNaN(f.port)&&(f.port=r[5])):(f.scheme=r[1]||void 0,f.userinfo=e.indexOf("@")!==-1?r[3]:void 0,f.host=e.indexOf("//")!==-1?r[4]:void 0,f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=e.indexOf("?")!==-1?r[7]:void 0,f.fragment=e.indexOf("#")!==-1?r[8]:void 0,isNaN(f.port)&&(f.port=e.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?r[4]:void 0)),void 0!==f.scheme||void 0!==f.userinfo||void 0!==f.host||void 0!==f.port||f.path||void 0!==f.query?void 0===f.scheme?f.reference="relative":void 0===f.fragment?f.reference="absolute":f.reference="uri":f.reference="same-document",t.reference&&"suffix"!==t.reference&&t.reference!==f.reference&&(f.error=f.error||"URI is not a "+t.reference+" reference."),n=S[(t.scheme||f.scheme||"").toLowerCase()],!o||"undefined"==typeof s||t.unicodeSupport||n&&n.unicodeSupport)u(f,l);else{if(f.host&&(t.domainHost||n&&n.domainHost))try{f.host=s.toASCII(f.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(e){f.error=f.error||"Host's domain name can not be converted to ASCII via punycode: "+e}u(f,w)}n&&n.parse&&n.parse(f,t)}else c=!0,f.error=f.error||"URI can not be parsed.";return f}function d(e,t){var r=[];return void 0!==e.userinfo&&(r.push(e.userinfo),r.push("@")),void 0!==e.host&&r.push(e.host),"number"==typeof e.port&&(r.push(":"),r.push(e.port.toString(10))),r.length?r.join(""):void 0}function p(e){for(var t,r=[];e.length;)e.match(C)?e=e.replace(C,""):e.match(k)?e=e.replace(k,"/"):e.match(O)?(e=e.replace(O,"/"),r.pop()):"."===e||".."===e?e="":(t=e.match(T)[0],e=e.slice(t.length),r.push(t));return r.join("")}function m(e,t){void 0===t&&(t={});var r,n,i,l=o&&t.iri?E:w,c=[];if(r=S[(t.scheme||e.scheme||"").toLowerCase()],r&&r.serialize&&r.serialize(e,t),o&&"undefined"!=typeof s&&e.host&&(t.domainHost||r&&r.domainHost))try{e.host=t.iri?s.toUnicode(e.host):s.toASCII(e.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(r){e.error=e.error||"Host's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}return u(e,l),"suffix"!==t.reference&&e.scheme&&(c.push(e.scheme),c.push(":")),n=d(e,t),void 0!==n&&("suffix"!==t.reference&&c.push("//"),c.push(n),e.path&&"/"!==e.path.charAt(0)&&c.push("/")),void 0!==e.path&&(i=e.path,t.absolutePath||r&&r.absolutePath||(i=p(i)),void 0===n&&(i=i.replace(/^\/\//,"/%2F")),c.push(i)),void 0!==e.query&&(c.push("?"),c.push(e.query)),void 0!==e.fragment&&(c.push("#"),c.push(e.fragment)),c.join("")}function h(e,t,r,n){void 0===r&&(r={});var o={};return n||(e=f(m(e,r),r),t=f(m(t,r),r)),r=r||{},!r.tolerant&&t.scheme?(o.scheme=t.scheme,o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(t.path?("/"===t.path.charAt(0)?o.path=p(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?o.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:o.path=t.path:o.path="/"+t.path,o.path=p(o.path)),o.query=t.query):(o.path=e.path,void 0!==t.query?o.query=t.query:o.query=e.query),o.userinfo=e.userinfo,o.host=e.host,o.port=e.port),o.scheme=e.scheme),o.fragment=t.fragment,o}function v(e,t,r){return m(h(f(e,r),f(t,r),r,!0),r)}function y(e,t){return"string"==typeof e?e=m(f(e,t),t):"object"===l(e)&&(e=f(m(e,t),t)),e}function g(e,t,r){return"string"==typeof e?e=m(f(e,r),r):"object"===l(e)&&(e=m(e,r)),"string"==typeof t?t=m(f(t,r),r):"object"===l(t)&&(t=m(t,r)),e===t}function b(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.ESCAPE:w.ESCAPE,n)}function x(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.PCT_ENCODED:w.PCT_ENCODED,a)}var w=r(!1),E=o?r(!0):void 0,$=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?([^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n)*))?/i,C=/^\.\.?\//,k=/^\/\.(\/|$)/,O=/^\/\.\.(\/|$)/,T=/^\/?(?:.|\n)*?(?=\/|$)/,A=void 0==="".match(/(){0}/)[1],S={};return{IRI_SUPPORT:o,VALIDATE_SUPPORT:i,pctEncChar:n,pctDecChars:a,SCHEMES:S,parse:f,_recomposeAuthority:d,removeDotSegments:p,serialize:m,resolveComponents:h,resolve:v,normalize:y,equal:g,escapeComponent:b,unescapeComponent:x}}();if(!n&&"undefined"!=typeof t&&"function"==typeof e){var s=e("./punycode");t.exports=a,e("./schemes")}},{"./punycode":18,"./schemes":19}]},{},[1])(1)})},function(e,t,r){"use strict";function n(e,t){var l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:r.i(i.createDefaults)(),c=arguments[3],u=arguments[4],f=arguments[5],d=arguments[6],p=[],m=[];t=t||[];var h=t.indexOf("*");u=u||{};var v={},y=t.indexOf("...");if("object"===("undefined"==typeof e?"undefined":s(e))&&e.hasOwnProperty("properties")){f=f||e.readonly||e.readOnly,v=r.i(i.defaultForm)(e,l,c,u);var g=v.lookup;e=g||e,p=p.concat(v.form)}return h!==-1&&(t=t.slice(0,h).concat(p).concat(t.slice(h+1))),v.form&&y!==-1&&!function(){var e=t.map(function(e){return"string"==typeof e?e:e.key?e.key:void 0}).filter(function(e){return void 0!==e});m=m.concat(v.form.map(function(t){var r=e.indexOf(t.key[0])!==-1;if(!r)return t}).filter(function(e){return void 0!==e}))}(),y!==-1&&(t=t.slice(0,y).concat(m).concat(t.slice(y+1))),t.map(function(t){if("string"==typeof t&&(t={key:t}),t.key&&"string"==typeof t.key&&(t.key=r.i(o.parse)(t.key)),t.titleMap&&(t.titleMap=r.i(a.a)(t.titleMap)),t.key){var i=r.i(o.stringify)(t.key);e[i]&&!function(){var r=e[i];r&&Object.keys(r).forEach(function(e){void 0===t[e]&&(t[e]=r[e])})}()}return f===!0&&(t.readonly=!0),t.items&&(t.items=n(e,t.items,l,c,u,t.readonly,d)),t.tabs&&t.tabs.forEach(function(r){r.items&&(r.items=n(e,r.items,l,c,u,t.readonly,d))}),"checkbox"===t.type&&(void 0===t.schema?t.schema={default:!1}:void 0===t.schema.default&&(t.schema.default=!1)),d&&"template"===t.type&&!t.template&&t.templateUrl&&d.push(t),t})}var o=r(0),i=r(3),a=r(1);t.a=n;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e}},function(e,t,r){"use strict";function n(e,t){var r=new Promise(function(t,r){o.resolveRefs(e,{filter:["relative","local","remote"]}).then(function(e){t(e.resolved)}).catch(function(e){r(new Error(e))})});return"function"!=typeof t?r:void r.then(function(e){t(null,e)}).catch(function(e){t(e)})}var o=r(5);r.n(o);t.a=n},function(e,t,r){"use strict";function n(e,t,r){t||(t=this);var n="string"==typeof e?o.parse(e):e;if("undefined"!=typeof r&&1===n.length)return t[n[0]]=r,t;"undefined"!=typeof r&&"undefined"==typeof t[n[0]]&&(t[n[0]]=n.length>2&&i.test(n[1])?[]:{});for(var a=t[n[0]],s=1;s<n.length;s++){if(""===n[s])return;if("undefined"!=typeof r){if(s===n.length-1)return a[n[s]]=r,r;var l=a[n[s]];"undefined"!=typeof l&&null!==l||(l=i.test(n[s+1])?[]:{},a[n[s]]=l),a=l}else a&&(a=a[n[s]])}return a}var o=r(0);t.a=n;var i=/^\d+$/},function(e,t,r){"use strict";function n(e,t,r,n){n=void 0===n||n,r=r||[];var o=function e(t,r,o){if(r(t,o),t.properties&&Object.keys(t.properties).forEach(function(n){var i=o.slice();i.push(n),e(t.properties[n],r,i)}),!n&&t.items){var i=o.slice();i.push(""),e(t.items,r,i)}};o(e,t,r||[])}function o(e,t){t(e),e.items&&e.items.forEach(function(e){o(e,t)}),e.tabs&&e.tabs.forEach(function(e){e.items&&e.items.forEach(function(e){o(e,t)})})}t.a=n,t.b=o},function(e,t,r){"use strict";function n(e,t){if(!e)return{valid:!0};var r=e.schema;if(!r)return{valid:!0};""===t&&(t=void 0),"number"===e.type&&null===t&&(t=void 0);var n={type:"object",properties:{},required:void 0},o=e.key[e.key.length-1];n.properties[o]=r,e.required&&(n.required=[o]);var a={};return t&&(a[o]=t),i.a.validateResult(a,n)}var o=r(12),i=r.n(o);t.a=n},function(e,t,r){"use strict";var n;!function(o){var i={parse:function(e){if("string"!=typeof e)throw new TypeError("ObjectPath.parse must be passed a string");for(var t,r,n,o,i=0,a=[];i<e.length;)if(t=e.indexOf(".",i),r=e.indexOf("[",i),t===-1&&r===-1)a.push(e.slice(i,e.length)),i=e.length;else if(r===-1||t!==-1&&t<r)a.push(e.slice(i,t)),i=t+1;else if(r>i&&(a.push(e.slice(i,r)),i=r),n=e.slice(r+1,r+2),'"'!==n&&"'"!==n)o=e.indexOf("]",r),o===-1&&(o=e.length),a.push(e.slice(i+1,o)),i="."===e.slice(o+1,o+2)?o+2:o+1;else{for(o=e.indexOf(n+"]",r),o===-1&&(o=e.length);"\\"===e.slice(o-1,o)&&r<e.length;)r++,o=e.indexOf(n+"]",r);a.push(e.slice(i+2,o).replace(new RegExp("\\"+n,"g"),n)),i="."===e.slice(o+2,o+3)?o+3:o+2}return a},stringify:function(e,t){return Array.isArray(e)||(e=[e.toString()]),t='"'===t?'"':"'",e.map(function(e){return"["+t+e.toString().replace(new RegExp(t,"g"),"\\"+t)+t+"]"}).join("")},normalize:function(e,t){return i.stringify(Array.isArray(e)?e:i.parse(e),t)},registerModule:function(e){e.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=i.parse,this.stringify=i.stringify,this.normalize=i.normalize,this.$get=function(){return i}})}};n=function(){return{ObjectPath:i}}.call(t,r,t,e),!(n!==o&&(e.exports=n))}()},function(e,t){e.exports=tv4},function(e,t,r){e.exports=r(4)}])}).call(t,r(2),r(19).setImmediate)},function(e,t){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(r=window)}e.exports=r},,function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(1),o=(r.n(n),r(0)),i=r.n(o),a=r(14),s=r(12),l=r(13),c=r(15),u=r(16),f=r(7),d=r(8),p=r(10),m=r(6),h=r(9),v=r(11),y=r(5),g=[];try{i.a.module("ngSanitize"),g.push("ngSanitize")}catch(e){}try{i.a.module("ui.sortable"),g.push("ui.sortable")}catch(e){}try{i.a.module("angularSpectrumColorpicker"),g.push("angularSpectrumColorpicker")}catch(e){}i.a.module("schemaForm",g).provider("sfPath",u.a).provider("sfBuilder",["sfPathProvider",a.a]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",s.a]).provider("sfErrorMessage",c.a).provider("schemaForm",["sfPathProvider",l.a]).factory("sfSelect",function(){return n.select}).factory("sfValidator",function(){return n.validate}).directive("sfChanged",f.a).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",d.a]).directive("sfMessage",["$injector","sfErrorMessage",p.a]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",m.a]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",v.a]).directive("schemaValidate",["sfValidator","$parse","sfSelect",y.a]).directive("sfKeyController",["schemaForm","sfPath",h.a])},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r){return{restrict:"A",scope:!1,priority:500,require:"ngModel",link:function(t,n,i,a){t.$emit("schemaFormPropagateNgModelController",a);var s=null,l=t.$eval(i.schemaValidate);l.copyValueTo&&a.$viewChangeListeners.push(function(){var e=l.copyValueTo;o.a.forEach(e,function(e){r(e,t.model,a.$modelValue)})});var c=function(r,n){if(!l)return r;if(t.options&&t.options.tv4Validation===!1)return r;var o=e(l,r);Object.keys(a.$error).filter(function(e){return 0===e.indexOf("tv4-")}).forEach(function(e){a.$setValidity(e,!0)});{if(o.valid||a.$pristine&&!n)return r;if(a.$setValidity("tv4-"+o.error.code,!1),s=o.error,a.$validators)return r}};"function"==typeof l.ngModel&&l.ngModel(a),["$parsers","$viewChangeListeners","$formatters"].forEach(function(e){l[e]&&a[e]&&l[e].forEach(function(t){a[e].push(t)})}),["$validators","$asyncValidators"].forEach(function(e){l[e]&&a[e]&&o.a.forEach(l[e],function(r,n){a[e][n]=function(e,n){return r(e,n,t.model,l)}})}),a.$parsers.push(c),a.$validators&&(a.$validators.schemaForm=function(){return!Object.keys(a.$error).some(function(e){return"schemaForm"!==e})});var u=l.schema;t.validateField=function(e,t){var r=void 0===e;(r||a.$$parentForm.$name===e)&&((r||u&&u.type.indexOf("array")!==-1)&&c(a.$modelValue,t),a.$setDirty?(a.$setDirty(),a.$setViewValue(a.$viewValue),a.$commitViewValue(),"checkbox"===l.type?l.required&&void 0===a.$modelValue&&a.$setValidity("tv4-302",!1):l.required&&a.$isEmpty(a.$modelValue)&&a.$setValidity("tv4-302",!1)):a.$setViewValue(a.$viewValue))};var f=!0;a.$formatters.push(function(e){return!a.$pristine||!f||t.options&&t.options.validateOnRender===!0?(c(a.$modelValue),e):(f=!1,e)}),t.$on("schemaFormValidate",function(e,r){t.validateField(r,!0)}),t.schemaError=function(){return s}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r){return{scope:!0,controller:["$scope",function(e){this.key=e.form&&e.form.key?e.form.key.splice(0,-2):[]}],link:function(n,i,a){n.min=0,n.modelArray=n.$eval(a.sfNewArray);var s=function(){n.modelArray=n.$eval(a.sfNewArray),n.ngModel&&n.ngModel.$pristine&&n.firstDigest&&(!n.options||n.options.validateOnRender!==!0)||n.validateField&&n.validateField()},l=function(){n.form&&n.form.onChange&&(o.a.isFunction(n.form.onChange)?n.form.onChange(n.modelArray,n.form):n.evalExpr(n.form.onChange,{modelValue:n.modelArray,form:n.form}))},c=function(){var r=n.modelArray;if(!r){var o=t.parse(a.sfNewArray);r=[],e(o,n,r),n.modelArray=r}return r},u=n.$watch("form",function(e){if(e){if(e.titleMap||e.startEmpty===!0||n.modelArray&&0!==n.modelArray.length||n.appendToArray(),n.$watch(function(e){return JSON.stringify(e.modelArray)},function(){s(),l()}),e.titleMap&&e.titleMap.length>0){n.titleMapValues=[];var t=function(t){n.titleMapValues=[],t=t||[],e.titleMap.forEach(function(e){n.titleMapValues.push(t.indexOf(e.value)!==-1)})};t(n.modelArray),n.$watchCollection("modelArray",t),n.$watchCollection("titleMapValues",function(t,r){if(t&&t!==r){var o=c();e.titleMap.forEach(function(e,r){var n=o.indexOf(e.value);n===-1&&t[r]&&o.push(e.value),n===-1||t[r]||o.splice(n,1)}),n.validateField&&n.validateField()}})}u()}});n.appendToArray=function(){var t,i=c();if(n.form&&n.form.schema&&n.form.schema.items){var a=n.form.schema.items;a.type&&a.type.indexOf("object")!==-1?(t={},n.options&&n.options.setSchemaDefaults===!1||(t=o.a.isDefined(a.default)?a.default:t,t&&r.traverseSchema(a,function(r,n){o.a.isDefined(r.default)&&e(n,t,r.default)}))):a.type&&a.type.indexOf("array")!==-1?(t=[],n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t)):n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t)}return i.push(t),i},n.deleteFromArray=function(e){var t=n.modelArray;return t&&t.splice(e,1),t};var f=function(e){return function(t){t.key&&(t.key[t.key.indexOf("")]=e)}},d={};n.copyWithIndex=function(e){var t=n.form;if(!d[e]){var i=t.items[0];if(t.items.length>1&&(i={type:"section",items:t.items.map(function(e){return e.ngModelOptions=t.ngModelOptions,o.a.isUndefined(e.readonly)&&(e.readonly=t.readonly),e})}),i){var a=o.a.copy(i);a.arrayIndex=e,r.traverseForm(a,f(e)),d[e]=a}}return d[e]}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){return{require:"ngModel",restrict:"AC",scope:!1,link:function(e,t,r,n){var i=e.$eval(r.sfChanged);i&&i.onChange&&n.$viewChangeListeners.push(function(){o.a.isFunction(i.onChange)?i.onChange(n.$modelValue,i):e.evalExpr(i.onChange,{modelValue:n.$modelValue,form:i,arrayIndex:e.$index,arrayIndices:e.arrayIndices,path:e.path,$i:e.$i,$index:e.$index})})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r,n,a,s,l,c,u){var f={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function(e,t,r,n){var o=n[0];n[1],n[2];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.initialForm=Object.assign({},o.lookup["f"+r.sfField]),e.form=o.lookup["f"+r.sfField]},post:function(e,t,r,n){var s=n[0],d=n[1];n[2];e.getKey=function(t){var r=t||f.COMPLETE,n=e.parentKey?e.parentKey.slice(0,e.parentKey.length-1):[];if(e.completeKey!==e.form.key&&("number"==typeof e.$index&&(n=n.concat(e.$index)),e.form.key&&e.form.key.length))if("number"==typeof n[n.length-1]&&e.form.key.length>=1){var o=e.form.key.length-n.length;e.completeKey=n.concat(e.form.key.slice(-o))}else e.completeKey=e.form.key.slice();if(Array.isArray(e.completeKey))return r===f.COMPLETE?e.completeKey:e.completeKey.reduce(function(e,t,n){return-1!==[r].indexOf("undefined"==typeof t?"undefined":i(t))?e.concat(t):e},[])},e.form.key&&(e.form.key=e.completeKey=e.getKey()),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=r||!1,o=t&&d&&d.$name?d.$name:void 0,i=e.completeKey;return Array.isArray(i)?c.name(i,"-",o,n):""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(s?s.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return s?s.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&a(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.errors===!1?e.ngModel.$invalid&&!e.ngModel.$pristine:e.ngModel.$invalid)},e.errorMessage=function(t){return l.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)},e.form.htmlClass=e.form.htmlClass||"",e.idClass=e.fieldId(!1)+" "+e.fieldId(!1,!0);var p=e.form;p.key&&(e.$on("schemaForm.error."+p.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(p.validationMessage||(p.validationMessage={}),p.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){var t=e.getKey();if(!e.externalDestructionInProgress){var r=p.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(t&&"retain"!==r){var n=e.model;if(t.length>1&&(n=u(t.slice(0,t.length-1),n)),void 0===n)return;var o=p.schema&&p.schema.type||"";"empty"===r&&o.indexOf("string")!==-1?n[t.slice(-1)]="":"empty"===r&&o.indexOf("object")!==-1?n[t.slice(-1)]={}:"empty"===r&&o.indexOf("array")!==-1?n[t.slice(-1)]=[]:"null"===r?n[t.slice(-1)]=null:delete n[t.slice(-1)]}}}))}}}}},function(e,t,r){"use strict";t.a=function(e,t){return{scope:!0,require:["?^^sfNewArray"],link:{pre:function(e,r,n,o){e.parentKey=e.parentKey||[];var i=t.parse(n.sfParentKey),a=i.length-e.parentKey.length;i.length>1&&(i=i.splice(-a)),e.parentKey=e.parentKey.concat(i,Number(n.sfIndex)),e.arrayIndex=Number(n.sfIndex),e.arrayIndices=e.arrayIndices||[],e.arrayIndices=e.arrayIndices.concat(e.arrayIndex),e.$i=e.arrayIndices,e.path=function(t){var r=-1;return t=t.replace(/\[\]/gi,function(t){return r++,"["+e.$i[r]+"]"}),e.evalExpr(t,e)}}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r=e.has("$sanitize")?e.get("$sanitize"):function(e){return e};return{scope:!1,restrict:"EA",link:function(e,n,i){var a="";i.sfMessage&&e.$watch(i.sfMessage,function(t){t&&(a=r(t),c(!!e.ngModel))});var s,l=function(e){e!==s&&(n.html(e),s=e)},c=function(r){if(r)if(e.hasError()){var n=[];o.a.forEach(e.ngModel&&e.ngModel.$error,function(e,t){e&&n.push(t)}),n=n.filter(function(e){return"schemaForm"!==e});var i=n[0];l(i?t.interpolate(i,e.ngModel.$modelValue,e.ngModel.$viewValue,e.form,e.options&&e.options.validationMessage):a)}else l(a);else l(a)};c();var u=e.$watch("ngModel",function(e){e&&(e.$parsers.push(function(e){return c(!0),e}),e.$formatters.push(function(e){return c(!0),e}),u())});e.$watchCollection("ngModel.$error",function(){c(!!e.ngModel)})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r,n,i,a,s,l,c){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function(e){this.$onInit=function(){this.evalInParentScope=function(t,r){return e.$parent.$eval(t,r)};var t=this;e.lookup=function(e){return e&&(t.lookup=e),t.lookup}},1===o.a.version.major&&o.a.version.minor<5&&this.$onInit()}],replace:!1,restrict:"A",transclude:!0,require:"?form",link:function(l,u,f,d,p){l.formCtrl=d;var m={};p(l,function(e){if(e.addClass("schema-form-ignore"),u.prepend(e),u[0].querySelectorAll){var t=u[0].querySelectorAll("[ng-model]");if(t)for(var r=0;r<t.length;r++){var n=t[r].getAttribute("ng-model");m[n.substring(n.indexOf(".")+1)]=!0}}});var h,v={};l.resolveReferences=function(e,t){i.jsonref(e).then(function(e){l.render(e,t)}).catch(function(e){new Error(e)})},l.render=function(e,o){var a=[],s=i.merge(e,o,void 0,m,l.options,void 0,a);a.length>0?n.all(a.map(function(e){return t.get(e.templateUrl,{cache:r}).then(function(t){e.template=t.data})})).then(function(){l.internalRender(e,o,s)}):l.internalRender(e,o,s)},l.internalRender=function(t,r,n){h&&(l.externalDestructionInProgress=!0,h.$destroy(),l.externalDestructionInProgress=!1),h=l.$new(),h.schemaForm={form:n,schema:t},Array.prototype.forEach.call(u.children(),function(e){var t=o.a.element(e);!1===t.hasClass("schema-form-ignore")&&t.remove()});for(var d={},p=u[0].querySelectorAll("*[sf-insert-field]"),m=0;m<p.length;m++)d[p[m].getAttribute("sf-insert-field")]=p[m];var v=a.decorator(f.sfUseDecorator),y=Object.create(null);l.lookup(y),u[0].appendChild(c.build(n,v,d,y)),h.firstDigest=!0,setTimeout(function(){h.firstDigest=!1,l.$apply()},0),e(u.children())(h),l.options&&l.options.setSchemaDefaults===!1||i.traverseSchema(t,function(e,t){if(o.a.isDefined(e.default)){var r=s(t,l.model);o.a.isUndefined(r)&&s(t,l.model,e.default)}}),l.$emit("sf-render-finished",u)};var y=["*"];l.$watch(function(){var e=l.schema,t=l.initialForm||y;t&&e&&e.type&&(v.form!==t||v.schema!==e)&&((!e.properties||0===Object.keys(e.properties).length)&&(t.indexOf("*")||t.indexOf("...")),v.schema=e,v.form=t,l.resolveReferences(e,t))}),l.$on("schemaFormRedraw",function(){var e=l.schema,t=l.initialForm?o.a.copy(l.initialForm):["*"];e&&l.resolveReferences(e,t)}),l.$on("$destroy",function(){l.externalDestructionInProgress=!0}),l.evalExpr=function(e,t){return l.$parent.$eval(e,t)}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r="",n={},i=function(e,t){"sfDecorator"===e&&(e=r);var o=n[e];return o[t.type]?o[t.type].template:o.default.template},a=function(r){e.directive(r,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function(e,n,a,s,l,c,u,f,d){return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["?^sfSchema","?^form"],link:function(e,p,m,h){var v=h[0],y=h[1];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=e.parentKey||[];if(e.form.key){if("number"==typeof n[n.length-1]){var o=n.concat(e.form.key.slice(-1)),i=t&&y&&y.$name?y.$name:void 0;return f.name(o,"-",i,r)}var i=t&&y&&y.$name?y.$name:void 0;return f.name(e.form.key,"-",i,r)}return""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(v?v.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return v?v.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&l(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.ngModel.$invalid&&!e.ngModel.$pristine)},e.errorMessage=function(t){return u.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)};var g=e.$watch(m.form,function(l){if(l){l.ngModelOptions=l.ngModelOptions||{},e.form=l;var u;if("template"===l.type&&l.template)u=c.when(l.template);else{var m="template"===l.type?l.templateUrl:i(r,l);u=a.get(m,{cache:s}).then(function(e){return e.data})}u.then(function(r){if(l.key){var i=l.key?t.stringify(l.key).replace(/"/g,"&quot;"):"";r=r.replace(/\$\$value\$\$/g,"model"+("["!==i[0]?".":"")+i)}if(p.html(r),l.condition){var a='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';l.key&&(a='evalExpr(form.condition, {model: model, "arrayIndex": arrayIndex, "modelValue": model'+f.stringify(l.key)+"})"),o.a.forEach(p.children(),function(e){var t=e.getAttribute("ng-if");e.setAttribute("ng-if",t?"("+t+") || ("+a+")":a)})}n(p.contents())(e)}),l.key&&(e.$on("schemaForm.error."+l.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(l.validationMessage||(l.validationMessage={}),l.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){if(!e.externalDestructionInProgress){var t=l.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(l.key&&"retain"!==t){var r=e.model;if(l.key.length>1&&(r=d(l.key.slice(0,l.key.length-1),r)),void 0===r)return;var n=l.schema&&l.schema.type||"";"empty"===t&&n.indexOf("string")!==-1?r[l.key.slice(-1)]="":"empty"===t&&n.indexOf("object")!==-1?r[l.key.slice(-1)]={}:"empty"===t&&n.indexOf("array")!==-1?r[l.key.slice(-1)]=[]:"null"===t?r[l.key.slice(-1)]=null:delete r[l.key.slice(-1)]}}})),g()}})}}}])},s=function(t,r,n){n=!!o.a.isDefined(n)&&n,e.directive("sf"+o.a.uppercase(t[0])+t.substr(1),function(){return{restrict:"EAC",scope:!0,replace:!0,transclude:n,template:'<sf-decorator form="form"></sf-decorator>',link:function(e,r,n){var i={items:"c",titleMap:"c",schema:"c"},a={type:t},s=!0;o.a.forEach(n,function(t,r){if("$"!==r[0]&&0!==r.indexOf("ng")&&"sfField"!==r){var l=function(t){o.a.isDefined(t)&&t!==a[r]&&(a[r]=t,s&&a.type&&(a.key||o.a.isUndefined(n.key))&&(e.form=a,s=!1))};"model"===r?e.$watch(t,function(t){t&&e.model!==t&&(e.model=t)}):"c"===i[r]?e.$watchCollection(t,l):n.$observe(r,l)}})}}})};this.createDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){n[e][r]={template:t,replace:!1,builder:[]}}),n[r]||(r=e),a(e)},this.defineDecorator=function(e,t){
+n[e]={__name:e},o.a.forEach(t,function(t,r){t.builder=t.builder||[],t.replace=!o.a.isDefined(t.replace)||t.replace,n[e][r]=t}),n[r]||(r=e),a(e)},this.createDirective=s,this.createDirectives=function(e){o.a.forEach(e,function(e,t){s(t,e)})},this.decorator=function(e){return e=e||r,n[e]},this.addMapping=function(e,t,r,o,i){n[e]&&(n[e][t]={template:r,builder:o,replace:!!i})},this.defineAddOn=function(e,t,r,o){n[e]&&(n[e][t]={template:r,builder:o,replace:!0})},this.$get=function(){return{decorator:function(e){return n[e]||n[r]},defaultDecorator:r}},a("sfDecorator")}},function(e,t,r){"use strict";var n=r(0),o=(r.n(n),r(1));r.n(o);t.a=function(){var e=function(e){return e},t=o.schemaDefaults.createDefaults();this.defaults=t,this.stdFormObj=o.schemaDefaults.stdFormObj,this.defaultFormDefinition=o.schemaDefaults.defaultFormDefinition,this.postProcess=function(t){e=t},this.appendRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].push(t)},this.prependRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].unshift(t)},this.createStandardForm=o.schemaDefaults.stdFormObj,this.$get=function(){var t={},n=this.defaults;return t.jsonref=o.jsonref,t.defaults=function(e,t,r,i){var a=t||n;return o.schemaDefaults.defaultForm(e,a,r,i)},t.merge=function(n){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["*"],a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.typeDefault,s=arguments[3],l=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},c=arguments.length>5&&void 0!==arguments[5]&&arguments[5],u=arguments[6],f=r.i(o.merge)(n,i,a,s,l,c,u);return e(f)},t.typeDefault=n,t.traverseSchema=o.traverseSchema,t.traverseForm=o.traverseForm,t}}},function(e,t,r){"use strict";t.a=function(e){var t=/[A-Z]/g,r=function(e,r){return r=r||"_",e.replace(t,function(e,t){return(t?r:"")+e.toLowerCase()})},n=0;"firstElementChild"in document.createDocumentFragment()||Object.defineProperty(DocumentFragment.prototype,"firstElementChild",{get:function(){for(var e,t=this.childNodes,r=0,n=t.length;r<n;++r)if(e=t[r],1===e.nodeType)return e;return null}});var o={sfField:function(e){e.fieldFrag.firstElementChild.setAttribute("sf-field",n),e.lookup["f"+n]=e.form,n++},ngModel:function(t){if(t.form.key){var r=t.form.key;t.state.keyRedaction&&(r=r.slice(t.state.keyRedaction));var n;if(t.state.modelValue)n=t.state.modelValue;else{var o=e.stringify(r).replace(/"/g,"&quot;");n=t.state.modelName||"model",o&&(n+=("["!==o[0]?".":"")+o)}for(var i=t.fieldFrag.querySelectorAll("[sf-field-model]"),a=0;a<i.length;a++){var s=i[a],l=s.getAttribute("sf-field-model");if(l&&""!==l)if("replaceAll"===l)for(var c=s.attributes,u=0;u<c.length;u++)c[u].value&&c[u].value.indexOf("$$value")!==-1&&(c[u].value=c[u].value.replace(/\$\$value\$\$/g,n));else{var f=s.getAttribute(l);f&&f.indexOf("$$value$$")?s.setAttribute(l,f.replace(/\$\$value\$\$/g,n)):s.setAttribute(l,n)}else s.setAttribute("ng-model",n)}}},simpleTransclusion:function(e){var t=e.build(e.form.items,e.path+".items",e.state);e.fieldFrag.firstChild.appendChild(t)},ngModelOptions:function(e){e.form.ngModelOptions&&Object.keys(e.form.ngModelOptions).length>0&&e.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(e.form.ngModelOptions))},transclusion:function(e){var t=e.fieldFrag.querySelectorAll("[sf-field-transclude]");if(t.length)for(var r=0;r<t.length;r++){var n=t[r],o=n.getAttribute("sf-field-transclude")||"items",i=e.form[o];if(i){var a=e.build(i,e.path+"."+o,e.state);n.appendChild(a)}}},condition:function(t){var r="",n="undefined",o="";if(t.form.condition){t.form.key&&(r=e.stringify(t.form.key),n="model"+("["===r[0]?"":".")+r);for(var i="evalExpr("+t.path+'.condition, { model: model, "arrayIndex": $index, "arrayIndices": arrayIndices, "path": path, "$i": $i, "$index": $index, "modelValue": '+n+"})",a=t.fieldFrag.children||t.fieldFrag.childNodes,s=0;s<a.length;s++){var l=a[s];l.hasAttribute&&l.hasAttribute("ng-if")&&(o=l.getAttribute("ng-if")),l.setAttribute&&l.setAttribute("ng-if",o?"("+o+") || ("+i+")":i)}}},array:function(t){var r=t.fieldFrag.querySelector("[schema-form-array-items]");if(t.form.key){t.form.key.filter(function(e){return""===e}).length}if(r){var n=angular.copy(t.state);if(n.keyRedaction=0,n.keyRedaction+=t.form.key.length+1,t.form.schema&&t.form.schema.items&&t.form.schema.items.type&&t.form.schema.items.type.indexOf("object")===-1&&t.form.schema.items.type.indexOf("array")===-1){e.stringify(t.form.key).replace(/"/g,"&quot;")+"[$index]";n.modelValue="modelArray[$index]"}else n.modelName="item";n.arrayCompatFlag=!0;var o=t.build(t.form.items,t.path+".items",n);r.appendChild(o)}},numeric:function(e){var t=e.fieldFrag.querySelector("input"),r=e.form.maximum||!1,n=e.form.exclusiveMaximum||!1,o=e.form.minimum||!1,i=e.form.exclusiveMinimum||!1,a=e.form.multipleOf||!1;t&&(a!==!1&&t.setAttribute("step",a),r!==!1&&(n!==!1&&a!==!1&&(r-=a),t.setAttribute("max",r)),o!==!1&&(i!==!1&&a!==!1&&(o+=a),t.setAttribute("min",o)))}};this.builders=o;var i=[o.sfField,o.ngModel,o.ngModelOptions,o.condition];this.stdBuilders=i,this.$get=["$templateCache","schemaFormDecorators","sfPath",function(e,t,n){var a=function(e,t){if(e.key){var r=t[n.stringify(e.key)];if(r){for(;r.firstChild;)r.removeChild(r.firstChild);return r}}},s=function e(t,n,o,i,s,l,c){l=l||{},l=l||{},c=c||Object.create(null),s=s||"schemaForm.form";var u=document.createDocumentFragment();return t.reduce(function(t,u,f){if(!u.type)return t;var d=n[u.type]||n.default;if(d.replace){var p;l.arrayCompatFlag=!1;var m=document.createElement("div"),h=o(u,d)||o(u,n.default);for(m.innerHTML=h,p=document.createDocumentFragment();m.childNodes.length>0;)p.appendChild(m.childNodes[0]);var v={fieldFrag:p,form:u,lookup:c,state:l,path:s+"["+f+"]",build:function(t,r,a){return e(t,n,o,i,r,a,c)}},y=u.builder||d.builder;"function"==typeof y?y(v):y.forEach(function(e){e(v)}),(a(u,i)||t).appendChild(p)}else{var g=document.createElement(r(n.__name,"-"));l.arrayCompatFlag?g.setAttribute("form","copyWithIndex($index)"):g.setAttribute("form",s+"["+f+"]"),(a(u,i)||t).appendChild(g)}return t},u),u};return{build:function(t,r,n,o){return s(t,r,function(t,r){return"template"===t.type?t.template:e.get(r.template)},n,void 0,void 0,o)},builder:o,stdBuilders:i,internalBuild:s}}]}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){var e={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};e.number=e[105],e.required=e[302],e.min=e[101],e.max=e[103],e.maxlength=e[201],e.minlength=e[200],e.pattern=e[202],this.setDefaultMessages=function(t){e=t},this.getDefaultMessages=function(){return e},this.setDefaultMessage=function(t,r){e[t]=r},this.$get=["$interpolate",function(t){var r={};return r.defaultMessages=e,r.interpolate=function(r,n,i,a,s){s=s||{};var l=a.validationMessage||{};0===r.indexOf("tv4-")&&(r=r.substring(4));var c=l.default||s.default||"";[l,s,e].some(function(e){return o.a.isString(e)||o.a.isFunction(e)?(c=e,!0):e&&e[r]?(c=e[r],!0):void 0});var u={error:r,value:n,viewValue:i,form:a,schema:a.schema,title:a.title||a.schema&&a.schema.title};return o.a.isFunction(c)?c(u):t(c)(u)},r}]}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=r(1),i=(r.n(o),r(0)),a=(r.n(i),function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}()),s=function(){function e(){n(this,e),this.name=o.sfPath.name,this.parse=o.sfPath.parse,this.stringify=o.sfPath.stringify,this.normalize=o.sfPath.normalize}return a(e,[{key:"$get",value:function(){return o.sfPath}}]),e}();t.a=s},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):v=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++v<t;)p&&p[v].run();v=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,v=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},function(e,t,r){(function(e,t){!function(e,r){"use strict";function n(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var n={callback:e,args:t};return h[m]=n,p(m),m++}function o(e){delete h[e]}function i(e){var t=e.callback,n=e.args;switch(n.length){case 0:t();break;case 1:t(n[0]);break;case 2:t(n[0],n[1]);break;case 3:t(n[0],n[1],n[2]);break;default:t.apply(r,n)}}function a(e){if(v)setTimeout(a,0,e);else{var t=h[e];if(t){v=!0;try{i(t)}finally{o(e),v=!1}}}}function s(){p=function(e){t.nextTick(function(){a(e)})}}function l(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}function c(){var t="setImmediate$"+Math.random()+"$",r=function(r){r.source===e&&"string"==typeof r.data&&0===r.data.indexOf(t)&&a(+r.data.slice(t.length))};e.addEventListener?e.addEventListener("message",r,!1):e.attachEvent("onmessage",r),p=function(r){e.postMessage(t+r,"*")}}function u(){var e=new MessageChannel;e.port1.onmessage=function(e){var t=e.data;a(t)},p=function(t){e.port2.postMessage(t)}}function f(){var e=y.documentElement;p=function(t){var r=y.createElement("script");r.onreadystatechange=function(){a(t),r.onreadystatechange=null,e.removeChild(r),r=null},e.appendChild(r)}}function d(){p=function(e){setTimeout(a,0,e)}}if(!e.setImmediate){var p,m=1,h={},v=!1,y=e.document,g=Object.getPrototypeOf&&Object.getPrototypeOf(e);g=g&&g.setTimeout?g:e,"[object process]"==={}.toString.call(e.process)?s():l()?c():e.MessageChannel?u():y&&"onreadystatechange"in y.createElement("script")?f():d(),g.setImmediate=n,g.clearImmediate=o}}("undefined"==typeof self?"undefined"==typeof e?this:e:self)}).call(t,r(2),r(17))},function(r,n,o){function i(e,t){this._id=e,this._clearFn=t}var a=Function.prototype.apply;n.setTimeout=function(){return new i(a.call(setTimeout,window,arguments),clearTimeout)},n.setInterval=function(){return new i(a.call(setInterval,window,arguments),clearInterval)},n.clearTimeout=n.clearInterval=function(e){e&&e.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(window,this._id)},n.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},n.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},n._unrefActive=n.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},o(18),n.setImmediate=e,n.clearImmediate=t},,function(e,t,r){r(1),e.exports=r(4)}])}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):v=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++v<t;)p&&p[v].run();v=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,v=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},,,function(e,t,r){r(19),e.exports=r(0)}]);
\ No newline at end of file
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index 1e4c0dc..cd827aa 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.1
- * @date Tue, 21 Feb 2017 11:44:44 GMT
+ * @date Thu, 30 Mar 2017 10:51:56 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
diff --git a/dist/angular-schema-form-bootstrap.min.js b/dist/angular-schema-form-bootstrap.min.js
index 8be19e0..9072aa9 100644
--- a/dist/angular-schema-form-bootstrap.min.js
+++ b/dist/angular-schema-form-bootstrap.min.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.1
- * @date Tue, 21 Feb 2017 11:44:44 GMT
+ * @date Thu, 30 Mar 2017 10:51:56 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form

From a2fbb0c23429b2e776e10059bdebd75b8e83c138 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Sun, 2 Apr 2017 19:48:50 +1000
Subject: [PATCH 41/50] Alpha 3

---
 dist/angular-schema-form-bootstrap-bundled.js     | 4 ++--
 dist/angular-schema-form-bootstrap-bundled.min.js | 4 ++--
 dist/angular-schema-form-bootstrap.js             | 4 ++--
 dist/angular-schema-form-bootstrap.min.js         | 4 ++--
 package.json                                      | 2 +-
 5 files changed, 9 insertions(+), 9 deletions(-)

diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index 915e4fd..d8f4b4c 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.1
- * @date Thu, 30 Mar 2017 10:51:56 GMT
+ * @version 1.0.0-alpha.3
+ * @date Sat, 01 Apr 2017 07:53:17 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
diff --git a/dist/angular-schema-form-bootstrap-bundled.min.js b/dist/angular-schema-form-bootstrap-bundled.min.js
index 751f77a..833c9a8 100644
--- a/dist/angular-schema-form-bootstrap-bundled.min.js
+++ b/dist/angular-schema-form-bootstrap-bundled.min.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.1
- * @date Thu, 30 Mar 2017 10:51:56 GMT
+ * @version 1.0.0-alpha.3
+ * @date Sat, 01 Apr 2017 07:53:17 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index cd827aa..0b14488 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.1
- * @date Thu, 30 Mar 2017 10:51:56 GMT
+ * @version 1.0.0-alpha.3
+ * @date Sat, 01 Apr 2017 07:53:17 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
diff --git a/dist/angular-schema-form-bootstrap.min.js b/dist/angular-schema-form-bootstrap.min.js
index 9072aa9..0d5221f 100644
--- a/dist/angular-schema-form-bootstrap.min.js
+++ b/dist/angular-schema-form-bootstrap.min.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.1
- * @date Thu, 30 Mar 2017 10:51:56 GMT
+ * @version 1.0.0-alpha.3
+ * @date Sat, 01 Apr 2017 07:53:17 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
diff --git a/package.json b/package.json
index 5e3cd66..fbb4027 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
 {
   "name": "angular-schema-form-bootstrap",
-  "version": "1.0.0-alpha.1",
+  "version": "1.0.0-alpha.3",
   "description": "Bootstrap 3 decorator for Angular Schema Form",
   "main": "dist/bootstrap-decorator.js",
   "scripts": {

From 005ac2fe8a3e06c2accfa0582e2994ea965174cc Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Sun, 2 Apr 2017 19:51:59 +1000
Subject: [PATCH 42/50] Update dependencies and 'main'

---
 package.json | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/package.json b/package.json
index fbb4027..eb00363 100644
--- a/package.json
+++ b/package.json
@@ -2,7 +2,7 @@
   "name": "angular-schema-form-bootstrap",
   "version": "1.0.0-alpha.3",
   "description": "Bootstrap 3 decorator for Angular Schema Form",
-  "main": "dist/bootstrap-decorator.js",
+  "main": "dist/angular-schema-form-bootstrap.js",
   "scripts": {
     "build": "webpack",
     "dist": "webpack --config webpack.config.dist.js",
@@ -23,6 +23,7 @@
     "angular": ">= 1.2",
     "angular-messages": "^1.5.0",
     "angular-sanitize": ">= 1.2",
+    "angular-schema-form": "^1.0.0-alpha.3",
     "tv4": "~1.0.15"
   },
   "devDependencies": {

From 5a6abc8dae2288088fa21c5ab1c394ef5e1bf284 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Sun, 2 Apr 2017 19:57:50 +1000
Subject: [PATCH 43/50] README updates

---
 README.md | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/README.md b/README.md
index 224872f..e154296 100644
--- a/README.md
+++ b/README.md
@@ -22,9 +22,11 @@ or
 ```sh
 npm install angular-schema-form-bootstrap
 ```
-And then include `angular-schema-form-bootstrap-bundled.min.js`. **Note that angular-schema-form >= 1.0.0-alpha.1 is needed**.
 
-You **DO NOT** need to include angular-schema-form with this version, it is now **embedded** within the above file. If you wish to include the files separately you can still use `angular-schema-form-bootstrap.min.js`
+The package.json 'main' script is this library alone and unminified so that minification can be handled by webpack or another script bundler.
+**Note that angular-schema-form >= 1.0.0-alpha.1 is needed in that case**.
+
+If you include `angular-schema-form-bootstrap-bundled.min.js` you **DO NOT** need to include angular-schema-form, it is now **embedded** within the bundled above file. If you wish to include the files separately you can still use `angular-schema-form-bootstrap.js` or `angular-schema-form-bootstrap.min.js`
 
 Future
 ------

From 00f578ad01e331062a1aa91ba868a9ae176f81af Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Sun, 2 Apr 2017 23:14:54 +1000
Subject: [PATCH 44/50] Fixes angular-schema-form#750

---
 dist/angular-schema-form-bootstrap-bundled.js     | 6 +++---
 dist/angular-schema-form-bootstrap-bundled.min.js | 6 +++---
 dist/angular-schema-form-bootstrap.js             | 4 ++--
 dist/angular-schema-form-bootstrap.min.js         | 4 ++--
 package.json                                      | 4 ++--
 src/bootstrap/array.html                          | 2 +-
 6 files changed, 13 insertions(+), 13 deletions(-)

diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index d8f4b4c..e3b857b 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.3
- * @date Sat, 01 Apr 2017 07:53:17 GMT
+ * @date Sun, 02 Apr 2017 13:11:20 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -175,7 +175,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/array.html';
-var html = "<div  class=\"schema-form-array {{::form.htmlClass + ' ' + idClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $index\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
+var html = "<div  class=\"schema-form-array {{::form.htmlClass + ' ' + idClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $id(item)\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -464,7 +464,7 @@ function bootstrapDecoratorConfig(
 /* WEBPACK VAR INJECTION */(function(setImmediate, clearImmediate) {/*!
  * angular-schema-form
  * @version 1.0.0-alpha.3
- * @date Thu, 30 Mar 2017 07:57:38 GMT
+ * @date Sun, 02 Apr 2017 13:00:09 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
diff --git a/dist/angular-schema-form-bootstrap-bundled.min.js b/dist/angular-schema-form-bootstrap-bundled.min.js
index 833c9a8..b18ccc1 100644
--- a/dist/angular-schema-form-bootstrap-bundled.min.js
+++ b/dist/angular-schema-form-bootstrap-bundled.min.js
@@ -1,15 +1,15 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.3
- * @date Sat, 01 Apr 2017 07:53:17 GMT
+ * @date Sun, 02 Apr 2017 13:11:20 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,v=r.builders.array,g=r.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},E=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,v,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,v,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:y.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:w.a,builder:C},"radios-inline":{template:$.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:C.concat(E)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,v,m]},tabs:{template:D.a,builder:[d,l,x,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),v=r(8),y=r.n(v),g=r(9),b=r.n(g),x=r(11),w=r.n(x),E=r(10),$=r.n(E),C=r(12),k=r.n(C),O=r(13),T=r.n(O),A=r(14),S=r.n(A),P=r(15),M=r.n(P),j=r(16),D=r.n(j),I=r(17),_=r.n(I);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
+!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(item)">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,v=r.builders.array,g=r.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},E=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,v,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,v,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:y.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:w.a,builder:C},"radios-inline":{template:$.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:C.concat(E)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,v,m]},tabs:{template:D.a,builder:[d,l,x,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),v=r(8),y=r.n(v),g=r(9),b=r.n(g),x=r(11),w=r.n(x),E=r(10),$=r.n(E),C=r(12),k=r.n(C),O=r(13),T=r.n(O),A=r(14),S=r.n(A),P=r(15),M=r.n(P),j=r(16),D=r.n(j),I=r(17),_=r.n(I);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
  * angular-schema-form
  * @version 1.0.0-alpha.3
- * @date Thu, 30 Mar 2017 07:57:38 GMT
+ * @date Sun, 02 Apr 2017 13:00:09 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index 0b14488..cf0bd68 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.3
- * @date Sat, 01 Apr 2017 07:53:17 GMT
+ * @date Sun, 02 Apr 2017 13:11:20 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -94,7 +94,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/array.html';
-var html = "<div  class=\"schema-form-array {{::form.htmlClass + ' ' + idClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $index\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
+var html = "<div  class=\"schema-form-array {{::form.htmlClass + ' ' + idClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $id(item)\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
diff --git a/dist/angular-schema-form-bootstrap.min.js b/dist/angular-schema-form-bootstrap.min.js
index 0d5221f..1407139 100644
--- a/dist/angular-schema-form-bootstrap.min.js
+++ b/dist/angular-schema-form-bootstrap.min.js
@@ -1,9 +1,9 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.3
- * @date Sat, 01 Apr 2017 07:53:17 GMT
+ * @date Sun, 02 Apr 2017 13:11:20 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function r(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return e[a].call(l.exports,l,l.exports,r),l.l=!0,l.exports}var n={};return r.m=e,r.c=n,r.i=function(e){return e},r.d=function(e,r,n){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=24)}([function(e,r,n){n(18)},,function(e,r){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $index">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r,n){"use strict";function a(e,r,n,a,l){var s=n.builders.simpleTransclusion,i=n.builders.ngModelOptions,m=n.builders.ngModel,c=n.builders.sfField,p=n.builders.condition,h=n.builders.array,v=n.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var r=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(n,a){var l="(evalExpr("+e.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=e.build(n.items,e.path+".tabs["+a+"].items",e.state);t.appendChild(s),r.appendChild(t)})}},C=function(e){if(e.form.placeholder){var r=e.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=e.form.placeholder,r.appendChild(n)}},k=[c,m,i,p];r.defineDecorator("bootstrapDecorator",{actions:{template:t.a,builder:k},array:{template:o.a,builder:[c,i,m,h,p]},button:{template:H.a,builder:k},checkbox:{template:d.a,builder:k},checkboxes:{template:f.a,builder:[c,i,m,h,p]},conditional:{template:A.a,builder:[c,s,p]},default:{template:u.a,builder:k},fieldset:{template:b.a,builder:[c,s,p]},help:{template:g.a,builder:k},number:{template:u.a,builder:k.concat(v)},password:{template:u.a,builder:k},radios:{template:$.a,builder:k},"radios-inline":{template:w.a,builder:k},radiobuttons:{template:y.a,builder:k},section:{template:A.a,builder:[c,s,p]},select:{template:E.a,builder:k.concat(C)},submit:{template:H.a,builder:k},tabarray:{template:M.a,builder:[c,i,m,h,p]},tabs:{template:L.a,builder:[c,i,x,p]},textarea:{template:D.a,builder:k}},[])}var l=n(2),t=n.n(l),s=n(3),o=n.n(s),i=n(4),d=n.n(i),m=n(5),f=n.n(m),c=n(6),u=n.n(c),p=n(7),b=n.n(p),h=n(8),g=n.n(h),v=n(9),y=n.n(v),x=n(11),$=n.n(x),C=n(10),w=n.n(C),k=n(12),A=n.n(k),S=n(13),E=n.n(S),I=n(14),H=n.n(I),T=n(15),M=n.n(T),R=n(16),L=n.n(R),j=n(17),D=n.n(j);angular.module("schemaForm").config(a),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,,function(e,r,n){e.exports=n(0)}]);
\ No newline at end of file
+!function(e){function r(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return e[a].call(l.exports,l,l.exports,r),l.l=!0,l.exports}var n={};return r.m=e,r.c=n,r.i=function(e){return e},r.d=function(e,r,n){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=24)}([function(e,r,n){n(18)},,function(e,r){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(item)">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r,n){"use strict";function a(e,r,n,a,l){var s=n.builders.simpleTransclusion,i=n.builders.ngModelOptions,m=n.builders.ngModel,c=n.builders.sfField,p=n.builders.condition,h=n.builders.array,v=n.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var r=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(n,a){var l="(evalExpr("+e.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=e.build(n.items,e.path+".tabs["+a+"].items",e.state);t.appendChild(s),r.appendChild(t)})}},C=function(e){if(e.form.placeholder){var r=e.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=e.form.placeholder,r.appendChild(n)}},k=[c,m,i,p];r.defineDecorator("bootstrapDecorator",{actions:{template:t.a,builder:k},array:{template:o.a,builder:[c,i,m,h,p]},button:{template:H.a,builder:k},checkbox:{template:d.a,builder:k},checkboxes:{template:f.a,builder:[c,i,m,h,p]},conditional:{template:A.a,builder:[c,s,p]},default:{template:u.a,builder:k},fieldset:{template:b.a,builder:[c,s,p]},help:{template:g.a,builder:k},number:{template:u.a,builder:k.concat(v)},password:{template:u.a,builder:k},radios:{template:$.a,builder:k},"radios-inline":{template:w.a,builder:k},radiobuttons:{template:y.a,builder:k},section:{template:A.a,builder:[c,s,p]},select:{template:E.a,builder:k.concat(C)},submit:{template:H.a,builder:k},tabarray:{template:M.a,builder:[c,i,m,h,p]},tabs:{template:L.a,builder:[c,i,x,p]},textarea:{template:D.a,builder:k}},[])}var l=n(2),t=n.n(l),s=n(3),o=n.n(s),i=n(4),d=n.n(i),m=n(5),f=n.n(m),c=n(6),u=n.n(c),p=n(7),b=n.n(p),h=n(8),g=n.n(h),v=n(9),y=n.n(v),x=n(11),$=n.n(x),C=n(10),w=n.n(C),k=n(12),A=n.n(k),S=n(13),E=n.n(S),I=n(14),H=n.n(I),T=n(15),M=n.n(T),R=n(16),L=n.n(R),j=n(17),D=n.n(j);angular.module("schemaForm").config(a),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,,function(e,r,n){e.exports=n(0)}]);
\ No newline at end of file
diff --git a/package.json b/package.json
index eb00363..99f3248 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
 {
   "name": "angular-schema-form-bootstrap",
-  "version": "1.0.0-alpha.3",
+  "version": "1.0.0-alpha.4",
   "description": "Bootstrap 3 decorator for Angular Schema Form",
   "main": "dist/angular-schema-form-bootstrap.js",
   "scripts": {
@@ -23,7 +23,7 @@
     "angular": ">= 1.2",
     "angular-messages": "^1.5.0",
     "angular-sanitize": ">= 1.2",
-    "angular-schema-form": "^1.0.0-alpha.3",
+    "angular-schema-form": "^1.0.0-alpha.4",
     "tv4": "~1.0.15"
   },
   "devDependencies": {
diff --git a/src/bootstrap/array.html b/src/bootstrap/array.html
index 7e05004..fad8312 100644
--- a/src/bootstrap/array.html
+++ b/src/bootstrap/array.html
@@ -5,7 +5,7 @@
   <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">
     <li class="list-group-item {{::form.fieldHtmlClass}}"
         sf-field-model="ng-repeat"
-        ng-repeat="item in $$value$$ track by $index">
+        ng-repeat="item in $$value$$ track by $id(item)">
       <button ng-hide="form.readonly || form.remove === null"
               ng-click="deleteFromArray($index)"
               ng-disabled="form.schema.minItems >= modelArray.length"

From 34cfa6c009ecb2dc4cd3a206b7b32eafc41f2321 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Mon, 3 Apr 2017 23:12:57 +1000
Subject: [PATCH 45/50] Fix for angular-schema-form#750

---
 dist/angular-schema-form-bootstrap-bundled.js | 98 +++++++++++--------
 ...gular-schema-form-bootstrap-bundled.min.js | 20 ++--
 dist/angular-schema-form-bootstrap.js         |  6 +-
 dist/angular-schema-form-bootstrap.min.js     |  6 +-
 src/bootstrap/array.html                      |  4 +-
 5 files changed, 73 insertions(+), 61 deletions(-)

diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index e3b857b..6268dfe 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.3
- * @date Sun, 02 Apr 2017 13:11:20 GMT
+ * @version 1.0.0-alpha.4
+ * @date Mon, 03 Apr 2017 13:11:24 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -175,7 +175,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/array.html';
-var html = "<div  class=\"schema-form-array {{::form.htmlClass + ' ' + idClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $id(item)\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
+var html = "<div  class=\"schema-form-array {{::form.htmlClass + ' ' + idClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $id(trackBy(item, $index))\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray(item)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -463,8 +463,8 @@ function bootstrapDecoratorConfig(
 
 /* WEBPACK VAR INJECTION */(function(setImmediate, clearImmediate) {/*!
  * angular-schema-form
- * @version 1.0.0-alpha.3
- * @date Sun, 02 Apr 2017 13:00:09 GMT
+ * @version 1.0.0-alpha.4
+ * @date Mon, 03 Apr 2017 12:57:49 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -534,7 +534,7 @@ function bootstrapDecoratorConfig(
 /******/ 	__webpack_require__.p = "";
 /******/
 /******/ 	// Load entry module and return exports
-/******/ 	return __webpack_require__(__webpack_require__.s = 21);
+/******/ 	return __webpack_require__(__webpack_require__.s = 19);
 /******/ })
 /************************************************************************/
 /******/ ([
@@ -3192,7 +3192,7 @@ module.exports = __webpack_require__(4);
 /***/ })
 /******/ ]);
 //# sourceMappingURL=json-schema-form-core.js.map
-/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(2), __webpack_require__(19).setImmediate))
+/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(2), __webpack_require__(18).setImmediate))
 
 /***/ }),
 /* 2 */
@@ -3222,8 +3222,7 @@ module.exports = g;
 
 
 /***/ }),
-/* 3 */,
-/* 4 */
+/* 3 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -3232,18 +3231,18 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_angular__ = __webpack_require__(0);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_angular__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_sf_builder_provider__ = __webpack_require__(14);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_schema_form_decorators_provider__ = __webpack_require__(12);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_schema_form_provider__ = __webpack_require__(13);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_sf_error_message_provider__ = __webpack_require__(15);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_sf_path_provider__ = __webpack_require__(16);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__ = __webpack_require__(7);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__ = __webpack_require__(8);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__ = __webpack_require__(10);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__ = __webpack_require__(6);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__ = __webpack_require__(9);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__ = __webpack_require__(11);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__ = __webpack_require__(5);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_sf_builder_provider__ = __webpack_require__(13);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_schema_form_decorators_provider__ = __webpack_require__(11);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_schema_form_provider__ = __webpack_require__(12);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_sf_error_message_provider__ = __webpack_require__(14);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_sf_path_provider__ = __webpack_require__(15);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__ = __webpack_require__(6);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__ = __webpack_require__(7);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__ = __webpack_require__(9);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__ = __webpack_require__(5);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__ = __webpack_require__(8);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__ = __webpack_require__(10);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__ = __webpack_require__(4);
 
 
 
@@ -3297,7 +3296,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 .directive('sfChanged', __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__["a" /* default */]).directive('sfField', ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__["a" /* default */]]).directive('sfMessage', ['$injector', 'sfErrorMessage', __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__["a" /* default */]]).directive('sfNewArray', ['sfSelect', 'sfPath', 'schemaForm', __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__["a" /* default */]]).directive('sfSchema', ['$compile', '$http', '$templateCache', '$q', 'schemaForm', 'schemaFormDecorators', 'sfSelect', 'sfPath', 'sfBuilder', __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__["a" /* default */]]).directive('schemaValidate', ['sfValidator', '$parse', 'sfSelect', __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__["a" /* default */]]).directive('sfKeyController', ['schemaForm', 'sfPath', __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__["a" /* default */]]);
 
 /***/ }),
-/* 5 */
+/* 4 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -3487,12 +3486,14 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 };
 
 /***/ }),
-/* 6 */
+/* 5 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular__ = __webpack_require__(0);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
+var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol" ? function (obj) { return typeof obj; } : function (obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; };
+
 
 
 /**
@@ -3507,6 +3508,11 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
     link: function link(scope, element, attrs) {
       scope.min = 0;
 
+      scope.trackBy = function (item, index) {
+        if (item && (typeof item === 'undefined' ? 'undefined' : _typeof(item)) === 'object') return item;
+        return index;
+      };
+
       scope.modelArray = scope.$eval(attrs.sfNewArray);
 
       // We need to have a ngModel to hook into validation. It doesn't really play well with
@@ -3664,11 +3670,17 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
         return model;
       };
 
-      scope.deleteFromArray = function (index) {
+      scope.deleteFromArray = function (item) {
+        var index = scope.modelArray.indexOf(item);
         var model = scope.modelArray;
         if (model) {
           model.splice(index, 1);
         }
+
+        if (item.$$hashKey) {
+          scope.destroyed = item.$$hashKey;
+        }
+
         return model;
       };
 
@@ -3718,7 +3730,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 };
 
 /***/ }),
-/* 7 */
+/* 6 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -3764,7 +3776,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 };
 
 /***/ }),
-/* 8 */
+/* 7 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -4049,9 +4061,10 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
           // in the form definition.
           scope.$on('$destroy', function () {
             var key = scope.getKey();
+            var arrayIndex = typeof scope.arrayIndex == 'number' ? scope.arrayIndex + 1 : 0;
 
             // If the entire schema form is destroyed we don't touch the model
-            if (!scope.externalDestructionInProgress) {
+            if (!scope.externalDestructionInProgress && (!scope.model.$$hashKey || scope.model.$$hashKey === scope.destroyed)) {
               var destroyStrategy = form.destroyStrategy || scope.options && scope.options.destroyStrategy || 'remove';
               // No key no model, and we might have strategy 'retain'
               if (key && destroyStrategy !== 'retain') {
@@ -4093,7 +4106,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
 };
 
 /***/ }),
-/* 9 */
+/* 8 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -4132,7 +4145,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
 };;
 
 /***/ }),
-/* 10 */
+/* 9 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -4236,7 +4249,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
 };
 
 /***/ }),
-/* 11 */
+/* 10 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -4466,7 +4479,7 @@ FIXME: real documentation
 };
 
 /***/ }),
-/* 12 */
+/* 11 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -5009,7 +5022,7 @@ FIXME: real documentation
 };;
 
 /***/ }),
-/* 13 */
+/* 12 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -5148,7 +5161,7 @@ FIXME: real documentation
 };
 
 /***/ }),
-/* 14 */
+/* 13 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -5476,7 +5489,7 @@ FIXME: real documentation
 };
 
 /***/ }),
-/* 15 */
+/* 14 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -5613,7 +5626,7 @@ FIXME: real documentation
 };
 
 /***/ }),
-/* 16 */
+/* 15 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -5653,7 +5666,7 @@ var sfPathProviderClass = function () {
 /* harmony default export */ __webpack_exports__["a"] = sfPathProviderClass;
 
 /***/ }),
-/* 17 */
+/* 16 */
 /***/ (function(module, exports) {
 
 // shim for using process in browser
@@ -5839,7 +5852,7 @@ process.umask = function() { return 0; };
 
 
 /***/ }),
-/* 18 */
+/* 17 */
 /***/ (function(module, exports, __webpack_require__) {
 
 /* WEBPACK VAR INJECTION */(function(global, process) {(function (global, undefined) {
@@ -6029,10 +6042,10 @@ process.umask = function() { return 0; };
     attachTo.clearImmediate = clearImmediate;
 }(typeof self === "undefined" ? typeof global === "undefined" ? this : global : self));
 
-/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(2), __webpack_require__(17)))
+/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(2), __webpack_require__(16)))
 
 /***/ }),
-/* 19 */
+/* 18 */
 /***/ (function(module, exports, __webpack_require__) {
 
 var apply = Function.prototype.apply;
@@ -6085,18 +6098,17 @@ exports._unrefActive = exports.active = function(item) {
 };
 
 // setimmediate attaches itself to the global object
-__webpack_require__(18);
+__webpack_require__(17);
 exports.setImmediate = setImmediate;
 exports.clearImmediate = clearImmediate;
 
 
 /***/ }),
-/* 20 */,
-/* 21 */
+/* 19 */
 /***/ (function(module, exports, __webpack_require__) {
 
 __webpack_require__(1);
-module.exports = __webpack_require__(4);
+module.exports = __webpack_require__(3);
 
 
 /***/ })
diff --git a/dist/angular-schema-form-bootstrap-bundled.min.js b/dist/angular-schema-form-bootstrap-bundled.min.js
index b18ccc1..33f0b9e 100644
--- a/dist/angular-schema-form-bootstrap-bundled.min.js
+++ b/dist/angular-schema-form-bootstrap-bundled.min.js
@@ -1,20 +1,20 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.3
- * @date Sun, 02 Apr 2017 13:11:20 GMT
+ * @version 1.0.0-alpha.4
+ * @date Mon, 03 Apr 2017 13:11:24 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(item)">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,v=r.builders.array,g=r.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},E=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,v,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,v,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:y.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:w.a,builder:C},"radios-inline":{template:$.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:C.concat(E)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,v,m]},tabs:{template:D.a,builder:[d,l,x,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),v=r(8),y=r.n(v),g=r(9),b=r.n(g),x=r(11),w=r.n(x),E=r(10),$=r.n(E),C=r(12),k=r.n(C),O=r(13),T=r.n(O),A=r(14),S=r.n(A),P=r(15),M=r.n(P),j=r(16),D=r.n(j),I=r(17),_=r.n(I);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
+!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,y=r.builders.array,g=r.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},E=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,y,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,y,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:v.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:w.a,builder:C},"radios-inline":{template:$.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:C.concat(E)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,y,m]},tabs:{template:I.a,builder:[d,l,x,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),y=r(8),v=r.n(y),g=r(9),b=r.n(g),x=r(11),w=r.n(x),E=r(10),$=r.n(E),C=r(12),k=r.n(C),O=r(13),T=r.n(O),A=r(14),S=r.n(A),P=r(15),M=r.n(P),j=r(16),I=r.n(j),D=r(17),_=r.n(D);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
  * angular-schema-form
- * @version 1.0.0-alpha.3
- * @date Sun, 02 Apr 2017 13:00:09 GMT
+ * @version 1.0.0-alpha.4
+ * @date Mon, 03 Apr 2017 12:57:49 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=21)}([function(e,t){e.exports=angular},function(e,t,r){(function(t,r){/*!
+!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=19)}([function(e,t){e.exports=angular},function(e,t,r){(function(t,r){/*!
  * json-schema-form-core
  * @version 1.0.0-alpha.3
  * @date Mon, 27 Mar 2017 13:05:31 GMT
@@ -22,11 +22,11 @@
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-e.exports=function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=13)}([function(e,t,r){"use strict";function n(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(e){var o=e.slice(),i=t||"-";return n&&(o=o.filter(function(e){return"number"!=typeof e})),(0!==r.length?r+i:"")+o.join(i)}return""}Object.defineProperty(t,"__esModule",{value:!0});var o=r(2);r.n(o);r.o(o,"parse")&&r.d(t,"parse",function(){return o.parse}),r.o(o,"stringify")&&r.d(t,"stringify",function(){return o.stringify}),r.o(o,"normalize")&&r.d(t,"normalize",function(){return o.normalize}),t.name=n},function(e,t,r){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t){if(!Array.isArray(e)){var r=function(){var r=[];return t?t.forEach(function(t){r.push({name:e[t],value:t})}):Object.keys(e).forEach(function(t){r.push({name:e[t],value:t})}),{v:r}}();if("object"===("undefined"==typeof r?"undefined":n(r)))return r.v}return e}},function(e,t,r){e.exports=r(11).ObjectPath},function(e,t,r){"use strict";function n(e,t,r,o){var i=e[g(r.type)];if(i)for(var a=void 0,s=function(t,r,o){return n(e,t,r,o)},l=0;l<i.length;l++)if(a=i[l](t,r,o,s))return a.schema["x-schema-form"]&&Object.assign(a,a.schema["x-schema-form"]),a}function o(e,t,n){n=n||{};var o=n.global&&n.global.formDefaults?Object.assign({},n.global.formDefaults):{};return n.global&&n.global.supressPropertyTitles===!0?o.title=t.title:o.title=t.title||e,t.description&&(o.description=t.description),n.required!==!0&&t.required!==!0||(o.required=!0),t.maxLength&&(o.maxlength=t.maxLength),t.minLength&&(o.minlength=t.minLength),(t.readOnly||t.readonly)&&(o.readonly=!0),t.minimum&&(o.minimum=t.minimum+(t.exclusiveMinimum?1:0)),t.maximum&&(o.maximum=t.maximum-(t.exclusiveMaximum?1:0)),t.validationMessage&&(o.validationMessage=t.validationMessage),t.enumNames&&(o.titleMap=r.i(v.a)(t.enumNames,t.enum)),o.schema=t,o.ngModelOptions=o.ngModelOptions||{},o}function i(e,t,n){if("string"===g(t.type)&&!t.enum){var i=o(e,t,n);return i.key=n.path,i.type="text",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function a(e,t,n){if("number"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function s(e,t,n){if("integer"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function l(e,t,n){if("boolean"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="checkbox",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function c(e,t,n){if("string"===g(t.type)&&t.enum){var i=o(e,t,n);return i.key=n.path,i.type="select",i.titleMap||(i.titleMap=b(t.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function u(e,t,n){if("array"===g(t.type)&&t.items&&t.items.enum){var i=o(e,t,n);return i.key=n.path,i.type="checkboxes",i.titleMap||(i.titleMap=b(t.items.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function f(e,t,n,i){if("object"===g(t.type)){var a=function(){var a=o(e,t,n);return a.type="fieldset",a.key=n.path,a.items=[],n.lookup[r.i(h.stringify)(n.path)]=a,t.properties&&Object.keys(t.properties).forEach(function(e){var o=t.properties[e],s=n.path.slice();if(s.push(e),n.ignore[r.i(h.stringify)(s)]!==!0){var l=t.required&&t.required.indexOf(e)!==-1,c=i(e,o,{path:s,required:l||!1,lookup:n.lookup,ignore:n.ignore,global:n.global});c&&a.items.push(c)}}),{v:a}}();if("object"===("undefined"==typeof a?"undefined":y(a)))return a.v}}function d(e,t,n,i){if("array"===g(t.type)){var a=o(e,t,n);a.type="array",a.key=n.path,n.lookup[r.i(h.stringify)(n.path)]=a;var s=t.required&&t.required.indexOf(n.path[n.path.length-1])!==-1,l=n.path.slice();return l.push(""),a.items=[i(e,t.items,{path:l,required:s||!1,lookup:n.lookup,ignore:n.ignore,global:n.global})],a}}function p(){return{string:[c,i],object:[f],number:[a],integer:[s],boolean:[l],array:[u,d]}}function m(e,t,r,o){var i=[],a={};if(r=r||{},o=o||{},t=t||p(),!e.properties)throw new Error('Not implemented. Only type "object" allowed at root level of schema.');return Object.keys(e.properties).forEach(function(s){if(r[s]!==!0){var l=e.required&&e.required.indexOf(s)!==-1,c=n(t,s,e.properties[s],{path:[s],lookup:a,ignore:r,required:l,global:o});c&&i.push(c)}}),{form:i,lookup:a}}Object.defineProperty(t,"__esModule",{value:!0});var h=r(0),v=r(1);t.defaultFormDefinition=n,t.stdFormObj=o,t.text=i,t.number=a,t.integer=s,t.checkbox=l,t.select=c,t.checkboxes=u,t.fieldset=f,t.array=d,t.createDefaults=p,t.defaultForm=m;var y="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},g=function(e){if(Array.isArray(e)&&2===e.length){if("null"===e[0])return e[1];if("null"===e[1])return e[0]}return e},b=function(e){var t=[];return e.forEach(function(e){t.push({name:e,value:e})}),t}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(3),o=r(0),i=r(1),a=r(6);r.d(t,"merge",function(){return a.a});var s=r(8);r.d(t,"select",function(){return s.a});var l=r(7);r.d(t,"jsonref",function(){return l.a});var c=r(9);r.d(t,"traverseSchema",function(){return c.a}),r.d(t,"traverseForm",function(){return c.b});var u=r(10);r.d(t,"validate",function(){return u.a}),r.d(t,"sfPath",function(){return f}),r.d(t,"schemaDefaults",function(){return d}),r.d(t,"canonicalTitleMap",function(){return p});var f=o,d=n,p=i.a},function(e,n,o){var i,a,s,l,l,c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};!function(t){if("object"===c(n)&&"undefined"!=typeof e)e.exports=t();else{a=[],i=t,s="function"==typeof i?i.apply(n,a):i,!(void 0!==s&&(e.exports=s))}}(function(){var e;return function e(t,r,n){function o(a,s){if(!r[a]){if(!t[a]){var c="function"==typeof l&&l;if(!s&&c)return l(a,!0);if(i)return i(a,!0);var u=new Error("Cannot find module '"+a+"'");throw u.code="MODULE_NOT_FOUND",u}var f=r[a]={exports:{}};t[a][0].call(f.exports,function(e){var r=t[a][1][e];return o(r?r:e)},f,f.exports,e,t,r,n)}return r[a].exports}for(var i="function"==typeof l&&l,a=0;a<n.length;a++)o(n[a]);return o}({1:[function(e,t,r){"use strict";function n(e){var t;return m(e,"Array")?(t=[],e.forEach(function(e,r){t[r]=n(e)})):m(e,"Object")?(t={},Object.keys(e).forEach(function(r){t[r]=n(e[r])})):t=e,t}function o(e,t){function r(e){Object.keys(e).forEach(function(t){n[t]=e[t]})}var n={};return r(_.parse(e||"")),r(_.parse(t||"")),0===Object.keys(n).length?void 0:_.stringify(n)}function i(e,t){m(e,"String")&&(e=F(e)),m(t,"String")&&(t=F(t));var r,n,i=y(m(t,"Undefined")?"":t);return L.indexOf(i.reference)>-1?n=i:(r=m(e,"Undefined")?void 0:y(e),m(r,"Undefined")?n=i:(n=r,n.path=F(D.join(r.path,i.path)),n.query=o(r.query,i.query))),n.fragment=void 0,(L.indexOf(n.reference)===-1&&0===n.path.indexOf("../")?"../":"")+R.serialize(n)}function a(e,t){var r,n=[];return t.length>0&&(r=e,t.slice(0,t.length-1).forEach(function(e){e in r&&(r=r[e],n.push(r))})),n}function s(e,t,r,o,i,a,s,u,f){var d,p;if(r.length>0)try{d=c(t,r)}catch(t){"remote"===e&&(o.error=t.message,o.missing=!0)}else d=t;if(m(d,"Undefined")||(o.value=d),m(d,"Array")||m(d,"Object"))return p=n(i),"local"===e?(delete p.subDocPath,t=d):(p.relativeBase=D.dirname(a[a.length-1]),0===r.length?delete p.subDocPath:p.subDocPath=r),l(t,p,a,s,u,f)}function l(e,t,r,n,o,a){var l=Promise.resolve(),c=n.length?S(n[n.length-1]):[],u=C(e,t),f=t.subDocPath||[],p=P(f),h=["#"];return r.forEach(function(e,t){"#"!==e.charAt(0)&&h.push(n[t])}),h.reverse(),"#"!==(r[r.length-1]||"").charAt(0)&&(o.documents[P(c)]=e),Object.keys(u).forEach(function(v){var y,g,b,x,w=u[v];b=0===r.length?c.concat(S(v)):c.concat(S(v).slice(0===r.length?0:f.length)),x=P(b),m(o[x],"Undefined")&&(o.refs[x]=u[v],m(w.error,"Undefined")&&"invalid"!==w.type&&(N.indexOf(w.type)>-1?(y=i(t.relativeBase,w.uri),g=r.indexOf(y)):(y=w.uri,g=n.indexOf(y)),w.ancestorPtrs=h,w.indirect=a,g===-1?N.indexOf(w.type)>-1?l=l.then(function(){return d(y,t).then(function(e){return s("remote",e,m(w.uriDetails.fragment,"Undefined")?[]:S(decodeURI(w.uriDetails.fragment)),w,t,r.concat(y),n.concat(x),o,a)}).catch(function(e){w.error=e.message,w.missing=!0})}):0!==x.indexOf(y+"/")&&x!==y&&0!==p.indexOf(y+"/")&&p!==y?0!==y.indexOf(p+"/")&&(l=l.then(function(){return s("local",e,S(y),w,t,r.concat(y),n.concat(x),o,a||y.indexOf(p+"/")===-1&&y!==p)})):w.circular=!0:(n.slice(g).forEach(function(e){o.refs[e].circular=!0}),w.circular=!0)))}),l=l.then(function(){function e(i,a,s,l){Object.keys(o.refs).forEach(function(c){var u=o.refs[c];n.indexOf(l)===-1&&r.indexOf(s)===-1&&t.indexOf(l)===-1&&c!==s&&0===c.indexOf(l+"/")&&(a.indexOf(l)>-1?a.forEach(function(e){t.indexOf(l)===-1&&t.push(e)}):e(i.concat(s),a.concat(l),c,u.uri),r.push(s),n.push(l))})}var t=[],r=[],n=[];Object.keys(o.refs).forEach(function(r){var n=o.refs[r];"local"!==n.type||n.circular||t.indexOf(n.uri)!==-1||e([],[],r,n.uri)}),Object.keys(o.refs).forEach(function(e){var r=o.refs[e];t.indexOf(r.uri)>-1&&(r.circular=!0)})}).then(function(){return o})}function c(e,t){var r=e;return t.forEach(function(e){if(e=decodeURI(e),!(e in r))throw Error("JSON Pointer points to missing location: "+P(t));r=r[e]}),r}function u(e){return Object.keys(e).filter(function(e){return"$ref"!==e})}function f(e){var t;switch(e.uriDetails.reference){case"absolute":case"uri":t="remote";break;case"same-document":t="local";break;default:t=e.uriDetails.reference}return t}function d(e,t){var r=U[e],o=Promise.resolve(),i=n(t.loaderOptions||{});return m(r,"Undefined")?(m(i.processContent,"Undefined")&&(i.processContent=function(e,t){t(void 0,JSON.parse(e.text))}),o=I.load(decodeURI(e),i),o=o.then(function(t){return U[e]={value:t},t}).catch(function(t){throw U[e]={error:t},t})):o=o.then(function(){return r.value}),o=o.then(function(e){return n(e)})}function p(e,t){var r=!0;try{if(!m(e,"Object"))throw new Error("obj is not an Object");if(!m(e.$ref,"String"))throw new Error("obj.$ref is not a String")}catch(e){if(t)throw e;r=!1}return r}function m(e,t){return"Undefined"===t?"undefined"==typeof e:Object.prototype.toString.call(e)==="[object "+t+"]"}function h(e){var t,r;return m(e.filter,"Array")||m(e.filter,"String")?(r=m(e.filter,"String")?[e.filter]:e.filter,t=function(e){return r.indexOf(e.type)>-1||r.indexOf(f(e))>-1}):m(e.filter,"Function")?t=e.filter:m(e.filter,"Undefined")&&(t=function(){return!0}),function(r,n){return("invalid"!==r.type||e.includeInvalid===!0)&&t(r,n)}}function v(e){var t;return m(e.subDocPath,"Array")?t=e.subDocPath:m(e.subDocPath,"String")?t=S(e.subDocPath):m(e.subDocPath,"Undefined")&&(t=[]),t}function y(e){return R.parse(encodeURI(decodeURI(e)))}function g(e,t,r){c(e,t.slice(0,t.length-1))[decodeURI(t[t.length-1])]=r}function b(e,t,r,n){function o(t,o){r.push(o),b(e,t,r,n),r.pop()}var i=!0;m(n,"Function")&&(i=n(e,t,r)),e.indexOf(t)===-1&&(e.push(t),i!==!1&&(m(t,"Array")?t.forEach(function(e,t){o(e,t.toString())}):m(t,"Object")&&Object.keys(t).forEach(function(e){o(t[e],e)}))),e.pop()}function x(e,t){if(e=m(e,"Undefined")?{}:n(e),!m(e,"Object"))throw new TypeError("options must be an Object");if(!(m(e.filter,"Undefined")||m(e.filter,"Array")||m(e.filter,"Function")||m(e.filter,"String")))throw new TypeError("options.filter must be an Array, a Function of a String");if(!m(e.includeInvalid,"Undefined")&&!m(e.includeInvalid,"Boolean"))throw new TypeError("options.includeInvalid must be a Boolean");if(!m(e.refPreProcessor,"Undefined")&&!m(e.refPreProcessor,"Function"))throw new TypeError("options.refPreProcessor must be a Function");if(!m(e.refPostProcessor,"Undefined")&&!m(e.refPostProcessor,"Function"))throw new TypeError("options.refPostProcessor must be a Function");if(!m(e.subDocPath,"Undefined")&&!m(e.subDocPath,"Array")&&!T(e.subDocPath))throw new TypeError("options.subDocPath must be an Array of path segments or a valid JSON Pointer");if(e.filter=h(e),e.subDocPath=v(e),!m(t,"Undefined"))try{c(t,e.subDocPath)}catch(e){throw e.message=e.message.replace("JSON Pointer","options.subDocPath"),e}return e}function w(){U={}}function E(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),decodeURI(e.replace(/~1/g,"/").replace(/~0/g,"~"))})}function $(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),e.replace(/~/g,"~0").replace(/\//g,"~1")})}function C(e,t){var r={};if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");return t=x(t,e),b(a(e,t.subDocPath),c(e,t.subDocPath),n(t.subDocPath),function(e,o,i){var a,s=!0;return p(o)&&(m(t.refPreProcessor,"Undefined")||(o=t.refPreProcessor(n(o),i)),a=O(o),m(t.refPostProcessor,"Undefined")||(a=t.refPostProcessor(a,i)),t.filter(a,i)&&(r[P(i)]=a),u(o).length>0&&(s=!1)),s}),r}function k(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=x(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(U[e]),i=n(t),a=y(e);return m(o.refs,"Undefined")&&(delete i.filter,delete i.subDocPath,i.includeInvalid=!0,U[e].refs=C(r,i)),m(t.filter,"Undefined")||(i.filter=t.filter),m(a.fragment,"Undefined")?m(a.subDocPath,"Undefined")||(i.subDocPath=t.subDocPath):i.subDocPath=S(decodeURI(a.fragment)),{refs:C(r,i),value:r}})}function O(e){var t,r,n,o={def:e};try{p(e,!0)?(t=e.$ref,n=H[t],m(n,"Undefined")&&(n=H[t]=y(t)),o.uri=t,o.uriDetails=n,m(n.error,"Undefined")?o.type=f(o):(o.error=o.uriDetails.error,o.type="invalid"),r=u(e),r.length>0&&(o.warning="Extra JSON Reference properties will be ignored: "+r.join(", "))):o.type="invalid"}catch(e){o.error=e.message,o.type="invalid"}return o}function T(e,t){var r,n=!0;try{if(!m(e,"String"))throw new Error("ptr is not a String");if(""!==e){if(r=e.charAt(0),["#","/"].indexOf(r)===-1)throw new Error("ptr must start with a / or #/");if("#"===r&&"#"!==e&&"/"!==e.charAt(1))throw new Error("ptr must start with a / or #/");if(e.match(q))throw new Error("ptr has invalid token(s)")}}catch(e){if(t===!0)throw e;n=!1}return n}function A(e,t){return p(e,t)&&"invalid"!==O(e,t).type}function S(e){if(!T(e))throw new Error("ptr must be a JSON Pointer");var t=e.split("/");return t.shift(),E(t)}function P(e,t){if(!m(e,"Array"))throw new Error("path must be an Array");return(t!==!1?"#":"")+(e.length>0?"/":"")+$(e).join("/")}function M(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");t=x(t,e),e=n(e)}).then(function(){return l(e,t,[],[],{documents:{},refs:{}})}).then(function(t){function r(e,t){return S(e).length-S(t).length}var n={},o={};return Object.keys(t.refs).sort(r).forEach(function(r){var i=t.refs[r];i.indirect||(o[r]=i),delete i.indirect,m(i.error,"Undefined")&&"invalid"!==i.type?(m(i.value,"Undefined")&&i.circular&&(i.value=i.def),m(i.value,"Undefined")?n[r]=i:("#"===r?e=i.value:g(e,S(r),i.value),delete i.ancestorPtrs)):delete i.ancestorPtrs}),Object.keys(n).forEach(function(r){var o=n[r];o.ancestorPtrs.forEach(function(n,i){if(m(o.value,"Undefined"))try{o.value=c(t.documents[n],S(o.uri)),delete o.ancestorPtrs,g(e,S(r),o.value)}catch(e){i===o.ancestorPtrs.length-1&&(o.error=e.message,o.missing=!0,delete o.ancestorPtrs)}})}),{refs:o,resolved:e}})}function j(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=x(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(t),i=y(e);return m(i.fragment,"Undefined")||(o.subDocPath=S(decodeURI(i.fragment))),o.relativeBase=D.dirname(e),M(r,o).then(function(e){return{refs:e.refs,resolved:e.resolved,value:r}})})}var D=e("path"),I=e("path-loader"),_=e("querystring"),F=e("slash"),R=e("uri-js"),q=/~(?:[^01]|$)/g,U={},N=["relative","remote"],L=["absolute","uri"],H={};"undefined"==typeof Promise&&e("native-promise-only"),t.exports.clearCache=w,t.exports.decodePath=E,t.exports.encodePath=$,t.exports.findRefs=C,t.exports.findRefsAt=k,t.exports.getRefDetails=O,t.exports.isPtr=T,t.exports.isRef=A,t.exports.pathFromPtr=S,t.exports.pathToPtr=P,t.exports.resolveRefs=M,t.exports.resolveRefsAt=j},{"native-promise-only":3,path:4,"path-loader":5,querystring:11,slash:13,"uri-js":23}],2:[function(e,t,r){function n(e){if(e)return o(e)}function o(e){for(var t in n.prototype)e[t]=n.prototype[t];return e}t.exports=n,n.prototype.on=n.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},n.prototype.once=function(e,t){function r(){this.off(e,r),t.apply(this,arguments)}return r.fn=t,this.on(e,r),this},n.prototype.off=n.prototype.removeListener=n.prototype.removeAllListeners=n.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var n,o=0;o<r.length;o++)if(n=r[o],n===t||n.fn===t){r.splice(o,1);break}return this},n.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),r=this._callbacks["$"+e];if(r){r=r.slice(0);for(var n=0,o=r.length;n<o;++n)r[n].apply(this,t)}return this},n.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},n.prototype.hasListeners=function(e){return!!this.listeners(e).length}},{}],3:[function(n,o,i){(function(t){/*! Native Promise Only
+e.exports=function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=13)}([function(e,t,r){"use strict";function n(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(e){var o=e.slice(),i=t||"-";return n&&(o=o.filter(function(e){return"number"!=typeof e})),(0!==r.length?r+i:"")+o.join(i)}return""}Object.defineProperty(t,"__esModule",{value:!0});var o=r(2);r.n(o);r.o(o,"parse")&&r.d(t,"parse",function(){return o.parse}),r.o(o,"stringify")&&r.d(t,"stringify",function(){return o.stringify}),r.o(o,"normalize")&&r.d(t,"normalize",function(){return o.normalize}),t.name=n},function(e,t,r){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t){if(!Array.isArray(e)){var r=function(){var r=[];return t?t.forEach(function(t){r.push({name:e[t],value:t})}):Object.keys(e).forEach(function(t){r.push({name:e[t],value:t})}),{v:r}}();if("object"===("undefined"==typeof r?"undefined":n(r)))return r.v}return e}},function(e,t,r){e.exports=r(11).ObjectPath},function(e,t,r){"use strict";function n(e,t,r,o){var i=e[g(r.type)];if(i)for(var a=void 0,s=function(t,r,o){return n(e,t,r,o)},l=0;l<i.length;l++)if(a=i[l](t,r,o,s))return a.schema["x-schema-form"]&&Object.assign(a,a.schema["x-schema-form"]),a}function o(e,t,n){n=n||{};var o=n.global&&n.global.formDefaults?Object.assign({},n.global.formDefaults):{};return n.global&&n.global.supressPropertyTitles===!0?o.title=t.title:o.title=t.title||e,t.description&&(o.description=t.description),n.required!==!0&&t.required!==!0||(o.required=!0),t.maxLength&&(o.maxlength=t.maxLength),t.minLength&&(o.minlength=t.minLength),(t.readOnly||t.readonly)&&(o.readonly=!0),t.minimum&&(o.minimum=t.minimum+(t.exclusiveMinimum?1:0)),t.maximum&&(o.maximum=t.maximum-(t.exclusiveMaximum?1:0)),t.validationMessage&&(o.validationMessage=t.validationMessage),t.enumNames&&(o.titleMap=r.i(y.a)(t.enumNames,t.enum)),o.schema=t,o.ngModelOptions=o.ngModelOptions||{},o}function i(e,t,n){if("string"===g(t.type)&&!t.enum){var i=o(e,t,n);return i.key=n.path,i.type="text",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function a(e,t,n){if("number"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function s(e,t,n){if("integer"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function l(e,t,n){if("boolean"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="checkbox",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function c(e,t,n){if("string"===g(t.type)&&t.enum){var i=o(e,t,n);return i.key=n.path,i.type="select",i.titleMap||(i.titleMap=b(t.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function u(e,t,n){if("array"===g(t.type)&&t.items&&t.items.enum){var i=o(e,t,n);return i.key=n.path,i.type="checkboxes",i.titleMap||(i.titleMap=b(t.items.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function f(e,t,n,i){if("object"===g(t.type)){var a=function(){var a=o(e,t,n);return a.type="fieldset",a.key=n.path,a.items=[],n.lookup[r.i(h.stringify)(n.path)]=a,t.properties&&Object.keys(t.properties).forEach(function(e){var o=t.properties[e],s=n.path.slice();if(s.push(e),n.ignore[r.i(h.stringify)(s)]!==!0){var l=t.required&&t.required.indexOf(e)!==-1,c=i(e,o,{path:s,required:l||!1,lookup:n.lookup,ignore:n.ignore,global:n.global});c&&a.items.push(c)}}),{v:a}}();if("object"===("undefined"==typeof a?"undefined":v(a)))return a.v}}function d(e,t,n,i){if("array"===g(t.type)){var a=o(e,t,n);a.type="array",a.key=n.path,n.lookup[r.i(h.stringify)(n.path)]=a;var s=t.required&&t.required.indexOf(n.path[n.path.length-1])!==-1,l=n.path.slice();return l.push(""),a.items=[i(e,t.items,{path:l,required:s||!1,lookup:n.lookup,ignore:n.ignore,global:n.global})],a}}function p(){return{string:[c,i],object:[f],number:[a],integer:[s],boolean:[l],array:[u,d]}}function m(e,t,r,o){var i=[],a={};if(r=r||{},o=o||{},t=t||p(),!e.properties)throw new Error('Not implemented. Only type "object" allowed at root level of schema.');return Object.keys(e.properties).forEach(function(s){if(r[s]!==!0){var l=e.required&&e.required.indexOf(s)!==-1,c=n(t,s,e.properties[s],{path:[s],lookup:a,ignore:r,required:l,global:o});c&&i.push(c)}}),{form:i,lookup:a}}Object.defineProperty(t,"__esModule",{value:!0});var h=r(0),y=r(1);t.defaultFormDefinition=n,t.stdFormObj=o,t.text=i,t.number=a,t.integer=s,t.checkbox=l,t.select=c,t.checkboxes=u,t.fieldset=f,t.array=d,t.createDefaults=p,t.defaultForm=m;var v="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},g=function(e){if(Array.isArray(e)&&2===e.length){if("null"===e[0])return e[1];if("null"===e[1])return e[0]}return e},b=function(e){var t=[];return e.forEach(function(e){t.push({name:e,value:e})}),t}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(3),o=r(0),i=r(1),a=r(6);r.d(t,"merge",function(){return a.a});var s=r(8);r.d(t,"select",function(){return s.a});var l=r(7);r.d(t,"jsonref",function(){return l.a});var c=r(9);r.d(t,"traverseSchema",function(){return c.a}),r.d(t,"traverseForm",function(){return c.b});var u=r(10);r.d(t,"validate",function(){return u.a}),r.d(t,"sfPath",function(){return f}),r.d(t,"schemaDefaults",function(){return d}),r.d(t,"canonicalTitleMap",function(){return p});var f=o,d=n,p=i.a},function(e,n,o){var i,a,s,l,l,c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};!function(t){if("object"===c(n)&&"undefined"!=typeof e)e.exports=t();else{a=[],i=t,s="function"==typeof i?i.apply(n,a):i,!(void 0!==s&&(e.exports=s))}}(function(){var e;return function e(t,r,n){function o(a,s){if(!r[a]){if(!t[a]){var c="function"==typeof l&&l;if(!s&&c)return l(a,!0);if(i)return i(a,!0);var u=new Error("Cannot find module '"+a+"'");throw u.code="MODULE_NOT_FOUND",u}var f=r[a]={exports:{}};t[a][0].call(f.exports,function(e){var r=t[a][1][e];return o(r?r:e)},f,f.exports,e,t,r,n)}return r[a].exports}for(var i="function"==typeof l&&l,a=0;a<n.length;a++)o(n[a]);return o}({1:[function(e,t,r){"use strict";function n(e){var t;return m(e,"Array")?(t=[],e.forEach(function(e,r){t[r]=n(e)})):m(e,"Object")?(t={},Object.keys(e).forEach(function(r){t[r]=n(e[r])})):t=e,t}function o(e,t){function r(e){Object.keys(e).forEach(function(t){n[t]=e[t]})}var n={};return r(_.parse(e||"")),r(_.parse(t||"")),0===Object.keys(n).length?void 0:_.stringify(n)}function i(e,t){m(e,"String")&&(e=F(e)),m(t,"String")&&(t=F(t));var r,n,i=v(m(t,"Undefined")?"":t);return L.indexOf(i.reference)>-1?n=i:(r=m(e,"Undefined")?void 0:v(e),m(r,"Undefined")?n=i:(n=r,n.path=F(I.join(r.path,i.path)),n.query=o(r.query,i.query))),n.fragment=void 0,(L.indexOf(n.reference)===-1&&0===n.path.indexOf("../")?"../":"")+R.serialize(n)}function a(e,t){var r,n=[];return t.length>0&&(r=e,t.slice(0,t.length-1).forEach(function(e){e in r&&(r=r[e],n.push(r))})),n}function s(e,t,r,o,i,a,s,u,f){var d,p;if(r.length>0)try{d=c(t,r)}catch(t){"remote"===e&&(o.error=t.message,o.missing=!0)}else d=t;if(m(d,"Undefined")||(o.value=d),m(d,"Array")||m(d,"Object"))return p=n(i),"local"===e?(delete p.subDocPath,t=d):(p.relativeBase=I.dirname(a[a.length-1]),0===r.length?delete p.subDocPath:p.subDocPath=r),l(t,p,a,s,u,f)}function l(e,t,r,n,o,a){var l=Promise.resolve(),c=n.length?S(n[n.length-1]):[],u=C(e,t),f=t.subDocPath||[],p=P(f),h=["#"];return r.forEach(function(e,t){"#"!==e.charAt(0)&&h.push(n[t])}),h.reverse(),"#"!==(r[r.length-1]||"").charAt(0)&&(o.documents[P(c)]=e),Object.keys(u).forEach(function(y){var v,g,b,x,w=u[y];b=0===r.length?c.concat(S(y)):c.concat(S(y).slice(0===r.length?0:f.length)),x=P(b),m(o[x],"Undefined")&&(o.refs[x]=u[y],m(w.error,"Undefined")&&"invalid"!==w.type&&(N.indexOf(w.type)>-1?(v=i(t.relativeBase,w.uri),g=r.indexOf(v)):(v=w.uri,g=n.indexOf(v)),w.ancestorPtrs=h,w.indirect=a,g===-1?N.indexOf(w.type)>-1?l=l.then(function(){return d(v,t).then(function(e){return s("remote",e,m(w.uriDetails.fragment,"Undefined")?[]:S(decodeURI(w.uriDetails.fragment)),w,t,r.concat(v),n.concat(x),o,a)}).catch(function(e){w.error=e.message,w.missing=!0})}):0!==x.indexOf(v+"/")&&x!==v&&0!==p.indexOf(v+"/")&&p!==v?0!==v.indexOf(p+"/")&&(l=l.then(function(){return s("local",e,S(v),w,t,r.concat(v),n.concat(x),o,a||v.indexOf(p+"/")===-1&&v!==p)})):w.circular=!0:(n.slice(g).forEach(function(e){o.refs[e].circular=!0}),w.circular=!0)))}),l=l.then(function(){function e(i,a,s,l){Object.keys(o.refs).forEach(function(c){var u=o.refs[c];n.indexOf(l)===-1&&r.indexOf(s)===-1&&t.indexOf(l)===-1&&c!==s&&0===c.indexOf(l+"/")&&(a.indexOf(l)>-1?a.forEach(function(e){t.indexOf(l)===-1&&t.push(e)}):e(i.concat(s),a.concat(l),c,u.uri),r.push(s),n.push(l))})}var t=[],r=[],n=[];Object.keys(o.refs).forEach(function(r){var n=o.refs[r];"local"!==n.type||n.circular||t.indexOf(n.uri)!==-1||e([],[],r,n.uri)}),Object.keys(o.refs).forEach(function(e){var r=o.refs[e];t.indexOf(r.uri)>-1&&(r.circular=!0)})}).then(function(){return o})}function c(e,t){var r=e;return t.forEach(function(e){if(e=decodeURI(e),!(e in r))throw Error("JSON Pointer points to missing location: "+P(t));r=r[e]}),r}function u(e){return Object.keys(e).filter(function(e){return"$ref"!==e})}function f(e){var t;switch(e.uriDetails.reference){case"absolute":case"uri":t="remote";break;case"same-document":t="local";break;default:t=e.uriDetails.reference}return t}function d(e,t){var r=U[e],o=Promise.resolve(),i=n(t.loaderOptions||{});return m(r,"Undefined")?(m(i.processContent,"Undefined")&&(i.processContent=function(e,t){t(void 0,JSON.parse(e.text))}),o=D.load(decodeURI(e),i),o=o.then(function(t){return U[e]={value:t},t}).catch(function(t){throw U[e]={error:t},t})):o=o.then(function(){return r.value}),o=o.then(function(e){return n(e)})}function p(e,t){var r=!0;try{if(!m(e,"Object"))throw new Error("obj is not an Object");if(!m(e.$ref,"String"))throw new Error("obj.$ref is not a String")}catch(e){if(t)throw e;r=!1}return r}function m(e,t){return"Undefined"===t?"undefined"==typeof e:Object.prototype.toString.call(e)==="[object "+t+"]"}function h(e){var t,r;return m(e.filter,"Array")||m(e.filter,"String")?(r=m(e.filter,"String")?[e.filter]:e.filter,t=function(e){return r.indexOf(e.type)>-1||r.indexOf(f(e))>-1}):m(e.filter,"Function")?t=e.filter:m(e.filter,"Undefined")&&(t=function(){return!0}),function(r,n){return("invalid"!==r.type||e.includeInvalid===!0)&&t(r,n)}}function y(e){var t;return m(e.subDocPath,"Array")?t=e.subDocPath:m(e.subDocPath,"String")?t=S(e.subDocPath):m(e.subDocPath,"Undefined")&&(t=[]),t}function v(e){return R.parse(encodeURI(decodeURI(e)))}function g(e,t,r){c(e,t.slice(0,t.length-1))[decodeURI(t[t.length-1])]=r}function b(e,t,r,n){function o(t,o){r.push(o),b(e,t,r,n),r.pop()}var i=!0;m(n,"Function")&&(i=n(e,t,r)),e.indexOf(t)===-1&&(e.push(t),i!==!1&&(m(t,"Array")?t.forEach(function(e,t){o(e,t.toString())}):m(t,"Object")&&Object.keys(t).forEach(function(e){o(t[e],e)}))),e.pop()}function x(e,t){if(e=m(e,"Undefined")?{}:n(e),!m(e,"Object"))throw new TypeError("options must be an Object");if(!(m(e.filter,"Undefined")||m(e.filter,"Array")||m(e.filter,"Function")||m(e.filter,"String")))throw new TypeError("options.filter must be an Array, a Function of a String");if(!m(e.includeInvalid,"Undefined")&&!m(e.includeInvalid,"Boolean"))throw new TypeError("options.includeInvalid must be a Boolean");if(!m(e.refPreProcessor,"Undefined")&&!m(e.refPreProcessor,"Function"))throw new TypeError("options.refPreProcessor must be a Function");if(!m(e.refPostProcessor,"Undefined")&&!m(e.refPostProcessor,"Function"))throw new TypeError("options.refPostProcessor must be a Function");if(!m(e.subDocPath,"Undefined")&&!m(e.subDocPath,"Array")&&!T(e.subDocPath))throw new TypeError("options.subDocPath must be an Array of path segments or a valid JSON Pointer");if(e.filter=h(e),e.subDocPath=y(e),!m(t,"Undefined"))try{c(t,e.subDocPath)}catch(e){throw e.message=e.message.replace("JSON Pointer","options.subDocPath"),e}return e}function w(){U={}}function E(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),decodeURI(e.replace(/~1/g,"/").replace(/~0/g,"~"))})}function $(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),e.replace(/~/g,"~0").replace(/\//g,"~1")})}function C(e,t){var r={};if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");return t=x(t,e),b(a(e,t.subDocPath),c(e,t.subDocPath),n(t.subDocPath),function(e,o,i){var a,s=!0;return p(o)&&(m(t.refPreProcessor,"Undefined")||(o=t.refPreProcessor(n(o),i)),a=O(o),m(t.refPostProcessor,"Undefined")||(a=t.refPostProcessor(a,i)),t.filter(a,i)&&(r[P(i)]=a),u(o).length>0&&(s=!1)),s}),r}function k(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=x(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(U[e]),i=n(t),a=v(e);return m(o.refs,"Undefined")&&(delete i.filter,delete i.subDocPath,i.includeInvalid=!0,U[e].refs=C(r,i)),m(t.filter,"Undefined")||(i.filter=t.filter),m(a.fragment,"Undefined")?m(a.subDocPath,"Undefined")||(i.subDocPath=t.subDocPath):i.subDocPath=S(decodeURI(a.fragment)),{refs:C(r,i),value:r}})}function O(e){var t,r,n,o={def:e};try{p(e,!0)?(t=e.$ref,n=H[t],m(n,"Undefined")&&(n=H[t]=v(t)),o.uri=t,o.uriDetails=n,m(n.error,"Undefined")?o.type=f(o):(o.error=o.uriDetails.error,o.type="invalid"),r=u(e),r.length>0&&(o.warning="Extra JSON Reference properties will be ignored: "+r.join(", "))):o.type="invalid"}catch(e){o.error=e.message,o.type="invalid"}return o}function T(e,t){var r,n=!0;try{if(!m(e,"String"))throw new Error("ptr is not a String");if(""!==e){if(r=e.charAt(0),["#","/"].indexOf(r)===-1)throw new Error("ptr must start with a / or #/");if("#"===r&&"#"!==e&&"/"!==e.charAt(1))throw new Error("ptr must start with a / or #/");if(e.match(q))throw new Error("ptr has invalid token(s)")}}catch(e){if(t===!0)throw e;n=!1}return n}function A(e,t){return p(e,t)&&"invalid"!==O(e,t).type}function S(e){if(!T(e))throw new Error("ptr must be a JSON Pointer");var t=e.split("/");return t.shift(),E(t)}function P(e,t){if(!m(e,"Array"))throw new Error("path must be an Array");return(t!==!1?"#":"")+(e.length>0?"/":"")+$(e).join("/")}function M(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");t=x(t,e),e=n(e)}).then(function(){return l(e,t,[],[],{documents:{},refs:{}})}).then(function(t){function r(e,t){return S(e).length-S(t).length}var n={},o={};return Object.keys(t.refs).sort(r).forEach(function(r){var i=t.refs[r];i.indirect||(o[r]=i),delete i.indirect,m(i.error,"Undefined")&&"invalid"!==i.type?(m(i.value,"Undefined")&&i.circular&&(i.value=i.def),m(i.value,"Undefined")?n[r]=i:("#"===r?e=i.value:g(e,S(r),i.value),delete i.ancestorPtrs)):delete i.ancestorPtrs}),Object.keys(n).forEach(function(r){var o=n[r];o.ancestorPtrs.forEach(function(n,i){if(m(o.value,"Undefined"))try{o.value=c(t.documents[n],S(o.uri)),delete o.ancestorPtrs,g(e,S(r),o.value)}catch(e){i===o.ancestorPtrs.length-1&&(o.error=e.message,o.missing=!0,delete o.ancestorPtrs)}})}),{refs:o,resolved:e}})}function j(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=x(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(t),i=v(e);return m(i.fragment,"Undefined")||(o.subDocPath=S(decodeURI(i.fragment))),o.relativeBase=I.dirname(e),M(r,o).then(function(e){return{refs:e.refs,resolved:e.resolved,value:r}})})}var I=e("path"),D=e("path-loader"),_=e("querystring"),F=e("slash"),R=e("uri-js"),q=/~(?:[^01]|$)/g,U={},N=["relative","remote"],L=["absolute","uri"],H={};"undefined"==typeof Promise&&e("native-promise-only"),t.exports.clearCache=w,t.exports.decodePath=E,t.exports.encodePath=$,t.exports.findRefs=C,t.exports.findRefsAt=k,t.exports.getRefDetails=O,t.exports.isPtr=T,t.exports.isRef=A,t.exports.pathFromPtr=S,t.exports.pathToPtr=P,t.exports.resolveRefs=M,t.exports.resolveRefsAt=j},{"native-promise-only":3,path:4,"path-loader":5,querystring:11,slash:13,"uri-js":23}],2:[function(e,t,r){function n(e){if(e)return o(e)}function o(e){for(var t in n.prototype)e[t]=n.prototype[t];return e}t.exports=n,n.prototype.on=n.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},n.prototype.once=function(e,t){function r(){this.off(e,r),t.apply(this,arguments)}return r.fn=t,this.on(e,r),this},n.prototype.off=n.prototype.removeListener=n.prototype.removeAllListeners=n.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var n,o=0;o<r.length;o++)if(n=r[o],n===t||n.fn===t){r.splice(o,1);break}return this},n.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),r=this._callbacks["$"+e];if(r){r=r.slice(0);for(var n=0,o=r.length;n<o;++n)r[n].apply(this,t)}return this},n.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},n.prototype.hasListeners=function(e){return!!this.listeners(e).length}},{}],3:[function(n,o,i){(function(t){/*! Native Promise Only
     v0.8.1 (c) Kyle Simpson
     MIT License: http://getify.mit-license.org
 */
-!function(t,r,n){r[t]=r[t]||n(),"undefined"!=typeof o&&o.exports?o.exports=r[t]:"function"==typeof e&&e.amd&&e(function(){return r[t]})}("Promise","undefined"!=typeof t?t:this,function(){"use strict";function e(e,t){m.add(e,t),p||(p=v(m.drain))}function t(e){var t,r="undefined"==typeof e?"undefined":c(e);return null==e||"object"!=r&&"function"!=r||(t=e.then),"function"==typeof t&&t}function n(){for(var e=0;e<this.chain.length;e++)o(this,1===this.state?this.chain[e].success:this.chain[e].failure,this.chain[e]);this.chain.length=0}function o(e,r,n){var o,i;try{r===!1?n.reject(e.msg):(o=r===!0?e.msg:r.call(void 0,e.msg),o===n.promise?n.reject(TypeError("Promise-chain cycle")):(i=t(o))?i.call(o,n.resolve,n.reject):n.resolve(o))}catch(e){n.reject(e)}}function i(r){var o,s=this;if(!s.triggered){s.triggered=!0,s.def&&(s=s.def);try{(o=t(r))?e(function(){var e=new l(s);try{o.call(r,function(){i.apply(e,arguments)},function(){a.apply(e,arguments)})}catch(t){a.call(e,t)}}):(s.msg=r,s.state=1,s.chain.length>0&&e(n,s))}catch(e){a.call(new l(s),e)}}}function a(t){var r=this;r.triggered||(r.triggered=!0,r.def&&(r=r.def),r.msg=t,r.state=2,r.chain.length>0&&e(n,r))}function s(e,t,r,n){for(var o=0;o<t.length;o++)!function(o){e.resolve(t[o]).then(function(e){r(o,e)},n)}(o)}function l(e){this.def=e,this.triggered=!1}function u(e){this.promise=e,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function f(t){if("function"!=typeof t)throw TypeError("Not a function");if(0!==this.__NPO__)throw TypeError("Not a promise");this.__NPO__=1;var r=new u(this);this.then=function(t,o){var i={success:"function"!=typeof t||t,failure:"function"==typeof o&&o};return i.promise=new this.constructor(function(e,t){if("function"!=typeof e||"function"!=typeof t)throw TypeError("Not a function");i.resolve=e,i.reject=t}),r.chain.push(i),0!==r.state&&e(n,r),i.promise},this.catch=function(e){return this.then(void 0,e)};try{t.call(void 0,function(e){i.call(r,e)},function(e){a.call(r,e)})}catch(e){a.call(r,e)}}var d,p,m,h=Object.prototype.toString,v="undefined"!=typeof r?function(e){return r(e)}:setTimeout;try{Object.defineProperty({},"x",{}),d=function(e,t,r,n){return Object.defineProperty(e,t,{value:r,writable:!0,configurable:n!==!1})}}catch(e){d=function(e,t,r){return e[t]=r,e}}m=function(){function e(e,t){this.fn=e,this.self=t,this.next=void 0}var t,r,n;return{add:function(o,i){n=new e(o,i),r?r.next=n:t=n,r=n,n=void 0},drain:function(){var e=t;for(t=r=p=void 0;e;)e.fn.call(e.self),e=e.next}}}();var y=d({},"constructor",f,!1);return f.prototype=y,d(y,"__NPO__",0,!1),d(f,"resolve",function(e){var t=this;return e&&"object"==("undefined"==typeof e?"undefined":c(e))&&1===e.__NPO__?e:new t(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");t(e)})}),d(f,"reject",function(e){return new this(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");r(e)})}),d(f,"all",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):0===e.length?t.resolve([]):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");var o=e.length,i=Array(o),a=0;s(t,e,function(e,t){i[e]=t,++a===o&&r(i)},n)})}),d(f,"race",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");s(t,e,function(e,t){r(t)},n)})}),f})}).call(this,"undefined"!=typeof t?t:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],4:[function(e,t,r){(function(e){function t(e,t){for(var r=0,n=e.length-1;n>=0;n--){var o=e[n];"."===o?e.splice(n,1):".."===o?(e.splice(n,1),r++):r&&(e.splice(n,1),r--)}if(t)for(;r--;r)e.unshift("..");return e}function n(e,t){if(e.filter)return e.filter(t);for(var r=[],n=0;n<e.length;n++)t(e[n],n,e)&&r.push(e[n]);return r}var o=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,i=function(e){return o.exec(e).slice(1)};r.resolve=function(){for(var r="",o=!1,i=arguments.length-1;i>=-1&&!o;i--){var a=i>=0?arguments[i]:e.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(r=a+"/"+r,o="/"===a.charAt(0))}return r=t(n(r.split("/"),function(e){return!!e}),!o).join("/"),(o?"/":"")+r||"."},r.normalize=function(e){var o=r.isAbsolute(e),i="/"===a(e,-1);return e=t(n(e.split("/"),function(e){return!!e}),!o).join("/"),e||o||(e="."),e&&i&&(e+="/"),(o?"/":"")+e},r.isAbsolute=function(e){return"/"===e.charAt(0)},r.join=function(){var e=Array.prototype.slice.call(arguments,0);return r.normalize(n(e,function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e}).join("/"))},r.relative=function(e,t){function n(e){for(var t=0;t<e.length&&""===e[t];t++);for(var r=e.length-1;r>=0&&""===e[r];r--);return t>r?[]:e.slice(t,r-t+1)}e=r.resolve(e).substr(1),t=r.resolve(t).substr(1);for(var o=n(e.split("/")),i=n(t.split("/")),a=Math.min(o.length,i.length),s=a,l=0;l<a;l++)if(o[l]!==i[l]){s=l;break}for(var c=[],l=s;l<o.length;l++)c.push("..");return c=c.concat(i.slice(s)),c.join("/")},r.sep="/",r.delimiter=":",r.dirname=function(e){var t=i(e),r=t[0],n=t[1];return r||n?(n&&(n=n.substr(0,n.length-1)),r+n):"."},r.basename=function(e,t){var r=i(e)[2];return t&&r.substr(-1*t.length)===t&&(r=r.substr(0,r.length-t.length)),r},r.extname=function(e){return i(e)[3]};var a="b"==="ab".substr(-1)?function(e,t,r){return e.substr(t,r)}:function(e,t,r){return t<0&&(t=e.length+t),e.substr(t,r)}}).call(this,e("_process"))},{_process:8}],5:[function(e,t,r){"use strict";function n(e){return"undefined"!=typeof e&&(e=e.indexOf("://")===-1?"":e.split("://")[0]),e}function o(e){var t=n(e),r=i[t];if("undefined"==typeof r){if(""!==t)throw new Error("Unsupported scheme: "+t);r=a}return r}var i={file:e("./lib/loaders/file"),http:e("./lib/loaders/http"),https:e("./lib/loaders/http")},a="object"===("undefined"==typeof window?"undefined":c(window))||"function"==typeof importScripts?i.http:i.file;"undefined"==typeof Promise&&e("native-promise-only"),t.exports.load=function(e,t){var r=Promise.resolve();return"undefined"==typeof t&&(t={}),r=r.then(function(){if("undefined"==typeof e)throw new TypeError("location is required");if("string"!=typeof e)throw new TypeError("location must be a string");if("undefined"!=typeof t){if("object"!==("undefined"==typeof t?"undefined":c(t)))throw new TypeError("options must be an object");if("undefined"!=typeof t.processContent&&"function"!=typeof t.processContent)throw new TypeError("options.processContent must be a function")}}),r=r.then(function(){return new Promise(function(r,n){var i=o(e);i.load(e,t||{},function(e,t){e?n(e):r(t)})})}).then(function(e){return t.processContent?new Promise(function(r,n){t.processContent("object"===("undefined"==typeof e?"undefined":c(e))?e:{text:e},function(e,t){e?n(e):r(t)})}):"object"===("undefined"==typeof e?"undefined":c(e))?e.text:e})}},{"./lib/loaders/file":6,"./lib/loaders/http":7,"native-promise-only":3}],6:[function(e,t,r){"use strict";var n=new TypeError("The 'file' scheme is not supported in the browser");t.exports.getBase=function(){throw n},t.exports.load=function(){var e=arguments[arguments.length-1];if("function"!=typeof e)throw n;e(n)}},{}],7:[function(e,t,r){"use strict";var n=e("superagent"),o=["delete","get","head","patch","post","put"];t.exports.load=function(e,t,r){function i(e,t){e?r(e):("function"==typeof t.buffer&&t.buffer(!0),t.end(function(e,t){e?r(e):r(void 0,t)}))}var a,s,l=t.method?t.method.toLowerCase():"get";if("undefined"!=typeof t.method?"string"!=typeof t.method?a=new TypeError("options.method must be a string"):o.indexOf(t.method)===-1&&(a=new TypeError("options.method must be one of the following: "+o.slice(0,o.length-1).join(", ")+" or "+o[o.length-1])):"undefined"!=typeof t.prepareRequest&&"function"!=typeof t.prepareRequest&&(a=new TypeError("options.prepareRequest must be a function")),a)r(a);else if(s=n["delete"===l?"del":l](e),t.prepareRequest)try{t.prepareRequest(s,i)}catch(e){r(e)}else i(void 0,s)}},{superagent:14}],8:[function(e,t,r){function n(){u=!1,s.length?c=s.concat(c):f=-1,c.length&&o()}function o(){if(!u){var e=setTimeout(n);u=!0;for(var t=c.length;t;){for(s=c,c=[];++f<t;)s&&s[f].run();f=-1,t=c.length}s=null,u=!1,clearTimeout(e)}}function i(e,t){this.fun=e,this.array=t}function a(){}var s,l=t.exports={},c=[],u=!1,f=-1;l.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];c.push(new i(e,t)),1!==c.length||u||setTimeout(o,0)},i.prototype.run=function(){this.fun.apply(null,this.array)},l.title="browser",l.browser=!0,l.env={},l.argv=[],l.version="",l.versions={},l.on=a,l.addListener=a,l.once=a,l.off=a,l.removeListener=a,l.removeAllListeners=a,l.emit=a,l.binding=function(e){throw new Error("process.binding is not supported")},l.cwd=function(){return"/"},l.chdir=function(e){throw new Error("process.chdir is not supported")},l.umask=function(){return 0}},{}],9:[function(e,t,r){"use strict";function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.exports=function(e,t,r,i){t=t||"&",r=r||"=";var a={};if("string"!=typeof e||0===e.length)return a;var s=/\+/g;e=e.split(t);var l=1e3;i&&"number"==typeof i.maxKeys&&(l=i.maxKeys);var c=e.length;l>0&&c>l&&(c=l);for(var u=0;u<c;++u){var f,d,p,m,h=e[u].replace(s,"%20"),v=h.indexOf(r);v>=0?(f=h.substr(0,v),d=h.substr(v+1)):(f=h,d=""),p=decodeURIComponent(f),m=decodeURIComponent(d),n(a,p)?o(a[p])?a[p].push(m):a[p]=[a[p],m]:a[p]=m}return a};var o=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},{}],10:[function(e,t,r){"use strict";function n(e,t){if(e.map)return e.map(t);for(var r=[],n=0;n<e.length;n++)r.push(t(e[n],n));return r}var o=function(e){switch("undefined"==typeof e?"undefined":c(e)){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};t.exports=function(e,t,r,s){return t=t||"&",r=r||"=",null===e&&(e=void 0),"object"===("undefined"==typeof e?"undefined":c(e))?n(a(e),function(a){var s=encodeURIComponent(o(a))+r;return i(e[a])?n(e[a],function(e){return s+encodeURIComponent(o(e))}).join(t):s+encodeURIComponent(o(e[a]))}).join(t):s?encodeURIComponent(o(s))+r+encodeURIComponent(o(e)):""};var i=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},a=Object.keys||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t}},{}],11:[function(e,t,r){"use strict";r.decode=r.parse=e("./decode"),r.encode=r.stringify=e("./encode")},{"./decode":9,"./encode":10}],12:[function(e,t,r){t.exports=function(e,t,r){for(var n=0,o=e.length,i=3==arguments.length?r:e[n++];n<o;)i=t.call(null,i,e[n],++n,e);return i}},{}],13:[function(e,t,r){"use strict";t.exports=function(e){var t=/^\\\\\?\\/.test(e),r=/[^\x00-\x80]+/.test(e);return t||r?e:e.replace(/\\/g,"/")}},{}],14:[function(e,t,r){function n(){}function o(e){var t={}.toString.call(e);switch(t){case"[object File]":case"[object Blob]":case"[object FormData]":return!0;default:return!1}}function i(e){if(!b(e))return e;var t=[];for(var r in e)null!=e[r]&&a(t,r,e[r]);return t.join("&")}function a(e,t,r){return Array.isArray(r)?r.forEach(function(r){a(e,t,r)}):void e.push(encodeURIComponent(t)+"="+encodeURIComponent(r))}function s(e){for(var t,r,n={},o=e.split("&"),i=0,a=o.length;i<a;++i)r=o[i],t=r.split("="),n[decodeURIComponent(t[0])]=decodeURIComponent(t[1]);return n}function l(e){var t,r,n,o,i=e.split(/\r?\n/),a={};i.pop();for(var s=0,l=i.length;s<l;++s)r=i[s],t=r.indexOf(":"),n=r.slice(0,t).toLowerCase(),o=w(r.slice(t+1)),a[n]=o;return a}function c(e){return/[\/+]json\b/.test(e)}function u(e){return e.split(/ *; */).shift()}function f(e){return y(e.split(/ *; */),function(e,t){var r=t.split(/ *= */),n=r.shift(),o=r.shift();return n&&o&&(e[n]=o),e},{})}function d(e,t){t=t||{},this.req=e,this.xhr=this.req.xhr,this.text="HEAD"!=this.req.method&&(""===this.xhr.responseType||"text"===this.xhr.responseType)||"undefined"==typeof this.xhr.responseType?this.xhr.responseText:null,this.statusText=this.req.xhr.statusText,this.setStatusProperties(this.xhr.status),this.header=this.headers=l(this.xhr.getAllResponseHeaders()),this.header["content-type"]=this.xhr.getResponseHeader("content-type"),this.setHeaderProperties(this.header),this.body="HEAD"!=this.req.method?this.parseBody(this.text?this.text:this.xhr.response):null}function p(e,t){var r=this;this._query=this._query||[],this.method=e,this.url=t,this.header={},this._header={},this.on("end",function(){var e=null,t=null;try{t=new d(r)}catch(t){return e=new Error("Parser is unable to parse the response"),e.parse=!0,e.original=t,e.rawResponse=r.xhr&&r.xhr.responseText?r.xhr.responseText:null,e.statusCode=r.xhr&&r.xhr.status?r.xhr.status:null,r.callback(e)}if(r.emit("response",t),e)return r.callback(e,t);if(t.status>=200&&t.status<300)return r.callback(e,t);var n=new Error(t.statusText||"Unsuccessful HTTP response");n.original=e,n.response=t,n.status=t.status,r.callback(n,t)})}function m(e,t){var r=x("DELETE",e);return t&&r.end(t),r}var h,v=e("emitter"),y=e("reduce"),g=e("./request-base"),b=e("./is-object");h="undefined"!=typeof window?window:"undefined"!=typeof self?self:this;var x=t.exports=e("./request").bind(null,p);x.getXHR=function(){if(!(!h.XMLHttpRequest||h.location&&"file:"==h.location.protocol&&h.ActiveXObject))return new XMLHttpRequest;try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(e){}return!1};var w="".trim?function(e){return e.trim()}:function(e){return e.replace(/(^\s*|\s*$)/g,"")};x.serializeObject=i,x.parseString=s,x.types={html:"text/html",json:"application/json",xml:"application/xml",urlencoded:"application/x-www-form-urlencoded",form:"application/x-www-form-urlencoded","form-data":"application/x-www-form-urlencoded"},x.serialize={"application/x-www-form-urlencoded":i,"application/json":JSON.stringify},x.parse={"application/x-www-form-urlencoded":s,"application/json":JSON.parse},d.prototype.get=function(e){return this.header[e.toLowerCase()]},d.prototype.setHeaderProperties=function(e){var t=this.header["content-type"]||"";this.type=u(t);var r=f(t);for(var n in r)this[n]=r[n]},d.prototype.parseBody=function(e){var t=x.parse[this.type];return!t&&c(this.type)&&(t=x.parse["application/json"]),t&&e&&(e.length||e instanceof Object)?t(e):null},d.prototype.setStatusProperties=function(e){1223===e&&(e=204);var t=e/100|0;this.status=this.statusCode=e,this.statusType=t,this.info=1==t,this.ok=2==t,this.clientError=4==t,this.serverError=5==t,this.error=(4==t||5==t)&&this.toError(),this.accepted=202==e,this.noContent=204==e,this.badRequest=400==e,this.unauthorized=401==e,this.notAcceptable=406==e,this.notFound=404==e,this.forbidden=403==e},d.prototype.toError=function(){var e=this.req,t=e.method,r=e.url,n="cannot "+t+" "+r+" ("+this.status+")",o=new Error(n);return o.status=this.status,o.method=t,o.url=r,o},x.Response=d,v(p.prototype);for(var E in g)p.prototype[E]=g[E];p.prototype.abort=function(){if(!this.aborted)return this.aborted=!0,this.xhr.abort(),this.clearTimeout(),this.emit("abort"),this},p.prototype.type=function(e){return this.set("Content-Type",x.types[e]||e),this},p.prototype.responseType=function(e){return this._responseType=e,this},p.prototype.accept=function(e){return this.set("Accept",x.types[e]||e),this},p.prototype.auth=function(e,t,r){switch(r||(r={type:"basic"}),r.type){case"basic":var n=btoa(e+":"+t);this.set("Authorization","Basic "+n);break;case"auto":this.username=e,this.password=t}return this},p.prototype.query=function(e){return"string"!=typeof e&&(e=i(e)),e&&this._query.push(e),this},p.prototype.attach=function(e,t,r){return this._getFormData().append(e,t,r||t.name),this},p.prototype._getFormData=function(){return this._formData||(this._formData=new h.FormData),this._formData},p.prototype.send=function(e){var t=b(e),r=this._header["content-type"];if(t&&b(this._data))for(var n in e)this._data[n]=e[n];else"string"==typeof e?(r||this.type("form"),r=this._header["content-type"],"application/x-www-form-urlencoded"==r?this._data=this._data?this._data+"&"+e:e:this._data=(this._data||"")+e):this._data=e;return!t||o(e)?this:(r||this.type("json"),this)},d.prototype.parse=function(e){return h.console&&console.warn("Client-side parse() method has been renamed to serialize(). This method is not compatible with superagent v2.0"),this.serialize(e),this},d.prototype.serialize=function(e){return this._parser=e,this},p.prototype.callback=function(e,t){var r=this._callback;this.clearTimeout(),r(e,t)},p.prototype.crossDomainError=function(){var e=new Error("Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.");e.crossDomain=!0,e.status=this.status,e.method=this.method,e.url=this.url,this.callback(e)},p.prototype.timeoutError=function(){var e=this._timeout,t=new Error("timeout of "+e+"ms exceeded");t.timeout=e,this.callback(t)},p.prototype.withCredentials=function(){return this._withCredentials=!0,this},p.prototype.end=function(e){var t=this,r=this.xhr=x.getXHR(),i=this._query.join("&"),a=this._timeout,s=this._formData||this._data;this._callback=e||n,r.onreadystatechange=function(){if(4==r.readyState){var e;try{e=r.status}catch(t){e=0}if(0==e){if(t.timedout)return t.timeoutError();if(t.aborted)return;return t.crossDomainError()}t.emit("end")}};var l=function(e){e.total>0&&(e.percent=e.loaded/e.total*100),e.direction="download",t.emit("progress",e)};this.hasListeners("progress")&&(r.onprogress=l);try{r.upload&&this.hasListeners("progress")&&(r.upload.onprogress=l)}catch(e){}if(a&&!this._timer&&(this._timer=setTimeout(function(){t.timedout=!0,t.abort()},a)),i&&(i=x.serializeObject(i),this.url+=~this.url.indexOf("?")?"&"+i:"?"+i),this.username&&this.password?r.open(this.method,this.url,!0,this.username,this.password):r.open(this.method,this.url,!0),this._withCredentials&&(r.withCredentials=!0),"GET"!=this.method&&"HEAD"!=this.method&&"string"!=typeof s&&!o(s)){var u=this._header["content-type"],f=this._parser||x.serialize[u?u.split(";")[0]:""];!f&&c(u)&&(f=x.serialize["application/json"]),f&&(s=f(s))}for(var d in this.header)null!=this.header[d]&&r.setRequestHeader(d,this.header[d]);return this._responseType&&(r.responseType=this._responseType),this.emit("request",this),r.send("undefined"!=typeof s?s:null),this},x.Request=p,x.get=function(e,t,r){var n=x("GET",e);return"function"==typeof t&&(r=t,t=null),t&&n.query(t),r&&n.end(r),n},x.head=function(e,t,r){var n=x("HEAD",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.del=m,x.delete=m,x.patch=function(e,t,r){var n=x("PATCH",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.post=function(e,t,r){var n=x("POST",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.put=function(e,t,r){var n=x("PUT",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n}},{"./is-object":15,"./request":17,"./request-base":16,emitter:2,reduce:12}],15:[function(e,t,r){function n(e){return null!=e&&"object"==("undefined"==typeof e?"undefined":c(e))}t.exports=n},{}],16:[function(e,t,r){var n=e("./is-object");r.clearTimeout=function(){return this._timeout=0,clearTimeout(this._timer),this},r.parse=function(e){return this._parser=e,this},r.timeout=function(e){return this._timeout=e,this},r.then=function(e,t){return this.end(function(r,n){r?t(r):e(n)})},r.use=function(e){return e(this),this},r.get=function(e){return this._header[e.toLowerCase()]},r.getHeader=r.get,r.set=function(e,t){if(n(e)){for(var r in e)this.set(r,e[r]);return this}return this._header[e.toLowerCase()]=t,this.header[e]=t,this},r.unset=function(e){return delete this._header[e.toLowerCase()],delete this.header[e],this},r.field=function(e,t){return this._getFormData().append(e,t),this}},{"./is-object":15}],17:[function(e,t,r){function n(e,t,r){return"function"==typeof r?new e("GET",t).end(r):2==arguments.length?new e("GET",t):new e(t,r)}t.exports=n},{}],18:[function(e,t,r){/*! https://mths.be/punycode v1.3.2 by @mathias, modified for URI.js */var n=function(){function e(e){throw new RangeError(k[e])}function t(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function r(e,r){var n=e.split("@"),o="";n.length>1&&(o=n[0]+"@",e=n[1]),e=e.replace(C,".");var i=e.split("."),a=t(i,r).join(".");return o+a}function n(e){for(var t,r,n=[],o=0,i=e.length;o<i;)t=e.charCodeAt(o++),t>=55296&&t<=56319&&o<i?(r=e.charCodeAt(o++),56320==(64512&r)?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),o--)):n.push(t);return n}function o(e){return t(e,function(e){var t="";return e>65535&&(e-=65536,t+=A(e>>>10&1023|55296),e=56320|1023&e),t+=A(e)}).join("")}function i(e){return e-48<10?e-22:e-65<26?e-65:e-97<26?e-97:m}function a(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function s(e,t,r){var n=0;for(e=r?T(e/g):e>>1,e+=T(e/t);e>O*v>>1;n+=m)e=T(e/O);return T(n+(O+1)*e/(e+y))}function l(t){var r,n,a,l,c,u,f,d,y,g,E=[],$=t.length,C=0,k=x,O=b;for(n=t.lastIndexOf(w),n<0&&(n=0),a=0;a<n;++a)t.charCodeAt(a)>=128&&e("not-basic"),E.push(t.charCodeAt(a));for(l=n>0?n+1:0;l<$;){for(c=C,u=1,f=m;l>=$&&e("invalid-input"),d=i(t.charCodeAt(l++)),(d>=m||d>T((p-C)/u))&&e("overflow"),C+=d*u,y=f<=O?h:f>=O+v?v:f-O,!(d<y);f+=m)g=m-y,u>T(p/g)&&e("overflow"),u*=g;r=E.length+1,O=s(C-c,r,0==c),T(C/r)>p-k&&e("overflow"),k+=T(C/r),C%=r,E.splice(C++,0,k)}return o(E)}function c(t){var r,o,i,l,c,u,f,d,y,g,E,$,C,k,O,S=[];for(t=n(t),$=t.length,r=x,o=0,c=b,u=0;u<$;++u)E=t[u],E<128&&S.push(A(E));for(i=l=S.length,l&&S.push(w);i<$;){for(f=p,u=0;u<$;++u)E=t[u],E>=r&&E<f&&(f=E);for(C=i+1,f-r>T((p-o)/C)&&e("overflow"),o+=(f-r)*C,r=f,u=0;u<$;++u)if(E=t[u],E<r&&++o>p&&e("overflow"),E==r){for(d=o,y=m;g=y<=c?h:y>=c+v?v:y-c,!(d<g);y+=m)O=d-g,k=m-g,S.push(A(a(g+O%k,0))),d=T(O/k);S.push(A(a(d,0))),c=s(o,C,i==l),o=0,++i}++o,++r}return S.join("")}function u(e){return r(e,function(e){return E.test(e)?l(e.slice(4).toLowerCase()):e})}function f(e){return r(e,function(e){return $.test(e)?"xn--"+c(e):e})}var d,p=2147483647,m=36,h=1,v=26,y=38,g=700,b=72,x=128,w="-",E=/^xn--/,$=/[^\x20-\x7E]/,C=/[\x2E\u3002\uFF0E\uFF61]/g,k={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},O=m-h,T=Math.floor,A=String.fromCharCode;return d={version:"1.3.2",ucs2:{decode:n,encode:o},decode:l,encode:c,toASCII:f,toUnicode:u}}();"undefined"==typeof COMPILED&&"undefined"!=typeof t&&(t.exports=n)},{}],19:[function(e,t,r){e("./schemes/http"),e("./schemes/urn"),e("./schemes/mailto")},{"./schemes/http":20,"./schemes/mailto":21,"./schemes/urn":22}],20:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");n.SCHEMES.http=n.SCHEMES.https={domainHost:!0,parse:function(e,t){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e},serialize:function(e,t){return e.port!==("https"!==String(e.scheme).toLowerCase()?80:443)&&""!==e.port||(e.port=void 0),e.path||(e.path="/"),e}}},{"../uri":23}],21:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri"),o=e("../punycode");!function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(e){return e.toUpperCase()}function i(e){var t=n.pctDecChars(e);return t.match(M)?t:e}function a(e){return void 0!==e&&null!==e?e instanceof Array&&!e.callee?e:"number"!=typeof e.length||e.split||e.setInterval||e.call?[e]:Array.prototype.slice.call(e):[]}var s={},l=n.IRI_SUPPORT,c="[A-Za-z0-9\\-\\.\\_\\~"+(l?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",u="[0-9A-Fa-f]",f=t(t("%[EFef]"+u+"%"+u+u+"%"+u+u)+"|"+t("%[89A-Fa-f]"+u+"%"+u+u)+"|"+t("%"+u+u)),d="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",p="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",m=e(p,'[\\"\\\\]'),h=t(d+"+"+t("\\."+d+"+")+"*"),v=t("\\\\"+m),y=t(p+"|"+v),g=t('\\"'+y+'*\\"'),b="[\\x21-\\x5A\\x5E-\\x7E]",x="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",w=t(c+"|"+f+"|"+x),E=t(h+"|\\["+b+"*\\]"),$=t(h+"|"+g),C=t($+"\\@"+E),k=t(C+t("\\,"+C)+"*"),O=t(w+"*"),T=O,A=t(O+"\\="+T),S=t(A+t("\\&"+A)+"*"),P=t("\\?"+S),M=(n.VALIDATE_SUPPORT&&new RegExp("^mailto\\:"+k+"?"+P+"?$"),new RegExp(c,"g")),j=new RegExp(f,"g"),D=new RegExp(e("[^]",d,"[\\.]",'[\\"]',m),"g"),I=new RegExp(e("[^]",d,"[\\.]","[\\[]",b,"[\\]]"),"g"),_=new RegExp(e("[^]",c,x),"g"),F=_,R=n.VALIDATE_SUPPORT&&new RegExp("^"+k+"$"),q=n.VALIDATE_SUPPORT&&new RegExp("^"+S+"$");n.SCHEMES.mailto={parse:function(e,t){n.VALIDATE_SUPPORT&&!e.error&&(e.path&&!R.test(e.path)?e.error="Email address is not valid":e.query&&!q.test(e.query)&&(e.error="Header fields are invalid"));var r=e.to=e.path?e.path.split(","):[];if(e.path=void 0,e.query){for(var i=!1,a={},s=e.query.split("&"),l=0,c=s.length;l<c;++l){var u=s[l].split("=");switch(u[0]){case"to":for(var f=u[1].split(","),d=0,p=f.length;d<p;++d)r.push(f[d]);break;case"subject":e.subject=n.unescapeComponent(u[1],t);break;case"body":e.body=n.unescapeComponent(u[1],t);break;default:i=!0,a[n.unescapeComponent(u[0],t)]=n.unescapeComponent(u[1],t)}}i&&(e.headers=a)}e.query=void 0;for(var l=0,c=r.length;l<c;++l){var m=r[l].split("@");if(m[0]=n.unescapeComponent(m[0]),"undefined"==typeof o||t.unicodeSupport)m[1]=n.unescapeComponent(m[1],t).toLowerCase();else try{m[1]=o.toASCII(n.unescapeComponent(m[1],t).toLowerCase())}catch(t){e.error=e.error||"Email address's domain name can not be converted to ASCII via punycode: "+t}r[l]=m.join("@")}return e},serialize:function(e,t){var l=a(e.to);if(l){for(var c=0,u=l.length;c<u;++c){var f=String(l[c]),d=f.lastIndexOf("@"),p=f.slice(0,d),m=f.slice(d+1);if(p=p.replace(j,i).replace(j,r).replace(D,n.pctEncChar),"undefined"!=typeof o)try{m=t.iri?o.toUnicode(m):o.toASCII(n.unescapeComponent(m,t).toLowerCase())}catch(r){e.error=e.error||"Email address's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}else m=m.replace(j,i).toLowerCase().replace(j,r).replace(I,n.pctEncChar);l[c]=p+"@"+m}e.path=l.join(",")}var h=e.headers=e.headers||{};e.subject&&(h.subject=e.subject),e.body&&(h.body=e.body);var v=[];for(var y in h)h[y]!==s[y]&&v.push(y.replace(j,i).replace(j,r).replace(_,n.pctEncChar)+"="+h[y].replace(j,i).replace(j,r).replace(F,n.pctEncChar));return v.length&&(e.query=v.join("&")),e}}}()},{"../punycode":18,"../uri":23}],22:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");!function(){var e=n.pctEncChar,t="(?:[0-9A-Za-z][0-9A-Za-z\\-]{1,31})",r="(?:\\%[0-9A-Fa-f]{2})",o="[0-9A-Za-z\\(\\)\\+\\,\\-\\.\\:\\=\\@\\;\\$\\_\\!\\*\\'\\/\\?\\#]",i="(?:(?:"+r+"|"+o+")+)",a=new RegExp("^urn\\:("+t+")$"),s=new RegExp("^("+t+")\\:("+i+")$"),l=/^([^\:]+)\:(.*)/,c=/[\x00-\x20\\\"\&\<\>\[\]\^\`\{\|\}\~\x7F-\xFF]/g,u=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/;n.SCHEMES.urn={parse:function(e,t){var r,o,i=e.path.match(s);return i||(t.tolerant||(e.error=e.error||"URN is not strictly valid."),i=e.path.match(l)),i?(r="urn:"+i[1].toLowerCase(),o=n.SCHEMES[r],o||(o=n.SCHEMES[r]={parse:function(e,t){return e},serialize:n.SCHEMES.urn.serialize}),e.scheme=r,e.path=i[2],e=o.parse(e,t)):e.error=e.error||"URN can not be parsed.",e},serialize:function(t,r){var n,o=t.scheme||r.scheme;if(o&&"urn"!==o){var n=o.match(a);n||(n=["urn:"+o,o]),t.scheme="urn",t.path=n[1]+":"+(t.path?t.path.replace(c,e):"")}return t}},n.SCHEMES["urn:uuid"]={parse:function(e,t){return t.tolerant||e.path&&e.path.match(u)||(e.error=e.error||"UUID is not valid."),e},serialize:function(e,t){return t.tolerant||e.path&&e.path.match(u)?e.path=(e.path||"").toLowerCase():e.scheme=void 0,n.SCHEMES.urn.serialize(e,t)}}}()},{"../uri":23}],23:[function(e,t,r){/**
+!function(t,r,n){r[t]=r[t]||n(),"undefined"!=typeof o&&o.exports?o.exports=r[t]:"function"==typeof e&&e.amd&&e(function(){return r[t]})}("Promise","undefined"!=typeof t?t:this,function(){"use strict";function e(e,t){m.add(e,t),p||(p=y(m.drain))}function t(e){var t,r="undefined"==typeof e?"undefined":c(e);return null==e||"object"!=r&&"function"!=r||(t=e.then),"function"==typeof t&&t}function n(){for(var e=0;e<this.chain.length;e++)o(this,1===this.state?this.chain[e].success:this.chain[e].failure,this.chain[e]);this.chain.length=0}function o(e,r,n){var o,i;try{r===!1?n.reject(e.msg):(o=r===!0?e.msg:r.call(void 0,e.msg),o===n.promise?n.reject(TypeError("Promise-chain cycle")):(i=t(o))?i.call(o,n.resolve,n.reject):n.resolve(o))}catch(e){n.reject(e)}}function i(r){var o,s=this;if(!s.triggered){s.triggered=!0,s.def&&(s=s.def);try{(o=t(r))?e(function(){var e=new l(s);try{o.call(r,function(){i.apply(e,arguments)},function(){a.apply(e,arguments)})}catch(t){a.call(e,t)}}):(s.msg=r,s.state=1,s.chain.length>0&&e(n,s))}catch(e){a.call(new l(s),e)}}}function a(t){var r=this;r.triggered||(r.triggered=!0,r.def&&(r=r.def),r.msg=t,r.state=2,r.chain.length>0&&e(n,r))}function s(e,t,r,n){for(var o=0;o<t.length;o++)!function(o){e.resolve(t[o]).then(function(e){r(o,e)},n)}(o)}function l(e){this.def=e,this.triggered=!1}function u(e){this.promise=e,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function f(t){if("function"!=typeof t)throw TypeError("Not a function");if(0!==this.__NPO__)throw TypeError("Not a promise");this.__NPO__=1;var r=new u(this);this.then=function(t,o){var i={success:"function"!=typeof t||t,failure:"function"==typeof o&&o};return i.promise=new this.constructor(function(e,t){if("function"!=typeof e||"function"!=typeof t)throw TypeError("Not a function");i.resolve=e,i.reject=t}),r.chain.push(i),0!==r.state&&e(n,r),i.promise},this.catch=function(e){return this.then(void 0,e)};try{t.call(void 0,function(e){i.call(r,e)},function(e){a.call(r,e)})}catch(e){a.call(r,e)}}var d,p,m,h=Object.prototype.toString,y="undefined"!=typeof r?function(e){return r(e)}:setTimeout;try{Object.defineProperty({},"x",{}),d=function(e,t,r,n){return Object.defineProperty(e,t,{value:r,writable:!0,configurable:n!==!1})}}catch(e){d=function(e,t,r){return e[t]=r,e}}m=function(){function e(e,t){this.fn=e,this.self=t,this.next=void 0}var t,r,n;return{add:function(o,i){n=new e(o,i),r?r.next=n:t=n,r=n,n=void 0},drain:function(){var e=t;for(t=r=p=void 0;e;)e.fn.call(e.self),e=e.next}}}();var v=d({},"constructor",f,!1);return f.prototype=v,d(v,"__NPO__",0,!1),d(f,"resolve",function(e){var t=this;return e&&"object"==("undefined"==typeof e?"undefined":c(e))&&1===e.__NPO__?e:new t(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");t(e)})}),d(f,"reject",function(e){return new this(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");r(e)})}),d(f,"all",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):0===e.length?t.resolve([]):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");var o=e.length,i=Array(o),a=0;s(t,e,function(e,t){i[e]=t,++a===o&&r(i)},n)})}),d(f,"race",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");s(t,e,function(e,t){r(t)},n)})}),f})}).call(this,"undefined"!=typeof t?t:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],4:[function(e,t,r){(function(e){function t(e,t){for(var r=0,n=e.length-1;n>=0;n--){var o=e[n];"."===o?e.splice(n,1):".."===o?(e.splice(n,1),r++):r&&(e.splice(n,1),r--)}if(t)for(;r--;r)e.unshift("..");return e}function n(e,t){if(e.filter)return e.filter(t);for(var r=[],n=0;n<e.length;n++)t(e[n],n,e)&&r.push(e[n]);return r}var o=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,i=function(e){return o.exec(e).slice(1)};r.resolve=function(){for(var r="",o=!1,i=arguments.length-1;i>=-1&&!o;i--){var a=i>=0?arguments[i]:e.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(r=a+"/"+r,o="/"===a.charAt(0))}return r=t(n(r.split("/"),function(e){return!!e}),!o).join("/"),(o?"/":"")+r||"."},r.normalize=function(e){var o=r.isAbsolute(e),i="/"===a(e,-1);return e=t(n(e.split("/"),function(e){return!!e}),!o).join("/"),e||o||(e="."),e&&i&&(e+="/"),(o?"/":"")+e},r.isAbsolute=function(e){return"/"===e.charAt(0)},r.join=function(){var e=Array.prototype.slice.call(arguments,0);return r.normalize(n(e,function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e}).join("/"))},r.relative=function(e,t){function n(e){for(var t=0;t<e.length&&""===e[t];t++);for(var r=e.length-1;r>=0&&""===e[r];r--);return t>r?[]:e.slice(t,r-t+1)}e=r.resolve(e).substr(1),t=r.resolve(t).substr(1);for(var o=n(e.split("/")),i=n(t.split("/")),a=Math.min(o.length,i.length),s=a,l=0;l<a;l++)if(o[l]!==i[l]){s=l;break}for(var c=[],l=s;l<o.length;l++)c.push("..");return c=c.concat(i.slice(s)),c.join("/")},r.sep="/",r.delimiter=":",r.dirname=function(e){var t=i(e),r=t[0],n=t[1];return r||n?(n&&(n=n.substr(0,n.length-1)),r+n):"."},r.basename=function(e,t){var r=i(e)[2];return t&&r.substr(-1*t.length)===t&&(r=r.substr(0,r.length-t.length)),r},r.extname=function(e){return i(e)[3]};var a="b"==="ab".substr(-1)?function(e,t,r){return e.substr(t,r)}:function(e,t,r){return t<0&&(t=e.length+t),e.substr(t,r)}}).call(this,e("_process"))},{_process:8}],5:[function(e,t,r){"use strict";function n(e){return"undefined"!=typeof e&&(e=e.indexOf("://")===-1?"":e.split("://")[0]),e}function o(e){var t=n(e),r=i[t];if("undefined"==typeof r){if(""!==t)throw new Error("Unsupported scheme: "+t);r=a}return r}var i={file:e("./lib/loaders/file"),http:e("./lib/loaders/http"),https:e("./lib/loaders/http")},a="object"===("undefined"==typeof window?"undefined":c(window))||"function"==typeof importScripts?i.http:i.file;"undefined"==typeof Promise&&e("native-promise-only"),t.exports.load=function(e,t){var r=Promise.resolve();return"undefined"==typeof t&&(t={}),r=r.then(function(){if("undefined"==typeof e)throw new TypeError("location is required");if("string"!=typeof e)throw new TypeError("location must be a string");if("undefined"!=typeof t){if("object"!==("undefined"==typeof t?"undefined":c(t)))throw new TypeError("options must be an object");if("undefined"!=typeof t.processContent&&"function"!=typeof t.processContent)throw new TypeError("options.processContent must be a function")}}),r=r.then(function(){return new Promise(function(r,n){var i=o(e);i.load(e,t||{},function(e,t){e?n(e):r(t)})})}).then(function(e){return t.processContent?new Promise(function(r,n){t.processContent("object"===("undefined"==typeof e?"undefined":c(e))?e:{text:e},function(e,t){e?n(e):r(t)})}):"object"===("undefined"==typeof e?"undefined":c(e))?e.text:e})}},{"./lib/loaders/file":6,"./lib/loaders/http":7,"native-promise-only":3}],6:[function(e,t,r){"use strict";var n=new TypeError("The 'file' scheme is not supported in the browser");t.exports.getBase=function(){throw n},t.exports.load=function(){var e=arguments[arguments.length-1];if("function"!=typeof e)throw n;e(n)}},{}],7:[function(e,t,r){"use strict";var n=e("superagent"),o=["delete","get","head","patch","post","put"];t.exports.load=function(e,t,r){function i(e,t){e?r(e):("function"==typeof t.buffer&&t.buffer(!0),t.end(function(e,t){e?r(e):r(void 0,t)}))}var a,s,l=t.method?t.method.toLowerCase():"get";if("undefined"!=typeof t.method?"string"!=typeof t.method?a=new TypeError("options.method must be a string"):o.indexOf(t.method)===-1&&(a=new TypeError("options.method must be one of the following: "+o.slice(0,o.length-1).join(", ")+" or "+o[o.length-1])):"undefined"!=typeof t.prepareRequest&&"function"!=typeof t.prepareRequest&&(a=new TypeError("options.prepareRequest must be a function")),a)r(a);else if(s=n["delete"===l?"del":l](e),t.prepareRequest)try{t.prepareRequest(s,i)}catch(e){r(e)}else i(void 0,s)}},{superagent:14}],8:[function(e,t,r){function n(){u=!1,s.length?c=s.concat(c):f=-1,c.length&&o()}function o(){if(!u){var e=setTimeout(n);u=!0;for(var t=c.length;t;){for(s=c,c=[];++f<t;)s&&s[f].run();f=-1,t=c.length}s=null,u=!1,clearTimeout(e)}}function i(e,t){this.fun=e,this.array=t}function a(){}var s,l=t.exports={},c=[],u=!1,f=-1;l.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];c.push(new i(e,t)),1!==c.length||u||setTimeout(o,0)},i.prototype.run=function(){this.fun.apply(null,this.array)},l.title="browser",l.browser=!0,l.env={},l.argv=[],l.version="",l.versions={},l.on=a,l.addListener=a,l.once=a,l.off=a,l.removeListener=a,l.removeAllListeners=a,l.emit=a,l.binding=function(e){throw new Error("process.binding is not supported")},l.cwd=function(){return"/"},l.chdir=function(e){throw new Error("process.chdir is not supported")},l.umask=function(){return 0}},{}],9:[function(e,t,r){"use strict";function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.exports=function(e,t,r,i){t=t||"&",r=r||"=";var a={};if("string"!=typeof e||0===e.length)return a;var s=/\+/g;e=e.split(t);var l=1e3;i&&"number"==typeof i.maxKeys&&(l=i.maxKeys);var c=e.length;l>0&&c>l&&(c=l);for(var u=0;u<c;++u){var f,d,p,m,h=e[u].replace(s,"%20"),y=h.indexOf(r);y>=0?(f=h.substr(0,y),d=h.substr(y+1)):(f=h,d=""),p=decodeURIComponent(f),m=decodeURIComponent(d),n(a,p)?o(a[p])?a[p].push(m):a[p]=[a[p],m]:a[p]=m}return a};var o=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},{}],10:[function(e,t,r){"use strict";function n(e,t){if(e.map)return e.map(t);for(var r=[],n=0;n<e.length;n++)r.push(t(e[n],n));return r}var o=function(e){switch("undefined"==typeof e?"undefined":c(e)){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};t.exports=function(e,t,r,s){return t=t||"&",r=r||"=",null===e&&(e=void 0),"object"===("undefined"==typeof e?"undefined":c(e))?n(a(e),function(a){var s=encodeURIComponent(o(a))+r;return i(e[a])?n(e[a],function(e){return s+encodeURIComponent(o(e))}).join(t):s+encodeURIComponent(o(e[a]))}).join(t):s?encodeURIComponent(o(s))+r+encodeURIComponent(o(e)):""};var i=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},a=Object.keys||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t}},{}],11:[function(e,t,r){"use strict";r.decode=r.parse=e("./decode"),r.encode=r.stringify=e("./encode")},{"./decode":9,"./encode":10}],12:[function(e,t,r){t.exports=function(e,t,r){for(var n=0,o=e.length,i=3==arguments.length?r:e[n++];n<o;)i=t.call(null,i,e[n],++n,e);return i}},{}],13:[function(e,t,r){"use strict";t.exports=function(e){var t=/^\\\\\?\\/.test(e),r=/[^\x00-\x80]+/.test(e);return t||r?e:e.replace(/\\/g,"/")}},{}],14:[function(e,t,r){function n(){}function o(e){var t={}.toString.call(e);switch(t){case"[object File]":case"[object Blob]":case"[object FormData]":return!0;default:return!1}}function i(e){if(!b(e))return e;var t=[];for(var r in e)null!=e[r]&&a(t,r,e[r]);return t.join("&")}function a(e,t,r){return Array.isArray(r)?r.forEach(function(r){a(e,t,r)}):void e.push(encodeURIComponent(t)+"="+encodeURIComponent(r))}function s(e){for(var t,r,n={},o=e.split("&"),i=0,a=o.length;i<a;++i)r=o[i],t=r.split("="),n[decodeURIComponent(t[0])]=decodeURIComponent(t[1]);return n}function l(e){var t,r,n,o,i=e.split(/\r?\n/),a={};i.pop();for(var s=0,l=i.length;s<l;++s)r=i[s],t=r.indexOf(":"),n=r.slice(0,t).toLowerCase(),o=w(r.slice(t+1)),a[n]=o;return a}function c(e){return/[\/+]json\b/.test(e)}function u(e){return e.split(/ *; */).shift()}function f(e){return v(e.split(/ *; */),function(e,t){var r=t.split(/ *= */),n=r.shift(),o=r.shift();return n&&o&&(e[n]=o),e},{})}function d(e,t){t=t||{},this.req=e,this.xhr=this.req.xhr,this.text="HEAD"!=this.req.method&&(""===this.xhr.responseType||"text"===this.xhr.responseType)||"undefined"==typeof this.xhr.responseType?this.xhr.responseText:null,this.statusText=this.req.xhr.statusText,this.setStatusProperties(this.xhr.status),this.header=this.headers=l(this.xhr.getAllResponseHeaders()),this.header["content-type"]=this.xhr.getResponseHeader("content-type"),this.setHeaderProperties(this.header),this.body="HEAD"!=this.req.method?this.parseBody(this.text?this.text:this.xhr.response):null}function p(e,t){var r=this;this._query=this._query||[],this.method=e,this.url=t,this.header={},this._header={},this.on("end",function(){var e=null,t=null;try{t=new d(r)}catch(t){return e=new Error("Parser is unable to parse the response"),e.parse=!0,e.original=t,e.rawResponse=r.xhr&&r.xhr.responseText?r.xhr.responseText:null,e.statusCode=r.xhr&&r.xhr.status?r.xhr.status:null,r.callback(e)}if(r.emit("response",t),e)return r.callback(e,t);if(t.status>=200&&t.status<300)return r.callback(e,t);var n=new Error(t.statusText||"Unsuccessful HTTP response");n.original=e,n.response=t,n.status=t.status,r.callback(n,t)})}function m(e,t){var r=x("DELETE",e);return t&&r.end(t),r}var h,y=e("emitter"),v=e("reduce"),g=e("./request-base"),b=e("./is-object");h="undefined"!=typeof window?window:"undefined"!=typeof self?self:this;var x=t.exports=e("./request").bind(null,p);x.getXHR=function(){if(!(!h.XMLHttpRequest||h.location&&"file:"==h.location.protocol&&h.ActiveXObject))return new XMLHttpRequest;try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(e){}return!1};var w="".trim?function(e){return e.trim()}:function(e){return e.replace(/(^\s*|\s*$)/g,"")};x.serializeObject=i,x.parseString=s,x.types={html:"text/html",json:"application/json",xml:"application/xml",urlencoded:"application/x-www-form-urlencoded",form:"application/x-www-form-urlencoded","form-data":"application/x-www-form-urlencoded"},x.serialize={"application/x-www-form-urlencoded":i,"application/json":JSON.stringify},x.parse={"application/x-www-form-urlencoded":s,"application/json":JSON.parse},d.prototype.get=function(e){return this.header[e.toLowerCase()]},d.prototype.setHeaderProperties=function(e){var t=this.header["content-type"]||"";this.type=u(t);var r=f(t);for(var n in r)this[n]=r[n]},d.prototype.parseBody=function(e){var t=x.parse[this.type];return!t&&c(this.type)&&(t=x.parse["application/json"]),t&&e&&(e.length||e instanceof Object)?t(e):null},d.prototype.setStatusProperties=function(e){1223===e&&(e=204);var t=e/100|0;this.status=this.statusCode=e,this.statusType=t,this.info=1==t,this.ok=2==t,this.clientError=4==t,this.serverError=5==t,this.error=(4==t||5==t)&&this.toError(),this.accepted=202==e,this.noContent=204==e,this.badRequest=400==e,this.unauthorized=401==e,this.notAcceptable=406==e,this.notFound=404==e,this.forbidden=403==e},d.prototype.toError=function(){var e=this.req,t=e.method,r=e.url,n="cannot "+t+" "+r+" ("+this.status+")",o=new Error(n);return o.status=this.status,o.method=t,o.url=r,o},x.Response=d,y(p.prototype);for(var E in g)p.prototype[E]=g[E];p.prototype.abort=function(){if(!this.aborted)return this.aborted=!0,this.xhr.abort(),this.clearTimeout(),this.emit("abort"),this},p.prototype.type=function(e){return this.set("Content-Type",x.types[e]||e),this},p.prototype.responseType=function(e){return this._responseType=e,this},p.prototype.accept=function(e){return this.set("Accept",x.types[e]||e),this},p.prototype.auth=function(e,t,r){switch(r||(r={type:"basic"}),r.type){case"basic":var n=btoa(e+":"+t);this.set("Authorization","Basic "+n);break;case"auto":this.username=e,this.password=t}return this},p.prototype.query=function(e){return"string"!=typeof e&&(e=i(e)),e&&this._query.push(e),this},p.prototype.attach=function(e,t,r){return this._getFormData().append(e,t,r||t.name),this},p.prototype._getFormData=function(){return this._formData||(this._formData=new h.FormData),this._formData},p.prototype.send=function(e){var t=b(e),r=this._header["content-type"];if(t&&b(this._data))for(var n in e)this._data[n]=e[n];else"string"==typeof e?(r||this.type("form"),r=this._header["content-type"],"application/x-www-form-urlencoded"==r?this._data=this._data?this._data+"&"+e:e:this._data=(this._data||"")+e):this._data=e;return!t||o(e)?this:(r||this.type("json"),this)},d.prototype.parse=function(e){return h.console&&console.warn("Client-side parse() method has been renamed to serialize(). This method is not compatible with superagent v2.0"),this.serialize(e),this},d.prototype.serialize=function(e){return this._parser=e,this},p.prototype.callback=function(e,t){var r=this._callback;this.clearTimeout(),r(e,t)},p.prototype.crossDomainError=function(){var e=new Error("Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.");e.crossDomain=!0,e.status=this.status,e.method=this.method,e.url=this.url,this.callback(e)},p.prototype.timeoutError=function(){var e=this._timeout,t=new Error("timeout of "+e+"ms exceeded");t.timeout=e,this.callback(t)},p.prototype.withCredentials=function(){return this._withCredentials=!0,this},p.prototype.end=function(e){var t=this,r=this.xhr=x.getXHR(),i=this._query.join("&"),a=this._timeout,s=this._formData||this._data;this._callback=e||n,r.onreadystatechange=function(){if(4==r.readyState){var e;try{e=r.status}catch(t){e=0}if(0==e){if(t.timedout)return t.timeoutError();if(t.aborted)return;return t.crossDomainError()}t.emit("end")}};var l=function(e){e.total>0&&(e.percent=e.loaded/e.total*100),e.direction="download",t.emit("progress",e)};this.hasListeners("progress")&&(r.onprogress=l);try{r.upload&&this.hasListeners("progress")&&(r.upload.onprogress=l)}catch(e){}if(a&&!this._timer&&(this._timer=setTimeout(function(){t.timedout=!0,t.abort()},a)),i&&(i=x.serializeObject(i),this.url+=~this.url.indexOf("?")?"&"+i:"?"+i),this.username&&this.password?r.open(this.method,this.url,!0,this.username,this.password):r.open(this.method,this.url,!0),this._withCredentials&&(r.withCredentials=!0),"GET"!=this.method&&"HEAD"!=this.method&&"string"!=typeof s&&!o(s)){var u=this._header["content-type"],f=this._parser||x.serialize[u?u.split(";")[0]:""];!f&&c(u)&&(f=x.serialize["application/json"]),f&&(s=f(s))}for(var d in this.header)null!=this.header[d]&&r.setRequestHeader(d,this.header[d]);return this._responseType&&(r.responseType=this._responseType),this.emit("request",this),r.send("undefined"!=typeof s?s:null),this},x.Request=p,x.get=function(e,t,r){var n=x("GET",e);return"function"==typeof t&&(r=t,t=null),t&&n.query(t),r&&n.end(r),n},x.head=function(e,t,r){var n=x("HEAD",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.del=m,x.delete=m,x.patch=function(e,t,r){var n=x("PATCH",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.post=function(e,t,r){var n=x("POST",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.put=function(e,t,r){var n=x("PUT",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n}},{"./is-object":15,"./request":17,"./request-base":16,emitter:2,reduce:12}],15:[function(e,t,r){function n(e){return null!=e&&"object"==("undefined"==typeof e?"undefined":c(e))}t.exports=n},{}],16:[function(e,t,r){var n=e("./is-object");r.clearTimeout=function(){return this._timeout=0,clearTimeout(this._timer),this},r.parse=function(e){return this._parser=e,this},r.timeout=function(e){return this._timeout=e,this},r.then=function(e,t){return this.end(function(r,n){r?t(r):e(n)})},r.use=function(e){return e(this),this},r.get=function(e){return this._header[e.toLowerCase()]},r.getHeader=r.get,r.set=function(e,t){if(n(e)){for(var r in e)this.set(r,e[r]);return this}return this._header[e.toLowerCase()]=t,this.header[e]=t,this},r.unset=function(e){return delete this._header[e.toLowerCase()],delete this.header[e],this},r.field=function(e,t){return this._getFormData().append(e,t),this}},{"./is-object":15}],17:[function(e,t,r){function n(e,t,r){return"function"==typeof r?new e("GET",t).end(r):2==arguments.length?new e("GET",t):new e(t,r)}t.exports=n},{}],18:[function(e,t,r){/*! https://mths.be/punycode v1.3.2 by @mathias, modified for URI.js */var n=function(){function e(e){throw new RangeError(k[e])}function t(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function r(e,r){var n=e.split("@"),o="";n.length>1&&(o=n[0]+"@",e=n[1]),e=e.replace(C,".");var i=e.split("."),a=t(i,r).join(".");return o+a}function n(e){for(var t,r,n=[],o=0,i=e.length;o<i;)t=e.charCodeAt(o++),t>=55296&&t<=56319&&o<i?(r=e.charCodeAt(o++),56320==(64512&r)?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),o--)):n.push(t);return n}function o(e){return t(e,function(e){var t="";return e>65535&&(e-=65536,t+=A(e>>>10&1023|55296),e=56320|1023&e),t+=A(e)}).join("")}function i(e){return e-48<10?e-22:e-65<26?e-65:e-97<26?e-97:m}function a(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function s(e,t,r){var n=0;for(e=r?T(e/g):e>>1,e+=T(e/t);e>O*y>>1;n+=m)e=T(e/O);return T(n+(O+1)*e/(e+v))}function l(t){var r,n,a,l,c,u,f,d,v,g,E=[],$=t.length,C=0,k=x,O=b;for(n=t.lastIndexOf(w),n<0&&(n=0),a=0;a<n;++a)t.charCodeAt(a)>=128&&e("not-basic"),E.push(t.charCodeAt(a));for(l=n>0?n+1:0;l<$;){for(c=C,u=1,f=m;l>=$&&e("invalid-input"),d=i(t.charCodeAt(l++)),(d>=m||d>T((p-C)/u))&&e("overflow"),C+=d*u,v=f<=O?h:f>=O+y?y:f-O,!(d<v);f+=m)g=m-v,u>T(p/g)&&e("overflow"),u*=g;r=E.length+1,O=s(C-c,r,0==c),T(C/r)>p-k&&e("overflow"),k+=T(C/r),C%=r,E.splice(C++,0,k)}return o(E)}function c(t){var r,o,i,l,c,u,f,d,v,g,E,$,C,k,O,S=[];for(t=n(t),$=t.length,r=x,o=0,c=b,u=0;u<$;++u)E=t[u],E<128&&S.push(A(E));for(i=l=S.length,l&&S.push(w);i<$;){for(f=p,u=0;u<$;++u)E=t[u],E>=r&&E<f&&(f=E);for(C=i+1,f-r>T((p-o)/C)&&e("overflow"),o+=(f-r)*C,r=f,u=0;u<$;++u)if(E=t[u],E<r&&++o>p&&e("overflow"),E==r){for(d=o,v=m;g=v<=c?h:v>=c+y?y:v-c,!(d<g);v+=m)O=d-g,k=m-g,S.push(A(a(g+O%k,0))),d=T(O/k);S.push(A(a(d,0))),c=s(o,C,i==l),o=0,++i}++o,++r}return S.join("")}function u(e){return r(e,function(e){return E.test(e)?l(e.slice(4).toLowerCase()):e})}function f(e){return r(e,function(e){return $.test(e)?"xn--"+c(e):e})}var d,p=2147483647,m=36,h=1,y=26,v=38,g=700,b=72,x=128,w="-",E=/^xn--/,$=/[^\x20-\x7E]/,C=/[\x2E\u3002\uFF0E\uFF61]/g,k={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},O=m-h,T=Math.floor,A=String.fromCharCode;return d={version:"1.3.2",ucs2:{decode:n,encode:o},decode:l,encode:c,toASCII:f,toUnicode:u}}();"undefined"==typeof COMPILED&&"undefined"!=typeof t&&(t.exports=n)},{}],19:[function(e,t,r){e("./schemes/http"),e("./schemes/urn"),e("./schemes/mailto")},{"./schemes/http":20,"./schemes/mailto":21,"./schemes/urn":22}],20:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");n.SCHEMES.http=n.SCHEMES.https={domainHost:!0,parse:function(e,t){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e},serialize:function(e,t){return e.port!==("https"!==String(e.scheme).toLowerCase()?80:443)&&""!==e.port||(e.port=void 0),e.path||(e.path="/"),e}}},{"../uri":23}],21:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri"),o=e("../punycode");!function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(e){return e.toUpperCase()}function i(e){var t=n.pctDecChars(e);return t.match(M)?t:e}function a(e){return void 0!==e&&null!==e?e instanceof Array&&!e.callee?e:"number"!=typeof e.length||e.split||e.setInterval||e.call?[e]:Array.prototype.slice.call(e):[]}var s={},l=n.IRI_SUPPORT,c="[A-Za-z0-9\\-\\.\\_\\~"+(l?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",u="[0-9A-Fa-f]",f=t(t("%[EFef]"+u+"%"+u+u+"%"+u+u)+"|"+t("%[89A-Fa-f]"+u+"%"+u+u)+"|"+t("%"+u+u)),d="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",p="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",m=e(p,'[\\"\\\\]'),h=t(d+"+"+t("\\."+d+"+")+"*"),y=t("\\\\"+m),v=t(p+"|"+y),g=t('\\"'+v+'*\\"'),b="[\\x21-\\x5A\\x5E-\\x7E]",x="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",w=t(c+"|"+f+"|"+x),E=t(h+"|\\["+b+"*\\]"),$=t(h+"|"+g),C=t($+"\\@"+E),k=t(C+t("\\,"+C)+"*"),O=t(w+"*"),T=O,A=t(O+"\\="+T),S=t(A+t("\\&"+A)+"*"),P=t("\\?"+S),M=(n.VALIDATE_SUPPORT&&new RegExp("^mailto\\:"+k+"?"+P+"?$"),new RegExp(c,"g")),j=new RegExp(f,"g"),I=new RegExp(e("[^]",d,"[\\.]",'[\\"]',m),"g"),D=new RegExp(e("[^]",d,"[\\.]","[\\[]",b,"[\\]]"),"g"),_=new RegExp(e("[^]",c,x),"g"),F=_,R=n.VALIDATE_SUPPORT&&new RegExp("^"+k+"$"),q=n.VALIDATE_SUPPORT&&new RegExp("^"+S+"$");n.SCHEMES.mailto={parse:function(e,t){n.VALIDATE_SUPPORT&&!e.error&&(e.path&&!R.test(e.path)?e.error="Email address is not valid":e.query&&!q.test(e.query)&&(e.error="Header fields are invalid"));var r=e.to=e.path?e.path.split(","):[];if(e.path=void 0,e.query){for(var i=!1,a={},s=e.query.split("&"),l=0,c=s.length;l<c;++l){var u=s[l].split("=");switch(u[0]){case"to":for(var f=u[1].split(","),d=0,p=f.length;d<p;++d)r.push(f[d]);break;case"subject":e.subject=n.unescapeComponent(u[1],t);break;case"body":e.body=n.unescapeComponent(u[1],t);break;default:i=!0,a[n.unescapeComponent(u[0],t)]=n.unescapeComponent(u[1],t)}}i&&(e.headers=a)}e.query=void 0;for(var l=0,c=r.length;l<c;++l){var m=r[l].split("@");if(m[0]=n.unescapeComponent(m[0]),"undefined"==typeof o||t.unicodeSupport)m[1]=n.unescapeComponent(m[1],t).toLowerCase();else try{m[1]=o.toASCII(n.unescapeComponent(m[1],t).toLowerCase())}catch(t){e.error=e.error||"Email address's domain name can not be converted to ASCII via punycode: "+t}r[l]=m.join("@")}return e},serialize:function(e,t){var l=a(e.to);if(l){for(var c=0,u=l.length;c<u;++c){var f=String(l[c]),d=f.lastIndexOf("@"),p=f.slice(0,d),m=f.slice(d+1);if(p=p.replace(j,i).replace(j,r).replace(I,n.pctEncChar),"undefined"!=typeof o)try{m=t.iri?o.toUnicode(m):o.toASCII(n.unescapeComponent(m,t).toLowerCase())}catch(r){e.error=e.error||"Email address's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}else m=m.replace(j,i).toLowerCase().replace(j,r).replace(D,n.pctEncChar);l[c]=p+"@"+m}e.path=l.join(",")}var h=e.headers=e.headers||{};e.subject&&(h.subject=e.subject),e.body&&(h.body=e.body);var y=[];for(var v in h)h[v]!==s[v]&&y.push(v.replace(j,i).replace(j,r).replace(_,n.pctEncChar)+"="+h[v].replace(j,i).replace(j,r).replace(F,n.pctEncChar));return y.length&&(e.query=y.join("&")),e}}}()},{"../punycode":18,"../uri":23}],22:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");!function(){var e=n.pctEncChar,t="(?:[0-9A-Za-z][0-9A-Za-z\\-]{1,31})",r="(?:\\%[0-9A-Fa-f]{2})",o="[0-9A-Za-z\\(\\)\\+\\,\\-\\.\\:\\=\\@\\;\\$\\_\\!\\*\\'\\/\\?\\#]",i="(?:(?:"+r+"|"+o+")+)",a=new RegExp("^urn\\:("+t+")$"),s=new RegExp("^("+t+")\\:("+i+")$"),l=/^([^\:]+)\:(.*)/,c=/[\x00-\x20\\\"\&\<\>\[\]\^\`\{\|\}\~\x7F-\xFF]/g,u=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/;n.SCHEMES.urn={parse:function(e,t){var r,o,i=e.path.match(s);return i||(t.tolerant||(e.error=e.error||"URN is not strictly valid."),i=e.path.match(l)),i?(r="urn:"+i[1].toLowerCase(),o=n.SCHEMES[r],o||(o=n.SCHEMES[r]={parse:function(e,t){return e},serialize:n.SCHEMES.urn.serialize}),e.scheme=r,e.path=i[2],e=o.parse(e,t)):e.error=e.error||"URN can not be parsed.",e},serialize:function(t,r){var n,o=t.scheme||r.scheme;if(o&&"urn"!==o){var n=o.match(a);n||(n=["urn:"+o,o]),t.scheme="urn",t.path=n[1]+":"+(t.path?t.path.replace(c,e):"")}return t}},n.SCHEMES["urn:uuid"]={parse:function(e,t){return t.tolerant||e.path&&e.path.match(u)||(e.error=e.error||"UUID is not valid."),e},serialize:function(e,t){return t.tolerant||e.path&&e.path.match(u)?e.path=(e.path||"").toLowerCase():e.scheme=void 0,n.SCHEMES.urn.serialize(e,t)}}}()},{"../uri":23}],23:[function(e,t,r){/**
  * URI.js
  *
  * @fileoverview An RFC 3986 compliant, scheme extendable URI parsing/validating/resolving library for JavaScript.
@@ -35,5 +35,5 @@ e.exports=function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,
  * @see http://github.com/garycourt/uri-js
  * @license URI.js v2.0.0 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js
  */
-var n=!1,o=!0,i=!0,a=function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(r){var n="[A-Za-z]",o="[0-9]",a=e(o,"[A-Fa-f]"),s=t(t("%[EFef]"+a+"%"+a+a+"%"+a+a)+"|"+t("%[89A-Fa-f]"+a+"%"+a+a)+"|"+t("%"+a+a)),l="[\\:\\/\\?\\#\\[\\]\\@]",c="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",u=e(l,c),f=r?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",d=r?"[\\uE000-\\uF8FF]":"[]",p=e(n,o,"[\\-\\.\\_\\~]",f),m=t(n+e(n,o,"[\\+\\-\\.]")+"*"),h=t(t(s+"|"+e(p,c,"[\\:]"))+"*"),v=t(t("25[0-5]")+"|"+t("2[0-4]"+o)+"|"+t("1"+o+o)+"|"+t("[1-9]"+o)+"|"+o),y=t(v+"\\."+v+"\\."+v+"\\."+v),g=t(a+"{1,4}"),b=(t(t(g+"\\:"+g)+"|"+y),t(e(p,c,"[\\:]")+"+")),x=t("v"+a+"+\\."+e(p,c,"[\\:]")+"+"),w=t("\\["+t(b+"|"+x)+"\\]"),E=t(t(s+"|"+e(p,c))+"*"),$=t(w+"|"+y+"(?!"+E+")|"+E),C=t(o+"*"),k=t(t(h+"@")+"?"+$+t("\\:"+C)+"?"),O=t(s+"|"+e(p,c,"[\\:\\@]")),T=t(O+"*"),A=t(O+"+"),S=t(t(s+"|"+e(p,c,"[\\@]"))+"+"),P=t(t("\\/"+T)+"*"),M=t("\\/"+t(A+P)+"?"),j=t(S+P),D=t(A+P),I="(?!"+O+")",_=(t(P+"|"+M+"|"+j+"|"+D+"|"+I),t(t(O+"|"+e("[\\/\\?]",d))+"*")),F=t(t(O+"|[\\/\\?]")+"*"),R=t(t("\\/\\/"+k+P)+"|"+M+"|"+D+"|"+I),q=t(m+"\\:"+R+t("\\?"+_)+"?"+t("\\#"+F)+"?"),U=t(t("\\/\\/"+k+P)+"|"+M+"|"+j+"|"+I),N=t(U+t("\\?"+_)+"?"+t("\\#"+F)+"?"),L=(t(q+"|"+N),t(m+"\\:"+R+t("\\?"+_)+"?"),"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+D+"|"+I+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$"),H="^(){0}"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+j+"|"+I+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$";"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+D+"|"+I+")")+t("\\?("+_+")")+"?$","^"+t("\\#("+F+")")+"?$","^"+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?$";return{URI_REF:i&&new RegExp("("+L+")|("+H+")"),NOT_SCHEME:new RegExp(e("[^]",n,o,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(e("[^\\%\\:]",p,c),"g"),NOT_HOST:new RegExp(e("[^\\%]",p,c),"g"),NOT_PATH:new RegExp(e("[^\\%\\/\\:\\@]",p,c),"g"),NOT_PATH_NOSCHEME:new RegExp(e("[^\\%\\/\\@]",p,c),"g"),NOT_QUERY:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]",d),"g"),NOT_FRAGMENT:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(e("[^]",p,c),"g"),UNRESERVED:new RegExp(p,"g"),OTHER_CHARS:new RegExp(e("[^\\%]",p,u),"g"),PCT_ENCODED:new RegExp(s,"g")}}function n(e){var t,r=e.charCodeAt(0);return t=r<16?"%0"+r.toString(16).toUpperCase():r<128?"%"+r.toString(16).toUpperCase():r<2048?"%"+(r>>6|192).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase():"%"+(r>>12|224).toString(16).toUpperCase()+"%"+(r>>6&63|128).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase()}function a(e){for(var t,r,n,o="",i=0,a=e.length;i<a;)t=parseInt(e.substr(i+1,2),16),t<128?(o+=String.fromCharCode(t),i+=3):t>=194&&t<224?(a-i>=6?(r=parseInt(e.substr(i+4,2),16),o+=String.fromCharCode((31&t)<<6|63&r)):o+=e.substr(i,6),i+=6):t>=224?(a-i>=9?(r=parseInt(e.substr(i+4,2),16),n=parseInt(e.substr(i+7,2),16),o+=String.fromCharCode((15&t)<<12|(63&r)<<6|63&n)):o+=e.substr(i,9),i+=9):(o+=e.substr(i,3),i+=3);return o}function l(e){return void 0===e?"undefined":null===e?"null":Object.prototype.toString.call(e).split(" ").pop().split("]").shift().toLowerCase()}function c(e){return e.toUpperCase()}function u(e,t){function r(e){var r=a(e);return r.match(t.UNRESERVED)?r:e}return e.scheme&&(e.scheme=String(e.scheme).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_SCHEME,"")),void 0!==e.userinfo&&(e.userinfo=String(e.userinfo).replace(t.PCT_ENCODED,r).replace(t.NOT_USERINFO,n).replace(t.PCT_ENCODED,c)),void 0!==e.host&&(e.host=String(e.host).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_HOST,n).replace(t.PCT_ENCODED,c)),void 0!==e.path&&(e.path=String(e.path).replace(t.PCT_ENCODED,r).replace(e.scheme?t.NOT_PATH:t.NOT_PATH_NOSCHEME,n).replace(t.PCT_ENCODED,c)),void 0!==e.query&&(e.query=String(e.query).replace(t.PCT_ENCODED,r).replace(t.NOT_QUERY,n).replace(t.PCT_ENCODED,c)),void 0!==e.fragment&&(e.fragment=String(e.fragment).replace(t.PCT_ENCODED,r).replace(t.NOT_FRAGMENT,n).replace(t.PCT_ENCODED,c)),e}function f(e,t){void 0===t&&(t={});var r,n,l=o&&t.iri!==!1?E:w,c=!1,f={};if("suffix"===t.reference&&(e=(t.scheme?t.scheme+":":"")+"//"+e),i?(r=e.match(l.URI_REF),r&&(r=r[1]?r.slice(1,10):r.slice(10,19)),r||(c=!0,t.tolerant||(f.error=f.error||"URI is not strictly valid."),r=e.match($))):r=e.match($),r){if(A?(f.scheme=r[1],f.userinfo=r[3],f.host=r[4],f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=r[7],f.fragment=r[8],isNaN(f.port)&&(f.port=r[5])):(f.scheme=r[1]||void 0,f.userinfo=e.indexOf("@")!==-1?r[3]:void 0,f.host=e.indexOf("//")!==-1?r[4]:void 0,f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=e.indexOf("?")!==-1?r[7]:void 0,f.fragment=e.indexOf("#")!==-1?r[8]:void 0,isNaN(f.port)&&(f.port=e.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?r[4]:void 0)),void 0!==f.scheme||void 0!==f.userinfo||void 0!==f.host||void 0!==f.port||f.path||void 0!==f.query?void 0===f.scheme?f.reference="relative":void 0===f.fragment?f.reference="absolute":f.reference="uri":f.reference="same-document",t.reference&&"suffix"!==t.reference&&t.reference!==f.reference&&(f.error=f.error||"URI is not a "+t.reference+" reference."),n=S[(t.scheme||f.scheme||"").toLowerCase()],!o||"undefined"==typeof s||t.unicodeSupport||n&&n.unicodeSupport)u(f,l);else{if(f.host&&(t.domainHost||n&&n.domainHost))try{f.host=s.toASCII(f.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(e){f.error=f.error||"Host's domain name can not be converted to ASCII via punycode: "+e}u(f,w)}n&&n.parse&&n.parse(f,t)}else c=!0,f.error=f.error||"URI can not be parsed.";return f}function d(e,t){var r=[];return void 0!==e.userinfo&&(r.push(e.userinfo),r.push("@")),void 0!==e.host&&r.push(e.host),"number"==typeof e.port&&(r.push(":"),r.push(e.port.toString(10))),r.length?r.join(""):void 0}function p(e){for(var t,r=[];e.length;)e.match(C)?e=e.replace(C,""):e.match(k)?e=e.replace(k,"/"):e.match(O)?(e=e.replace(O,"/"),r.pop()):"."===e||".."===e?e="":(t=e.match(T)[0],e=e.slice(t.length),r.push(t));return r.join("")}function m(e,t){void 0===t&&(t={});var r,n,i,l=o&&t.iri?E:w,c=[];if(r=S[(t.scheme||e.scheme||"").toLowerCase()],r&&r.serialize&&r.serialize(e,t),o&&"undefined"!=typeof s&&e.host&&(t.domainHost||r&&r.domainHost))try{e.host=t.iri?s.toUnicode(e.host):s.toASCII(e.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(r){e.error=e.error||"Host's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}return u(e,l),"suffix"!==t.reference&&e.scheme&&(c.push(e.scheme),c.push(":")),n=d(e,t),void 0!==n&&("suffix"!==t.reference&&c.push("//"),c.push(n),e.path&&"/"!==e.path.charAt(0)&&c.push("/")),void 0!==e.path&&(i=e.path,t.absolutePath||r&&r.absolutePath||(i=p(i)),void 0===n&&(i=i.replace(/^\/\//,"/%2F")),c.push(i)),void 0!==e.query&&(c.push("?"),c.push(e.query)),void 0!==e.fragment&&(c.push("#"),c.push(e.fragment)),c.join("")}function h(e,t,r,n){void 0===r&&(r={});var o={};return n||(e=f(m(e,r),r),t=f(m(t,r),r)),r=r||{},!r.tolerant&&t.scheme?(o.scheme=t.scheme,o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(t.path?("/"===t.path.charAt(0)?o.path=p(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?o.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:o.path=t.path:o.path="/"+t.path,o.path=p(o.path)),o.query=t.query):(o.path=e.path,void 0!==t.query?o.query=t.query:o.query=e.query),o.userinfo=e.userinfo,o.host=e.host,o.port=e.port),o.scheme=e.scheme),o.fragment=t.fragment,o}function v(e,t,r){return m(h(f(e,r),f(t,r),r,!0),r)}function y(e,t){return"string"==typeof e?e=m(f(e,t),t):"object"===l(e)&&(e=f(m(e,t),t)),e}function g(e,t,r){return"string"==typeof e?e=m(f(e,r),r):"object"===l(e)&&(e=m(e,r)),"string"==typeof t?t=m(f(t,r),r):"object"===l(t)&&(t=m(t,r)),e===t}function b(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.ESCAPE:w.ESCAPE,n)}function x(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.PCT_ENCODED:w.PCT_ENCODED,a)}var w=r(!1),E=o?r(!0):void 0,$=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?([^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n)*))?/i,C=/^\.\.?\//,k=/^\/\.(\/|$)/,O=/^\/\.\.(\/|$)/,T=/^\/?(?:.|\n)*?(?=\/|$)/,A=void 0==="".match(/(){0}/)[1],S={};return{IRI_SUPPORT:o,VALIDATE_SUPPORT:i,pctEncChar:n,pctDecChars:a,SCHEMES:S,parse:f,_recomposeAuthority:d,removeDotSegments:p,serialize:m,resolveComponents:h,resolve:v,normalize:y,equal:g,escapeComponent:b,unescapeComponent:x}}();if(!n&&"undefined"!=typeof t&&"function"==typeof e){var s=e("./punycode");t.exports=a,e("./schemes")}},{"./punycode":18,"./schemes":19}]},{},[1])(1)})},function(e,t,r){"use strict";function n(e,t){var l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:r.i(i.createDefaults)(),c=arguments[3],u=arguments[4],f=arguments[5],d=arguments[6],p=[],m=[];t=t||[];var h=t.indexOf("*");u=u||{};var v={},y=t.indexOf("...");if("object"===("undefined"==typeof e?"undefined":s(e))&&e.hasOwnProperty("properties")){f=f||e.readonly||e.readOnly,v=r.i(i.defaultForm)(e,l,c,u);var g=v.lookup;e=g||e,p=p.concat(v.form)}return h!==-1&&(t=t.slice(0,h).concat(p).concat(t.slice(h+1))),v.form&&y!==-1&&!function(){var e=t.map(function(e){return"string"==typeof e?e:e.key?e.key:void 0}).filter(function(e){return void 0!==e});m=m.concat(v.form.map(function(t){var r=e.indexOf(t.key[0])!==-1;if(!r)return t}).filter(function(e){return void 0!==e}))}(),y!==-1&&(t=t.slice(0,y).concat(m).concat(t.slice(y+1))),t.map(function(t){if("string"==typeof t&&(t={key:t}),t.key&&"string"==typeof t.key&&(t.key=r.i(o.parse)(t.key)),t.titleMap&&(t.titleMap=r.i(a.a)(t.titleMap)),t.key){var i=r.i(o.stringify)(t.key);e[i]&&!function(){var r=e[i];r&&Object.keys(r).forEach(function(e){void 0===t[e]&&(t[e]=r[e])})}()}return f===!0&&(t.readonly=!0),t.items&&(t.items=n(e,t.items,l,c,u,t.readonly,d)),t.tabs&&t.tabs.forEach(function(r){r.items&&(r.items=n(e,r.items,l,c,u,t.readonly,d))}),"checkbox"===t.type&&(void 0===t.schema?t.schema={default:!1}:void 0===t.schema.default&&(t.schema.default=!1)),d&&"template"===t.type&&!t.template&&t.templateUrl&&d.push(t),t})}var o=r(0),i=r(3),a=r(1);t.a=n;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e}},function(e,t,r){"use strict";function n(e,t){var r=new Promise(function(t,r){o.resolveRefs(e,{filter:["relative","local","remote"]}).then(function(e){t(e.resolved)}).catch(function(e){r(new Error(e))})});return"function"!=typeof t?r:void r.then(function(e){t(null,e)}).catch(function(e){t(e)})}var o=r(5);r.n(o);t.a=n},function(e,t,r){"use strict";function n(e,t,r){t||(t=this);var n="string"==typeof e?o.parse(e):e;if("undefined"!=typeof r&&1===n.length)return t[n[0]]=r,t;"undefined"!=typeof r&&"undefined"==typeof t[n[0]]&&(t[n[0]]=n.length>2&&i.test(n[1])?[]:{});for(var a=t[n[0]],s=1;s<n.length;s++){if(""===n[s])return;if("undefined"!=typeof r){if(s===n.length-1)return a[n[s]]=r,r;var l=a[n[s]];"undefined"!=typeof l&&null!==l||(l=i.test(n[s+1])?[]:{},a[n[s]]=l),a=l}else a&&(a=a[n[s]])}return a}var o=r(0);t.a=n;var i=/^\d+$/},function(e,t,r){"use strict";function n(e,t,r,n){n=void 0===n||n,r=r||[];var o=function e(t,r,o){if(r(t,o),t.properties&&Object.keys(t.properties).forEach(function(n){var i=o.slice();i.push(n),e(t.properties[n],r,i)}),!n&&t.items){var i=o.slice();i.push(""),e(t.items,r,i)}};o(e,t,r||[])}function o(e,t){t(e),e.items&&e.items.forEach(function(e){o(e,t)}),e.tabs&&e.tabs.forEach(function(e){e.items&&e.items.forEach(function(e){o(e,t)})})}t.a=n,t.b=o},function(e,t,r){"use strict";function n(e,t){if(!e)return{valid:!0};var r=e.schema;if(!r)return{valid:!0};""===t&&(t=void 0),"number"===e.type&&null===t&&(t=void 0);var n={type:"object",properties:{},required:void 0},o=e.key[e.key.length-1];n.properties[o]=r,e.required&&(n.required=[o]);var a={};return t&&(a[o]=t),i.a.validateResult(a,n)}var o=r(12),i=r.n(o);t.a=n},function(e,t,r){"use strict";var n;!function(o){var i={parse:function(e){if("string"!=typeof e)throw new TypeError("ObjectPath.parse must be passed a string");for(var t,r,n,o,i=0,a=[];i<e.length;)if(t=e.indexOf(".",i),r=e.indexOf("[",i),t===-1&&r===-1)a.push(e.slice(i,e.length)),i=e.length;else if(r===-1||t!==-1&&t<r)a.push(e.slice(i,t)),i=t+1;else if(r>i&&(a.push(e.slice(i,r)),i=r),n=e.slice(r+1,r+2),'"'!==n&&"'"!==n)o=e.indexOf("]",r),o===-1&&(o=e.length),a.push(e.slice(i+1,o)),i="."===e.slice(o+1,o+2)?o+2:o+1;else{for(o=e.indexOf(n+"]",r),o===-1&&(o=e.length);"\\"===e.slice(o-1,o)&&r<e.length;)r++,o=e.indexOf(n+"]",r);a.push(e.slice(i+2,o).replace(new RegExp("\\"+n,"g"),n)),i="."===e.slice(o+2,o+3)?o+3:o+2}return a},stringify:function(e,t){return Array.isArray(e)||(e=[e.toString()]),t='"'===t?'"':"'",e.map(function(e){return"["+t+e.toString().replace(new RegExp(t,"g"),"\\"+t)+t+"]"}).join("")},normalize:function(e,t){return i.stringify(Array.isArray(e)?e:i.parse(e),t)},registerModule:function(e){e.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=i.parse,this.stringify=i.stringify,this.normalize=i.normalize,this.$get=function(){return i}})}};n=function(){return{ObjectPath:i}}.call(t,r,t,e),!(n!==o&&(e.exports=n))}()},function(e,t){e.exports=tv4},function(e,t,r){e.exports=r(4)}])}).call(t,r(2),r(19).setImmediate)},function(e,t){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(r=window)}e.exports=r},,function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(1),o=(r.n(n),r(0)),i=r.n(o),a=r(14),s=r(12),l=r(13),c=r(15),u=r(16),f=r(7),d=r(8),p=r(10),m=r(6),h=r(9),v=r(11),y=r(5),g=[];try{i.a.module("ngSanitize"),g.push("ngSanitize")}catch(e){}try{i.a.module("ui.sortable"),g.push("ui.sortable")}catch(e){}try{i.a.module("angularSpectrumColorpicker"),g.push("angularSpectrumColorpicker")}catch(e){}i.a.module("schemaForm",g).provider("sfPath",u.a).provider("sfBuilder",["sfPathProvider",a.a]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",s.a]).provider("sfErrorMessage",c.a).provider("schemaForm",["sfPathProvider",l.a]).factory("sfSelect",function(){return n.select}).factory("sfValidator",function(){return n.validate}).directive("sfChanged",f.a).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",d.a]).directive("sfMessage",["$injector","sfErrorMessage",p.a]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",m.a]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",v.a]).directive("schemaValidate",["sfValidator","$parse","sfSelect",y.a]).directive("sfKeyController",["schemaForm","sfPath",h.a])},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r){return{restrict:"A",scope:!1,priority:500,require:"ngModel",link:function(t,n,i,a){t.$emit("schemaFormPropagateNgModelController",a);var s=null,l=t.$eval(i.schemaValidate);l.copyValueTo&&a.$viewChangeListeners.push(function(){var e=l.copyValueTo;o.a.forEach(e,function(e){r(e,t.model,a.$modelValue)})});var c=function(r,n){if(!l)return r;if(t.options&&t.options.tv4Validation===!1)return r;var o=e(l,r);Object.keys(a.$error).filter(function(e){return 0===e.indexOf("tv4-")}).forEach(function(e){a.$setValidity(e,!0)});{if(o.valid||a.$pristine&&!n)return r;if(a.$setValidity("tv4-"+o.error.code,!1),s=o.error,a.$validators)return r}};"function"==typeof l.ngModel&&l.ngModel(a),["$parsers","$viewChangeListeners","$formatters"].forEach(function(e){l[e]&&a[e]&&l[e].forEach(function(t){a[e].push(t)})}),["$validators","$asyncValidators"].forEach(function(e){l[e]&&a[e]&&o.a.forEach(l[e],function(r,n){a[e][n]=function(e,n){return r(e,n,t.model,l)}})}),a.$parsers.push(c),a.$validators&&(a.$validators.schemaForm=function(){return!Object.keys(a.$error).some(function(e){return"schemaForm"!==e})});var u=l.schema;t.validateField=function(e,t){var r=void 0===e;(r||a.$$parentForm.$name===e)&&((r||u&&u.type.indexOf("array")!==-1)&&c(a.$modelValue,t),a.$setDirty?(a.$setDirty(),a.$setViewValue(a.$viewValue),a.$commitViewValue(),"checkbox"===l.type?l.required&&void 0===a.$modelValue&&a.$setValidity("tv4-302",!1):l.required&&a.$isEmpty(a.$modelValue)&&a.$setValidity("tv4-302",!1)):a.$setViewValue(a.$viewValue))};var f=!0;a.$formatters.push(function(e){return!a.$pristine||!f||t.options&&t.options.validateOnRender===!0?(c(a.$modelValue),e):(f=!1,e)}),t.$on("schemaFormValidate",function(e,r){t.validateField(r,!0)}),t.schemaError=function(){return s}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r){return{scope:!0,controller:["$scope",function(e){this.key=e.form&&e.form.key?e.form.key.splice(0,-2):[]}],link:function(n,i,a){n.min=0,n.modelArray=n.$eval(a.sfNewArray);var s=function(){n.modelArray=n.$eval(a.sfNewArray),n.ngModel&&n.ngModel.$pristine&&n.firstDigest&&(!n.options||n.options.validateOnRender!==!0)||n.validateField&&n.validateField()},l=function(){n.form&&n.form.onChange&&(o.a.isFunction(n.form.onChange)?n.form.onChange(n.modelArray,n.form):n.evalExpr(n.form.onChange,{modelValue:n.modelArray,form:n.form}))},c=function(){var r=n.modelArray;if(!r){var o=t.parse(a.sfNewArray);r=[],e(o,n,r),n.modelArray=r}return r},u=n.$watch("form",function(e){if(e){if(e.titleMap||e.startEmpty===!0||n.modelArray&&0!==n.modelArray.length||n.appendToArray(),n.$watch(function(e){return JSON.stringify(e.modelArray)},function(){s(),l()}),e.titleMap&&e.titleMap.length>0){n.titleMapValues=[];var t=function(t){n.titleMapValues=[],t=t||[],e.titleMap.forEach(function(e){n.titleMapValues.push(t.indexOf(e.value)!==-1)})};t(n.modelArray),n.$watchCollection("modelArray",t),n.$watchCollection("titleMapValues",function(t,r){if(t&&t!==r){var o=c();e.titleMap.forEach(function(e,r){var n=o.indexOf(e.value);n===-1&&t[r]&&o.push(e.value),n===-1||t[r]||o.splice(n,1)}),n.validateField&&n.validateField()}})}u()}});n.appendToArray=function(){var t,i=c();if(n.form&&n.form.schema&&n.form.schema.items){var a=n.form.schema.items;a.type&&a.type.indexOf("object")!==-1?(t={},n.options&&n.options.setSchemaDefaults===!1||(t=o.a.isDefined(a.default)?a.default:t,t&&r.traverseSchema(a,function(r,n){o.a.isDefined(r.default)&&e(n,t,r.default)}))):a.type&&a.type.indexOf("array")!==-1?(t=[],n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t)):n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t)}return i.push(t),i},n.deleteFromArray=function(e){var t=n.modelArray;return t&&t.splice(e,1),t};var f=function(e){return function(t){t.key&&(t.key[t.key.indexOf("")]=e)}},d={};n.copyWithIndex=function(e){var t=n.form;if(!d[e]){var i=t.items[0];if(t.items.length>1&&(i={type:"section",items:t.items.map(function(e){return e.ngModelOptions=t.ngModelOptions,o.a.isUndefined(e.readonly)&&(e.readonly=t.readonly),e})}),i){var a=o.a.copy(i);a.arrayIndex=e,r.traverseForm(a,f(e)),d[e]=a}}return d[e]}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){return{require:"ngModel",restrict:"AC",scope:!1,link:function(e,t,r,n){var i=e.$eval(r.sfChanged);i&&i.onChange&&n.$viewChangeListeners.push(function(){o.a.isFunction(i.onChange)?i.onChange(n.$modelValue,i):e.evalExpr(i.onChange,{modelValue:n.$modelValue,form:i,arrayIndex:e.$index,arrayIndices:e.arrayIndices,path:e.path,$i:e.$i,$index:e.$index})})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r,n,a,s,l,c,u){var f={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function(e,t,r,n){var o=n[0];n[1],n[2];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.initialForm=Object.assign({},o.lookup["f"+r.sfField]),e.form=o.lookup["f"+r.sfField]},post:function(e,t,r,n){var s=n[0],d=n[1];n[2];e.getKey=function(t){var r=t||f.COMPLETE,n=e.parentKey?e.parentKey.slice(0,e.parentKey.length-1):[];if(e.completeKey!==e.form.key&&("number"==typeof e.$index&&(n=n.concat(e.$index)),e.form.key&&e.form.key.length))if("number"==typeof n[n.length-1]&&e.form.key.length>=1){var o=e.form.key.length-n.length;e.completeKey=n.concat(e.form.key.slice(-o))}else e.completeKey=e.form.key.slice();if(Array.isArray(e.completeKey))return r===f.COMPLETE?e.completeKey:e.completeKey.reduce(function(e,t,n){return-1!==[r].indexOf("undefined"==typeof t?"undefined":i(t))?e.concat(t):e},[])},e.form.key&&(e.form.key=e.completeKey=e.getKey()),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=r||!1,o=t&&d&&d.$name?d.$name:void 0,i=e.completeKey;return Array.isArray(i)?c.name(i,"-",o,n):""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(s?s.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return s?s.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&a(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.errors===!1?e.ngModel.$invalid&&!e.ngModel.$pristine:e.ngModel.$invalid)},e.errorMessage=function(t){return l.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)},e.form.htmlClass=e.form.htmlClass||"",e.idClass=e.fieldId(!1)+" "+e.fieldId(!1,!0);var p=e.form;p.key&&(e.$on("schemaForm.error."+p.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(p.validationMessage||(p.validationMessage={}),p.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){var t=e.getKey();if(!e.externalDestructionInProgress){var r=p.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(t&&"retain"!==r){var n=e.model;if(t.length>1&&(n=u(t.slice(0,t.length-1),n)),void 0===n)return;var o=p.schema&&p.schema.type||"";"empty"===r&&o.indexOf("string")!==-1?n[t.slice(-1)]="":"empty"===r&&o.indexOf("object")!==-1?n[t.slice(-1)]={}:"empty"===r&&o.indexOf("array")!==-1?n[t.slice(-1)]=[]:"null"===r?n[t.slice(-1)]=null:delete n[t.slice(-1)]}}}))}}}}},function(e,t,r){"use strict";t.a=function(e,t){return{scope:!0,require:["?^^sfNewArray"],link:{pre:function(e,r,n,o){e.parentKey=e.parentKey||[];var i=t.parse(n.sfParentKey),a=i.length-e.parentKey.length;i.length>1&&(i=i.splice(-a)),e.parentKey=e.parentKey.concat(i,Number(n.sfIndex)),e.arrayIndex=Number(n.sfIndex),e.arrayIndices=e.arrayIndices||[],e.arrayIndices=e.arrayIndices.concat(e.arrayIndex),e.$i=e.arrayIndices,e.path=function(t){var r=-1;return t=t.replace(/\[\]/gi,function(t){return r++,"["+e.$i[r]+"]"}),e.evalExpr(t,e)}}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r=e.has("$sanitize")?e.get("$sanitize"):function(e){return e};return{scope:!1,restrict:"EA",link:function(e,n,i){var a="";i.sfMessage&&e.$watch(i.sfMessage,function(t){t&&(a=r(t),c(!!e.ngModel))});var s,l=function(e){e!==s&&(n.html(e),s=e)},c=function(r){if(r)if(e.hasError()){var n=[];o.a.forEach(e.ngModel&&e.ngModel.$error,function(e,t){e&&n.push(t)}),n=n.filter(function(e){return"schemaForm"!==e});var i=n[0];l(i?t.interpolate(i,e.ngModel.$modelValue,e.ngModel.$viewValue,e.form,e.options&&e.options.validationMessage):a)}else l(a);else l(a)};c();var u=e.$watch("ngModel",function(e){e&&(e.$parsers.push(function(e){return c(!0),e}),e.$formatters.push(function(e){return c(!0),e}),u())});e.$watchCollection("ngModel.$error",function(){c(!!e.ngModel)})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r,n,i,a,s,l,c){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function(e){this.$onInit=function(){this.evalInParentScope=function(t,r){return e.$parent.$eval(t,r)};var t=this;e.lookup=function(e){return e&&(t.lookup=e),t.lookup}},1===o.a.version.major&&o.a.version.minor<5&&this.$onInit()}],replace:!1,restrict:"A",transclude:!0,require:"?form",link:function(l,u,f,d,p){l.formCtrl=d;var m={};p(l,function(e){if(e.addClass("schema-form-ignore"),u.prepend(e),u[0].querySelectorAll){var t=u[0].querySelectorAll("[ng-model]");if(t)for(var r=0;r<t.length;r++){var n=t[r].getAttribute("ng-model");m[n.substring(n.indexOf(".")+1)]=!0}}});var h,v={};l.resolveReferences=function(e,t){i.jsonref(e).then(function(e){l.render(e,t)}).catch(function(e){new Error(e)})},l.render=function(e,o){var a=[],s=i.merge(e,o,void 0,m,l.options,void 0,a);a.length>0?n.all(a.map(function(e){return t.get(e.templateUrl,{cache:r}).then(function(t){e.template=t.data})})).then(function(){l.internalRender(e,o,s)}):l.internalRender(e,o,s)},l.internalRender=function(t,r,n){h&&(l.externalDestructionInProgress=!0,h.$destroy(),l.externalDestructionInProgress=!1),h=l.$new(),h.schemaForm={form:n,schema:t},Array.prototype.forEach.call(u.children(),function(e){var t=o.a.element(e);!1===t.hasClass("schema-form-ignore")&&t.remove()});for(var d={},p=u[0].querySelectorAll("*[sf-insert-field]"),m=0;m<p.length;m++)d[p[m].getAttribute("sf-insert-field")]=p[m];var v=a.decorator(f.sfUseDecorator),y=Object.create(null);l.lookup(y),u[0].appendChild(c.build(n,v,d,y)),h.firstDigest=!0,setTimeout(function(){h.firstDigest=!1,l.$apply()},0),e(u.children())(h),l.options&&l.options.setSchemaDefaults===!1||i.traverseSchema(t,function(e,t){if(o.a.isDefined(e.default)){var r=s(t,l.model);o.a.isUndefined(r)&&s(t,l.model,e.default)}}),l.$emit("sf-render-finished",u)};var y=["*"];l.$watch(function(){var e=l.schema,t=l.initialForm||y;t&&e&&e.type&&(v.form!==t||v.schema!==e)&&((!e.properties||0===Object.keys(e.properties).length)&&(t.indexOf("*")||t.indexOf("...")),v.schema=e,v.form=t,l.resolveReferences(e,t))}),l.$on("schemaFormRedraw",function(){var e=l.schema,t=l.initialForm?o.a.copy(l.initialForm):["*"];e&&l.resolveReferences(e,t)}),l.$on("$destroy",function(){l.externalDestructionInProgress=!0}),l.evalExpr=function(e,t){return l.$parent.$eval(e,t)}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r="",n={},i=function(e,t){"sfDecorator"===e&&(e=r);var o=n[e];return o[t.type]?o[t.type].template:o.default.template},a=function(r){e.directive(r,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function(e,n,a,s,l,c,u,f,d){return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["?^sfSchema","?^form"],link:function(e,p,m,h){var v=h[0],y=h[1];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=e.parentKey||[];if(e.form.key){if("number"==typeof n[n.length-1]){var o=n.concat(e.form.key.slice(-1)),i=t&&y&&y.$name?y.$name:void 0;return f.name(o,"-",i,r)}var i=t&&y&&y.$name?y.$name:void 0;return f.name(e.form.key,"-",i,r)}return""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(v?v.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return v?v.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&l(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.ngModel.$invalid&&!e.ngModel.$pristine)},e.errorMessage=function(t){return u.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)};var g=e.$watch(m.form,function(l){if(l){l.ngModelOptions=l.ngModelOptions||{},e.form=l;var u;if("template"===l.type&&l.template)u=c.when(l.template);else{var m="template"===l.type?l.templateUrl:i(r,l);u=a.get(m,{cache:s}).then(function(e){return e.data})}u.then(function(r){if(l.key){var i=l.key?t.stringify(l.key).replace(/"/g,"&quot;"):"";r=r.replace(/\$\$value\$\$/g,"model"+("["!==i[0]?".":"")+i)}if(p.html(r),l.condition){var a='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';l.key&&(a='evalExpr(form.condition, {model: model, "arrayIndex": arrayIndex, "modelValue": model'+f.stringify(l.key)+"})"),o.a.forEach(p.children(),function(e){var t=e.getAttribute("ng-if");e.setAttribute("ng-if",t?"("+t+") || ("+a+")":a)})}n(p.contents())(e)}),l.key&&(e.$on("schemaForm.error."+l.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(l.validationMessage||(l.validationMessage={}),l.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){if(!e.externalDestructionInProgress){var t=l.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(l.key&&"retain"!==t){var r=e.model;if(l.key.length>1&&(r=d(l.key.slice(0,l.key.length-1),r)),void 0===r)return;var n=l.schema&&l.schema.type||"";"empty"===t&&n.indexOf("string")!==-1?r[l.key.slice(-1)]="":"empty"===t&&n.indexOf("object")!==-1?r[l.key.slice(-1)]={}:"empty"===t&&n.indexOf("array")!==-1?r[l.key.slice(-1)]=[]:"null"===t?r[l.key.slice(-1)]=null:delete r[l.key.slice(-1)]}}})),g()}})}}}])},s=function(t,r,n){n=!!o.a.isDefined(n)&&n,e.directive("sf"+o.a.uppercase(t[0])+t.substr(1),function(){return{restrict:"EAC",scope:!0,replace:!0,transclude:n,template:'<sf-decorator form="form"></sf-decorator>',link:function(e,r,n){var i={items:"c",titleMap:"c",schema:"c"},a={type:t},s=!0;o.a.forEach(n,function(t,r){if("$"!==r[0]&&0!==r.indexOf("ng")&&"sfField"!==r){var l=function(t){o.a.isDefined(t)&&t!==a[r]&&(a[r]=t,s&&a.type&&(a.key||o.a.isUndefined(n.key))&&(e.form=a,s=!1))};"model"===r?e.$watch(t,function(t){t&&e.model!==t&&(e.model=t)}):"c"===i[r]?e.$watchCollection(t,l):n.$observe(r,l)}})}}})};this.createDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){n[e][r]={template:t,replace:!1,builder:[]}}),n[r]||(r=e),a(e)},this.defineDecorator=function(e,t){
-n[e]={__name:e},o.a.forEach(t,function(t,r){t.builder=t.builder||[],t.replace=!o.a.isDefined(t.replace)||t.replace,n[e][r]=t}),n[r]||(r=e),a(e)},this.createDirective=s,this.createDirectives=function(e){o.a.forEach(e,function(e,t){s(t,e)})},this.decorator=function(e){return e=e||r,n[e]},this.addMapping=function(e,t,r,o,i){n[e]&&(n[e][t]={template:r,builder:o,replace:!!i})},this.defineAddOn=function(e,t,r,o){n[e]&&(n[e][t]={template:r,builder:o,replace:!0})},this.$get=function(){return{decorator:function(e){return n[e]||n[r]},defaultDecorator:r}},a("sfDecorator")}},function(e,t,r){"use strict";var n=r(0),o=(r.n(n),r(1));r.n(o);t.a=function(){var e=function(e){return e},t=o.schemaDefaults.createDefaults();this.defaults=t,this.stdFormObj=o.schemaDefaults.stdFormObj,this.defaultFormDefinition=o.schemaDefaults.defaultFormDefinition,this.postProcess=function(t){e=t},this.appendRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].push(t)},this.prependRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].unshift(t)},this.createStandardForm=o.schemaDefaults.stdFormObj,this.$get=function(){var t={},n=this.defaults;return t.jsonref=o.jsonref,t.defaults=function(e,t,r,i){var a=t||n;return o.schemaDefaults.defaultForm(e,a,r,i)},t.merge=function(n){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["*"],a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.typeDefault,s=arguments[3],l=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},c=arguments.length>5&&void 0!==arguments[5]&&arguments[5],u=arguments[6],f=r.i(o.merge)(n,i,a,s,l,c,u);return e(f)},t.typeDefault=n,t.traverseSchema=o.traverseSchema,t.traverseForm=o.traverseForm,t}}},function(e,t,r){"use strict";t.a=function(e){var t=/[A-Z]/g,r=function(e,r){return r=r||"_",e.replace(t,function(e,t){return(t?r:"")+e.toLowerCase()})},n=0;"firstElementChild"in document.createDocumentFragment()||Object.defineProperty(DocumentFragment.prototype,"firstElementChild",{get:function(){for(var e,t=this.childNodes,r=0,n=t.length;r<n;++r)if(e=t[r],1===e.nodeType)return e;return null}});var o={sfField:function(e){e.fieldFrag.firstElementChild.setAttribute("sf-field",n),e.lookup["f"+n]=e.form,n++},ngModel:function(t){if(t.form.key){var r=t.form.key;t.state.keyRedaction&&(r=r.slice(t.state.keyRedaction));var n;if(t.state.modelValue)n=t.state.modelValue;else{var o=e.stringify(r).replace(/"/g,"&quot;");n=t.state.modelName||"model",o&&(n+=("["!==o[0]?".":"")+o)}for(var i=t.fieldFrag.querySelectorAll("[sf-field-model]"),a=0;a<i.length;a++){var s=i[a],l=s.getAttribute("sf-field-model");if(l&&""!==l)if("replaceAll"===l)for(var c=s.attributes,u=0;u<c.length;u++)c[u].value&&c[u].value.indexOf("$$value")!==-1&&(c[u].value=c[u].value.replace(/\$\$value\$\$/g,n));else{var f=s.getAttribute(l);f&&f.indexOf("$$value$$")?s.setAttribute(l,f.replace(/\$\$value\$\$/g,n)):s.setAttribute(l,n)}else s.setAttribute("ng-model",n)}}},simpleTransclusion:function(e){var t=e.build(e.form.items,e.path+".items",e.state);e.fieldFrag.firstChild.appendChild(t)},ngModelOptions:function(e){e.form.ngModelOptions&&Object.keys(e.form.ngModelOptions).length>0&&e.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(e.form.ngModelOptions))},transclusion:function(e){var t=e.fieldFrag.querySelectorAll("[sf-field-transclude]");if(t.length)for(var r=0;r<t.length;r++){var n=t[r],o=n.getAttribute("sf-field-transclude")||"items",i=e.form[o];if(i){var a=e.build(i,e.path+"."+o,e.state);n.appendChild(a)}}},condition:function(t){var r="",n="undefined",o="";if(t.form.condition){t.form.key&&(r=e.stringify(t.form.key),n="model"+("["===r[0]?"":".")+r);for(var i="evalExpr("+t.path+'.condition, { model: model, "arrayIndex": $index, "arrayIndices": arrayIndices, "path": path, "$i": $i, "$index": $index, "modelValue": '+n+"})",a=t.fieldFrag.children||t.fieldFrag.childNodes,s=0;s<a.length;s++){var l=a[s];l.hasAttribute&&l.hasAttribute("ng-if")&&(o=l.getAttribute("ng-if")),l.setAttribute&&l.setAttribute("ng-if",o?"("+o+") || ("+i+")":i)}}},array:function(t){var r=t.fieldFrag.querySelector("[schema-form-array-items]");if(t.form.key){t.form.key.filter(function(e){return""===e}).length}if(r){var n=angular.copy(t.state);if(n.keyRedaction=0,n.keyRedaction+=t.form.key.length+1,t.form.schema&&t.form.schema.items&&t.form.schema.items.type&&t.form.schema.items.type.indexOf("object")===-1&&t.form.schema.items.type.indexOf("array")===-1){e.stringify(t.form.key).replace(/"/g,"&quot;")+"[$index]";n.modelValue="modelArray[$index]"}else n.modelName="item";n.arrayCompatFlag=!0;var o=t.build(t.form.items,t.path+".items",n);r.appendChild(o)}},numeric:function(e){var t=e.fieldFrag.querySelector("input"),r=e.form.maximum||!1,n=e.form.exclusiveMaximum||!1,o=e.form.minimum||!1,i=e.form.exclusiveMinimum||!1,a=e.form.multipleOf||!1;t&&(a!==!1&&t.setAttribute("step",a),r!==!1&&(n!==!1&&a!==!1&&(r-=a),t.setAttribute("max",r)),o!==!1&&(i!==!1&&a!==!1&&(o+=a),t.setAttribute("min",o)))}};this.builders=o;var i=[o.sfField,o.ngModel,o.ngModelOptions,o.condition];this.stdBuilders=i,this.$get=["$templateCache","schemaFormDecorators","sfPath",function(e,t,n){var a=function(e,t){if(e.key){var r=t[n.stringify(e.key)];if(r){for(;r.firstChild;)r.removeChild(r.firstChild);return r}}},s=function e(t,n,o,i,s,l,c){l=l||{},l=l||{},c=c||Object.create(null),s=s||"schemaForm.form";var u=document.createDocumentFragment();return t.reduce(function(t,u,f){if(!u.type)return t;var d=n[u.type]||n.default;if(d.replace){var p;l.arrayCompatFlag=!1;var m=document.createElement("div"),h=o(u,d)||o(u,n.default);for(m.innerHTML=h,p=document.createDocumentFragment();m.childNodes.length>0;)p.appendChild(m.childNodes[0]);var v={fieldFrag:p,form:u,lookup:c,state:l,path:s+"["+f+"]",build:function(t,r,a){return e(t,n,o,i,r,a,c)}},y=u.builder||d.builder;"function"==typeof y?y(v):y.forEach(function(e){e(v)}),(a(u,i)||t).appendChild(p)}else{var g=document.createElement(r(n.__name,"-"));l.arrayCompatFlag?g.setAttribute("form","copyWithIndex($index)"):g.setAttribute("form",s+"["+f+"]"),(a(u,i)||t).appendChild(g)}return t},u),u};return{build:function(t,r,n,o){return s(t,r,function(t,r){return"template"===t.type?t.template:e.get(r.template)},n,void 0,void 0,o)},builder:o,stdBuilders:i,internalBuild:s}}]}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){var e={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};e.number=e[105],e.required=e[302],e.min=e[101],e.max=e[103],e.maxlength=e[201],e.minlength=e[200],e.pattern=e[202],this.setDefaultMessages=function(t){e=t},this.getDefaultMessages=function(){return e},this.setDefaultMessage=function(t,r){e[t]=r},this.$get=["$interpolate",function(t){var r={};return r.defaultMessages=e,r.interpolate=function(r,n,i,a,s){s=s||{};var l=a.validationMessage||{};0===r.indexOf("tv4-")&&(r=r.substring(4));var c=l.default||s.default||"";[l,s,e].some(function(e){return o.a.isString(e)||o.a.isFunction(e)?(c=e,!0):e&&e[r]?(c=e[r],!0):void 0});var u={error:r,value:n,viewValue:i,form:a,schema:a.schema,title:a.title||a.schema&&a.schema.title};return o.a.isFunction(c)?c(u):t(c)(u)},r}]}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=r(1),i=(r.n(o),r(0)),a=(r.n(i),function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}()),s=function(){function e(){n(this,e),this.name=o.sfPath.name,this.parse=o.sfPath.parse,this.stringify=o.sfPath.stringify,this.normalize=o.sfPath.normalize}return a(e,[{key:"$get",value:function(){return o.sfPath}}]),e}();t.a=s},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):v=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++v<t;)p&&p[v].run();v=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,v=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},function(e,t,r){(function(e,t){!function(e,r){"use strict";function n(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var n={callback:e,args:t};return h[m]=n,p(m),m++}function o(e){delete h[e]}function i(e){var t=e.callback,n=e.args;switch(n.length){case 0:t();break;case 1:t(n[0]);break;case 2:t(n[0],n[1]);break;case 3:t(n[0],n[1],n[2]);break;default:t.apply(r,n)}}function a(e){if(v)setTimeout(a,0,e);else{var t=h[e];if(t){v=!0;try{i(t)}finally{o(e),v=!1}}}}function s(){p=function(e){t.nextTick(function(){a(e)})}}function l(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}function c(){var t="setImmediate$"+Math.random()+"$",r=function(r){r.source===e&&"string"==typeof r.data&&0===r.data.indexOf(t)&&a(+r.data.slice(t.length))};e.addEventListener?e.addEventListener("message",r,!1):e.attachEvent("onmessage",r),p=function(r){e.postMessage(t+r,"*")}}function u(){var e=new MessageChannel;e.port1.onmessage=function(e){var t=e.data;a(t)},p=function(t){e.port2.postMessage(t)}}function f(){var e=y.documentElement;p=function(t){var r=y.createElement("script");r.onreadystatechange=function(){a(t),r.onreadystatechange=null,e.removeChild(r),r=null},e.appendChild(r)}}function d(){p=function(e){setTimeout(a,0,e)}}if(!e.setImmediate){var p,m=1,h={},v=!1,y=e.document,g=Object.getPrototypeOf&&Object.getPrototypeOf(e);g=g&&g.setTimeout?g:e,"[object process]"==={}.toString.call(e.process)?s():l()?c():e.MessageChannel?u():y&&"onreadystatechange"in y.createElement("script")?f():d(),g.setImmediate=n,g.clearImmediate=o}}("undefined"==typeof self?"undefined"==typeof e?this:e:self)}).call(t,r(2),r(17))},function(r,n,o){function i(e,t){this._id=e,this._clearFn=t}var a=Function.prototype.apply;n.setTimeout=function(){return new i(a.call(setTimeout,window,arguments),clearTimeout)},n.setInterval=function(){return new i(a.call(setInterval,window,arguments),clearInterval)},n.clearTimeout=n.clearInterval=function(e){e&&e.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(window,this._id)},n.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},n.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},n._unrefActive=n.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},o(18),n.setImmediate=e,n.clearImmediate=t},,function(e,t,r){r(1),e.exports=r(4)}])}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):v=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++v<t;)p&&p[v].run();v=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,v=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},,,function(e,t,r){r(19),e.exports=r(0)}]);
\ No newline at end of file
+var n=!1,o=!0,i=!0,a=function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(r){var n="[A-Za-z]",o="[0-9]",a=e(o,"[A-Fa-f]"),s=t(t("%[EFef]"+a+"%"+a+a+"%"+a+a)+"|"+t("%[89A-Fa-f]"+a+"%"+a+a)+"|"+t("%"+a+a)),l="[\\:\\/\\?\\#\\[\\]\\@]",c="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",u=e(l,c),f=r?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",d=r?"[\\uE000-\\uF8FF]":"[]",p=e(n,o,"[\\-\\.\\_\\~]",f),m=t(n+e(n,o,"[\\+\\-\\.]")+"*"),h=t(t(s+"|"+e(p,c,"[\\:]"))+"*"),y=t(t("25[0-5]")+"|"+t("2[0-4]"+o)+"|"+t("1"+o+o)+"|"+t("[1-9]"+o)+"|"+o),v=t(y+"\\."+y+"\\."+y+"\\."+y),g=t(a+"{1,4}"),b=(t(t(g+"\\:"+g)+"|"+v),t(e(p,c,"[\\:]")+"+")),x=t("v"+a+"+\\."+e(p,c,"[\\:]")+"+"),w=t("\\["+t(b+"|"+x)+"\\]"),E=t(t(s+"|"+e(p,c))+"*"),$=t(w+"|"+v+"(?!"+E+")|"+E),C=t(o+"*"),k=t(t(h+"@")+"?"+$+t("\\:"+C)+"?"),O=t(s+"|"+e(p,c,"[\\:\\@]")),T=t(O+"*"),A=t(O+"+"),S=t(t(s+"|"+e(p,c,"[\\@]"))+"+"),P=t(t("\\/"+T)+"*"),M=t("\\/"+t(A+P)+"?"),j=t(S+P),I=t(A+P),D="(?!"+O+")",_=(t(P+"|"+M+"|"+j+"|"+I+"|"+D),t(t(O+"|"+e("[\\/\\?]",d))+"*")),F=t(t(O+"|[\\/\\?]")+"*"),R=t(t("\\/\\/"+k+P)+"|"+M+"|"+I+"|"+D),q=t(m+"\\:"+R+t("\\?"+_)+"?"+t("\\#"+F)+"?"),U=t(t("\\/\\/"+k+P)+"|"+M+"|"+j+"|"+D),N=t(U+t("\\?"+_)+"?"+t("\\#"+F)+"?"),L=(t(q+"|"+N),t(m+"\\:"+R+t("\\?"+_)+"?"),"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+I+"|"+D+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$"),H="^(){0}"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+j+"|"+D+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$";"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+I+"|"+D+")")+t("\\?("+_+")")+"?$","^"+t("\\#("+F+")")+"?$","^"+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?$";return{URI_REF:i&&new RegExp("("+L+")|("+H+")"),NOT_SCHEME:new RegExp(e("[^]",n,o,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(e("[^\\%\\:]",p,c),"g"),NOT_HOST:new RegExp(e("[^\\%]",p,c),"g"),NOT_PATH:new RegExp(e("[^\\%\\/\\:\\@]",p,c),"g"),NOT_PATH_NOSCHEME:new RegExp(e("[^\\%\\/\\@]",p,c),"g"),NOT_QUERY:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]",d),"g"),NOT_FRAGMENT:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(e("[^]",p,c),"g"),UNRESERVED:new RegExp(p,"g"),OTHER_CHARS:new RegExp(e("[^\\%]",p,u),"g"),PCT_ENCODED:new RegExp(s,"g")}}function n(e){var t,r=e.charCodeAt(0);return t=r<16?"%0"+r.toString(16).toUpperCase():r<128?"%"+r.toString(16).toUpperCase():r<2048?"%"+(r>>6|192).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase():"%"+(r>>12|224).toString(16).toUpperCase()+"%"+(r>>6&63|128).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase()}function a(e){for(var t,r,n,o="",i=0,a=e.length;i<a;)t=parseInt(e.substr(i+1,2),16),t<128?(o+=String.fromCharCode(t),i+=3):t>=194&&t<224?(a-i>=6?(r=parseInt(e.substr(i+4,2),16),o+=String.fromCharCode((31&t)<<6|63&r)):o+=e.substr(i,6),i+=6):t>=224?(a-i>=9?(r=parseInt(e.substr(i+4,2),16),n=parseInt(e.substr(i+7,2),16),o+=String.fromCharCode((15&t)<<12|(63&r)<<6|63&n)):o+=e.substr(i,9),i+=9):(o+=e.substr(i,3),i+=3);return o}function l(e){return void 0===e?"undefined":null===e?"null":Object.prototype.toString.call(e).split(" ").pop().split("]").shift().toLowerCase()}function c(e){return e.toUpperCase()}function u(e,t){function r(e){var r=a(e);return r.match(t.UNRESERVED)?r:e}return e.scheme&&(e.scheme=String(e.scheme).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_SCHEME,"")),void 0!==e.userinfo&&(e.userinfo=String(e.userinfo).replace(t.PCT_ENCODED,r).replace(t.NOT_USERINFO,n).replace(t.PCT_ENCODED,c)),void 0!==e.host&&(e.host=String(e.host).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_HOST,n).replace(t.PCT_ENCODED,c)),void 0!==e.path&&(e.path=String(e.path).replace(t.PCT_ENCODED,r).replace(e.scheme?t.NOT_PATH:t.NOT_PATH_NOSCHEME,n).replace(t.PCT_ENCODED,c)),void 0!==e.query&&(e.query=String(e.query).replace(t.PCT_ENCODED,r).replace(t.NOT_QUERY,n).replace(t.PCT_ENCODED,c)),void 0!==e.fragment&&(e.fragment=String(e.fragment).replace(t.PCT_ENCODED,r).replace(t.NOT_FRAGMENT,n).replace(t.PCT_ENCODED,c)),e}function f(e,t){void 0===t&&(t={});var r,n,l=o&&t.iri!==!1?E:w,c=!1,f={};if("suffix"===t.reference&&(e=(t.scheme?t.scheme+":":"")+"//"+e),i?(r=e.match(l.URI_REF),r&&(r=r[1]?r.slice(1,10):r.slice(10,19)),r||(c=!0,t.tolerant||(f.error=f.error||"URI is not strictly valid."),r=e.match($))):r=e.match($),r){if(A?(f.scheme=r[1],f.userinfo=r[3],f.host=r[4],f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=r[7],f.fragment=r[8],isNaN(f.port)&&(f.port=r[5])):(f.scheme=r[1]||void 0,f.userinfo=e.indexOf("@")!==-1?r[3]:void 0,f.host=e.indexOf("//")!==-1?r[4]:void 0,f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=e.indexOf("?")!==-1?r[7]:void 0,f.fragment=e.indexOf("#")!==-1?r[8]:void 0,isNaN(f.port)&&(f.port=e.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?r[4]:void 0)),void 0!==f.scheme||void 0!==f.userinfo||void 0!==f.host||void 0!==f.port||f.path||void 0!==f.query?void 0===f.scheme?f.reference="relative":void 0===f.fragment?f.reference="absolute":f.reference="uri":f.reference="same-document",t.reference&&"suffix"!==t.reference&&t.reference!==f.reference&&(f.error=f.error||"URI is not a "+t.reference+" reference."),n=S[(t.scheme||f.scheme||"").toLowerCase()],!o||"undefined"==typeof s||t.unicodeSupport||n&&n.unicodeSupport)u(f,l);else{if(f.host&&(t.domainHost||n&&n.domainHost))try{f.host=s.toASCII(f.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(e){f.error=f.error||"Host's domain name can not be converted to ASCII via punycode: "+e}u(f,w)}n&&n.parse&&n.parse(f,t)}else c=!0,f.error=f.error||"URI can not be parsed.";return f}function d(e,t){var r=[];return void 0!==e.userinfo&&(r.push(e.userinfo),r.push("@")),void 0!==e.host&&r.push(e.host),"number"==typeof e.port&&(r.push(":"),r.push(e.port.toString(10))),r.length?r.join(""):void 0}function p(e){for(var t,r=[];e.length;)e.match(C)?e=e.replace(C,""):e.match(k)?e=e.replace(k,"/"):e.match(O)?(e=e.replace(O,"/"),r.pop()):"."===e||".."===e?e="":(t=e.match(T)[0],e=e.slice(t.length),r.push(t));return r.join("")}function m(e,t){void 0===t&&(t={});var r,n,i,l=o&&t.iri?E:w,c=[];if(r=S[(t.scheme||e.scheme||"").toLowerCase()],r&&r.serialize&&r.serialize(e,t),o&&"undefined"!=typeof s&&e.host&&(t.domainHost||r&&r.domainHost))try{e.host=t.iri?s.toUnicode(e.host):s.toASCII(e.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(r){e.error=e.error||"Host's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}return u(e,l),"suffix"!==t.reference&&e.scheme&&(c.push(e.scheme),c.push(":")),n=d(e,t),void 0!==n&&("suffix"!==t.reference&&c.push("//"),c.push(n),e.path&&"/"!==e.path.charAt(0)&&c.push("/")),void 0!==e.path&&(i=e.path,t.absolutePath||r&&r.absolutePath||(i=p(i)),void 0===n&&(i=i.replace(/^\/\//,"/%2F")),c.push(i)),void 0!==e.query&&(c.push("?"),c.push(e.query)),void 0!==e.fragment&&(c.push("#"),c.push(e.fragment)),c.join("")}function h(e,t,r,n){void 0===r&&(r={});var o={};return n||(e=f(m(e,r),r),t=f(m(t,r),r)),r=r||{},!r.tolerant&&t.scheme?(o.scheme=t.scheme,o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(t.path?("/"===t.path.charAt(0)?o.path=p(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?o.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:o.path=t.path:o.path="/"+t.path,o.path=p(o.path)),o.query=t.query):(o.path=e.path,void 0!==t.query?o.query=t.query:o.query=e.query),o.userinfo=e.userinfo,o.host=e.host,o.port=e.port),o.scheme=e.scheme),o.fragment=t.fragment,o}function y(e,t,r){return m(h(f(e,r),f(t,r),r,!0),r)}function v(e,t){return"string"==typeof e?e=m(f(e,t),t):"object"===l(e)&&(e=f(m(e,t),t)),e}function g(e,t,r){return"string"==typeof e?e=m(f(e,r),r):"object"===l(e)&&(e=m(e,r)),"string"==typeof t?t=m(f(t,r),r):"object"===l(t)&&(t=m(t,r)),e===t}function b(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.ESCAPE:w.ESCAPE,n)}function x(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.PCT_ENCODED:w.PCT_ENCODED,a)}var w=r(!1),E=o?r(!0):void 0,$=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?([^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n)*))?/i,C=/^\.\.?\//,k=/^\/\.(\/|$)/,O=/^\/\.\.(\/|$)/,T=/^\/?(?:.|\n)*?(?=\/|$)/,A=void 0==="".match(/(){0}/)[1],S={};return{IRI_SUPPORT:o,VALIDATE_SUPPORT:i,pctEncChar:n,pctDecChars:a,SCHEMES:S,parse:f,_recomposeAuthority:d,removeDotSegments:p,serialize:m,resolveComponents:h,resolve:y,normalize:v,equal:g,escapeComponent:b,unescapeComponent:x}}();if(!n&&"undefined"!=typeof t&&"function"==typeof e){var s=e("./punycode");t.exports=a,e("./schemes")}},{"./punycode":18,"./schemes":19}]},{},[1])(1)})},function(e,t,r){"use strict";function n(e,t){var l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:r.i(i.createDefaults)(),c=arguments[3],u=arguments[4],f=arguments[5],d=arguments[6],p=[],m=[];t=t||[];var h=t.indexOf("*");u=u||{};var y={},v=t.indexOf("...");if("object"===("undefined"==typeof e?"undefined":s(e))&&e.hasOwnProperty("properties")){f=f||e.readonly||e.readOnly,y=r.i(i.defaultForm)(e,l,c,u);var g=y.lookup;e=g||e,p=p.concat(y.form)}return h!==-1&&(t=t.slice(0,h).concat(p).concat(t.slice(h+1))),y.form&&v!==-1&&!function(){var e=t.map(function(e){return"string"==typeof e?e:e.key?e.key:void 0}).filter(function(e){return void 0!==e});m=m.concat(y.form.map(function(t){var r=e.indexOf(t.key[0])!==-1;if(!r)return t}).filter(function(e){return void 0!==e}))}(),v!==-1&&(t=t.slice(0,v).concat(m).concat(t.slice(v+1))),t.map(function(t){if("string"==typeof t&&(t={key:t}),t.key&&"string"==typeof t.key&&(t.key=r.i(o.parse)(t.key)),t.titleMap&&(t.titleMap=r.i(a.a)(t.titleMap)),t.key){var i=r.i(o.stringify)(t.key);e[i]&&!function(){var r=e[i];r&&Object.keys(r).forEach(function(e){void 0===t[e]&&(t[e]=r[e])})}()}return f===!0&&(t.readonly=!0),t.items&&(t.items=n(e,t.items,l,c,u,t.readonly,d)),t.tabs&&t.tabs.forEach(function(r){r.items&&(r.items=n(e,r.items,l,c,u,t.readonly,d))}),"checkbox"===t.type&&(void 0===t.schema?t.schema={default:!1}:void 0===t.schema.default&&(t.schema.default=!1)),d&&"template"===t.type&&!t.template&&t.templateUrl&&d.push(t),t})}var o=r(0),i=r(3),a=r(1);t.a=n;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e}},function(e,t,r){"use strict";function n(e,t){var r=new Promise(function(t,r){o.resolveRefs(e,{filter:["relative","local","remote"]}).then(function(e){t(e.resolved)}).catch(function(e){r(new Error(e))})});return"function"!=typeof t?r:void r.then(function(e){t(null,e)}).catch(function(e){t(e)})}var o=r(5);r.n(o);t.a=n},function(e,t,r){"use strict";function n(e,t,r){t||(t=this);var n="string"==typeof e?o.parse(e):e;if("undefined"!=typeof r&&1===n.length)return t[n[0]]=r,t;"undefined"!=typeof r&&"undefined"==typeof t[n[0]]&&(t[n[0]]=n.length>2&&i.test(n[1])?[]:{});for(var a=t[n[0]],s=1;s<n.length;s++){if(""===n[s])return;if("undefined"!=typeof r){if(s===n.length-1)return a[n[s]]=r,r;var l=a[n[s]];"undefined"!=typeof l&&null!==l||(l=i.test(n[s+1])?[]:{},a[n[s]]=l),a=l}else a&&(a=a[n[s]])}return a}var o=r(0);t.a=n;var i=/^\d+$/},function(e,t,r){"use strict";function n(e,t,r,n){n=void 0===n||n,r=r||[];var o=function e(t,r,o){if(r(t,o),t.properties&&Object.keys(t.properties).forEach(function(n){var i=o.slice();i.push(n),e(t.properties[n],r,i)}),!n&&t.items){var i=o.slice();i.push(""),e(t.items,r,i)}};o(e,t,r||[])}function o(e,t){t(e),e.items&&e.items.forEach(function(e){o(e,t)}),e.tabs&&e.tabs.forEach(function(e){e.items&&e.items.forEach(function(e){o(e,t)})})}t.a=n,t.b=o},function(e,t,r){"use strict";function n(e,t){if(!e)return{valid:!0};var r=e.schema;if(!r)return{valid:!0};""===t&&(t=void 0),"number"===e.type&&null===t&&(t=void 0);var n={type:"object",properties:{},required:void 0},o=e.key[e.key.length-1];n.properties[o]=r,e.required&&(n.required=[o]);var a={};return t&&(a[o]=t),i.a.validateResult(a,n)}var o=r(12),i=r.n(o);t.a=n},function(e,t,r){"use strict";var n;!function(o){var i={parse:function(e){if("string"!=typeof e)throw new TypeError("ObjectPath.parse must be passed a string");for(var t,r,n,o,i=0,a=[];i<e.length;)if(t=e.indexOf(".",i),r=e.indexOf("[",i),t===-1&&r===-1)a.push(e.slice(i,e.length)),i=e.length;else if(r===-1||t!==-1&&t<r)a.push(e.slice(i,t)),i=t+1;else if(r>i&&(a.push(e.slice(i,r)),i=r),n=e.slice(r+1,r+2),'"'!==n&&"'"!==n)o=e.indexOf("]",r),o===-1&&(o=e.length),a.push(e.slice(i+1,o)),i="."===e.slice(o+1,o+2)?o+2:o+1;else{for(o=e.indexOf(n+"]",r),o===-1&&(o=e.length);"\\"===e.slice(o-1,o)&&r<e.length;)r++,o=e.indexOf(n+"]",r);a.push(e.slice(i+2,o).replace(new RegExp("\\"+n,"g"),n)),i="."===e.slice(o+2,o+3)?o+3:o+2}return a},stringify:function(e,t){return Array.isArray(e)||(e=[e.toString()]),t='"'===t?'"':"'",e.map(function(e){return"["+t+e.toString().replace(new RegExp(t,"g"),"\\"+t)+t+"]"}).join("")},normalize:function(e,t){return i.stringify(Array.isArray(e)?e:i.parse(e),t)},registerModule:function(e){e.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=i.parse,this.stringify=i.stringify,this.normalize=i.normalize,this.$get=function(){return i}})}};n=function(){return{ObjectPath:i}}.call(t,r,t,e),!(n!==o&&(e.exports=n))}()},function(e,t){e.exports=tv4},function(e,t,r){e.exports=r(4)}])}).call(t,r(2),r(18).setImmediate)},function(e,t){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(r=window)}e.exports=r},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(1),o=(r.n(n),r(0)),i=r.n(o),a=r(13),s=r(11),l=r(12),c=r(14),u=r(15),f=r(6),d=r(7),p=r(9),m=r(5),h=r(8),y=r(10),v=r(4),g=[];try{i.a.module("ngSanitize"),g.push("ngSanitize")}catch(e){}try{i.a.module("ui.sortable"),g.push("ui.sortable")}catch(e){}try{i.a.module("angularSpectrumColorpicker"),g.push("angularSpectrumColorpicker")}catch(e){}i.a.module("schemaForm",g).provider("sfPath",u.a).provider("sfBuilder",["sfPathProvider",a.a]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",s.a]).provider("sfErrorMessage",c.a).provider("schemaForm",["sfPathProvider",l.a]).factory("sfSelect",function(){return n.select}).factory("sfValidator",function(){return n.validate}).directive("sfChanged",f.a).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",d.a]).directive("sfMessage",["$injector","sfErrorMessage",p.a]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",m.a]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",y.a]).directive("schemaValidate",["sfValidator","$parse","sfSelect",v.a]).directive("sfKeyController",["schemaForm","sfPath",h.a])},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r){return{restrict:"A",scope:!1,priority:500,require:"ngModel",link:function(t,n,i,a){t.$emit("schemaFormPropagateNgModelController",a);var s=null,l=t.$eval(i.schemaValidate);l.copyValueTo&&a.$viewChangeListeners.push(function(){var e=l.copyValueTo;o.a.forEach(e,function(e){r(e,t.model,a.$modelValue)})});var c=function(r,n){if(!l)return r;if(t.options&&t.options.tv4Validation===!1)return r;var o=e(l,r);Object.keys(a.$error).filter(function(e){return 0===e.indexOf("tv4-")}).forEach(function(e){a.$setValidity(e,!0)});{if(o.valid||a.$pristine&&!n)return r;if(a.$setValidity("tv4-"+o.error.code,!1),s=o.error,a.$validators)return r}};"function"==typeof l.ngModel&&l.ngModel(a),["$parsers","$viewChangeListeners","$formatters"].forEach(function(e){l[e]&&a[e]&&l[e].forEach(function(t){a[e].push(t)})}),["$validators","$asyncValidators"].forEach(function(e){l[e]&&a[e]&&o.a.forEach(l[e],function(r,n){a[e][n]=function(e,n){return r(e,n,t.model,l)}})}),a.$parsers.push(c),a.$validators&&(a.$validators.schemaForm=function(){return!Object.keys(a.$error).some(function(e){return"schemaForm"!==e})});var u=l.schema;t.validateField=function(e,t){var r=void 0===e;(r||a.$$parentForm.$name===e)&&((r||u&&u.type.indexOf("array")!==-1)&&c(a.$modelValue,t),a.$setDirty?(a.$setDirty(),a.$setViewValue(a.$viewValue),a.$commitViewValue(),"checkbox"===l.type?l.required&&void 0===a.$modelValue&&a.$setValidity("tv4-302",!1):l.required&&a.$isEmpty(a.$modelValue)&&a.$setValidity("tv4-302",!1)):a.$setViewValue(a.$viewValue))};var f=!0;a.$formatters.push(function(e){return!a.$pristine||!f||t.options&&t.options.validateOnRender===!0?(c(a.$modelValue),e):(f=!1,e)}),t.$on("schemaFormValidate",function(e,r){t.validateField(r,!0)}),t.schemaError=function(){return s}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r){return{scope:!0,controller:["$scope",function(e){this.key=e.form&&e.form.key?e.form.key.splice(0,-2):[]}],link:function(n,a,s){n.min=0,n.trackBy=function(e,t){return e&&"object"===("undefined"==typeof e?"undefined":i(e))?e:t},n.modelArray=n.$eval(s.sfNewArray);var l=function(){n.modelArray=n.$eval(s.sfNewArray),n.ngModel&&n.ngModel.$pristine&&n.firstDigest&&(!n.options||n.options.validateOnRender!==!0)||n.validateField&&n.validateField()},c=function(){n.form&&n.form.onChange&&(o.a.isFunction(n.form.onChange)?n.form.onChange(n.modelArray,n.form):n.evalExpr(n.form.onChange,{modelValue:n.modelArray,form:n.form}))},u=function(){var r=n.modelArray;if(!r){var o=t.parse(s.sfNewArray);r=[],e(o,n,r),n.modelArray=r}return r},f=n.$watch("form",function(e){if(e){if(e.titleMap||e.startEmpty===!0||n.modelArray&&0!==n.modelArray.length||n.appendToArray(),n.$watch(function(e){return JSON.stringify(e.modelArray)},function(){l(),c()}),e.titleMap&&e.titleMap.length>0){n.titleMapValues=[];var t=function(t){n.titleMapValues=[],t=t||[],e.titleMap.forEach(function(e){n.titleMapValues.push(t.indexOf(e.value)!==-1)})};t(n.modelArray),n.$watchCollection("modelArray",t),n.$watchCollection("titleMapValues",function(t,r){if(t&&t!==r){var o=u();e.titleMap.forEach(function(e,r){var n=o.indexOf(e.value);n===-1&&t[r]&&o.push(e.value),n===-1||t[r]||o.splice(n,1)}),n.validateField&&n.validateField()}})}f()}});n.appendToArray=function(){var t,i=u();if(n.form&&n.form.schema&&n.form.schema.items){var a=n.form.schema.items;a.type&&a.type.indexOf("object")!==-1?(t={},n.options&&n.options.setSchemaDefaults===!1||(t=o.a.isDefined(a.default)?a.default:t,t&&r.traverseSchema(a,function(r,n){o.a.isDefined(r.default)&&e(n,t,r.default)}))):a.type&&a.type.indexOf("array")!==-1?(t=[],n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t)):n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t)}return i.push(t),i},n.deleteFromArray=function(e){var t=n.modelArray.indexOf(e),r=n.modelArray;return r&&r.splice(t,1),e.$$hashKey&&(n.destroyed=e.$$hashKey),r};var d=function(e){return function(t){t.key&&(t.key[t.key.indexOf("")]=e)}},p={};n.copyWithIndex=function(e){var t=n.form;if(!p[e]){var i=t.items[0];if(t.items.length>1&&(i={type:"section",items:t.items.map(function(e){return e.ngModelOptions=t.ngModelOptions,o.a.isUndefined(e.readonly)&&(e.readonly=t.readonly),e})}),i){var a=o.a.copy(i);a.arrayIndex=e,r.traverseForm(a,d(e)),p[e]=a}}return p[e]}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){return{require:"ngModel",restrict:"AC",scope:!1,link:function(e,t,r,n){var i=e.$eval(r.sfChanged);i&&i.onChange&&n.$viewChangeListeners.push(function(){o.a.isFunction(i.onChange)?i.onChange(n.$modelValue,i):e.evalExpr(i.onChange,{modelValue:n.$modelValue,form:i,arrayIndex:e.$index,arrayIndices:e.arrayIndices,path:e.path,$i:e.$i,$index:e.$index})})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r,n,a,s,l,c,u){var f={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function(e,t,r,n){var o=n[0];n[1],n[2];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.initialForm=Object.assign({},o.lookup["f"+r.sfField]),e.form=o.lookup["f"+r.sfField]},post:function(e,t,r,n){var s=n[0],d=n[1];n[2];e.getKey=function(t){var r=t||f.COMPLETE,n=e.parentKey?e.parentKey.slice(0,e.parentKey.length-1):[];if(e.completeKey!==e.form.key&&("number"==typeof e.$index&&(n=n.concat(e.$index)),e.form.key&&e.form.key.length))if("number"==typeof n[n.length-1]&&e.form.key.length>=1){var o=e.form.key.length-n.length;e.completeKey=n.concat(e.form.key.slice(-o))}else e.completeKey=e.form.key.slice();if(Array.isArray(e.completeKey))return r===f.COMPLETE?e.completeKey:e.completeKey.reduce(function(e,t,n){return-1!==[r].indexOf("undefined"==typeof t?"undefined":i(t))?e.concat(t):e},[])},e.form.key&&(e.form.key=e.completeKey=e.getKey()),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=r||!1,o=t&&d&&d.$name?d.$name:void 0,i=e.completeKey;return Array.isArray(i)?c.name(i,"-",o,n):""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(s?s.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return s?s.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&a(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.errors===!1?e.ngModel.$invalid&&!e.ngModel.$pristine:e.ngModel.$invalid)},e.errorMessage=function(t){return l.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)},e.form.htmlClass=e.form.htmlClass||"",e.idClass=e.fieldId(!1)+" "+e.fieldId(!1,!0);var p=e.form;p.key&&(e.$on("schemaForm.error."+p.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(p.validationMessage||(p.validationMessage={}),p.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){var t=e.getKey();"number"==typeof e.arrayIndex?e.arrayIndex+1:0;if(!(e.externalDestructionInProgress||e.model.$$hashKey&&e.model.$$hashKey!==e.destroyed)){var r=p.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(t&&"retain"!==r){var n=e.model;if(t.length>1&&(n=u(t.slice(0,t.length-1),n)),void 0===n)return;var o=p.schema&&p.schema.type||"";"empty"===r&&o.indexOf("string")!==-1?n[t.slice(-1)]="":"empty"===r&&o.indexOf("object")!==-1?n[t.slice(-1)]={}:"empty"===r&&o.indexOf("array")!==-1?n[t.slice(-1)]=[]:"null"===r?n[t.slice(-1)]=null:delete n[t.slice(-1)]}}}))}}}}},function(e,t,r){"use strict";t.a=function(e,t){return{scope:!0,require:["?^^sfNewArray"],link:{pre:function(e,r,n,o){e.parentKey=e.parentKey||[];var i=t.parse(n.sfParentKey),a=i.length-e.parentKey.length;i.length>1&&(i=i.splice(-a)),e.parentKey=e.parentKey.concat(i,Number(n.sfIndex)),e.arrayIndex=Number(n.sfIndex),e.arrayIndices=e.arrayIndices||[],e.arrayIndices=e.arrayIndices.concat(e.arrayIndex),e.$i=e.arrayIndices,e.path=function(t){var r=-1;return t=t.replace(/\[\]/gi,function(t){return r++,"["+e.$i[r]+"]"}),e.evalExpr(t,e)}}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r=e.has("$sanitize")?e.get("$sanitize"):function(e){return e};return{scope:!1,restrict:"EA",link:function(e,n,i){var a="";i.sfMessage&&e.$watch(i.sfMessage,function(t){t&&(a=r(t),c(!!e.ngModel))});var s,l=function(e){e!==s&&(n.html(e),s=e)},c=function(r){if(r)if(e.hasError()){var n=[];o.a.forEach(e.ngModel&&e.ngModel.$error,function(e,t){e&&n.push(t)}),n=n.filter(function(e){return"schemaForm"!==e});var i=n[0];l(i?t.interpolate(i,e.ngModel.$modelValue,e.ngModel.$viewValue,e.form,e.options&&e.options.validationMessage):a)}else l(a);else l(a)};c();var u=e.$watch("ngModel",function(e){e&&(e.$parsers.push(function(e){return c(!0),e}),e.$formatters.push(function(e){return c(!0),e}),u())});e.$watchCollection("ngModel.$error",function(){c(!!e.ngModel)})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r,n,i,a,s,l,c){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function(e){this.$onInit=function(){this.evalInParentScope=function(t,r){return e.$parent.$eval(t,r)};var t=this;e.lookup=function(e){return e&&(t.lookup=e),t.lookup}},1===o.a.version.major&&o.a.version.minor<5&&this.$onInit()}],replace:!1,restrict:"A",transclude:!0,require:"?form",link:function(l,u,f,d,p){l.formCtrl=d;var m={};p(l,function(e){if(e.addClass("schema-form-ignore"),u.prepend(e),u[0].querySelectorAll){var t=u[0].querySelectorAll("[ng-model]");if(t)for(var r=0;r<t.length;r++){var n=t[r].getAttribute("ng-model");m[n.substring(n.indexOf(".")+1)]=!0}}});var h,y={};l.resolveReferences=function(e,t){i.jsonref(e).then(function(e){l.render(e,t)}).catch(function(e){new Error(e)})},l.render=function(e,o){var a=[],s=i.merge(e,o,void 0,m,l.options,void 0,a);a.length>0?n.all(a.map(function(e){return t.get(e.templateUrl,{cache:r}).then(function(t){e.template=t.data})})).then(function(){l.internalRender(e,o,s)}):l.internalRender(e,o,s)},l.internalRender=function(t,r,n){h&&(l.externalDestructionInProgress=!0,h.$destroy(),l.externalDestructionInProgress=!1),h=l.$new(),h.schemaForm={form:n,schema:t},Array.prototype.forEach.call(u.children(),function(e){var t=o.a.element(e);!1===t.hasClass("schema-form-ignore")&&t.remove()});for(var d={},p=u[0].querySelectorAll("*[sf-insert-field]"),m=0;m<p.length;m++)d[p[m].getAttribute("sf-insert-field")]=p[m];var y=a.decorator(f.sfUseDecorator),v=Object.create(null);l.lookup(v),u[0].appendChild(c.build(n,y,d,v)),h.firstDigest=!0,setTimeout(function(){h.firstDigest=!1,l.$apply()},0),e(u.children())(h),l.options&&l.options.setSchemaDefaults===!1||i.traverseSchema(t,function(e,t){if(o.a.isDefined(e.default)){var r=s(t,l.model);o.a.isUndefined(r)&&s(t,l.model,e.default)}}),l.$emit("sf-render-finished",u)};var v=["*"];l.$watch(function(){var e=l.schema,t=l.initialForm||v;t&&e&&e.type&&(y.form!==t||y.schema!==e)&&((!e.properties||0===Object.keys(e.properties).length)&&(t.indexOf("*")||t.indexOf("...")),y.schema=e,y.form=t,l.resolveReferences(e,t))}),l.$on("schemaFormRedraw",function(){var e=l.schema,t=l.initialForm?o.a.copy(l.initialForm):["*"];e&&l.resolveReferences(e,t)}),l.$on("$destroy",function(){l.externalDestructionInProgress=!0}),l.evalExpr=function(e,t){return l.$parent.$eval(e,t)}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r="",n={},i=function(e,t){"sfDecorator"===e&&(e=r);var o=n[e];return o[t.type]?o[t.type].template:o.default.template},a=function(r){e.directive(r,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function(e,n,a,s,l,c,u,f,d){return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["?^sfSchema","?^form"],link:function(e,p,m,h){var y=h[0],v=h[1];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=e.parentKey||[];if(e.form.key){if("number"==typeof n[n.length-1]){var o=n.concat(e.form.key.slice(-1)),i=t&&v&&v.$name?v.$name:void 0;return f.name(o,"-",i,r)}var i=t&&v&&v.$name?v.$name:void 0;return f.name(e.form.key,"-",i,r)}return""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(y?y.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return y?y.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&l(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.ngModel.$invalid&&!e.ngModel.$pristine)},e.errorMessage=function(t){return u.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)};var g=e.$watch(m.form,function(l){if(l){l.ngModelOptions=l.ngModelOptions||{},e.form=l;var u;if("template"===l.type&&l.template)u=c.when(l.template);else{var m="template"===l.type?l.templateUrl:i(r,l);u=a.get(m,{cache:s}).then(function(e){return e.data})}u.then(function(r){if(l.key){var i=l.key?t.stringify(l.key).replace(/"/g,"&quot;"):"";r=r.replace(/\$\$value\$\$/g,"model"+("["!==i[0]?".":"")+i)}if(p.html(r),l.condition){var a='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';l.key&&(a='evalExpr(form.condition, {model: model, "arrayIndex": arrayIndex, "modelValue": model'+f.stringify(l.key)+"})"),o.a.forEach(p.children(),function(e){var t=e.getAttribute("ng-if");e.setAttribute("ng-if",t?"("+t+") || ("+a+")":a)})}n(p.contents())(e)}),l.key&&(e.$on("schemaForm.error."+l.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(l.validationMessage||(l.validationMessage={}),l.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){if(!e.externalDestructionInProgress){var t=l.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(l.key&&"retain"!==t){var r=e.model;if(l.key.length>1&&(r=d(l.key.slice(0,l.key.length-1),r)),void 0===r)return;var n=l.schema&&l.schema.type||"";"empty"===t&&n.indexOf("string")!==-1?r[l.key.slice(-1)]="":"empty"===t&&n.indexOf("object")!==-1?r[l.key.slice(-1)]={}:"empty"===t&&n.indexOf("array")!==-1?r[l.key.slice(-1)]=[]:"null"===t?r[l.key.slice(-1)]=null:delete r[l.key.slice(-1)]}}})),g()}})}}}])},s=function(t,r,n){n=!!o.a.isDefined(n)&&n,e.directive("sf"+o.a.uppercase(t[0])+t.substr(1),function(){return{restrict:"EAC",scope:!0,replace:!0,transclude:n,template:'<sf-decorator form="form"></sf-decorator>',link:function(e,r,n){var i={items:"c",titleMap:"c",schema:"c"},a={type:t},s=!0;o.a.forEach(n,function(t,r){
+if("$"!==r[0]&&0!==r.indexOf("ng")&&"sfField"!==r){var l=function(t){o.a.isDefined(t)&&t!==a[r]&&(a[r]=t,s&&a.type&&(a.key||o.a.isUndefined(n.key))&&(e.form=a,s=!1))};"model"===r?e.$watch(t,function(t){t&&e.model!==t&&(e.model=t)}):"c"===i[r]?e.$watchCollection(t,l):n.$observe(r,l)}})}}})};this.createDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){n[e][r]={template:t,replace:!1,builder:[]}}),n[r]||(r=e),a(e)},this.defineDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){t.builder=t.builder||[],t.replace=!o.a.isDefined(t.replace)||t.replace,n[e][r]=t}),n[r]||(r=e),a(e)},this.createDirective=s,this.createDirectives=function(e){o.a.forEach(e,function(e,t){s(t,e)})},this.decorator=function(e){return e=e||r,n[e]},this.addMapping=function(e,t,r,o,i){n[e]&&(n[e][t]={template:r,builder:o,replace:!!i})},this.defineAddOn=function(e,t,r,o){n[e]&&(n[e][t]={template:r,builder:o,replace:!0})},this.$get=function(){return{decorator:function(e){return n[e]||n[r]},defaultDecorator:r}},a("sfDecorator")}},function(e,t,r){"use strict";var n=r(0),o=(r.n(n),r(1));r.n(o);t.a=function(){var e=function(e){return e},t=o.schemaDefaults.createDefaults();this.defaults=t,this.stdFormObj=o.schemaDefaults.stdFormObj,this.defaultFormDefinition=o.schemaDefaults.defaultFormDefinition,this.postProcess=function(t){e=t},this.appendRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].push(t)},this.prependRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].unshift(t)},this.createStandardForm=o.schemaDefaults.stdFormObj,this.$get=function(){var t={},n=this.defaults;return t.jsonref=o.jsonref,t.defaults=function(e,t,r,i){var a=t||n;return o.schemaDefaults.defaultForm(e,a,r,i)},t.merge=function(n){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["*"],a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.typeDefault,s=arguments[3],l=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},c=arguments.length>5&&void 0!==arguments[5]&&arguments[5],u=arguments[6],f=r.i(o.merge)(n,i,a,s,l,c,u);return e(f)},t.typeDefault=n,t.traverseSchema=o.traverseSchema,t.traverseForm=o.traverseForm,t}}},function(e,t,r){"use strict";t.a=function(e){var t=/[A-Z]/g,r=function(e,r){return r=r||"_",e.replace(t,function(e,t){return(t?r:"")+e.toLowerCase()})},n=0;"firstElementChild"in document.createDocumentFragment()||Object.defineProperty(DocumentFragment.prototype,"firstElementChild",{get:function(){for(var e,t=this.childNodes,r=0,n=t.length;r<n;++r)if(e=t[r],1===e.nodeType)return e;return null}});var o={sfField:function(e){e.fieldFrag.firstElementChild.setAttribute("sf-field",n),e.lookup["f"+n]=e.form,n++},ngModel:function(t){if(t.form.key){var r=t.form.key;t.state.keyRedaction&&(r=r.slice(t.state.keyRedaction));var n;if(t.state.modelValue)n=t.state.modelValue;else{var o=e.stringify(r).replace(/"/g,"&quot;");n=t.state.modelName||"model",o&&(n+=("["!==o[0]?".":"")+o)}for(var i=t.fieldFrag.querySelectorAll("[sf-field-model]"),a=0;a<i.length;a++){var s=i[a],l=s.getAttribute("sf-field-model");if(l&&""!==l)if("replaceAll"===l)for(var c=s.attributes,u=0;u<c.length;u++)c[u].value&&c[u].value.indexOf("$$value")!==-1&&(c[u].value=c[u].value.replace(/\$\$value\$\$/g,n));else{var f=s.getAttribute(l);f&&f.indexOf("$$value$$")?s.setAttribute(l,f.replace(/\$\$value\$\$/g,n)):s.setAttribute(l,n)}else s.setAttribute("ng-model",n)}}},simpleTransclusion:function(e){var t=e.build(e.form.items,e.path+".items",e.state);e.fieldFrag.firstChild.appendChild(t)},ngModelOptions:function(e){e.form.ngModelOptions&&Object.keys(e.form.ngModelOptions).length>0&&e.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(e.form.ngModelOptions))},transclusion:function(e){var t=e.fieldFrag.querySelectorAll("[sf-field-transclude]");if(t.length)for(var r=0;r<t.length;r++){var n=t[r],o=n.getAttribute("sf-field-transclude")||"items",i=e.form[o];if(i){var a=e.build(i,e.path+"."+o,e.state);n.appendChild(a)}}},condition:function(t){var r="",n="undefined",o="";if(t.form.condition){t.form.key&&(r=e.stringify(t.form.key),n="model"+("["===r[0]?"":".")+r);for(var i="evalExpr("+t.path+'.condition, { model: model, "arrayIndex": $index, "arrayIndices": arrayIndices, "path": path, "$i": $i, "$index": $index, "modelValue": '+n+"})",a=t.fieldFrag.children||t.fieldFrag.childNodes,s=0;s<a.length;s++){var l=a[s];l.hasAttribute&&l.hasAttribute("ng-if")&&(o=l.getAttribute("ng-if")),l.setAttribute&&l.setAttribute("ng-if",o?"("+o+") || ("+i+")":i)}}},array:function(t){var r=t.fieldFrag.querySelector("[schema-form-array-items]");if(t.form.key){t.form.key.filter(function(e){return""===e}).length}if(r){var n=angular.copy(t.state);if(n.keyRedaction=0,n.keyRedaction+=t.form.key.length+1,t.form.schema&&t.form.schema.items&&t.form.schema.items.type&&t.form.schema.items.type.indexOf("object")===-1&&t.form.schema.items.type.indexOf("array")===-1){e.stringify(t.form.key).replace(/"/g,"&quot;")+"[$index]";n.modelValue="modelArray[$index]"}else n.modelName="item";n.arrayCompatFlag=!0;var o=t.build(t.form.items,t.path+".items",n);r.appendChild(o)}},numeric:function(e){var t=e.fieldFrag.querySelector("input"),r=e.form.maximum||!1,n=e.form.exclusiveMaximum||!1,o=e.form.minimum||!1,i=e.form.exclusiveMinimum||!1,a=e.form.multipleOf||!1;t&&(a!==!1&&t.setAttribute("step",a),r!==!1&&(n!==!1&&a!==!1&&(r-=a),t.setAttribute("max",r)),o!==!1&&(i!==!1&&a!==!1&&(o+=a),t.setAttribute("min",o)))}};this.builders=o;var i=[o.sfField,o.ngModel,o.ngModelOptions,o.condition];this.stdBuilders=i,this.$get=["$templateCache","schemaFormDecorators","sfPath",function(e,t,n){var a=function(e,t){if(e.key){var r=t[n.stringify(e.key)];if(r){for(;r.firstChild;)r.removeChild(r.firstChild);return r}}},s=function e(t,n,o,i,s,l,c){l=l||{},l=l||{},c=c||Object.create(null),s=s||"schemaForm.form";var u=document.createDocumentFragment();return t.reduce(function(t,u,f){if(!u.type)return t;var d=n[u.type]||n.default;if(d.replace){var p;l.arrayCompatFlag=!1;var m=document.createElement("div"),h=o(u,d)||o(u,n.default);for(m.innerHTML=h,p=document.createDocumentFragment();m.childNodes.length>0;)p.appendChild(m.childNodes[0]);var y={fieldFrag:p,form:u,lookup:c,state:l,path:s+"["+f+"]",build:function(t,r,a){return e(t,n,o,i,r,a,c)}},v=u.builder||d.builder;"function"==typeof v?v(y):v.forEach(function(e){e(y)}),(a(u,i)||t).appendChild(p)}else{var g=document.createElement(r(n.__name,"-"));l.arrayCompatFlag?g.setAttribute("form","copyWithIndex($index)"):g.setAttribute("form",s+"["+f+"]"),(a(u,i)||t).appendChild(g)}return t},u),u};return{build:function(t,r,n,o){return s(t,r,function(t,r){return"template"===t.type?t.template:e.get(r.template)},n,void 0,void 0,o)},builder:o,stdBuilders:i,internalBuild:s}}]}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){var e={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};e.number=e[105],e.required=e[302],e.min=e[101],e.max=e[103],e.maxlength=e[201],e.minlength=e[200],e.pattern=e[202],this.setDefaultMessages=function(t){e=t},this.getDefaultMessages=function(){return e},this.setDefaultMessage=function(t,r){e[t]=r},this.$get=["$interpolate",function(t){var r={};return r.defaultMessages=e,r.interpolate=function(r,n,i,a,s){s=s||{};var l=a.validationMessage||{};0===r.indexOf("tv4-")&&(r=r.substring(4));var c=l.default||s.default||"";[l,s,e].some(function(e){return o.a.isString(e)||o.a.isFunction(e)?(c=e,!0):e&&e[r]?(c=e[r],!0):void 0});var u={error:r,value:n,viewValue:i,form:a,schema:a.schema,title:a.title||a.schema&&a.schema.title};return o.a.isFunction(c)?c(u):t(c)(u)},r}]}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=r(1),i=(r.n(o),r(0)),a=(r.n(i),function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}()),s=function(){function e(){n(this,e),this.name=o.sfPath.name,this.parse=o.sfPath.parse,this.stringify=o.sfPath.stringify,this.normalize=o.sfPath.normalize}return a(e,[{key:"$get",value:function(){return o.sfPath}}]),e}();t.a=s},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):y=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++y<t;)p&&p[y].run();y=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,y=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},function(e,t,r){(function(e,t){!function(e,r){"use strict";function n(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var n={callback:e,args:t};return h[m]=n,p(m),m++}function o(e){delete h[e]}function i(e){var t=e.callback,n=e.args;switch(n.length){case 0:t();break;case 1:t(n[0]);break;case 2:t(n[0],n[1]);break;case 3:t(n[0],n[1],n[2]);break;default:t.apply(r,n)}}function a(e){if(y)setTimeout(a,0,e);else{var t=h[e];if(t){y=!0;try{i(t)}finally{o(e),y=!1}}}}function s(){p=function(e){t.nextTick(function(){a(e)})}}function l(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}function c(){var t="setImmediate$"+Math.random()+"$",r=function(r){r.source===e&&"string"==typeof r.data&&0===r.data.indexOf(t)&&a(+r.data.slice(t.length))};e.addEventListener?e.addEventListener("message",r,!1):e.attachEvent("onmessage",r),p=function(r){e.postMessage(t+r,"*")}}function u(){var e=new MessageChannel;e.port1.onmessage=function(e){var t=e.data;a(t)},p=function(t){e.port2.postMessage(t)}}function f(){var e=v.documentElement;p=function(t){var r=v.createElement("script");r.onreadystatechange=function(){a(t),r.onreadystatechange=null,e.removeChild(r),r=null},e.appendChild(r)}}function d(){p=function(e){setTimeout(a,0,e)}}if(!e.setImmediate){var p,m=1,h={},y=!1,v=e.document,g=Object.getPrototypeOf&&Object.getPrototypeOf(e);g=g&&g.setTimeout?g:e,"[object process]"==={}.toString.call(e.process)?s():l()?c():e.MessageChannel?u():v&&"onreadystatechange"in v.createElement("script")?f():d(),g.setImmediate=n,g.clearImmediate=o}}("undefined"==typeof self?"undefined"==typeof e?this:e:self)}).call(t,r(2),r(16))},function(r,n,o){function i(e,t){this._id=e,this._clearFn=t}var a=Function.prototype.apply;n.setTimeout=function(){return new i(a.call(setTimeout,window,arguments),clearTimeout)},n.setInterval=function(){return new i(a.call(setInterval,window,arguments),clearInterval)},n.clearTimeout=n.clearInterval=function(e){e&&e.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(window,this._id)},n.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},n.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},n._unrefActive=n.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},o(17),n.setImmediate=e,n.clearImmediate=t},function(e,t,r){r(1),e.exports=r(3)}])}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):y=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++y<t;)p&&p[y].run();y=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,y=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},,,function(e,t,r){r(19),e.exports=r(0)}]);
\ No newline at end of file
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index cf0bd68..f5b5353 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.3
- * @date Sun, 02 Apr 2017 13:11:20 GMT
+ * @version 1.0.0-alpha.4
+ * @date Mon, 03 Apr 2017 13:11:24 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -94,7 +94,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/array.html';
-var html = "<div  class=\"schema-form-array {{::form.htmlClass + ' ' + idClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $id(item)\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray($index)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
+var html = "<div  class=\"schema-form-array {{::form.htmlClass + ' ' + idClass}}\"\r\n      sf-field-model=\"sf-new-array\"\r\n      sf-new-array>\r\n  <label class=\"control-label\" ng-show=\"showTitle()\">{{ form.title }}</label>\r\n  <ol class=\"list-group\" sf-field-model ui-sortable=\"form.sortOptions\">\r\n    <li class=\"list-group-item {{::form.fieldHtmlClass}}\"\r\n        sf-field-model=\"ng-repeat\"\r\n        ng-repeat=\"item in $$value$$ track by $id(trackBy(item, $index))\">\r\n      <button ng-hide=\"form.readonly || form.remove === null\"\r\n              ng-click=\"deleteFromArray(item)\"\r\n              ng-disabled=\"form.schema.minItems >= modelArray.length\"\r\n              style=\"position: relative; z-index: 20;\"\r\n              type=\"button\" class=\"close pull-right\">\r\n              <span aria-hidden=\"true\">&times;</span><span class=\"sr-only\">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\"></div>\r\n    </li>\r\n  </ol>\r\n  <div class=\"clearfix\" style=\"padding: 15px;\" ng-model=\"modelArray\" schema-validate=\"form\">\r\n    <div class=\"help-block\"\r\n         ng-show=\"(hasError() && errorMessage(schemaError())) || form.description\"\r\n         ng-bind-html=\"(hasError() && errorMessage(schemaError())) || form.description\"></div>\r\n\r\n    <button ng-hide=\"form.readonly || form.add === null\"\r\n            ng-click=\"appendToArray()\"\r\n            ng-disabled=\"form.schema.maxItems <= modelArray.length\"\r\n            type=\"button\"\r\n            class=\"btn {{ form.style.add || 'btn-default' }} pull-right\">\r\n      <i class=\"glyphicon glyphicon-plus\"></i>\r\n      {{ form.add || 'Add'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
diff --git a/dist/angular-schema-form-bootstrap.min.js b/dist/angular-schema-form-bootstrap.min.js
index 1407139..5fdcba0 100644
--- a/dist/angular-schema-form-bootstrap.min.js
+++ b/dist/angular-schema-form-bootstrap.min.js
@@ -1,9 +1,9 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.3
- * @date Sun, 02 Apr 2017 13:11:20 GMT
+ * @version 1.0.0-alpha.4
+ * @date Mon, 03 Apr 2017 13:11:24 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function r(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return e[a].call(l.exports,l,l.exports,r),l.l=!0,l.exports}var n={};return r.m=e,r.c=n,r.i=function(e){return e},r.d=function(e,r,n){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=24)}([function(e,r,n){n(18)},,function(e,r){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(item)">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray($index)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r,n){"use strict";function a(e,r,n,a,l){var s=n.builders.simpleTransclusion,i=n.builders.ngModelOptions,m=n.builders.ngModel,c=n.builders.sfField,p=n.builders.condition,h=n.builders.array,v=n.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var r=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(n,a){var l="(evalExpr("+e.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=e.build(n.items,e.path+".tabs["+a+"].items",e.state);t.appendChild(s),r.appendChild(t)})}},C=function(e){if(e.form.placeholder){var r=e.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=e.form.placeholder,r.appendChild(n)}},k=[c,m,i,p];r.defineDecorator("bootstrapDecorator",{actions:{template:t.a,builder:k},array:{template:o.a,builder:[c,i,m,h,p]},button:{template:H.a,builder:k},checkbox:{template:d.a,builder:k},checkboxes:{template:f.a,builder:[c,i,m,h,p]},conditional:{template:A.a,builder:[c,s,p]},default:{template:u.a,builder:k},fieldset:{template:b.a,builder:[c,s,p]},help:{template:g.a,builder:k},number:{template:u.a,builder:k.concat(v)},password:{template:u.a,builder:k},radios:{template:$.a,builder:k},"radios-inline":{template:w.a,builder:k},radiobuttons:{template:y.a,builder:k},section:{template:A.a,builder:[c,s,p]},select:{template:E.a,builder:k.concat(C)},submit:{template:H.a,builder:k},tabarray:{template:M.a,builder:[c,i,m,h,p]},tabs:{template:L.a,builder:[c,i,x,p]},textarea:{template:D.a,builder:k}},[])}var l=n(2),t=n.n(l),s=n(3),o=n.n(s),i=n(4),d=n.n(i),m=n(5),f=n.n(m),c=n(6),u=n.n(c),p=n(7),b=n.n(p),h=n(8),g=n.n(h),v=n(9),y=n.n(v),x=n(11),$=n.n(x),C=n(10),w=n.n(C),k=n(12),A=n.n(k),S=n(13),E=n.n(S),I=n(14),H=n.n(I),T=n(15),M=n.n(T),R=n(16),L=n.n(R),j=n(17),D=n.n(j);angular.module("schemaForm").config(a),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,,function(e,r,n){e.exports=n(0)}]);
\ No newline at end of file
+!function(e){function r(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return e[a].call(l.exports,l,l.exports,r),l.l=!0,l.exports}var n={};return r.m=e,r.c=n,r.i=function(e){return e},r.d=function(e,r,n){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=24)}([function(e,r,n){n(18)},,function(e,r){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r,n){"use strict";function a(e,r,n,a,l){var s=n.builders.simpleTransclusion,i=n.builders.ngModelOptions,m=n.builders.ngModel,c=n.builders.sfField,p=n.builders.condition,h=n.builders.array,v=n.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var r=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(n,a){var l="(evalExpr("+e.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=e.build(n.items,e.path+".tabs["+a+"].items",e.state);t.appendChild(s),r.appendChild(t)})}},C=function(e){if(e.form.placeholder){var r=e.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=e.form.placeholder,r.appendChild(n)}},k=[c,m,i,p];r.defineDecorator("bootstrapDecorator",{actions:{template:t.a,builder:k},array:{template:o.a,builder:[c,i,m,h,p]},button:{template:H.a,builder:k},checkbox:{template:d.a,builder:k},checkboxes:{template:f.a,builder:[c,i,m,h,p]},conditional:{template:A.a,builder:[c,s,p]},default:{template:u.a,builder:k},fieldset:{template:b.a,builder:[c,s,p]},help:{template:g.a,builder:k},number:{template:u.a,builder:k.concat(v)},password:{template:u.a,builder:k},radios:{template:$.a,builder:k},"radios-inline":{template:w.a,builder:k},radiobuttons:{template:y.a,builder:k},section:{template:A.a,builder:[c,s,p]},select:{template:E.a,builder:k.concat(C)},submit:{template:H.a,builder:k},tabarray:{template:M.a,builder:[c,i,m,h,p]},tabs:{template:L.a,builder:[c,i,x,p]},textarea:{template:D.a,builder:k}},[])}var l=n(2),t=n.n(l),s=n(3),o=n.n(s),i=n(4),d=n.n(i),m=n(5),f=n.n(m),c=n(6),u=n.n(c),p=n(7),b=n.n(p),h=n(8),g=n.n(h),v=n(9),y=n.n(v),x=n(11),$=n.n(x),C=n(10),w=n.n(C),k=n(12),A=n.n(k),S=n(13),E=n.n(S),I=n(14),H=n.n(I),T=n(15),M=n.n(T),R=n(16),L=n.n(R),j=n(17),D=n.n(j);angular.module("schemaForm").config(a),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,,function(e,r,n){e.exports=n(0)}]);
\ No newline at end of file
diff --git a/src/bootstrap/array.html b/src/bootstrap/array.html
index fad8312..f9c6c35 100644
--- a/src/bootstrap/array.html
+++ b/src/bootstrap/array.html
@@ -5,9 +5,9 @@
   <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">
     <li class="list-group-item {{::form.fieldHtmlClass}}"
         sf-field-model="ng-repeat"
-        ng-repeat="item in $$value$$ track by $id(item)">
+        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">
       <button ng-hide="form.readonly || form.remove === null"
-              ng-click="deleteFromArray($index)"
+              ng-click="deleteFromArray(item)"
               ng-disabled="form.schema.minItems >= modelArray.length"
               style="position: relative; z-index: 20;"
               type="button" class="close pull-right">

From dad0be4fb2850ed58af6739c9a8bbff4cece1920 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Mon, 17 Apr 2017 19:03:44 +1000
Subject: [PATCH 46/50] Fixes #41 thanks to @ramakrij

---
 dist/angular-schema-form-bootstrap-bundled.js | 115 ++++++++++--------
 ...gular-schema-form-bootstrap-bundled.min.js |  16 +--
 dist/angular-schema-form-bootstrap.js         |  18 +--
 dist/angular-schema-form-bootstrap.min.js     |   4 +-
 src/bootstrap-decorator.js                    |  16 +--
 5 files changed, 89 insertions(+), 80 deletions(-)

diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index 6268dfe..cbe22a9 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.4
- * @date Mon, 03 Apr 2017 13:11:24 GMT
+ * @date Mon, 17 Apr 2017 08:57:43 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -434,24 +434,24 @@ function bootstrapDecoratorConfig(
   var defaults = [sfField, ngModel, ngModelOptions, condition];
   decoratorsProvider.defineDecorator('bootstrapDecorator', {
     actions: {template: __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html___default.a, builder: defaults},
-    array: {template: __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    array: {template: __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html___default.a, builder: [ sfField, ngModelOptions, ngModel, array, condition ]},
     button: {template: __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html___default.a, builder: defaults},
     checkbox: {template: __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html___default.a, builder: defaults},
-    checkboxes: {template: __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    conditional: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    checkboxes: {template: __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html___default.a, builder: [ sfField, ngModelOptions, ngModel, array, condition ]},
+    conditional: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default.a, builder: [ sfField, simpleTransclusion, condition ]},
     'default': {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default.a, builder: defaults},
-    fieldset: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    fieldset: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html___default.a, builder: [ sfField, simpleTransclusion, condition ]},
     help: {template: __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html___default.a, builder: defaults},
     number: {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default.a, builder: defaults.concat(numeric)},
     password: {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default.a, builder: defaults},
     radios: {template: __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html___default.a, builder: defaults},
     'radios-inline': {template: __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html___default.a, builder: defaults},
     radiobuttons: {template: __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html___default.a, builder: defaults},
-    section: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
-    select: {template: __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html___default.a, builder: defaults.concat(selectPlaceholder)},
+    section: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default.a, builder: [ sfField, simpleTransclusion, condition ]},
+    select: {template: __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html___default.a, builder: [ selectPlaceholder ].concat(defaults)},
     submit: {template: __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html___default.a, builder: defaults},
-    tabarray: {template: __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    tabs: {template: __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html___default.a, builder: [sfField, ngModelOptions, tabs, condition]},
+    tabarray: {template: __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html___default.a, builder: [ sfField, ngModelOptions, ngModel, array, condition ]},
+    tabs: {template: __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html___default.a, builder: [ sfField, ngModelOptions, tabs, condition ]},
     textarea: {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html___default.a, builder: defaults},
   }, []);
 };
@@ -464,7 +464,7 @@ function bootstrapDecoratorConfig(
 /* WEBPACK VAR INJECTION */(function(setImmediate, clearImmediate) {/*!
  * angular-schema-form
  * @version 1.0.0-alpha.4
- * @date Mon, 03 Apr 2017 12:57:49 GMT
+ * @date Mon, 17 Apr 2017 08:55:13 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -534,7 +534,7 @@ function bootstrapDecoratorConfig(
 /******/ 	__webpack_require__.p = "";
 /******/
 /******/ 	// Load entry module and return exports
-/******/ 	return __webpack_require__(__webpack_require__.s = 19);
+/******/ 	return __webpack_require__(__webpack_require__.s = 21);
 /******/ })
 /************************************************************************/
 /******/ ([
@@ -549,8 +549,8 @@ module.exports = angular;
 
 /* WEBPACK VAR INJECTION */(function(global, setImmediate) {/*!
  * json-schema-form-core
- * @version 1.0.0-alpha.3
- * @date Mon, 27 Mar 2017 13:05:31 GMT
+ * @version 1.0.0-alpha.4
+ * @date Sat, 15 Apr 2017 08:25:55 GMT
  * @link https://github.com/json-schema-form/json-schema-form-core
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -3059,7 +3059,7 @@ function validate(form, value) {
   };
 
   var valueWrap = {};
-  if (!!value) {
+  if (typeof value !== 'undefined') {
     valueWrap[propName] = value;
   };
 
@@ -3192,7 +3192,7 @@ module.exports = __webpack_require__(4);
 /***/ })
 /******/ ]);
 //# sourceMappingURL=json-schema-form-core.js.map
-/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(2), __webpack_require__(18).setImmediate))
+/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(2), __webpack_require__(19).setImmediate))
 
 /***/ }),
 /* 2 */
@@ -3222,7 +3222,8 @@ module.exports = g;
 
 
 /***/ }),
-/* 3 */
+/* 3 */,
+/* 4 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -3231,18 +3232,18 @@ Object.defineProperty(__webpack_exports__, "__esModule", { value: true });
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_json_schema_form_core___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_json_schema_form_core__);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_angular__ = __webpack_require__(0);
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_1_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_1_angular__);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_sf_builder_provider__ = __webpack_require__(13);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_schema_form_decorators_provider__ = __webpack_require__(11);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_schema_form_provider__ = __webpack_require__(12);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_sf_error_message_provider__ = __webpack_require__(14);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_sf_path_provider__ = __webpack_require__(15);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__ = __webpack_require__(6);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__ = __webpack_require__(7);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__ = __webpack_require__(9);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__ = __webpack_require__(5);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__ = __webpack_require__(8);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__ = __webpack_require__(10);
-/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__ = __webpack_require__(4);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_2_sf_builder_provider__ = __webpack_require__(14);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_3_schema_form_decorators_provider__ = __webpack_require__(12);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_4_schema_form_provider__ = __webpack_require__(13);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_5_sf_error_message_provider__ = __webpack_require__(15);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_6_sf_path_provider__ = __webpack_require__(16);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__ = __webpack_require__(7);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__ = __webpack_require__(8);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__ = __webpack_require__(10);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__ = __webpack_require__(6);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__ = __webpack_require__(9);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__ = __webpack_require__(11);
+/* harmony import */ var __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__ = __webpack_require__(5);
 
 
 
@@ -3296,7 +3297,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 .directive('sfChanged', __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__["a" /* default */]).directive('sfField', ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__["a" /* default */]]).directive('sfMessage', ['$injector', 'sfErrorMessage', __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__["a" /* default */]]).directive('sfNewArray', ['sfSelect', 'sfPath', 'schemaForm', __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__["a" /* default */]]).directive('sfSchema', ['$compile', '$http', '$templateCache', '$q', 'schemaForm', 'schemaFormDecorators', 'sfSelect', 'sfPath', 'sfBuilder', __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__["a" /* default */]]).directive('schemaValidate', ['sfValidator', '$parse', 'sfSelect', __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__["a" /* default */]]).directive('sfKeyController', ['schemaForm', 'sfPath', __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__["a" /* default */]]);
 
 /***/ }),
-/* 4 */
+/* 5 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -3486,7 +3487,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 };
 
 /***/ }),
-/* 5 */
+/* 6 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -3653,12 +3654,14 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
                 });
               }
             }
-          } else if (items.type && items.type.indexOf('array') !== -1) {
-            empty = [];
-            if (!scope.options || scope.options.setSchemaDefaults !== false) {
-              empty = items['default'] || empty;
-            }
           } else {
+            if (items.type) {
+              if (items.type.indexOf('array') !== -1) {
+                empty = [];
+              } else if (items.type.indexOf('string') !== -1 || items.type.indexOf('number') !== -1) {
+                empty = '';
+              }
+            }
             // No type? could still have defaults.
             if (!scope.options || scope.options.setSchemaDefaults !== false) {
               empty = items['default'] || empty;
@@ -3693,6 +3696,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
           }
         };
       };
+
       var formDefCache = {};
       scope.copyWithIndex = function (index) {
         var form = scope.form;
@@ -3730,7 +3734,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
 };
 
 /***/ }),
-/* 6 */
+/* 7 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -3776,7 +3780,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
 };
 
 /***/ }),
-/* 7 */
+/* 8 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -4064,7 +4068,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
             var arrayIndex = typeof scope.arrayIndex == 'number' ? scope.arrayIndex + 1 : 0;
 
             // If the entire schema form is destroyed we don't touch the model
-            if (!scope.externalDestructionInProgress && (!scope.model.$$hashKey || scope.model.$$hashKey === scope.destroyed)) {
+            if (!scope.externalDestructionInProgress) {
               var destroyStrategy = form.destroyStrategy || scope.options && scope.options.destroyStrategy || 'remove';
               // No key no model, and we might have strategy 'retain'
               if (key && destroyStrategy !== 'retain') {
@@ -4075,6 +4079,10 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
                   obj = sfSelect(key.slice(0, key.length - 1), obj);
                 }
 
+                if (obj && scope.destroyed && obj.$$hashKey && obj.$$hashKey !== scope.destroyed) {
+                  return;
+                }
+
                 // We can get undefined here if the form hasn't been filled out entirely
                 if (obj === undefined) {
                   return;
@@ -4106,7 +4114,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
 };
 
 /***/ }),
-/* 8 */
+/* 9 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -4145,7 +4153,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
 };;
 
 /***/ }),
-/* 9 */
+/* 10 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -4249,7 +4257,7 @@ var _typeof = typeof Symbol === "function" && typeof Symbol.iterator === "symbol
 };
 
 /***/ }),
-/* 10 */
+/* 11 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -4479,7 +4487,7 @@ FIXME: real documentation
 };
 
 /***/ }),
-/* 11 */
+/* 12 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -5022,7 +5030,7 @@ FIXME: real documentation
 };;
 
 /***/ }),
-/* 12 */
+/* 13 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -5161,7 +5169,7 @@ FIXME: real documentation
 };
 
 /***/ }),
-/* 13 */
+/* 14 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -5489,7 +5497,7 @@ FIXME: real documentation
 };
 
 /***/ }),
-/* 14 */
+/* 15 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -5626,7 +5634,7 @@ FIXME: real documentation
 };
 
 /***/ }),
-/* 15 */
+/* 16 */
 /***/ (function(module, __webpack_exports__, __webpack_require__) {
 
 "use strict";
@@ -5666,7 +5674,7 @@ var sfPathProviderClass = function () {
 /* harmony default export */ __webpack_exports__["a"] = sfPathProviderClass;
 
 /***/ }),
-/* 16 */
+/* 17 */
 /***/ (function(module, exports) {
 
 // shim for using process in browser
@@ -5852,7 +5860,7 @@ process.umask = function() { return 0; };
 
 
 /***/ }),
-/* 17 */
+/* 18 */
 /***/ (function(module, exports, __webpack_require__) {
 
 /* WEBPACK VAR INJECTION */(function(global, process) {(function (global, undefined) {
@@ -6042,10 +6050,10 @@ process.umask = function() { return 0; };
     attachTo.clearImmediate = clearImmediate;
 }(typeof self === "undefined" ? typeof global === "undefined" ? this : global : self));
 
-/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(2), __webpack_require__(16)))
+/* WEBPACK VAR INJECTION */}.call(exports, __webpack_require__(2), __webpack_require__(17)))
 
 /***/ }),
-/* 18 */
+/* 19 */
 /***/ (function(module, exports, __webpack_require__) {
 
 var apply = Function.prototype.apply;
@@ -6098,17 +6106,18 @@ exports._unrefActive = exports.active = function(item) {
 };
 
 // setimmediate attaches itself to the global object
-__webpack_require__(17);
+__webpack_require__(18);
 exports.setImmediate = setImmediate;
 exports.clearImmediate = clearImmediate;
 
 
 /***/ }),
-/* 19 */
+/* 20 */,
+/* 21 */
 /***/ (function(module, exports, __webpack_require__) {
 
 __webpack_require__(1);
-module.exports = __webpack_require__(3);
+module.exports = __webpack_require__(4);
 
 
 /***/ })
diff --git a/dist/angular-schema-form-bootstrap-bundled.min.js b/dist/angular-schema-form-bootstrap-bundled.min.js
index 33f0b9e..6846ca6 100644
--- a/dist/angular-schema-form-bootstrap-bundled.min.js
+++ b/dist/angular-schema-form-bootstrap-bundled.min.js
@@ -1,23 +1,23 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.4
- * @date Mon, 03 Apr 2017 13:11:24 GMT
+ * @date Mon, 17 Apr 2017 08:57:43 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,y=r.builders.array,g=r.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},E=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,y,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,y,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:v.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:w.a,builder:C},"radios-inline":{template:$.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:C.concat(E)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,y,m]},tabs:{template:I.a,builder:[d,l,x,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),y=r(8),v=r.n(y),g=r(9),b=r.n(g),x=r(11),w=r.n(x),E=r(10),$=r.n(E),C=r(12),k=r.n(C),O=r(13),T=r.n(O),A=r(14),S=r.n(A),P=r(15),M=r.n(P),j=r(16),I=r.n(j),D=r(17),_=r.n(D);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
+!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,y=r.builders.array,g=r.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},E=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,y,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,y,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:v.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:w.a,builder:C},"radios-inline":{template:$.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:[E].concat(C)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,y,m]},tabs:{template:I.a,builder:[d,l,x,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),y=r(8),v=r.n(y),g=r(9),b=r.n(g),x=r(11),w=r.n(x),E=r(10),$=r.n(E),C=r(12),k=r.n(C),O=r(13),T=r.n(O),A=r(14),S=r.n(A),P=r(15),M=r.n(P),j=r(16),I=r.n(j),D=r(17),_=r.n(D);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
  * angular-schema-form
  * @version 1.0.0-alpha.4
- * @date Mon, 03 Apr 2017 12:57:49 GMT
+ * @date Mon, 17 Apr 2017 08:55:13 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=19)}([function(e,t){e.exports=angular},function(e,t,r){(function(t,r){/*!
+!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=21)}([function(e,t){e.exports=angular},function(e,t,r){(function(t,r){/*!
  * json-schema-form-core
- * @version 1.0.0-alpha.3
- * @date Mon, 27 Mar 2017 13:05:31 GMT
+ * @version 1.0.0-alpha.4
+ * @date Sat, 15 Apr 2017 08:25:55 GMT
  * @link https://github.com/json-schema-form/json-schema-form-core
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -35,5 +35,5 @@ e.exports=function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,
  * @see http://github.com/garycourt/uri-js
  * @license URI.js v2.0.0 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js
  */
-var n=!1,o=!0,i=!0,a=function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(r){var n="[A-Za-z]",o="[0-9]",a=e(o,"[A-Fa-f]"),s=t(t("%[EFef]"+a+"%"+a+a+"%"+a+a)+"|"+t("%[89A-Fa-f]"+a+"%"+a+a)+"|"+t("%"+a+a)),l="[\\:\\/\\?\\#\\[\\]\\@]",c="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",u=e(l,c),f=r?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",d=r?"[\\uE000-\\uF8FF]":"[]",p=e(n,o,"[\\-\\.\\_\\~]",f),m=t(n+e(n,o,"[\\+\\-\\.]")+"*"),h=t(t(s+"|"+e(p,c,"[\\:]"))+"*"),y=t(t("25[0-5]")+"|"+t("2[0-4]"+o)+"|"+t("1"+o+o)+"|"+t("[1-9]"+o)+"|"+o),v=t(y+"\\."+y+"\\."+y+"\\."+y),g=t(a+"{1,4}"),b=(t(t(g+"\\:"+g)+"|"+v),t(e(p,c,"[\\:]")+"+")),x=t("v"+a+"+\\."+e(p,c,"[\\:]")+"+"),w=t("\\["+t(b+"|"+x)+"\\]"),E=t(t(s+"|"+e(p,c))+"*"),$=t(w+"|"+v+"(?!"+E+")|"+E),C=t(o+"*"),k=t(t(h+"@")+"?"+$+t("\\:"+C)+"?"),O=t(s+"|"+e(p,c,"[\\:\\@]")),T=t(O+"*"),A=t(O+"+"),S=t(t(s+"|"+e(p,c,"[\\@]"))+"+"),P=t(t("\\/"+T)+"*"),M=t("\\/"+t(A+P)+"?"),j=t(S+P),I=t(A+P),D="(?!"+O+")",_=(t(P+"|"+M+"|"+j+"|"+I+"|"+D),t(t(O+"|"+e("[\\/\\?]",d))+"*")),F=t(t(O+"|[\\/\\?]")+"*"),R=t(t("\\/\\/"+k+P)+"|"+M+"|"+I+"|"+D),q=t(m+"\\:"+R+t("\\?"+_)+"?"+t("\\#"+F)+"?"),U=t(t("\\/\\/"+k+P)+"|"+M+"|"+j+"|"+D),N=t(U+t("\\?"+_)+"?"+t("\\#"+F)+"?"),L=(t(q+"|"+N),t(m+"\\:"+R+t("\\?"+_)+"?"),"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+I+"|"+D+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$"),H="^(){0}"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+j+"|"+D+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$";"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+I+"|"+D+")")+t("\\?("+_+")")+"?$","^"+t("\\#("+F+")")+"?$","^"+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?$";return{URI_REF:i&&new RegExp("("+L+")|("+H+")"),NOT_SCHEME:new RegExp(e("[^]",n,o,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(e("[^\\%\\:]",p,c),"g"),NOT_HOST:new RegExp(e("[^\\%]",p,c),"g"),NOT_PATH:new RegExp(e("[^\\%\\/\\:\\@]",p,c),"g"),NOT_PATH_NOSCHEME:new RegExp(e("[^\\%\\/\\@]",p,c),"g"),NOT_QUERY:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]",d),"g"),NOT_FRAGMENT:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(e("[^]",p,c),"g"),UNRESERVED:new RegExp(p,"g"),OTHER_CHARS:new RegExp(e("[^\\%]",p,u),"g"),PCT_ENCODED:new RegExp(s,"g")}}function n(e){var t,r=e.charCodeAt(0);return t=r<16?"%0"+r.toString(16).toUpperCase():r<128?"%"+r.toString(16).toUpperCase():r<2048?"%"+(r>>6|192).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase():"%"+(r>>12|224).toString(16).toUpperCase()+"%"+(r>>6&63|128).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase()}function a(e){for(var t,r,n,o="",i=0,a=e.length;i<a;)t=parseInt(e.substr(i+1,2),16),t<128?(o+=String.fromCharCode(t),i+=3):t>=194&&t<224?(a-i>=6?(r=parseInt(e.substr(i+4,2),16),o+=String.fromCharCode((31&t)<<6|63&r)):o+=e.substr(i,6),i+=6):t>=224?(a-i>=9?(r=parseInt(e.substr(i+4,2),16),n=parseInt(e.substr(i+7,2),16),o+=String.fromCharCode((15&t)<<12|(63&r)<<6|63&n)):o+=e.substr(i,9),i+=9):(o+=e.substr(i,3),i+=3);return o}function l(e){return void 0===e?"undefined":null===e?"null":Object.prototype.toString.call(e).split(" ").pop().split("]").shift().toLowerCase()}function c(e){return e.toUpperCase()}function u(e,t){function r(e){var r=a(e);return r.match(t.UNRESERVED)?r:e}return e.scheme&&(e.scheme=String(e.scheme).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_SCHEME,"")),void 0!==e.userinfo&&(e.userinfo=String(e.userinfo).replace(t.PCT_ENCODED,r).replace(t.NOT_USERINFO,n).replace(t.PCT_ENCODED,c)),void 0!==e.host&&(e.host=String(e.host).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_HOST,n).replace(t.PCT_ENCODED,c)),void 0!==e.path&&(e.path=String(e.path).replace(t.PCT_ENCODED,r).replace(e.scheme?t.NOT_PATH:t.NOT_PATH_NOSCHEME,n).replace(t.PCT_ENCODED,c)),void 0!==e.query&&(e.query=String(e.query).replace(t.PCT_ENCODED,r).replace(t.NOT_QUERY,n).replace(t.PCT_ENCODED,c)),void 0!==e.fragment&&(e.fragment=String(e.fragment).replace(t.PCT_ENCODED,r).replace(t.NOT_FRAGMENT,n).replace(t.PCT_ENCODED,c)),e}function f(e,t){void 0===t&&(t={});var r,n,l=o&&t.iri!==!1?E:w,c=!1,f={};if("suffix"===t.reference&&(e=(t.scheme?t.scheme+":":"")+"//"+e),i?(r=e.match(l.URI_REF),r&&(r=r[1]?r.slice(1,10):r.slice(10,19)),r||(c=!0,t.tolerant||(f.error=f.error||"URI is not strictly valid."),r=e.match($))):r=e.match($),r){if(A?(f.scheme=r[1],f.userinfo=r[3],f.host=r[4],f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=r[7],f.fragment=r[8],isNaN(f.port)&&(f.port=r[5])):(f.scheme=r[1]||void 0,f.userinfo=e.indexOf("@")!==-1?r[3]:void 0,f.host=e.indexOf("//")!==-1?r[4]:void 0,f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=e.indexOf("?")!==-1?r[7]:void 0,f.fragment=e.indexOf("#")!==-1?r[8]:void 0,isNaN(f.port)&&(f.port=e.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?r[4]:void 0)),void 0!==f.scheme||void 0!==f.userinfo||void 0!==f.host||void 0!==f.port||f.path||void 0!==f.query?void 0===f.scheme?f.reference="relative":void 0===f.fragment?f.reference="absolute":f.reference="uri":f.reference="same-document",t.reference&&"suffix"!==t.reference&&t.reference!==f.reference&&(f.error=f.error||"URI is not a "+t.reference+" reference."),n=S[(t.scheme||f.scheme||"").toLowerCase()],!o||"undefined"==typeof s||t.unicodeSupport||n&&n.unicodeSupport)u(f,l);else{if(f.host&&(t.domainHost||n&&n.domainHost))try{f.host=s.toASCII(f.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(e){f.error=f.error||"Host's domain name can not be converted to ASCII via punycode: "+e}u(f,w)}n&&n.parse&&n.parse(f,t)}else c=!0,f.error=f.error||"URI can not be parsed.";return f}function d(e,t){var r=[];return void 0!==e.userinfo&&(r.push(e.userinfo),r.push("@")),void 0!==e.host&&r.push(e.host),"number"==typeof e.port&&(r.push(":"),r.push(e.port.toString(10))),r.length?r.join(""):void 0}function p(e){for(var t,r=[];e.length;)e.match(C)?e=e.replace(C,""):e.match(k)?e=e.replace(k,"/"):e.match(O)?(e=e.replace(O,"/"),r.pop()):"."===e||".."===e?e="":(t=e.match(T)[0],e=e.slice(t.length),r.push(t));return r.join("")}function m(e,t){void 0===t&&(t={});var r,n,i,l=o&&t.iri?E:w,c=[];if(r=S[(t.scheme||e.scheme||"").toLowerCase()],r&&r.serialize&&r.serialize(e,t),o&&"undefined"!=typeof s&&e.host&&(t.domainHost||r&&r.domainHost))try{e.host=t.iri?s.toUnicode(e.host):s.toASCII(e.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(r){e.error=e.error||"Host's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}return u(e,l),"suffix"!==t.reference&&e.scheme&&(c.push(e.scheme),c.push(":")),n=d(e,t),void 0!==n&&("suffix"!==t.reference&&c.push("//"),c.push(n),e.path&&"/"!==e.path.charAt(0)&&c.push("/")),void 0!==e.path&&(i=e.path,t.absolutePath||r&&r.absolutePath||(i=p(i)),void 0===n&&(i=i.replace(/^\/\//,"/%2F")),c.push(i)),void 0!==e.query&&(c.push("?"),c.push(e.query)),void 0!==e.fragment&&(c.push("#"),c.push(e.fragment)),c.join("")}function h(e,t,r,n){void 0===r&&(r={});var o={};return n||(e=f(m(e,r),r),t=f(m(t,r),r)),r=r||{},!r.tolerant&&t.scheme?(o.scheme=t.scheme,o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(t.path?("/"===t.path.charAt(0)?o.path=p(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?o.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:o.path=t.path:o.path="/"+t.path,o.path=p(o.path)),o.query=t.query):(o.path=e.path,void 0!==t.query?o.query=t.query:o.query=e.query),o.userinfo=e.userinfo,o.host=e.host,o.port=e.port),o.scheme=e.scheme),o.fragment=t.fragment,o}function y(e,t,r){return m(h(f(e,r),f(t,r),r,!0),r)}function v(e,t){return"string"==typeof e?e=m(f(e,t),t):"object"===l(e)&&(e=f(m(e,t),t)),e}function g(e,t,r){return"string"==typeof e?e=m(f(e,r),r):"object"===l(e)&&(e=m(e,r)),"string"==typeof t?t=m(f(t,r),r):"object"===l(t)&&(t=m(t,r)),e===t}function b(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.ESCAPE:w.ESCAPE,n)}function x(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.PCT_ENCODED:w.PCT_ENCODED,a)}var w=r(!1),E=o?r(!0):void 0,$=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?([^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n)*))?/i,C=/^\.\.?\//,k=/^\/\.(\/|$)/,O=/^\/\.\.(\/|$)/,T=/^\/?(?:.|\n)*?(?=\/|$)/,A=void 0==="".match(/(){0}/)[1],S={};return{IRI_SUPPORT:o,VALIDATE_SUPPORT:i,pctEncChar:n,pctDecChars:a,SCHEMES:S,parse:f,_recomposeAuthority:d,removeDotSegments:p,serialize:m,resolveComponents:h,resolve:y,normalize:v,equal:g,escapeComponent:b,unescapeComponent:x}}();if(!n&&"undefined"!=typeof t&&"function"==typeof e){var s=e("./punycode");t.exports=a,e("./schemes")}},{"./punycode":18,"./schemes":19}]},{},[1])(1)})},function(e,t,r){"use strict";function n(e,t){var l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:r.i(i.createDefaults)(),c=arguments[3],u=arguments[4],f=arguments[5],d=arguments[6],p=[],m=[];t=t||[];var h=t.indexOf("*");u=u||{};var y={},v=t.indexOf("...");if("object"===("undefined"==typeof e?"undefined":s(e))&&e.hasOwnProperty("properties")){f=f||e.readonly||e.readOnly,y=r.i(i.defaultForm)(e,l,c,u);var g=y.lookup;e=g||e,p=p.concat(y.form)}return h!==-1&&(t=t.slice(0,h).concat(p).concat(t.slice(h+1))),y.form&&v!==-1&&!function(){var e=t.map(function(e){return"string"==typeof e?e:e.key?e.key:void 0}).filter(function(e){return void 0!==e});m=m.concat(y.form.map(function(t){var r=e.indexOf(t.key[0])!==-1;if(!r)return t}).filter(function(e){return void 0!==e}))}(),v!==-1&&(t=t.slice(0,v).concat(m).concat(t.slice(v+1))),t.map(function(t){if("string"==typeof t&&(t={key:t}),t.key&&"string"==typeof t.key&&(t.key=r.i(o.parse)(t.key)),t.titleMap&&(t.titleMap=r.i(a.a)(t.titleMap)),t.key){var i=r.i(o.stringify)(t.key);e[i]&&!function(){var r=e[i];r&&Object.keys(r).forEach(function(e){void 0===t[e]&&(t[e]=r[e])})}()}return f===!0&&(t.readonly=!0),t.items&&(t.items=n(e,t.items,l,c,u,t.readonly,d)),t.tabs&&t.tabs.forEach(function(r){r.items&&(r.items=n(e,r.items,l,c,u,t.readonly,d))}),"checkbox"===t.type&&(void 0===t.schema?t.schema={default:!1}:void 0===t.schema.default&&(t.schema.default=!1)),d&&"template"===t.type&&!t.template&&t.templateUrl&&d.push(t),t})}var o=r(0),i=r(3),a=r(1);t.a=n;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e}},function(e,t,r){"use strict";function n(e,t){var r=new Promise(function(t,r){o.resolveRefs(e,{filter:["relative","local","remote"]}).then(function(e){t(e.resolved)}).catch(function(e){r(new Error(e))})});return"function"!=typeof t?r:void r.then(function(e){t(null,e)}).catch(function(e){t(e)})}var o=r(5);r.n(o);t.a=n},function(e,t,r){"use strict";function n(e,t,r){t||(t=this);var n="string"==typeof e?o.parse(e):e;if("undefined"!=typeof r&&1===n.length)return t[n[0]]=r,t;"undefined"!=typeof r&&"undefined"==typeof t[n[0]]&&(t[n[0]]=n.length>2&&i.test(n[1])?[]:{});for(var a=t[n[0]],s=1;s<n.length;s++){if(""===n[s])return;if("undefined"!=typeof r){if(s===n.length-1)return a[n[s]]=r,r;var l=a[n[s]];"undefined"!=typeof l&&null!==l||(l=i.test(n[s+1])?[]:{},a[n[s]]=l),a=l}else a&&(a=a[n[s]])}return a}var o=r(0);t.a=n;var i=/^\d+$/},function(e,t,r){"use strict";function n(e,t,r,n){n=void 0===n||n,r=r||[];var o=function e(t,r,o){if(r(t,o),t.properties&&Object.keys(t.properties).forEach(function(n){var i=o.slice();i.push(n),e(t.properties[n],r,i)}),!n&&t.items){var i=o.slice();i.push(""),e(t.items,r,i)}};o(e,t,r||[])}function o(e,t){t(e),e.items&&e.items.forEach(function(e){o(e,t)}),e.tabs&&e.tabs.forEach(function(e){e.items&&e.items.forEach(function(e){o(e,t)})})}t.a=n,t.b=o},function(e,t,r){"use strict";function n(e,t){if(!e)return{valid:!0};var r=e.schema;if(!r)return{valid:!0};""===t&&(t=void 0),"number"===e.type&&null===t&&(t=void 0);var n={type:"object",properties:{},required:void 0},o=e.key[e.key.length-1];n.properties[o]=r,e.required&&(n.required=[o]);var a={};return t&&(a[o]=t),i.a.validateResult(a,n)}var o=r(12),i=r.n(o);t.a=n},function(e,t,r){"use strict";var n;!function(o){var i={parse:function(e){if("string"!=typeof e)throw new TypeError("ObjectPath.parse must be passed a string");for(var t,r,n,o,i=0,a=[];i<e.length;)if(t=e.indexOf(".",i),r=e.indexOf("[",i),t===-1&&r===-1)a.push(e.slice(i,e.length)),i=e.length;else if(r===-1||t!==-1&&t<r)a.push(e.slice(i,t)),i=t+1;else if(r>i&&(a.push(e.slice(i,r)),i=r),n=e.slice(r+1,r+2),'"'!==n&&"'"!==n)o=e.indexOf("]",r),o===-1&&(o=e.length),a.push(e.slice(i+1,o)),i="."===e.slice(o+1,o+2)?o+2:o+1;else{for(o=e.indexOf(n+"]",r),o===-1&&(o=e.length);"\\"===e.slice(o-1,o)&&r<e.length;)r++,o=e.indexOf(n+"]",r);a.push(e.slice(i+2,o).replace(new RegExp("\\"+n,"g"),n)),i="."===e.slice(o+2,o+3)?o+3:o+2}return a},stringify:function(e,t){return Array.isArray(e)||(e=[e.toString()]),t='"'===t?'"':"'",e.map(function(e){return"["+t+e.toString().replace(new RegExp(t,"g"),"\\"+t)+t+"]"}).join("")},normalize:function(e,t){return i.stringify(Array.isArray(e)?e:i.parse(e),t)},registerModule:function(e){e.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=i.parse,this.stringify=i.stringify,this.normalize=i.normalize,this.$get=function(){return i}})}};n=function(){return{ObjectPath:i}}.call(t,r,t,e),!(n!==o&&(e.exports=n))}()},function(e,t){e.exports=tv4},function(e,t,r){e.exports=r(4)}])}).call(t,r(2),r(18).setImmediate)},function(e,t){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(r=window)}e.exports=r},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(1),o=(r.n(n),r(0)),i=r.n(o),a=r(13),s=r(11),l=r(12),c=r(14),u=r(15),f=r(6),d=r(7),p=r(9),m=r(5),h=r(8),y=r(10),v=r(4),g=[];try{i.a.module("ngSanitize"),g.push("ngSanitize")}catch(e){}try{i.a.module("ui.sortable"),g.push("ui.sortable")}catch(e){}try{i.a.module("angularSpectrumColorpicker"),g.push("angularSpectrumColorpicker")}catch(e){}i.a.module("schemaForm",g).provider("sfPath",u.a).provider("sfBuilder",["sfPathProvider",a.a]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",s.a]).provider("sfErrorMessage",c.a).provider("schemaForm",["sfPathProvider",l.a]).factory("sfSelect",function(){return n.select}).factory("sfValidator",function(){return n.validate}).directive("sfChanged",f.a).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",d.a]).directive("sfMessage",["$injector","sfErrorMessage",p.a]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",m.a]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",y.a]).directive("schemaValidate",["sfValidator","$parse","sfSelect",v.a]).directive("sfKeyController",["schemaForm","sfPath",h.a])},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r){return{restrict:"A",scope:!1,priority:500,require:"ngModel",link:function(t,n,i,a){t.$emit("schemaFormPropagateNgModelController",a);var s=null,l=t.$eval(i.schemaValidate);l.copyValueTo&&a.$viewChangeListeners.push(function(){var e=l.copyValueTo;o.a.forEach(e,function(e){r(e,t.model,a.$modelValue)})});var c=function(r,n){if(!l)return r;if(t.options&&t.options.tv4Validation===!1)return r;var o=e(l,r);Object.keys(a.$error).filter(function(e){return 0===e.indexOf("tv4-")}).forEach(function(e){a.$setValidity(e,!0)});{if(o.valid||a.$pristine&&!n)return r;if(a.$setValidity("tv4-"+o.error.code,!1),s=o.error,a.$validators)return r}};"function"==typeof l.ngModel&&l.ngModel(a),["$parsers","$viewChangeListeners","$formatters"].forEach(function(e){l[e]&&a[e]&&l[e].forEach(function(t){a[e].push(t)})}),["$validators","$asyncValidators"].forEach(function(e){l[e]&&a[e]&&o.a.forEach(l[e],function(r,n){a[e][n]=function(e,n){return r(e,n,t.model,l)}})}),a.$parsers.push(c),a.$validators&&(a.$validators.schemaForm=function(){return!Object.keys(a.$error).some(function(e){return"schemaForm"!==e})});var u=l.schema;t.validateField=function(e,t){var r=void 0===e;(r||a.$$parentForm.$name===e)&&((r||u&&u.type.indexOf("array")!==-1)&&c(a.$modelValue,t),a.$setDirty?(a.$setDirty(),a.$setViewValue(a.$viewValue),a.$commitViewValue(),"checkbox"===l.type?l.required&&void 0===a.$modelValue&&a.$setValidity("tv4-302",!1):l.required&&a.$isEmpty(a.$modelValue)&&a.$setValidity("tv4-302",!1)):a.$setViewValue(a.$viewValue))};var f=!0;a.$formatters.push(function(e){return!a.$pristine||!f||t.options&&t.options.validateOnRender===!0?(c(a.$modelValue),e):(f=!1,e)}),t.$on("schemaFormValidate",function(e,r){t.validateField(r,!0)}),t.schemaError=function(){return s}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r){return{scope:!0,controller:["$scope",function(e){this.key=e.form&&e.form.key?e.form.key.splice(0,-2):[]}],link:function(n,a,s){n.min=0,n.trackBy=function(e,t){return e&&"object"===("undefined"==typeof e?"undefined":i(e))?e:t},n.modelArray=n.$eval(s.sfNewArray);var l=function(){n.modelArray=n.$eval(s.sfNewArray),n.ngModel&&n.ngModel.$pristine&&n.firstDigest&&(!n.options||n.options.validateOnRender!==!0)||n.validateField&&n.validateField()},c=function(){n.form&&n.form.onChange&&(o.a.isFunction(n.form.onChange)?n.form.onChange(n.modelArray,n.form):n.evalExpr(n.form.onChange,{modelValue:n.modelArray,form:n.form}))},u=function(){var r=n.modelArray;if(!r){var o=t.parse(s.sfNewArray);r=[],e(o,n,r),n.modelArray=r}return r},f=n.$watch("form",function(e){if(e){if(e.titleMap||e.startEmpty===!0||n.modelArray&&0!==n.modelArray.length||n.appendToArray(),n.$watch(function(e){return JSON.stringify(e.modelArray)},function(){l(),c()}),e.titleMap&&e.titleMap.length>0){n.titleMapValues=[];var t=function(t){n.titleMapValues=[],t=t||[],e.titleMap.forEach(function(e){n.titleMapValues.push(t.indexOf(e.value)!==-1)})};t(n.modelArray),n.$watchCollection("modelArray",t),n.$watchCollection("titleMapValues",function(t,r){if(t&&t!==r){var o=u();e.titleMap.forEach(function(e,r){var n=o.indexOf(e.value);n===-1&&t[r]&&o.push(e.value),n===-1||t[r]||o.splice(n,1)}),n.validateField&&n.validateField()}})}f()}});n.appendToArray=function(){var t,i=u();if(n.form&&n.form.schema&&n.form.schema.items){var a=n.form.schema.items;a.type&&a.type.indexOf("object")!==-1?(t={},n.options&&n.options.setSchemaDefaults===!1||(t=o.a.isDefined(a.default)?a.default:t,t&&r.traverseSchema(a,function(r,n){o.a.isDefined(r.default)&&e(n,t,r.default)}))):a.type&&a.type.indexOf("array")!==-1?(t=[],n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t)):n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t)}return i.push(t),i},n.deleteFromArray=function(e){var t=n.modelArray.indexOf(e),r=n.modelArray;return r&&r.splice(t,1),e.$$hashKey&&(n.destroyed=e.$$hashKey),r};var d=function(e){return function(t){t.key&&(t.key[t.key.indexOf("")]=e)}},p={};n.copyWithIndex=function(e){var t=n.form;if(!p[e]){var i=t.items[0];if(t.items.length>1&&(i={type:"section",items:t.items.map(function(e){return e.ngModelOptions=t.ngModelOptions,o.a.isUndefined(e.readonly)&&(e.readonly=t.readonly),e})}),i){var a=o.a.copy(i);a.arrayIndex=e,r.traverseForm(a,d(e)),p[e]=a}}return p[e]}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){return{require:"ngModel",restrict:"AC",scope:!1,link:function(e,t,r,n){var i=e.$eval(r.sfChanged);i&&i.onChange&&n.$viewChangeListeners.push(function(){o.a.isFunction(i.onChange)?i.onChange(n.$modelValue,i):e.evalExpr(i.onChange,{modelValue:n.$modelValue,form:i,arrayIndex:e.$index,arrayIndices:e.arrayIndices,path:e.path,$i:e.$i,$index:e.$index})})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r,n,a,s,l,c,u){var f={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function(e,t,r,n){var o=n[0];n[1],n[2];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.initialForm=Object.assign({},o.lookup["f"+r.sfField]),e.form=o.lookup["f"+r.sfField]},post:function(e,t,r,n){var s=n[0],d=n[1];n[2];e.getKey=function(t){var r=t||f.COMPLETE,n=e.parentKey?e.parentKey.slice(0,e.parentKey.length-1):[];if(e.completeKey!==e.form.key&&("number"==typeof e.$index&&(n=n.concat(e.$index)),e.form.key&&e.form.key.length))if("number"==typeof n[n.length-1]&&e.form.key.length>=1){var o=e.form.key.length-n.length;e.completeKey=n.concat(e.form.key.slice(-o))}else e.completeKey=e.form.key.slice();if(Array.isArray(e.completeKey))return r===f.COMPLETE?e.completeKey:e.completeKey.reduce(function(e,t,n){return-1!==[r].indexOf("undefined"==typeof t?"undefined":i(t))?e.concat(t):e},[])},e.form.key&&(e.form.key=e.completeKey=e.getKey()),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=r||!1,o=t&&d&&d.$name?d.$name:void 0,i=e.completeKey;return Array.isArray(i)?c.name(i,"-",o,n):""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(s?s.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return s?s.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&a(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.errors===!1?e.ngModel.$invalid&&!e.ngModel.$pristine:e.ngModel.$invalid)},e.errorMessage=function(t){return l.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)},e.form.htmlClass=e.form.htmlClass||"",e.idClass=e.fieldId(!1)+" "+e.fieldId(!1,!0);var p=e.form;p.key&&(e.$on("schemaForm.error."+p.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(p.validationMessage||(p.validationMessage={}),p.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){var t=e.getKey();"number"==typeof e.arrayIndex?e.arrayIndex+1:0;if(!(e.externalDestructionInProgress||e.model.$$hashKey&&e.model.$$hashKey!==e.destroyed)){var r=p.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(t&&"retain"!==r){var n=e.model;if(t.length>1&&(n=u(t.slice(0,t.length-1),n)),void 0===n)return;var o=p.schema&&p.schema.type||"";"empty"===r&&o.indexOf("string")!==-1?n[t.slice(-1)]="":"empty"===r&&o.indexOf("object")!==-1?n[t.slice(-1)]={}:"empty"===r&&o.indexOf("array")!==-1?n[t.slice(-1)]=[]:"null"===r?n[t.slice(-1)]=null:delete n[t.slice(-1)]}}}))}}}}},function(e,t,r){"use strict";t.a=function(e,t){return{scope:!0,require:["?^^sfNewArray"],link:{pre:function(e,r,n,o){e.parentKey=e.parentKey||[];var i=t.parse(n.sfParentKey),a=i.length-e.parentKey.length;i.length>1&&(i=i.splice(-a)),e.parentKey=e.parentKey.concat(i,Number(n.sfIndex)),e.arrayIndex=Number(n.sfIndex),e.arrayIndices=e.arrayIndices||[],e.arrayIndices=e.arrayIndices.concat(e.arrayIndex),e.$i=e.arrayIndices,e.path=function(t){var r=-1;return t=t.replace(/\[\]/gi,function(t){return r++,"["+e.$i[r]+"]"}),e.evalExpr(t,e)}}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r=e.has("$sanitize")?e.get("$sanitize"):function(e){return e};return{scope:!1,restrict:"EA",link:function(e,n,i){var a="";i.sfMessage&&e.$watch(i.sfMessage,function(t){t&&(a=r(t),c(!!e.ngModel))});var s,l=function(e){e!==s&&(n.html(e),s=e)},c=function(r){if(r)if(e.hasError()){var n=[];o.a.forEach(e.ngModel&&e.ngModel.$error,function(e,t){e&&n.push(t)}),n=n.filter(function(e){return"schemaForm"!==e});var i=n[0];l(i?t.interpolate(i,e.ngModel.$modelValue,e.ngModel.$viewValue,e.form,e.options&&e.options.validationMessage):a)}else l(a);else l(a)};c();var u=e.$watch("ngModel",function(e){e&&(e.$parsers.push(function(e){return c(!0),e}),e.$formatters.push(function(e){return c(!0),e}),u())});e.$watchCollection("ngModel.$error",function(){c(!!e.ngModel)})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r,n,i,a,s,l,c){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function(e){this.$onInit=function(){this.evalInParentScope=function(t,r){return e.$parent.$eval(t,r)};var t=this;e.lookup=function(e){return e&&(t.lookup=e),t.lookup}},1===o.a.version.major&&o.a.version.minor<5&&this.$onInit()}],replace:!1,restrict:"A",transclude:!0,require:"?form",link:function(l,u,f,d,p){l.formCtrl=d;var m={};p(l,function(e){if(e.addClass("schema-form-ignore"),u.prepend(e),u[0].querySelectorAll){var t=u[0].querySelectorAll("[ng-model]");if(t)for(var r=0;r<t.length;r++){var n=t[r].getAttribute("ng-model");m[n.substring(n.indexOf(".")+1)]=!0}}});var h,y={};l.resolveReferences=function(e,t){i.jsonref(e).then(function(e){l.render(e,t)}).catch(function(e){new Error(e)})},l.render=function(e,o){var a=[],s=i.merge(e,o,void 0,m,l.options,void 0,a);a.length>0?n.all(a.map(function(e){return t.get(e.templateUrl,{cache:r}).then(function(t){e.template=t.data})})).then(function(){l.internalRender(e,o,s)}):l.internalRender(e,o,s)},l.internalRender=function(t,r,n){h&&(l.externalDestructionInProgress=!0,h.$destroy(),l.externalDestructionInProgress=!1),h=l.$new(),h.schemaForm={form:n,schema:t},Array.prototype.forEach.call(u.children(),function(e){var t=o.a.element(e);!1===t.hasClass("schema-form-ignore")&&t.remove()});for(var d={},p=u[0].querySelectorAll("*[sf-insert-field]"),m=0;m<p.length;m++)d[p[m].getAttribute("sf-insert-field")]=p[m];var y=a.decorator(f.sfUseDecorator),v=Object.create(null);l.lookup(v),u[0].appendChild(c.build(n,y,d,v)),h.firstDigest=!0,setTimeout(function(){h.firstDigest=!1,l.$apply()},0),e(u.children())(h),l.options&&l.options.setSchemaDefaults===!1||i.traverseSchema(t,function(e,t){if(o.a.isDefined(e.default)){var r=s(t,l.model);o.a.isUndefined(r)&&s(t,l.model,e.default)}}),l.$emit("sf-render-finished",u)};var v=["*"];l.$watch(function(){var e=l.schema,t=l.initialForm||v;t&&e&&e.type&&(y.form!==t||y.schema!==e)&&((!e.properties||0===Object.keys(e.properties).length)&&(t.indexOf("*")||t.indexOf("...")),y.schema=e,y.form=t,l.resolveReferences(e,t))}),l.$on("schemaFormRedraw",function(){var e=l.schema,t=l.initialForm?o.a.copy(l.initialForm):["*"];e&&l.resolveReferences(e,t)}),l.$on("$destroy",function(){l.externalDestructionInProgress=!0}),l.evalExpr=function(e,t){return l.$parent.$eval(e,t)}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r="",n={},i=function(e,t){"sfDecorator"===e&&(e=r);var o=n[e];return o[t.type]?o[t.type].template:o.default.template},a=function(r){e.directive(r,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function(e,n,a,s,l,c,u,f,d){return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["?^sfSchema","?^form"],link:function(e,p,m,h){var y=h[0],v=h[1];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=e.parentKey||[];if(e.form.key){if("number"==typeof n[n.length-1]){var o=n.concat(e.form.key.slice(-1)),i=t&&v&&v.$name?v.$name:void 0;return f.name(o,"-",i,r)}var i=t&&v&&v.$name?v.$name:void 0;return f.name(e.form.key,"-",i,r)}return""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(y?y.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return y?y.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&l(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.ngModel.$invalid&&!e.ngModel.$pristine)},e.errorMessage=function(t){return u.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)};var g=e.$watch(m.form,function(l){if(l){l.ngModelOptions=l.ngModelOptions||{},e.form=l;var u;if("template"===l.type&&l.template)u=c.when(l.template);else{var m="template"===l.type?l.templateUrl:i(r,l);u=a.get(m,{cache:s}).then(function(e){return e.data})}u.then(function(r){if(l.key){var i=l.key?t.stringify(l.key).replace(/"/g,"&quot;"):"";r=r.replace(/\$\$value\$\$/g,"model"+("["!==i[0]?".":"")+i)}if(p.html(r),l.condition){var a='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';l.key&&(a='evalExpr(form.condition, {model: model, "arrayIndex": arrayIndex, "modelValue": model'+f.stringify(l.key)+"})"),o.a.forEach(p.children(),function(e){var t=e.getAttribute("ng-if");e.setAttribute("ng-if",t?"("+t+") || ("+a+")":a)})}n(p.contents())(e)}),l.key&&(e.$on("schemaForm.error."+l.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(l.validationMessage||(l.validationMessage={}),l.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){if(!e.externalDestructionInProgress){var t=l.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(l.key&&"retain"!==t){var r=e.model;if(l.key.length>1&&(r=d(l.key.slice(0,l.key.length-1),r)),void 0===r)return;var n=l.schema&&l.schema.type||"";"empty"===t&&n.indexOf("string")!==-1?r[l.key.slice(-1)]="":"empty"===t&&n.indexOf("object")!==-1?r[l.key.slice(-1)]={}:"empty"===t&&n.indexOf("array")!==-1?r[l.key.slice(-1)]=[]:"null"===t?r[l.key.slice(-1)]=null:delete r[l.key.slice(-1)]}}})),g()}})}}}])},s=function(t,r,n){n=!!o.a.isDefined(n)&&n,e.directive("sf"+o.a.uppercase(t[0])+t.substr(1),function(){return{restrict:"EAC",scope:!0,replace:!0,transclude:n,template:'<sf-decorator form="form"></sf-decorator>',link:function(e,r,n){var i={items:"c",titleMap:"c",schema:"c"},a={type:t},s=!0;o.a.forEach(n,function(t,r){
-if("$"!==r[0]&&0!==r.indexOf("ng")&&"sfField"!==r){var l=function(t){o.a.isDefined(t)&&t!==a[r]&&(a[r]=t,s&&a.type&&(a.key||o.a.isUndefined(n.key))&&(e.form=a,s=!1))};"model"===r?e.$watch(t,function(t){t&&e.model!==t&&(e.model=t)}):"c"===i[r]?e.$watchCollection(t,l):n.$observe(r,l)}})}}})};this.createDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){n[e][r]={template:t,replace:!1,builder:[]}}),n[r]||(r=e),a(e)},this.defineDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){t.builder=t.builder||[],t.replace=!o.a.isDefined(t.replace)||t.replace,n[e][r]=t}),n[r]||(r=e),a(e)},this.createDirective=s,this.createDirectives=function(e){o.a.forEach(e,function(e,t){s(t,e)})},this.decorator=function(e){return e=e||r,n[e]},this.addMapping=function(e,t,r,o,i){n[e]&&(n[e][t]={template:r,builder:o,replace:!!i})},this.defineAddOn=function(e,t,r,o){n[e]&&(n[e][t]={template:r,builder:o,replace:!0})},this.$get=function(){return{decorator:function(e){return n[e]||n[r]},defaultDecorator:r}},a("sfDecorator")}},function(e,t,r){"use strict";var n=r(0),o=(r.n(n),r(1));r.n(o);t.a=function(){var e=function(e){return e},t=o.schemaDefaults.createDefaults();this.defaults=t,this.stdFormObj=o.schemaDefaults.stdFormObj,this.defaultFormDefinition=o.schemaDefaults.defaultFormDefinition,this.postProcess=function(t){e=t},this.appendRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].push(t)},this.prependRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].unshift(t)},this.createStandardForm=o.schemaDefaults.stdFormObj,this.$get=function(){var t={},n=this.defaults;return t.jsonref=o.jsonref,t.defaults=function(e,t,r,i){var a=t||n;return o.schemaDefaults.defaultForm(e,a,r,i)},t.merge=function(n){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["*"],a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.typeDefault,s=arguments[3],l=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},c=arguments.length>5&&void 0!==arguments[5]&&arguments[5],u=arguments[6],f=r.i(o.merge)(n,i,a,s,l,c,u);return e(f)},t.typeDefault=n,t.traverseSchema=o.traverseSchema,t.traverseForm=o.traverseForm,t}}},function(e,t,r){"use strict";t.a=function(e){var t=/[A-Z]/g,r=function(e,r){return r=r||"_",e.replace(t,function(e,t){return(t?r:"")+e.toLowerCase()})},n=0;"firstElementChild"in document.createDocumentFragment()||Object.defineProperty(DocumentFragment.prototype,"firstElementChild",{get:function(){for(var e,t=this.childNodes,r=0,n=t.length;r<n;++r)if(e=t[r],1===e.nodeType)return e;return null}});var o={sfField:function(e){e.fieldFrag.firstElementChild.setAttribute("sf-field",n),e.lookup["f"+n]=e.form,n++},ngModel:function(t){if(t.form.key){var r=t.form.key;t.state.keyRedaction&&(r=r.slice(t.state.keyRedaction));var n;if(t.state.modelValue)n=t.state.modelValue;else{var o=e.stringify(r).replace(/"/g,"&quot;");n=t.state.modelName||"model",o&&(n+=("["!==o[0]?".":"")+o)}for(var i=t.fieldFrag.querySelectorAll("[sf-field-model]"),a=0;a<i.length;a++){var s=i[a],l=s.getAttribute("sf-field-model");if(l&&""!==l)if("replaceAll"===l)for(var c=s.attributes,u=0;u<c.length;u++)c[u].value&&c[u].value.indexOf("$$value")!==-1&&(c[u].value=c[u].value.replace(/\$\$value\$\$/g,n));else{var f=s.getAttribute(l);f&&f.indexOf("$$value$$")?s.setAttribute(l,f.replace(/\$\$value\$\$/g,n)):s.setAttribute(l,n)}else s.setAttribute("ng-model",n)}}},simpleTransclusion:function(e){var t=e.build(e.form.items,e.path+".items",e.state);e.fieldFrag.firstChild.appendChild(t)},ngModelOptions:function(e){e.form.ngModelOptions&&Object.keys(e.form.ngModelOptions).length>0&&e.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(e.form.ngModelOptions))},transclusion:function(e){var t=e.fieldFrag.querySelectorAll("[sf-field-transclude]");if(t.length)for(var r=0;r<t.length;r++){var n=t[r],o=n.getAttribute("sf-field-transclude")||"items",i=e.form[o];if(i){var a=e.build(i,e.path+"."+o,e.state);n.appendChild(a)}}},condition:function(t){var r="",n="undefined",o="";if(t.form.condition){t.form.key&&(r=e.stringify(t.form.key),n="model"+("["===r[0]?"":".")+r);for(var i="evalExpr("+t.path+'.condition, { model: model, "arrayIndex": $index, "arrayIndices": arrayIndices, "path": path, "$i": $i, "$index": $index, "modelValue": '+n+"})",a=t.fieldFrag.children||t.fieldFrag.childNodes,s=0;s<a.length;s++){var l=a[s];l.hasAttribute&&l.hasAttribute("ng-if")&&(o=l.getAttribute("ng-if")),l.setAttribute&&l.setAttribute("ng-if",o?"("+o+") || ("+i+")":i)}}},array:function(t){var r=t.fieldFrag.querySelector("[schema-form-array-items]");if(t.form.key){t.form.key.filter(function(e){return""===e}).length}if(r){var n=angular.copy(t.state);if(n.keyRedaction=0,n.keyRedaction+=t.form.key.length+1,t.form.schema&&t.form.schema.items&&t.form.schema.items.type&&t.form.schema.items.type.indexOf("object")===-1&&t.form.schema.items.type.indexOf("array")===-1){e.stringify(t.form.key).replace(/"/g,"&quot;")+"[$index]";n.modelValue="modelArray[$index]"}else n.modelName="item";n.arrayCompatFlag=!0;var o=t.build(t.form.items,t.path+".items",n);r.appendChild(o)}},numeric:function(e){var t=e.fieldFrag.querySelector("input"),r=e.form.maximum||!1,n=e.form.exclusiveMaximum||!1,o=e.form.minimum||!1,i=e.form.exclusiveMinimum||!1,a=e.form.multipleOf||!1;t&&(a!==!1&&t.setAttribute("step",a),r!==!1&&(n!==!1&&a!==!1&&(r-=a),t.setAttribute("max",r)),o!==!1&&(i!==!1&&a!==!1&&(o+=a),t.setAttribute("min",o)))}};this.builders=o;var i=[o.sfField,o.ngModel,o.ngModelOptions,o.condition];this.stdBuilders=i,this.$get=["$templateCache","schemaFormDecorators","sfPath",function(e,t,n){var a=function(e,t){if(e.key){var r=t[n.stringify(e.key)];if(r){for(;r.firstChild;)r.removeChild(r.firstChild);return r}}},s=function e(t,n,o,i,s,l,c){l=l||{},l=l||{},c=c||Object.create(null),s=s||"schemaForm.form";var u=document.createDocumentFragment();return t.reduce(function(t,u,f){if(!u.type)return t;var d=n[u.type]||n.default;if(d.replace){var p;l.arrayCompatFlag=!1;var m=document.createElement("div"),h=o(u,d)||o(u,n.default);for(m.innerHTML=h,p=document.createDocumentFragment();m.childNodes.length>0;)p.appendChild(m.childNodes[0]);var y={fieldFrag:p,form:u,lookup:c,state:l,path:s+"["+f+"]",build:function(t,r,a){return e(t,n,o,i,r,a,c)}},v=u.builder||d.builder;"function"==typeof v?v(y):v.forEach(function(e){e(y)}),(a(u,i)||t).appendChild(p)}else{var g=document.createElement(r(n.__name,"-"));l.arrayCompatFlag?g.setAttribute("form","copyWithIndex($index)"):g.setAttribute("form",s+"["+f+"]"),(a(u,i)||t).appendChild(g)}return t},u),u};return{build:function(t,r,n,o){return s(t,r,function(t,r){return"template"===t.type?t.template:e.get(r.template)},n,void 0,void 0,o)},builder:o,stdBuilders:i,internalBuild:s}}]}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){var e={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};e.number=e[105],e.required=e[302],e.min=e[101],e.max=e[103],e.maxlength=e[201],e.minlength=e[200],e.pattern=e[202],this.setDefaultMessages=function(t){e=t},this.getDefaultMessages=function(){return e},this.setDefaultMessage=function(t,r){e[t]=r},this.$get=["$interpolate",function(t){var r={};return r.defaultMessages=e,r.interpolate=function(r,n,i,a,s){s=s||{};var l=a.validationMessage||{};0===r.indexOf("tv4-")&&(r=r.substring(4));var c=l.default||s.default||"";[l,s,e].some(function(e){return o.a.isString(e)||o.a.isFunction(e)?(c=e,!0):e&&e[r]?(c=e[r],!0):void 0});var u={error:r,value:n,viewValue:i,form:a,schema:a.schema,title:a.title||a.schema&&a.schema.title};return o.a.isFunction(c)?c(u):t(c)(u)},r}]}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=r(1),i=(r.n(o),r(0)),a=(r.n(i),function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}()),s=function(){function e(){n(this,e),this.name=o.sfPath.name,this.parse=o.sfPath.parse,this.stringify=o.sfPath.stringify,this.normalize=o.sfPath.normalize}return a(e,[{key:"$get",value:function(){return o.sfPath}}]),e}();t.a=s},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):y=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++y<t;)p&&p[y].run();y=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,y=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},function(e,t,r){(function(e,t){!function(e,r){"use strict";function n(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var n={callback:e,args:t};return h[m]=n,p(m),m++}function o(e){delete h[e]}function i(e){var t=e.callback,n=e.args;switch(n.length){case 0:t();break;case 1:t(n[0]);break;case 2:t(n[0],n[1]);break;case 3:t(n[0],n[1],n[2]);break;default:t.apply(r,n)}}function a(e){if(y)setTimeout(a,0,e);else{var t=h[e];if(t){y=!0;try{i(t)}finally{o(e),y=!1}}}}function s(){p=function(e){t.nextTick(function(){a(e)})}}function l(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}function c(){var t="setImmediate$"+Math.random()+"$",r=function(r){r.source===e&&"string"==typeof r.data&&0===r.data.indexOf(t)&&a(+r.data.slice(t.length))};e.addEventListener?e.addEventListener("message",r,!1):e.attachEvent("onmessage",r),p=function(r){e.postMessage(t+r,"*")}}function u(){var e=new MessageChannel;e.port1.onmessage=function(e){var t=e.data;a(t)},p=function(t){e.port2.postMessage(t)}}function f(){var e=v.documentElement;p=function(t){var r=v.createElement("script");r.onreadystatechange=function(){a(t),r.onreadystatechange=null,e.removeChild(r),r=null},e.appendChild(r)}}function d(){p=function(e){setTimeout(a,0,e)}}if(!e.setImmediate){var p,m=1,h={},y=!1,v=e.document,g=Object.getPrototypeOf&&Object.getPrototypeOf(e);g=g&&g.setTimeout?g:e,"[object process]"==={}.toString.call(e.process)?s():l()?c():e.MessageChannel?u():v&&"onreadystatechange"in v.createElement("script")?f():d(),g.setImmediate=n,g.clearImmediate=o}}("undefined"==typeof self?"undefined"==typeof e?this:e:self)}).call(t,r(2),r(16))},function(r,n,o){function i(e,t){this._id=e,this._clearFn=t}var a=Function.prototype.apply;n.setTimeout=function(){return new i(a.call(setTimeout,window,arguments),clearTimeout)},n.setInterval=function(){return new i(a.call(setInterval,window,arguments),clearInterval)},n.clearTimeout=n.clearInterval=function(e){e&&e.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(window,this._id)},n.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},n.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},n._unrefActive=n.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},o(17),n.setImmediate=e,n.clearImmediate=t},function(e,t,r){r(1),e.exports=r(3)}])}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):y=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++y<t;)p&&p[y].run();y=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,y=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},,,function(e,t,r){r(19),e.exports=r(0)}]);
\ No newline at end of file
+var n=!1,o=!0,i=!0,a=function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(r){var n="[A-Za-z]",o="[0-9]",a=e(o,"[A-Fa-f]"),s=t(t("%[EFef]"+a+"%"+a+a+"%"+a+a)+"|"+t("%[89A-Fa-f]"+a+"%"+a+a)+"|"+t("%"+a+a)),l="[\\:\\/\\?\\#\\[\\]\\@]",c="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",u=e(l,c),f=r?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",d=r?"[\\uE000-\\uF8FF]":"[]",p=e(n,o,"[\\-\\.\\_\\~]",f),m=t(n+e(n,o,"[\\+\\-\\.]")+"*"),h=t(t(s+"|"+e(p,c,"[\\:]"))+"*"),y=t(t("25[0-5]")+"|"+t("2[0-4]"+o)+"|"+t("1"+o+o)+"|"+t("[1-9]"+o)+"|"+o),v=t(y+"\\."+y+"\\."+y+"\\."+y),g=t(a+"{1,4}"),b=(t(t(g+"\\:"+g)+"|"+v),t(e(p,c,"[\\:]")+"+")),x=t("v"+a+"+\\."+e(p,c,"[\\:]")+"+"),w=t("\\["+t(b+"|"+x)+"\\]"),E=t(t(s+"|"+e(p,c))+"*"),$=t(w+"|"+v+"(?!"+E+")|"+E),C=t(o+"*"),k=t(t(h+"@")+"?"+$+t("\\:"+C)+"?"),O=t(s+"|"+e(p,c,"[\\:\\@]")),T=t(O+"*"),A=t(O+"+"),S=t(t(s+"|"+e(p,c,"[\\@]"))+"+"),P=t(t("\\/"+T)+"*"),M=t("\\/"+t(A+P)+"?"),j=t(S+P),I=t(A+P),D="(?!"+O+")",_=(t(P+"|"+M+"|"+j+"|"+I+"|"+D),t(t(O+"|"+e("[\\/\\?]",d))+"*")),F=t(t(O+"|[\\/\\?]")+"*"),R=t(t("\\/\\/"+k+P)+"|"+M+"|"+I+"|"+D),q=t(m+"\\:"+R+t("\\?"+_)+"?"+t("\\#"+F)+"?"),U=t(t("\\/\\/"+k+P)+"|"+M+"|"+j+"|"+D),N=t(U+t("\\?"+_)+"?"+t("\\#"+F)+"?"),L=(t(q+"|"+N),t(m+"\\:"+R+t("\\?"+_)+"?"),"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+I+"|"+D+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$"),H="^(){0}"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+j+"|"+D+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$";"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+I+"|"+D+")")+t("\\?("+_+")")+"?$","^"+t("\\#("+F+")")+"?$","^"+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?$";return{URI_REF:i&&new RegExp("("+L+")|("+H+")"),NOT_SCHEME:new RegExp(e("[^]",n,o,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(e("[^\\%\\:]",p,c),"g"),NOT_HOST:new RegExp(e("[^\\%]",p,c),"g"),NOT_PATH:new RegExp(e("[^\\%\\/\\:\\@]",p,c),"g"),NOT_PATH_NOSCHEME:new RegExp(e("[^\\%\\/\\@]",p,c),"g"),NOT_QUERY:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]",d),"g"),NOT_FRAGMENT:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(e("[^]",p,c),"g"),UNRESERVED:new RegExp(p,"g"),OTHER_CHARS:new RegExp(e("[^\\%]",p,u),"g"),PCT_ENCODED:new RegExp(s,"g")}}function n(e){var t,r=e.charCodeAt(0);return t=r<16?"%0"+r.toString(16).toUpperCase():r<128?"%"+r.toString(16).toUpperCase():r<2048?"%"+(r>>6|192).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase():"%"+(r>>12|224).toString(16).toUpperCase()+"%"+(r>>6&63|128).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase()}function a(e){for(var t,r,n,o="",i=0,a=e.length;i<a;)t=parseInt(e.substr(i+1,2),16),t<128?(o+=String.fromCharCode(t),i+=3):t>=194&&t<224?(a-i>=6?(r=parseInt(e.substr(i+4,2),16),o+=String.fromCharCode((31&t)<<6|63&r)):o+=e.substr(i,6),i+=6):t>=224?(a-i>=9?(r=parseInt(e.substr(i+4,2),16),n=parseInt(e.substr(i+7,2),16),o+=String.fromCharCode((15&t)<<12|(63&r)<<6|63&n)):o+=e.substr(i,9),i+=9):(o+=e.substr(i,3),i+=3);return o}function l(e){return void 0===e?"undefined":null===e?"null":Object.prototype.toString.call(e).split(" ").pop().split("]").shift().toLowerCase()}function c(e){return e.toUpperCase()}function u(e,t){function r(e){var r=a(e);return r.match(t.UNRESERVED)?r:e}return e.scheme&&(e.scheme=String(e.scheme).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_SCHEME,"")),void 0!==e.userinfo&&(e.userinfo=String(e.userinfo).replace(t.PCT_ENCODED,r).replace(t.NOT_USERINFO,n).replace(t.PCT_ENCODED,c)),void 0!==e.host&&(e.host=String(e.host).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_HOST,n).replace(t.PCT_ENCODED,c)),void 0!==e.path&&(e.path=String(e.path).replace(t.PCT_ENCODED,r).replace(e.scheme?t.NOT_PATH:t.NOT_PATH_NOSCHEME,n).replace(t.PCT_ENCODED,c)),void 0!==e.query&&(e.query=String(e.query).replace(t.PCT_ENCODED,r).replace(t.NOT_QUERY,n).replace(t.PCT_ENCODED,c)),void 0!==e.fragment&&(e.fragment=String(e.fragment).replace(t.PCT_ENCODED,r).replace(t.NOT_FRAGMENT,n).replace(t.PCT_ENCODED,c)),e}function f(e,t){void 0===t&&(t={});var r,n,l=o&&t.iri!==!1?E:w,c=!1,f={};if("suffix"===t.reference&&(e=(t.scheme?t.scheme+":":"")+"//"+e),i?(r=e.match(l.URI_REF),r&&(r=r[1]?r.slice(1,10):r.slice(10,19)),r||(c=!0,t.tolerant||(f.error=f.error||"URI is not strictly valid."),r=e.match($))):r=e.match($),r){if(A?(f.scheme=r[1],f.userinfo=r[3],f.host=r[4],f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=r[7],f.fragment=r[8],isNaN(f.port)&&(f.port=r[5])):(f.scheme=r[1]||void 0,f.userinfo=e.indexOf("@")!==-1?r[3]:void 0,f.host=e.indexOf("//")!==-1?r[4]:void 0,f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=e.indexOf("?")!==-1?r[7]:void 0,f.fragment=e.indexOf("#")!==-1?r[8]:void 0,isNaN(f.port)&&(f.port=e.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?r[4]:void 0)),void 0!==f.scheme||void 0!==f.userinfo||void 0!==f.host||void 0!==f.port||f.path||void 0!==f.query?void 0===f.scheme?f.reference="relative":void 0===f.fragment?f.reference="absolute":f.reference="uri":f.reference="same-document",t.reference&&"suffix"!==t.reference&&t.reference!==f.reference&&(f.error=f.error||"URI is not a "+t.reference+" reference."),n=S[(t.scheme||f.scheme||"").toLowerCase()],!o||"undefined"==typeof s||t.unicodeSupport||n&&n.unicodeSupport)u(f,l);else{if(f.host&&(t.domainHost||n&&n.domainHost))try{f.host=s.toASCII(f.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(e){f.error=f.error||"Host's domain name can not be converted to ASCII via punycode: "+e}u(f,w)}n&&n.parse&&n.parse(f,t)}else c=!0,f.error=f.error||"URI can not be parsed.";return f}function d(e,t){var r=[];return void 0!==e.userinfo&&(r.push(e.userinfo),r.push("@")),void 0!==e.host&&r.push(e.host),"number"==typeof e.port&&(r.push(":"),r.push(e.port.toString(10))),r.length?r.join(""):void 0}function p(e){for(var t,r=[];e.length;)e.match(C)?e=e.replace(C,""):e.match(k)?e=e.replace(k,"/"):e.match(O)?(e=e.replace(O,"/"),r.pop()):"."===e||".."===e?e="":(t=e.match(T)[0],e=e.slice(t.length),r.push(t));return r.join("")}function m(e,t){void 0===t&&(t={});var r,n,i,l=o&&t.iri?E:w,c=[];if(r=S[(t.scheme||e.scheme||"").toLowerCase()],r&&r.serialize&&r.serialize(e,t),o&&"undefined"!=typeof s&&e.host&&(t.domainHost||r&&r.domainHost))try{e.host=t.iri?s.toUnicode(e.host):s.toASCII(e.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(r){e.error=e.error||"Host's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}return u(e,l),"suffix"!==t.reference&&e.scheme&&(c.push(e.scheme),c.push(":")),n=d(e,t),void 0!==n&&("suffix"!==t.reference&&c.push("//"),c.push(n),e.path&&"/"!==e.path.charAt(0)&&c.push("/")),void 0!==e.path&&(i=e.path,t.absolutePath||r&&r.absolutePath||(i=p(i)),void 0===n&&(i=i.replace(/^\/\//,"/%2F")),c.push(i)),void 0!==e.query&&(c.push("?"),c.push(e.query)),void 0!==e.fragment&&(c.push("#"),c.push(e.fragment)),c.join("")}function h(e,t,r,n){void 0===r&&(r={});var o={};return n||(e=f(m(e,r),r),t=f(m(t,r),r)),r=r||{},!r.tolerant&&t.scheme?(o.scheme=t.scheme,o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(t.path?("/"===t.path.charAt(0)?o.path=p(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?o.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:o.path=t.path:o.path="/"+t.path,o.path=p(o.path)),o.query=t.query):(o.path=e.path,void 0!==t.query?o.query=t.query:o.query=e.query),o.userinfo=e.userinfo,o.host=e.host,o.port=e.port),o.scheme=e.scheme),o.fragment=t.fragment,o}function y(e,t,r){return m(h(f(e,r),f(t,r),r,!0),r)}function v(e,t){return"string"==typeof e?e=m(f(e,t),t):"object"===l(e)&&(e=f(m(e,t),t)),e}function g(e,t,r){return"string"==typeof e?e=m(f(e,r),r):"object"===l(e)&&(e=m(e,r)),"string"==typeof t?t=m(f(t,r),r):"object"===l(t)&&(t=m(t,r)),e===t}function b(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.ESCAPE:w.ESCAPE,n)}function x(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.PCT_ENCODED:w.PCT_ENCODED,a)}var w=r(!1),E=o?r(!0):void 0,$=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?([^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n)*))?/i,C=/^\.\.?\//,k=/^\/\.(\/|$)/,O=/^\/\.\.(\/|$)/,T=/^\/?(?:.|\n)*?(?=\/|$)/,A=void 0==="".match(/(){0}/)[1],S={};return{IRI_SUPPORT:o,VALIDATE_SUPPORT:i,pctEncChar:n,pctDecChars:a,SCHEMES:S,parse:f,_recomposeAuthority:d,removeDotSegments:p,serialize:m,resolveComponents:h,resolve:y,normalize:v,equal:g,escapeComponent:b,unescapeComponent:x}}();if(!n&&"undefined"!=typeof t&&"function"==typeof e){var s=e("./punycode");t.exports=a,e("./schemes")}},{"./punycode":18,"./schemes":19}]},{},[1])(1)})},function(e,t,r){"use strict";function n(e,t){var l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:r.i(i.createDefaults)(),c=arguments[3],u=arguments[4],f=arguments[5],d=arguments[6],p=[],m=[];t=t||[];var h=t.indexOf("*");u=u||{};var y={},v=t.indexOf("...");if("object"===("undefined"==typeof e?"undefined":s(e))&&e.hasOwnProperty("properties")){f=f||e.readonly||e.readOnly,y=r.i(i.defaultForm)(e,l,c,u);var g=y.lookup;e=g||e,p=p.concat(y.form)}return h!==-1&&(t=t.slice(0,h).concat(p).concat(t.slice(h+1))),y.form&&v!==-1&&!function(){var e=t.map(function(e){return"string"==typeof e?e:e.key?e.key:void 0}).filter(function(e){return void 0!==e});m=m.concat(y.form.map(function(t){var r=e.indexOf(t.key[0])!==-1;if(!r)return t}).filter(function(e){return void 0!==e}))}(),v!==-1&&(t=t.slice(0,v).concat(m).concat(t.slice(v+1))),t.map(function(t){if("string"==typeof t&&(t={key:t}),t.key&&"string"==typeof t.key&&(t.key=r.i(o.parse)(t.key)),t.titleMap&&(t.titleMap=r.i(a.a)(t.titleMap)),t.key){var i=r.i(o.stringify)(t.key);e[i]&&!function(){var r=e[i];r&&Object.keys(r).forEach(function(e){void 0===t[e]&&(t[e]=r[e])})}()}return f===!0&&(t.readonly=!0),t.items&&(t.items=n(e,t.items,l,c,u,t.readonly,d)),t.tabs&&t.tabs.forEach(function(r){r.items&&(r.items=n(e,r.items,l,c,u,t.readonly,d))}),"checkbox"===t.type&&(void 0===t.schema?t.schema={default:!1}:void 0===t.schema.default&&(t.schema.default=!1)),d&&"template"===t.type&&!t.template&&t.templateUrl&&d.push(t),t})}var o=r(0),i=r(3),a=r(1);t.a=n;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e}},function(e,t,r){"use strict";function n(e,t){var r=new Promise(function(t,r){o.resolveRefs(e,{filter:["relative","local","remote"]}).then(function(e){t(e.resolved)}).catch(function(e){r(new Error(e))})});return"function"!=typeof t?r:void r.then(function(e){t(null,e)}).catch(function(e){t(e)})}var o=r(5);r.n(o);t.a=n},function(e,t,r){"use strict";function n(e,t,r){t||(t=this);var n="string"==typeof e?o.parse(e):e;if("undefined"!=typeof r&&1===n.length)return t[n[0]]=r,t;"undefined"!=typeof r&&"undefined"==typeof t[n[0]]&&(t[n[0]]=n.length>2&&i.test(n[1])?[]:{});for(var a=t[n[0]],s=1;s<n.length;s++){if(""===n[s])return;if("undefined"!=typeof r){if(s===n.length-1)return a[n[s]]=r,r;var l=a[n[s]];"undefined"!=typeof l&&null!==l||(l=i.test(n[s+1])?[]:{},a[n[s]]=l),a=l}else a&&(a=a[n[s]])}return a}var o=r(0);t.a=n;var i=/^\d+$/},function(e,t,r){"use strict";function n(e,t,r,n){n=void 0===n||n,r=r||[];var o=function e(t,r,o){if(r(t,o),t.properties&&Object.keys(t.properties).forEach(function(n){var i=o.slice();i.push(n),e(t.properties[n],r,i)}),!n&&t.items){var i=o.slice();i.push(""),e(t.items,r,i)}};o(e,t,r||[])}function o(e,t){t(e),e.items&&e.items.forEach(function(e){o(e,t)}),e.tabs&&e.tabs.forEach(function(e){e.items&&e.items.forEach(function(e){o(e,t)})})}t.a=n,t.b=o},function(e,t,r){"use strict";function n(e,t){if(!e)return{valid:!0};var r=e.schema;if(!r)return{valid:!0};""===t&&(t=void 0),"number"===e.type&&null===t&&(t=void 0);var n={type:"object",properties:{},required:void 0},o=e.key[e.key.length-1];n.properties[o]=r,e.required&&(n.required=[o]);var a={};return"undefined"!=typeof t&&(a[o]=t),i.a.validateResult(a,n)}var o=r(12),i=r.n(o);t.a=n},function(e,t,r){"use strict";var n;!function(o){var i={parse:function(e){if("string"!=typeof e)throw new TypeError("ObjectPath.parse must be passed a string");for(var t,r,n,o,i=0,a=[];i<e.length;)if(t=e.indexOf(".",i),r=e.indexOf("[",i),t===-1&&r===-1)a.push(e.slice(i,e.length)),i=e.length;else if(r===-1||t!==-1&&t<r)a.push(e.slice(i,t)),i=t+1;else if(r>i&&(a.push(e.slice(i,r)),i=r),n=e.slice(r+1,r+2),'"'!==n&&"'"!==n)o=e.indexOf("]",r),o===-1&&(o=e.length),a.push(e.slice(i+1,o)),i="."===e.slice(o+1,o+2)?o+2:o+1;else{for(o=e.indexOf(n+"]",r),o===-1&&(o=e.length);"\\"===e.slice(o-1,o)&&r<e.length;)r++,o=e.indexOf(n+"]",r);a.push(e.slice(i+2,o).replace(new RegExp("\\"+n,"g"),n)),i="."===e.slice(o+2,o+3)?o+3:o+2}return a},stringify:function(e,t){return Array.isArray(e)||(e=[e.toString()]),t='"'===t?'"':"'",e.map(function(e){return"["+t+e.toString().replace(new RegExp(t,"g"),"\\"+t)+t+"]"}).join("")},normalize:function(e,t){return i.stringify(Array.isArray(e)?e:i.parse(e),t)},registerModule:function(e){e.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=i.parse,this.stringify=i.stringify,this.normalize=i.normalize,this.$get=function(){return i}})}};n=function(){return{ObjectPath:i}}.call(t,r,t,e),!(n!==o&&(e.exports=n))}()},function(e,t){e.exports=tv4},function(e,t,r){e.exports=r(4)}])}).call(t,r(2),r(19).setImmediate)},function(e,t){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(r=window)}e.exports=r},,function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(1),o=(r.n(n),r(0)),i=r.n(o),a=r(14),s=r(12),l=r(13),c=r(15),u=r(16),f=r(7),d=r(8),p=r(10),m=r(6),h=r(9),y=r(11),v=r(5),g=[];try{i.a.module("ngSanitize"),g.push("ngSanitize")}catch(e){}try{i.a.module("ui.sortable"),g.push("ui.sortable")}catch(e){}try{i.a.module("angularSpectrumColorpicker"),g.push("angularSpectrumColorpicker")}catch(e){}i.a.module("schemaForm",g).provider("sfPath",u.a).provider("sfBuilder",["sfPathProvider",a.a]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",s.a]).provider("sfErrorMessage",c.a).provider("schemaForm",["sfPathProvider",l.a]).factory("sfSelect",function(){return n.select}).factory("sfValidator",function(){return n.validate}).directive("sfChanged",f.a).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",d.a]).directive("sfMessage",["$injector","sfErrorMessage",p.a]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",m.a]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",y.a]).directive("schemaValidate",["sfValidator","$parse","sfSelect",v.a]).directive("sfKeyController",["schemaForm","sfPath",h.a])},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r){return{restrict:"A",scope:!1,priority:500,require:"ngModel",link:function(t,n,i,a){t.$emit("schemaFormPropagateNgModelController",a);var s=null,l=t.$eval(i.schemaValidate);l.copyValueTo&&a.$viewChangeListeners.push(function(){var e=l.copyValueTo;o.a.forEach(e,function(e){r(e,t.model,a.$modelValue)})});var c=function(r,n){if(!l)return r;if(t.options&&t.options.tv4Validation===!1)return r;var o=e(l,r);Object.keys(a.$error).filter(function(e){return 0===e.indexOf("tv4-")}).forEach(function(e){a.$setValidity(e,!0)});{if(o.valid||a.$pristine&&!n)return r;if(a.$setValidity("tv4-"+o.error.code,!1),s=o.error,a.$validators)return r}};"function"==typeof l.ngModel&&l.ngModel(a),["$parsers","$viewChangeListeners","$formatters"].forEach(function(e){l[e]&&a[e]&&l[e].forEach(function(t){a[e].push(t)})}),["$validators","$asyncValidators"].forEach(function(e){l[e]&&a[e]&&o.a.forEach(l[e],function(r,n){a[e][n]=function(e,n){return r(e,n,t.model,l)}})}),a.$parsers.push(c),a.$validators&&(a.$validators.schemaForm=function(){return!Object.keys(a.$error).some(function(e){return"schemaForm"!==e})});var u=l.schema;t.validateField=function(e,t){var r=void 0===e;(r||a.$$parentForm.$name===e)&&((r||u&&u.type.indexOf("array")!==-1)&&c(a.$modelValue,t),a.$setDirty?(a.$setDirty(),a.$setViewValue(a.$viewValue),a.$commitViewValue(),"checkbox"===l.type?l.required&&void 0===a.$modelValue&&a.$setValidity("tv4-302",!1):l.required&&a.$isEmpty(a.$modelValue)&&a.$setValidity("tv4-302",!1)):a.$setViewValue(a.$viewValue))};var f=!0;a.$formatters.push(function(e){return!a.$pristine||!f||t.options&&t.options.validateOnRender===!0?(c(a.$modelValue),e):(f=!1,e)}),t.$on("schemaFormValidate",function(e,r){t.validateField(r,!0)}),t.schemaError=function(){return s}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r){return{scope:!0,controller:["$scope",function(e){this.key=e.form&&e.form.key?e.form.key.splice(0,-2):[]}],link:function(n,a,s){n.min=0,n.trackBy=function(e,t){return e&&"object"===("undefined"==typeof e?"undefined":i(e))?e:t},n.modelArray=n.$eval(s.sfNewArray);var l=function(){n.modelArray=n.$eval(s.sfNewArray),n.ngModel&&n.ngModel.$pristine&&n.firstDigest&&(!n.options||n.options.validateOnRender!==!0)||n.validateField&&n.validateField()},c=function(){n.form&&n.form.onChange&&(o.a.isFunction(n.form.onChange)?n.form.onChange(n.modelArray,n.form):n.evalExpr(n.form.onChange,{modelValue:n.modelArray,form:n.form}))},u=function(){var r=n.modelArray;if(!r){var o=t.parse(s.sfNewArray);r=[],e(o,n,r),n.modelArray=r}return r},f=n.$watch("form",function(e){if(e){if(e.titleMap||e.startEmpty===!0||n.modelArray&&0!==n.modelArray.length||n.appendToArray(),n.$watch(function(e){return JSON.stringify(e.modelArray)},function(){l(),c()}),e.titleMap&&e.titleMap.length>0){n.titleMapValues=[];var t=function(t){n.titleMapValues=[],t=t||[],e.titleMap.forEach(function(e){n.titleMapValues.push(t.indexOf(e.value)!==-1)})};t(n.modelArray),n.$watchCollection("modelArray",t),n.$watchCollection("titleMapValues",function(t,r){if(t&&t!==r){var o=u();e.titleMap.forEach(function(e,r){var n=o.indexOf(e.value);n===-1&&t[r]&&o.push(e.value),n===-1||t[r]||o.splice(n,1)}),n.validateField&&n.validateField()}})}f()}});n.appendToArray=function(){var t,i=u();if(n.form&&n.form.schema&&n.form.schema.items){var a=n.form.schema.items;a.type&&a.type.indexOf("object")!==-1?(t={},n.options&&n.options.setSchemaDefaults===!1||(t=o.a.isDefined(a.default)?a.default:t,t&&r.traverseSchema(a,function(r,n){o.a.isDefined(r.default)&&e(n,t,r.default)}))):(a.type&&(a.type.indexOf("array")!==-1?t=[]:a.type.indexOf("string")===-1&&a.type.indexOf("number")===-1||(t="")),n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t))}return i.push(t),i},n.deleteFromArray=function(e){var t=n.modelArray.indexOf(e),r=n.modelArray;return r&&r.splice(t,1),e.$$hashKey&&(n.destroyed=e.$$hashKey),r};var d=function(e){return function(t){t.key&&(t.key[t.key.indexOf("")]=e)}},p={};n.copyWithIndex=function(e){var t=n.form;if(!p[e]){var i=t.items[0];if(t.items.length>1&&(i={type:"section",items:t.items.map(function(e){return e.ngModelOptions=t.ngModelOptions,o.a.isUndefined(e.readonly)&&(e.readonly=t.readonly),e})}),i){var a=o.a.copy(i);a.arrayIndex=e,r.traverseForm(a,d(e)),p[e]=a}}return p[e]}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){return{require:"ngModel",restrict:"AC",scope:!1,link:function(e,t,r,n){var i=e.$eval(r.sfChanged);i&&i.onChange&&n.$viewChangeListeners.push(function(){o.a.isFunction(i.onChange)?i.onChange(n.$modelValue,i):e.evalExpr(i.onChange,{modelValue:n.$modelValue,form:i,arrayIndex:e.$index,arrayIndices:e.arrayIndices,path:e.path,$i:e.$i,$index:e.$index})})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r,n,a,s,l,c,u){var f={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function(e,t,r,n){var o=n[0];n[1],n[2];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.initialForm=Object.assign({},o.lookup["f"+r.sfField]),e.form=o.lookup["f"+r.sfField]},post:function(e,t,r,n){var s=n[0],d=n[1];n[2];e.getKey=function(t){var r=t||f.COMPLETE,n=e.parentKey?e.parentKey.slice(0,e.parentKey.length-1):[];if(e.completeKey!==e.form.key&&("number"==typeof e.$index&&(n=n.concat(e.$index)),e.form.key&&e.form.key.length))if("number"==typeof n[n.length-1]&&e.form.key.length>=1){var o=e.form.key.length-n.length;e.completeKey=n.concat(e.form.key.slice(-o))}else e.completeKey=e.form.key.slice();if(Array.isArray(e.completeKey))return r===f.COMPLETE?e.completeKey:e.completeKey.reduce(function(e,t,n){return-1!==[r].indexOf("undefined"==typeof t?"undefined":i(t))?e.concat(t):e},[])},e.form.key&&(e.form.key=e.completeKey=e.getKey()),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=r||!1,o=t&&d&&d.$name?d.$name:void 0,i=e.completeKey;return Array.isArray(i)?c.name(i,"-",o,n):""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(s?s.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return s?s.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&a(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.errors===!1?e.ngModel.$invalid&&!e.ngModel.$pristine:e.ngModel.$invalid)},e.errorMessage=function(t){return l.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)},e.form.htmlClass=e.form.htmlClass||"",e.idClass=e.fieldId(!1)+" "+e.fieldId(!1,!0);var p=e.form;p.key&&(e.$on("schemaForm.error."+p.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(p.validationMessage||(p.validationMessage={}),p.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){var t=e.getKey();"number"==typeof e.arrayIndex?e.arrayIndex+1:0;if(!e.externalDestructionInProgress){var r=p.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(t&&"retain"!==r){var n=e.model;if(t.length>1&&(n=u(t.slice(0,t.length-1),n)),n&&e.destroyed&&n.$$hashKey&&n.$$hashKey!==e.destroyed)return;if(void 0===n)return;var o=p.schema&&p.schema.type||"";"empty"===r&&o.indexOf("string")!==-1?n[t.slice(-1)]="":"empty"===r&&o.indexOf("object")!==-1?n[t.slice(-1)]={}:"empty"===r&&o.indexOf("array")!==-1?n[t.slice(-1)]=[]:"null"===r?n[t.slice(-1)]=null:delete n[t.slice(-1)]}}}))}}}}},function(e,t,r){"use strict";t.a=function(e,t){return{scope:!0,require:["?^^sfNewArray"],link:{pre:function(e,r,n,o){e.parentKey=e.parentKey||[];var i=t.parse(n.sfParentKey),a=i.length-e.parentKey.length;i.length>1&&(i=i.splice(-a)),e.parentKey=e.parentKey.concat(i,Number(n.sfIndex)),e.arrayIndex=Number(n.sfIndex),e.arrayIndices=e.arrayIndices||[],e.arrayIndices=e.arrayIndices.concat(e.arrayIndex),e.$i=e.arrayIndices,e.path=function(t){var r=-1;return t=t.replace(/\[\]/gi,function(t){return r++,"["+e.$i[r]+"]"}),e.evalExpr(t,e)}}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r=e.has("$sanitize")?e.get("$sanitize"):function(e){return e};return{scope:!1,restrict:"EA",link:function(e,n,i){var a="";i.sfMessage&&e.$watch(i.sfMessage,function(t){t&&(a=r(t),c(!!e.ngModel))});var s,l=function(e){e!==s&&(n.html(e),s=e)},c=function(r){if(r)if(e.hasError()){var n=[];o.a.forEach(e.ngModel&&e.ngModel.$error,function(e,t){e&&n.push(t)}),n=n.filter(function(e){return"schemaForm"!==e});var i=n[0];l(i?t.interpolate(i,e.ngModel.$modelValue,e.ngModel.$viewValue,e.form,e.options&&e.options.validationMessage):a)}else l(a);else l(a)};c();var u=e.$watch("ngModel",function(e){e&&(e.$parsers.push(function(e){return c(!0),e}),e.$formatters.push(function(e){return c(!0),e}),u())});e.$watchCollection("ngModel.$error",function(){c(!!e.ngModel)})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r,n,i,a,s,l,c){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function(e){this.$onInit=function(){this.evalInParentScope=function(t,r){return e.$parent.$eval(t,r)};var t=this;e.lookup=function(e){return e&&(t.lookup=e),t.lookup}},1===o.a.version.major&&o.a.version.minor<5&&this.$onInit()}],replace:!1,restrict:"A",transclude:!0,require:"?form",link:function(l,u,f,d,p){l.formCtrl=d;var m={};p(l,function(e){if(e.addClass("schema-form-ignore"),u.prepend(e),u[0].querySelectorAll){var t=u[0].querySelectorAll("[ng-model]");if(t)for(var r=0;r<t.length;r++){var n=t[r].getAttribute("ng-model");m[n.substring(n.indexOf(".")+1)]=!0}}});var h,y={};l.resolveReferences=function(e,t){i.jsonref(e).then(function(e){l.render(e,t)}).catch(function(e){new Error(e)})},l.render=function(e,o){var a=[],s=i.merge(e,o,void 0,m,l.options,void 0,a);a.length>0?n.all(a.map(function(e){return t.get(e.templateUrl,{cache:r}).then(function(t){e.template=t.data})})).then(function(){l.internalRender(e,o,s)}):l.internalRender(e,o,s)},l.internalRender=function(t,r,n){h&&(l.externalDestructionInProgress=!0,h.$destroy(),l.externalDestructionInProgress=!1),h=l.$new(),h.schemaForm={form:n,schema:t},Array.prototype.forEach.call(u.children(),function(e){var t=o.a.element(e);!1===t.hasClass("schema-form-ignore")&&t.remove()});for(var d={},p=u[0].querySelectorAll("*[sf-insert-field]"),m=0;m<p.length;m++)d[p[m].getAttribute("sf-insert-field")]=p[m];var y=a.decorator(f.sfUseDecorator),v=Object.create(null);l.lookup(v),u[0].appendChild(c.build(n,y,d,v)),h.firstDigest=!0,setTimeout(function(){h.firstDigest=!1,l.$apply()},0),e(u.children())(h),l.options&&l.options.setSchemaDefaults===!1||i.traverseSchema(t,function(e,t){if(o.a.isDefined(e.default)){var r=s(t,l.model);o.a.isUndefined(r)&&s(t,l.model,e.default)}}),l.$emit("sf-render-finished",u)};var v=["*"];l.$watch(function(){var e=l.schema,t=l.initialForm||v;t&&e&&e.type&&(y.form!==t||y.schema!==e)&&((!e.properties||0===Object.keys(e.properties).length)&&(t.indexOf("*")||t.indexOf("...")),y.schema=e,y.form=t,l.resolveReferences(e,t))}),l.$on("schemaFormRedraw",function(){var e=l.schema,t=l.initialForm?o.a.copy(l.initialForm):["*"];e&&l.resolveReferences(e,t)}),l.$on("$destroy",function(){l.externalDestructionInProgress=!0}),l.evalExpr=function(e,t){return l.$parent.$eval(e,t)}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r="",n={},i=function(e,t){"sfDecorator"===e&&(e=r);var o=n[e];return o[t.type]?o[t.type].template:o.default.template},a=function(r){e.directive(r,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function(e,n,a,s,l,c,u,f,d){return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["?^sfSchema","?^form"],link:function(e,p,m,h){var y=h[0],v=h[1];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=e.parentKey||[];if(e.form.key){if("number"==typeof n[n.length-1]){var o=n.concat(e.form.key.slice(-1)),i=t&&v&&v.$name?v.$name:void 0;return f.name(o,"-",i,r)}var i=t&&v&&v.$name?v.$name:void 0;return f.name(e.form.key,"-",i,r)}return""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(y?y.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return y?y.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&l(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.ngModel.$invalid&&!e.ngModel.$pristine)},e.errorMessage=function(t){return u.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)};var g=e.$watch(m.form,function(l){if(l){l.ngModelOptions=l.ngModelOptions||{},e.form=l;var u;if("template"===l.type&&l.template)u=c.when(l.template);else{var m="template"===l.type?l.templateUrl:i(r,l);u=a.get(m,{cache:s}).then(function(e){return e.data})}u.then(function(r){if(l.key){var i=l.key?t.stringify(l.key).replace(/"/g,"&quot;"):"";r=r.replace(/\$\$value\$\$/g,"model"+("["!==i[0]?".":"")+i)}if(p.html(r),l.condition){var a='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';l.key&&(a='evalExpr(form.condition, {model: model, "arrayIndex": arrayIndex, "modelValue": model'+f.stringify(l.key)+"})"),o.a.forEach(p.children(),function(e){var t=e.getAttribute("ng-if");e.setAttribute("ng-if",t?"("+t+") || ("+a+")":a)})}n(p.contents())(e)}),l.key&&(e.$on("schemaForm.error."+l.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(l.validationMessage||(l.validationMessage={}),l.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){if(!e.externalDestructionInProgress){var t=l.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(l.key&&"retain"!==t){var r=e.model;if(l.key.length>1&&(r=d(l.key.slice(0,l.key.length-1),r)),void 0===r)return;var n=l.schema&&l.schema.type||"";"empty"===t&&n.indexOf("string")!==-1?r[l.key.slice(-1)]="":"empty"===t&&n.indexOf("object")!==-1?r[l.key.slice(-1)]={}:"empty"===t&&n.indexOf("array")!==-1?r[l.key.slice(-1)]=[]:"null"===t?r[l.key.slice(-1)]=null:delete r[l.key.slice(-1)]}}})),g()}})}}}])},s=function(t,r,n){n=!!o.a.isDefined(n)&&n,e.directive("sf"+o.a.uppercase(t[0])+t.substr(1),function(){return{restrict:"EAC",scope:!0,replace:!0,transclude:n,template:'<sf-decorator form="form"></sf-decorator>',link:function(e,r,n){var i={items:"c",titleMap:"c",schema:"c"
+},a={type:t},s=!0;o.a.forEach(n,function(t,r){if("$"!==r[0]&&0!==r.indexOf("ng")&&"sfField"!==r){var l=function(t){o.a.isDefined(t)&&t!==a[r]&&(a[r]=t,s&&a.type&&(a.key||o.a.isUndefined(n.key))&&(e.form=a,s=!1))};"model"===r?e.$watch(t,function(t){t&&e.model!==t&&(e.model=t)}):"c"===i[r]?e.$watchCollection(t,l):n.$observe(r,l)}})}}})};this.createDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){n[e][r]={template:t,replace:!1,builder:[]}}),n[r]||(r=e),a(e)},this.defineDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){t.builder=t.builder||[],t.replace=!o.a.isDefined(t.replace)||t.replace,n[e][r]=t}),n[r]||(r=e),a(e)},this.createDirective=s,this.createDirectives=function(e){o.a.forEach(e,function(e,t){s(t,e)})},this.decorator=function(e){return e=e||r,n[e]},this.addMapping=function(e,t,r,o,i){n[e]&&(n[e][t]={template:r,builder:o,replace:!!i})},this.defineAddOn=function(e,t,r,o){n[e]&&(n[e][t]={template:r,builder:o,replace:!0})},this.$get=function(){return{decorator:function(e){return n[e]||n[r]},defaultDecorator:r}},a("sfDecorator")}},function(e,t,r){"use strict";var n=r(0),o=(r.n(n),r(1));r.n(o);t.a=function(){var e=function(e){return e},t=o.schemaDefaults.createDefaults();this.defaults=t,this.stdFormObj=o.schemaDefaults.stdFormObj,this.defaultFormDefinition=o.schemaDefaults.defaultFormDefinition,this.postProcess=function(t){e=t},this.appendRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].push(t)},this.prependRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].unshift(t)},this.createStandardForm=o.schemaDefaults.stdFormObj,this.$get=function(){var t={},n=this.defaults;return t.jsonref=o.jsonref,t.defaults=function(e,t,r,i){var a=t||n;return o.schemaDefaults.defaultForm(e,a,r,i)},t.merge=function(n){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["*"],a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.typeDefault,s=arguments[3],l=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},c=arguments.length>5&&void 0!==arguments[5]&&arguments[5],u=arguments[6],f=r.i(o.merge)(n,i,a,s,l,c,u);return e(f)},t.typeDefault=n,t.traverseSchema=o.traverseSchema,t.traverseForm=o.traverseForm,t}}},function(e,t,r){"use strict";t.a=function(e){var t=/[A-Z]/g,r=function(e,r){return r=r||"_",e.replace(t,function(e,t){return(t?r:"")+e.toLowerCase()})},n=0;"firstElementChild"in document.createDocumentFragment()||Object.defineProperty(DocumentFragment.prototype,"firstElementChild",{get:function(){for(var e,t=this.childNodes,r=0,n=t.length;r<n;++r)if(e=t[r],1===e.nodeType)return e;return null}});var o={sfField:function(e){e.fieldFrag.firstElementChild.setAttribute("sf-field",n),e.lookup["f"+n]=e.form,n++},ngModel:function(t){if(t.form.key){var r=t.form.key;t.state.keyRedaction&&(r=r.slice(t.state.keyRedaction));var n;if(t.state.modelValue)n=t.state.modelValue;else{var o=e.stringify(r).replace(/"/g,"&quot;");n=t.state.modelName||"model",o&&(n+=("["!==o[0]?".":"")+o)}for(var i=t.fieldFrag.querySelectorAll("[sf-field-model]"),a=0;a<i.length;a++){var s=i[a],l=s.getAttribute("sf-field-model");if(l&&""!==l)if("replaceAll"===l)for(var c=s.attributes,u=0;u<c.length;u++)c[u].value&&c[u].value.indexOf("$$value")!==-1&&(c[u].value=c[u].value.replace(/\$\$value\$\$/g,n));else{var f=s.getAttribute(l);f&&f.indexOf("$$value$$")?s.setAttribute(l,f.replace(/\$\$value\$\$/g,n)):s.setAttribute(l,n)}else s.setAttribute("ng-model",n)}}},simpleTransclusion:function(e){var t=e.build(e.form.items,e.path+".items",e.state);e.fieldFrag.firstChild.appendChild(t)},ngModelOptions:function(e){e.form.ngModelOptions&&Object.keys(e.form.ngModelOptions).length>0&&e.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(e.form.ngModelOptions))},transclusion:function(e){var t=e.fieldFrag.querySelectorAll("[sf-field-transclude]");if(t.length)for(var r=0;r<t.length;r++){var n=t[r],o=n.getAttribute("sf-field-transclude")||"items",i=e.form[o];if(i){var a=e.build(i,e.path+"."+o,e.state);n.appendChild(a)}}},condition:function(t){var r="",n="undefined",o="";if(t.form.condition){t.form.key&&(r=e.stringify(t.form.key),n="model"+("["===r[0]?"":".")+r);for(var i="evalExpr("+t.path+'.condition, { model: model, "arrayIndex": $index, "arrayIndices": arrayIndices, "path": path, "$i": $i, "$index": $index, "modelValue": '+n+"})",a=t.fieldFrag.children||t.fieldFrag.childNodes,s=0;s<a.length;s++){var l=a[s];l.hasAttribute&&l.hasAttribute("ng-if")&&(o=l.getAttribute("ng-if")),l.setAttribute&&l.setAttribute("ng-if",o?"("+o+") || ("+i+")":i)}}},array:function(t){var r=t.fieldFrag.querySelector("[schema-form-array-items]");if(t.form.key){t.form.key.filter(function(e){return""===e}).length}if(r){var n=angular.copy(t.state);if(n.keyRedaction=0,n.keyRedaction+=t.form.key.length+1,t.form.schema&&t.form.schema.items&&t.form.schema.items.type&&t.form.schema.items.type.indexOf("object")===-1&&t.form.schema.items.type.indexOf("array")===-1){e.stringify(t.form.key).replace(/"/g,"&quot;")+"[$index]";n.modelValue="modelArray[$index]"}else n.modelName="item";n.arrayCompatFlag=!0;var o=t.build(t.form.items,t.path+".items",n);r.appendChild(o)}},numeric:function(e){var t=e.fieldFrag.querySelector("input"),r=e.form.maximum||!1,n=e.form.exclusiveMaximum||!1,o=e.form.minimum||!1,i=e.form.exclusiveMinimum||!1,a=e.form.multipleOf||!1;t&&(a!==!1&&t.setAttribute("step",a),r!==!1&&(n!==!1&&a!==!1&&(r-=a),t.setAttribute("max",r)),o!==!1&&(i!==!1&&a!==!1&&(o+=a),t.setAttribute("min",o)))}};this.builders=o;var i=[o.sfField,o.ngModel,o.ngModelOptions,o.condition];this.stdBuilders=i,this.$get=["$templateCache","schemaFormDecorators","sfPath",function(e,t,n){var a=function(e,t){if(e.key){var r=t[n.stringify(e.key)];if(r){for(;r.firstChild;)r.removeChild(r.firstChild);return r}}},s=function e(t,n,o,i,s,l,c){l=l||{},l=l||{},c=c||Object.create(null),s=s||"schemaForm.form";var u=document.createDocumentFragment();return t.reduce(function(t,u,f){if(!u.type)return t;var d=n[u.type]||n.default;if(d.replace){var p;l.arrayCompatFlag=!1;var m=document.createElement("div"),h=o(u,d)||o(u,n.default);for(m.innerHTML=h,p=document.createDocumentFragment();m.childNodes.length>0;)p.appendChild(m.childNodes[0]);var y={fieldFrag:p,form:u,lookup:c,state:l,path:s+"["+f+"]",build:function(t,r,a){return e(t,n,o,i,r,a,c)}},v=u.builder||d.builder;"function"==typeof v?v(y):v.forEach(function(e){e(y)}),(a(u,i)||t).appendChild(p)}else{var g=document.createElement(r(n.__name,"-"));l.arrayCompatFlag?g.setAttribute("form","copyWithIndex($index)"):g.setAttribute("form",s+"["+f+"]"),(a(u,i)||t).appendChild(g)}return t},u),u};return{build:function(t,r,n,o){return s(t,r,function(t,r){return"template"===t.type?t.template:e.get(r.template)},n,void 0,void 0,o)},builder:o,stdBuilders:i,internalBuild:s}}]}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){var e={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};e.number=e[105],e.required=e[302],e.min=e[101],e.max=e[103],e.maxlength=e[201],e.minlength=e[200],e.pattern=e[202],this.setDefaultMessages=function(t){e=t},this.getDefaultMessages=function(){return e},this.setDefaultMessage=function(t,r){e[t]=r},this.$get=["$interpolate",function(t){var r={};return r.defaultMessages=e,r.interpolate=function(r,n,i,a,s){s=s||{};var l=a.validationMessage||{};0===r.indexOf("tv4-")&&(r=r.substring(4));var c=l.default||s.default||"";[l,s,e].some(function(e){return o.a.isString(e)||o.a.isFunction(e)?(c=e,!0):e&&e[r]?(c=e[r],!0):void 0});var u={error:r,value:n,viewValue:i,form:a,schema:a.schema,title:a.title||a.schema&&a.schema.title};return o.a.isFunction(c)?c(u):t(c)(u)},r}]}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=r(1),i=(r.n(o),r(0)),a=(r.n(i),function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}()),s=function(){function e(){n(this,e),this.name=o.sfPath.name,this.parse=o.sfPath.parse,this.stringify=o.sfPath.stringify,this.normalize=o.sfPath.normalize}return a(e,[{key:"$get",value:function(){return o.sfPath}}]),e}();t.a=s},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):y=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++y<t;)p&&p[y].run();y=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,y=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},function(e,t,r){(function(e,t){!function(e,r){"use strict";function n(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var n={callback:e,args:t};return h[m]=n,p(m),m++}function o(e){delete h[e]}function i(e){var t=e.callback,n=e.args;switch(n.length){case 0:t();break;case 1:t(n[0]);break;case 2:t(n[0],n[1]);break;case 3:t(n[0],n[1],n[2]);break;default:t.apply(r,n)}}function a(e){if(y)setTimeout(a,0,e);else{var t=h[e];if(t){y=!0;try{i(t)}finally{o(e),y=!1}}}}function s(){p=function(e){t.nextTick(function(){a(e)})}}function l(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}function c(){var t="setImmediate$"+Math.random()+"$",r=function(r){r.source===e&&"string"==typeof r.data&&0===r.data.indexOf(t)&&a(+r.data.slice(t.length))};e.addEventListener?e.addEventListener("message",r,!1):e.attachEvent("onmessage",r),p=function(r){e.postMessage(t+r,"*")}}function u(){var e=new MessageChannel;e.port1.onmessage=function(e){var t=e.data;a(t)},p=function(t){e.port2.postMessage(t)}}function f(){var e=v.documentElement;p=function(t){var r=v.createElement("script");r.onreadystatechange=function(){a(t),r.onreadystatechange=null,e.removeChild(r),r=null},e.appendChild(r)}}function d(){p=function(e){setTimeout(a,0,e)}}if(!e.setImmediate){var p,m=1,h={},y=!1,v=e.document,g=Object.getPrototypeOf&&Object.getPrototypeOf(e);g=g&&g.setTimeout?g:e,"[object process]"==={}.toString.call(e.process)?s():l()?c():e.MessageChannel?u():v&&"onreadystatechange"in v.createElement("script")?f():d(),g.setImmediate=n,g.clearImmediate=o}}("undefined"==typeof self?"undefined"==typeof e?this:e:self)}).call(t,r(2),r(17))},function(r,n,o){function i(e,t){this._id=e,this._clearFn=t}var a=Function.prototype.apply;n.setTimeout=function(){return new i(a.call(setTimeout,window,arguments),clearTimeout)},n.setInterval=function(){return new i(a.call(setInterval,window,arguments),clearInterval)},n.clearTimeout=n.clearInterval=function(e){e&&e.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(window,this._id)},n.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},n.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},n._unrefActive=n.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},o(18),n.setImmediate=e,n.clearImmediate=t},,function(e,t,r){r(1),e.exports=r(4)}])}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):y=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++y<t;)p&&p[y].run();y=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,y=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},,,function(e,t,r){r(19),e.exports=r(0)}]);
\ No newline at end of file
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index f5b5353..f22bac4 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.4
- * @date Mon, 03 Apr 2017 13:11:24 GMT
+ * @date Mon, 17 Apr 2017 08:57:43 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -353,24 +353,24 @@ function bootstrapDecoratorConfig(
   var defaults = [sfField, ngModel, ngModelOptions, condition];
   decoratorsProvider.defineDecorator('bootstrapDecorator', {
     actions: {template: __WEBPACK_IMPORTED_MODULE_0__bootstrap_actions_html___default.a, builder: defaults},
-    array: {template: __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    array: {template: __WEBPACK_IMPORTED_MODULE_1__bootstrap_array_html___default.a, builder: [ sfField, ngModelOptions, ngModel, array, condition ]},
     button: {template: __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html___default.a, builder: defaults},
     checkbox: {template: __WEBPACK_IMPORTED_MODULE_2__bootstrap_checkbox_html___default.a, builder: defaults},
-    checkboxes: {template: __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    conditional: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    checkboxes: {template: __WEBPACK_IMPORTED_MODULE_3__bootstrap_checkboxes_html___default.a, builder: [ sfField, ngModelOptions, ngModel, array, condition ]},
+    conditional: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default.a, builder: [ sfField, simpleTransclusion, condition ]},
     'default': {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default.a, builder: defaults},
-    fieldset: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html___default.a, builder: [sfField, simpleTransclusion, condition]},
+    fieldset: {template: __WEBPACK_IMPORTED_MODULE_5__bootstrap_fieldset_html___default.a, builder: [ sfField, simpleTransclusion, condition ]},
     help: {template: __WEBPACK_IMPORTED_MODULE_6__bootstrap_help_html___default.a, builder: defaults},
     number: {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default.a, builder: defaults.concat(numeric)},
     password: {template: __WEBPACK_IMPORTED_MODULE_4__bootstrap_default_html___default.a, builder: defaults},
     radios: {template: __WEBPACK_IMPORTED_MODULE_8__bootstrap_radios_html___default.a, builder: defaults},
     'radios-inline': {template: __WEBPACK_IMPORTED_MODULE_9__bootstrap_radios_inline_html___default.a, builder: defaults},
     radiobuttons: {template: __WEBPACK_IMPORTED_MODULE_7__bootstrap_radio_buttons_html___default.a, builder: defaults},
-    section: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default.a, builder: [sfField, simpleTransclusion, condition]},
-    select: {template: __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html___default.a, builder: defaults.concat(selectPlaceholder)},
+    section: {template: __WEBPACK_IMPORTED_MODULE_10__bootstrap_section_html___default.a, builder: [ sfField, simpleTransclusion, condition ]},
+    select: {template: __WEBPACK_IMPORTED_MODULE_11__bootstrap_select_html___default.a, builder: [ selectPlaceholder ].concat(defaults)},
     submit: {template: __WEBPACK_IMPORTED_MODULE_12__bootstrap_submit_html___default.a, builder: defaults},
-    tabarray: {template: __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html___default.a, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    tabs: {template: __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html___default.a, builder: [sfField, ngModelOptions, tabs, condition]},
+    tabarray: {template: __WEBPACK_IMPORTED_MODULE_13__bootstrap_tabarray_html___default.a, builder: [ sfField, ngModelOptions, ngModel, array, condition ]},
+    tabs: {template: __WEBPACK_IMPORTED_MODULE_14__bootstrap_tabs_html___default.a, builder: [ sfField, ngModelOptions, tabs, condition ]},
     textarea: {template: __WEBPACK_IMPORTED_MODULE_15__bootstrap_textarea_html___default.a, builder: defaults},
   }, []);
 };
diff --git a/dist/angular-schema-form-bootstrap.min.js b/dist/angular-schema-form-bootstrap.min.js
index 5fdcba0..7edc052 100644
--- a/dist/angular-schema-form-bootstrap.min.js
+++ b/dist/angular-schema-form-bootstrap.min.js
@@ -1,9 +1,9 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.4
- * @date Mon, 03 Apr 2017 13:11:24 GMT
+ * @date Mon, 17 Apr 2017 08:57:43 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function r(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return e[a].call(l.exports,l,l.exports,r),l.l=!0,l.exports}var n={};return r.m=e,r.c=n,r.i=function(e){return e},r.d=function(e,r,n){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=24)}([function(e,r,n){n(18)},,function(e,r){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r,n){"use strict";function a(e,r,n,a,l){var s=n.builders.simpleTransclusion,i=n.builders.ngModelOptions,m=n.builders.ngModel,c=n.builders.sfField,p=n.builders.condition,h=n.builders.array,v=n.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var r=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(n,a){var l="(evalExpr("+e.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=e.build(n.items,e.path+".tabs["+a+"].items",e.state);t.appendChild(s),r.appendChild(t)})}},C=function(e){if(e.form.placeholder){var r=e.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=e.form.placeholder,r.appendChild(n)}},k=[c,m,i,p];r.defineDecorator("bootstrapDecorator",{actions:{template:t.a,builder:k},array:{template:o.a,builder:[c,i,m,h,p]},button:{template:H.a,builder:k},checkbox:{template:d.a,builder:k},checkboxes:{template:f.a,builder:[c,i,m,h,p]},conditional:{template:A.a,builder:[c,s,p]},default:{template:u.a,builder:k},fieldset:{template:b.a,builder:[c,s,p]},help:{template:g.a,builder:k},number:{template:u.a,builder:k.concat(v)},password:{template:u.a,builder:k},radios:{template:$.a,builder:k},"radios-inline":{template:w.a,builder:k},radiobuttons:{template:y.a,builder:k},section:{template:A.a,builder:[c,s,p]},select:{template:E.a,builder:k.concat(C)},submit:{template:H.a,builder:k},tabarray:{template:M.a,builder:[c,i,m,h,p]},tabs:{template:L.a,builder:[c,i,x,p]},textarea:{template:D.a,builder:k}},[])}var l=n(2),t=n.n(l),s=n(3),o=n.n(s),i=n(4),d=n.n(i),m=n(5),f=n.n(m),c=n(6),u=n.n(c),p=n(7),b=n.n(p),h=n(8),g=n.n(h),v=n(9),y=n.n(v),x=n(11),$=n.n(x),C=n(10),w=n.n(C),k=n(12),A=n.n(k),S=n(13),E=n.n(S),I=n(14),H=n.n(I),T=n(15),M=n.n(T),R=n(16),L=n.n(R),j=n(17),D=n.n(j);angular.module("schemaForm").config(a),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,,function(e,r,n){e.exports=n(0)}]);
\ No newline at end of file
+!function(e){function r(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return e[a].call(l.exports,l,l.exports,r),l.l=!0,l.exports}var n={};return r.m=e,r.c=n,r.i=function(e){return e},r.d=function(e,r,n){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=24)}([function(e,r,n){n(18)},,function(e,r){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r,n){"use strict";function a(e,r,n,a,l){var s=n.builders.simpleTransclusion,i=n.builders.ngModelOptions,m=n.builders.ngModel,c=n.builders.sfField,p=n.builders.condition,h=n.builders.array,v=n.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var r=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(n,a){var l="(evalExpr("+e.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=e.build(n.items,e.path+".tabs["+a+"].items",e.state);t.appendChild(s),r.appendChild(t)})}},C=function(e){if(e.form.placeholder){var r=e.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=e.form.placeholder,r.appendChild(n)}},k=[c,m,i,p];r.defineDecorator("bootstrapDecorator",{actions:{template:t.a,builder:k},array:{template:o.a,builder:[c,i,m,h,p]},button:{template:H.a,builder:k},checkbox:{template:d.a,builder:k},checkboxes:{template:f.a,builder:[c,i,m,h,p]},conditional:{template:A.a,builder:[c,s,p]},default:{template:u.a,builder:k},fieldset:{template:b.a,builder:[c,s,p]},help:{template:g.a,builder:k},number:{template:u.a,builder:k.concat(v)},password:{template:u.a,builder:k},radios:{template:$.a,builder:k},"radios-inline":{template:w.a,builder:k},radiobuttons:{template:y.a,builder:k},section:{template:A.a,builder:[c,s,p]},select:{template:E.a,builder:[C].concat(k)},submit:{template:H.a,builder:k},tabarray:{template:M.a,builder:[c,i,m,h,p]},tabs:{template:L.a,builder:[c,i,x,p]},textarea:{template:D.a,builder:k}},[])}var l=n(2),t=n.n(l),s=n(3),o=n.n(s),i=n(4),d=n.n(i),m=n(5),f=n.n(m),c=n(6),u=n.n(c),p=n(7),b=n.n(p),h=n(8),g=n.n(h),v=n(9),y=n.n(v),x=n(11),$=n.n(x),C=n(10),w=n.n(C),k=n(12),A=n.n(k),S=n(13),E=n.n(S),I=n(14),H=n.n(I),T=n(15),M=n.n(T),R=n(16),L=n.n(R),j=n(17),D=n.n(j);angular.module("schemaForm").config(a),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,,function(e,r,n){e.exports=n(0)}]);
\ No newline at end of file
diff --git a/src/bootstrap-decorator.js b/src/bootstrap-decorator.js
index ba94cc2..e209399 100644
--- a/src/bootstrap-decorator.js
+++ b/src/bootstrap-decorator.js
@@ -90,24 +90,24 @@ function bootstrapDecoratorConfig(
   var defaults = [sfField, ngModel, ngModelOptions, condition];
   decoratorsProvider.defineDecorator('bootstrapDecorator', {
     actions: {template: actionsTemplate, builder: defaults},
-    array: {template: arrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition]},
+    array: {template: arrayTemplate, builder: [ sfField, ngModelOptions, ngModel, array, condition ]},
     button: {template: submitTemplate, builder: defaults},
     checkbox: {template: checkboxTemplate, builder: defaults},
-    checkboxes: {template: checkboxesTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    conditional: {template: sectionTemplate, builder: [sfField, simpleTransclusion, condition]},
+    checkboxes: {template: checkboxesTemplate, builder: [ sfField, ngModelOptions, ngModel, array, condition ]},
+    conditional: {template: sectionTemplate, builder: [ sfField, simpleTransclusion, condition ]},
     'default': {template: defaultTemplate, builder: defaults},
-    fieldset: {template: fieldsetTemplate, builder: [sfField, simpleTransclusion, condition]},
+    fieldset: {template: fieldsetTemplate, builder: [ sfField, simpleTransclusion, condition ]},
     help: {template: helpTemplate, builder: defaults},
     number: {template: defaultTemplate, builder: defaults.concat(numeric)},
     password: {template: defaultTemplate, builder: defaults},
     radios: {template: radiosTemplate, builder: defaults},
     'radios-inline': {template: radiosInlineTemplate, builder: defaults},
     radiobuttons: {template: radiobuttonsTemplate, builder: defaults},
-    section: {template: sectionTemplate, builder: [sfField, simpleTransclusion, condition]},
-    select: {template: selectTemplate, builder: defaults.concat(selectPlaceholder)},
+    section: {template: sectionTemplate, builder: [ sfField, simpleTransclusion, condition ]},
+    select: {template: selectTemplate, builder: [ selectPlaceholder ].concat(defaults)},
     submit: {template: submitTemplate, builder: defaults},
-    tabarray: {template: tabarrayTemplate, builder: [sfField, ngModelOptions, ngModel, array, condition]},
-    tabs: {template: tabsTemplate, builder: [sfField, ngModelOptions, tabs, condition]},
+    tabarray: {template: tabarrayTemplate, builder: [ sfField, ngModelOptions, ngModel, array, condition ]},
+    tabs: {template: tabsTemplate, builder: [ sfField, ngModelOptions, tabs, condition ]},
     textarea: {template: textareaTemplate, builder: defaults},
   }, []);
 };

From 0cd0a1e047d4860514d34d750e7795987ea2c8cc Mon Sep 17 00:00:00 2001
From: Marcel J Bennett <iamanthropic@gmail.com>
Date: Mon, 17 Apr 2017 23:15:29 +1000
Subject: [PATCH 47/50] Fixes #37

---
 README.md | 24 +++++++++++++++++++-----
 1 file changed, 19 insertions(+), 5 deletions(-)

diff --git a/README.md b/README.md
index e154296..85693ea 100644
--- a/README.md
+++ b/README.md
@@ -16,15 +16,29 @@ since they are no longer needed.
 Install
 -------
 ```sh
-bower install angular-schema-form-bootstrap
-```
-or
-```sh
 npm install angular-schema-form-bootstrap
 ```
+**note** we do not recommend using bower as even the bower team recommend using yarn and webpack now.
 
 The package.json 'main' script is this library alone and unminified so that minification can be handled by webpack or another script bundler.
-**Note that angular-schema-form >= 1.0.0-alpha.1 is needed in that case**.
+
+**Note when using webpack angular-schema-form versions match this repo so ASF 1.0.0-alpha.4 works with Bootstrap 1.0.0-alpha.4**.
+
+If you are unsure, check the bundled version in this repo and see which versions are used as both repo now include a version header.
+
+Look for this:
+```js
+/*!
+ * angular-schema-form
+ * @version 1.0.0-alpha.4
+ * @date Mon, 17 Apr 2017 08:55:13 GMT
+ * @link https://github.com/json-schema-form/angular-schema-form
+ * @license MIT
+ * Copyright (c) 2014-2017 JSON Schema Form
+ */
+```
+
+Old versions pre-alpha work with 0.8.13 or ASF, but the alphas should be more stable than those versions with more bugs fixed.
 
 If you include `angular-schema-form-bootstrap-bundled.min.js` you **DO NOT** need to include angular-schema-form, it is now **embedded** within the bundled above file. If you wish to include the files separately you can still use `angular-schema-form-bootstrap.js` or `angular-schema-form-bootstrap.min.js`
 

From 4bbd97b7b50bec54f99712bb0777c57ea37abf1d Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Thu, 20 Apr 2017 21:31:57 +1000
Subject: [PATCH 48/50] Close angular-schema-form#612 add 'required' to css

---
 dist/angular-schema-form-bootstrap-bundled.js | 24 +++++++++----------
 ...gular-schema-form-bootstrap-bundled.min.js | 10 ++++----
 dist/angular-schema-form-bootstrap.js         | 20 ++++++++--------
 dist/angular-schema-form-bootstrap.min.js     |  6 ++---
 package.json                                  |  4 ++--
 src/bootstrap/checkbox.html                   |  7 +++++-
 src/bootstrap/checkboxes.html                 |  6 ++++-
 src/bootstrap/default.html                    |  7 +++++-
 src/bootstrap/radio-buttons.html              |  6 ++++-
 src/bootstrap/radios-inline.html              |  6 ++++-
 src/bootstrap/radios.html                     |  7 +++++-
 src/bootstrap/select.html                     |  7 +++++-
 src/bootstrap/textarea.html                   |  8 ++++++-
 13 files changed, 78 insertions(+), 40 deletions(-)

diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index cbe22a9..8417f46 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.4
- * @date Mon, 17 Apr 2017 08:57:43 GMT
+ * @version 1.0.0-alpha.5
+ * @date Thu, 20 Apr 2017 11:28:20 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -184,7 +184,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/checkbox.html';
-var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{::fieldId(true, false)}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true && hasError(),\r\n       'has-success': form.disableSuccessState !== true && hasSuccess(),\r\n       'has-feedback': form.feedback !== false,\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{::fieldId(true, false)}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -193,7 +193,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/checkboxes.html';
-var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true &&  hasError(),\r\n       'has-success': form.disableSuccessState !== true &&  hasSuccess(),\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -202,7 +202,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/default.html';
-var html = "<div class=\"form-group {{::form.htmlClass + ' schema-form-' + form.type + ' ' + idClass}}\"\r\n     ng-class=\"{ 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{::fieldId(true, false)}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{::fieldId(true, false)}}\"\r\n         aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{::fieldId(true, false)}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{::fieldId(true, false)}}\"\r\n           aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{::fieldId(true, true) + '-status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div class=\"form-group {{::form.htmlClass + ' schema-form-' + form.type + ' ' + idClass}}\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true && hasError(),\r\n       'has-success': form.disableSuccessState !== true && hasSuccess(),\r\n       'has-feedback': form.feedback !== false,\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{::fieldId(true, false)}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{::fieldId(true, false)}}\"\r\n         aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{::fieldId(true, false)}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{::fieldId(true, false)}}\"\r\n           aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{::fieldId(true, true) + '-status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -229,7 +229,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/radio-buttons.html';
-var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (tm.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: tm.value === $$value$$ }\"\r\n           ng-repeat=\"tm in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true &&  hasError(),\r\n       'has-success': form.disableSuccessState !== true &&  hasSuccess(),\r\n       'required': form.required === true\r\n     }\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (tm.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: tm.value === $$value$$ }\"\r\n           ng-repeat=\"tm in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -238,7 +238,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/radios-inline.html';
-var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"tm in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true &&  hasError(),\r\n       'has-success': form.disableSuccessState !== true && hasSuccess(),\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"tm in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -247,7 +247,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/radios.html';
-var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass + ' ' + idClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"tm in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true &&  hasError(),\n       'has-success': form.disableSuccessState !== true && hasSuccess(),\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"tm in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -265,7 +265,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/select.html';
-var html = "<div class=\"form-group {{::form.htmlClass + ' ' + idClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\" for=\"{{::fieldId(true, false)}}\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id=\"{{::fieldId(true, false)}}\"\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{::fieldId(true, false)}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div class=\"form-group {{::form.htmlClass + ' ' + idClass}} schema-form-select\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true && hasError(),\r\n       'has-success': form.disableSuccessState !== true && hasSuccess(),\r\n       'has-feedback': form.feedback !== false,\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\" for=\"{{::fieldId(true, false)}}\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id=\"{{::fieldId(true, false)}}\"\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{::fieldId(true, false)}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -301,7 +301,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/textarea.html';
-var html = "<div class=\"form-group has-feedback {{::form.htmlClass + ' ' + idClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{::fieldId(true, false)}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{::fieldId(true, false)}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{::fieldId(true, false)}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{::fieldId(true, false)}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
+var html = "<div class=\"form-group has-feedback {{::form.htmlClass + ' ' + idClass}} schema-form-textarea\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true && hasError(),\r\n       'has-success': form.disableSuccessState !== true && hasSuccess(),\r\n       'has-feedback': form.feedback !== false,\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{::fieldId(true, false)}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{::fieldId(true, false)}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{::fieldId(true, false)}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{::fieldId(true, false)}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -463,8 +463,8 @@ function bootstrapDecoratorConfig(
 
 /* WEBPACK VAR INJECTION */(function(setImmediate, clearImmediate) {/*!
  * angular-schema-form
- * @version 1.0.0-alpha.4
- * @date Mon, 17 Apr 2017 08:55:13 GMT
+ * @version 1.0.0-alpha.5
+ * @date Thu, 20 Apr 2017 11:16:31 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
diff --git a/dist/angular-schema-form-bootstrap-bundled.min.js b/dist/angular-schema-form-bootstrap-bundled.min.js
index 6846ca6..2cb96dc 100644
--- a/dist/angular-schema-form-bootstrap-bundled.min.js
+++ b/dist/angular-schema-form-bootstrap-bundled.min.js
@@ -1,15 +1,15 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.4
- * @date Mon, 17 Apr 2017 08:57:43 GMT
+ * @version 1.0.0-alpha.5
+ * @date Thu, 20 Apr 2017 11:28:20 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,y=r.builders.array,g=r.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},E=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,y,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,y,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:v.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:w.a,builder:C},"radios-inline":{template:$.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:[E].concat(C)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,y,m]},tabs:{template:I.a,builder:[d,l,x,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),y=r(8),v=r.n(y),g=r(9),b=r.n(g),x=r(11),w=r.n(x),E=r(10),$=r.n(E),C=r(12),k=r.n(C),O=r(13),T=r.n(O),A=r(14),S=r.n(A),P=r(15),M=r.n(P),j=r(16),I=r.n(j),D=r(17),_=r.n(D);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
+!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true &&  hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true &&  hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,y=r.builders.array,g=r.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},E=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,y,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,y,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:v.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:w.a,builder:C},"radios-inline":{template:$.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:[E].concat(C)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,y,m]},tabs:{template:I.a,builder:[d,l,x,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),y=r(8),v=r.n(y),g=r(9),b=r.n(g),x=r(11),w=r.n(x),E=r(10),$=r.n(E),C=r(12),k=r.n(C),O=r(13),T=r.n(O),A=r(14),S=r.n(A),P=r(15),M=r.n(P),j=r(16),I=r.n(j),D=r(17),_=r.n(D);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
  * angular-schema-form
- * @version 1.0.0-alpha.4
- * @date Mon, 17 Apr 2017 08:55:13 GMT
+ * @version 1.0.0-alpha.5
+ * @date Thu, 20 Apr 2017 11:16:31 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index f22bac4..f2722c2 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.4
- * @date Mon, 17 Apr 2017 08:57:43 GMT
+ * @version 1.0.0-alpha.5
+ * @date Thu, 20 Apr 2017 11:28:20 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -103,7 +103,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/checkbox.html';
-var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{::fieldId(true, false)}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div class=\"checkbox schema-form-checkbox {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true && hasError(),\r\n       'has-success': form.disableSuccessState !== true && hasSuccess(),\r\n       'has-feedback': form.feedback !== false,\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"{{::form.labelHtmlClass}}\">\r\n    <input type=\"checkbox\"\r\n           sf-changed=\"form\"\r\n           ng-disabled=\"form.readonly\"\r\n           sf-field-model\r\n           schema-validate=\"form\"\r\n           class=\"{{::form.fieldHtmlClass}}\"\r\n           name=\"{{::fieldId(true, false)}}\">\r\n    <span ng-bind-html=\"form.title\"></span>\r\n  </label>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -112,7 +112,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/checkboxes.html';
-var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div sf-field-model=\"sf-new-array\"\r\n     sf-new-array\r\n     class=\"form-group schema-form-checkboxes {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true &&  hasError(),\r\n       'has-success': form.disableSuccessState !== true &&  hasSuccess(),\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model\r\n         schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n\r\n  <div class=\"checkbox\" ng-repeat=\"val in titleMapValues track by $index\" >\r\n    <label>\r\n      <input type=\"checkbox\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-changed=\"form\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             ng-model=\"titleMapValues[$index]\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"form.titleMap[$index].name\"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -121,7 +121,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/default.html';
-var html = "<div class=\"form-group {{::form.htmlClass + ' schema-form-' + form.type + ' ' + idClass}}\"\r\n     ng-class=\"{ 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{::fieldId(true, false)}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{::fieldId(true, false)}}\"\r\n         aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{::fieldId(true, false)}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{::fieldId(true, false)}}\"\r\n           aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{::fieldId(true, true) + '-status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div class=\"form-group {{::form.htmlClass + ' schema-form-' + form.type + ' ' + idClass}}\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true && hasError(),\r\n       'has-success': form.disableSuccessState !== true && hasSuccess(),\r\n       'has-feedback': form.feedback !== false,\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <input ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n         ng-show=\"::form.key\"\r\n         type=\"{{::form.type}}\"\r\n         step=\"any\"\r\n         sf-changed=\"form\"\r\n         placeholder=\"{{::form.placeholder}}\"\r\n         class=\"form-control {{::form.fieldHtmlClass}}\"\r\n         id=\"{{::fieldId(true, false)}}\"\r\n         sf-field-model\r\n         ng-disabled=\"form.readonly\"\r\n         schema-validate=\"form\"\r\n         name=\"{{::fieldId(true, false)}}\"\r\n         aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <input ng-show=\"::form.key\"\r\n           type=\"{{::form.type}}\"\r\n           step=\"any\"\r\n           sf-changed=\"form\"\r\n           placeholder=\"{{::form.placeholder}}\"\r\n           class=\"form-control {{::form.fieldHtmlClass}}\"\r\n           id=\"{{::fieldId(true, false)}}\"\r\n           sf-field-model\r\n           ng-disabled=\"form.readonly\"\r\n           schema-validate=\"form\"\r\n           name=\"{{::fieldId(true, false)}}\"\r\n           aria-describedby=\"{{::fieldId(true, true) + '-status'}}\">\r\n\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span ng-if=\"form.feedback !== false\"\r\n        class=\"form-control-feedback\"\r\n        ng-class=\"evalInScope(form.feedback) || {'glyphicon': true, 'glyphicon-ok': form.disableSuccessState !== true && hasSuccess(), 'glyphicon-remove': form.disableErrorState !== true && hasError() }\"\r\n        aria-hidden=\"true\"></span>\r\n\r\n  <span ng-if=\"hasError() || hasSuccess()\"\r\n        id=\"{{::fieldId(true, true) + '-status'}}\"\r\n        class=\"sr-only\">{{ hasSuccess() ? '(success)' : '(error)' }}</span>\r\n\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -148,7 +148,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/radio-buttons.html';
-var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (tm.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: tm.value === $$value$$ }\"\r\n           ng-repeat=\"tm in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div class=\"form-group schema-form-radiobuttons {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true &&  hasError(),\r\n       'has-success': form.disableSuccessState !== true &&  hasSuccess(),\r\n       'required': form.required === true\r\n     }\">\r\n  <div>\r\n    <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\">{{form.title}}</label>\r\n  </div>\r\n  <div class=\"btn-group\">\r\n    <label sf-field-model=\"replaceAll\" class=\"btn {{ (tm.value === $$value$$) ? form.style.selected || 'btn-default' : form.style.unselected || 'btn-default'; }}\"\r\n           ng-class=\"{ active: tm.value === $$value$$ }\"\r\n           ng-repeat=\"tm in form.titleMap\">\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             style=\"display: none;\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             schema-validate=\"form\"\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -157,7 +157,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/radios-inline.html';
-var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"tm in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div class=\"form-group schema-form-radios-inline {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true &&  hasError(),\r\n       'has-success': form.disableSuccessState !== true && hasSuccess(),\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n        ng-show=\"showTitle()\" sf-field-model\r\n        schema-validate=\"form\" >{{form.title}}</label>\r\n  <div>\r\n      <label class=\"radio-inline\" ng-repeat=\"tm in form.titleMap\" >\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -166,7 +166,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/radios.html';
-var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass + ' ' + idClass}}\" ng-class=\"{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"tm in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div class=\"form-group schema-form-radios {{::form.htmlClass + ' ' + idClass}}\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true &&  hasError(),\n       'has-success': form.disableSuccessState !== true && hasSuccess(),\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\"\r\n         sf-field-model schema-validate=\"form\"\r\n         ng-show=\"showTitle()\">{{form.title}}</label>\r\n  <div class=\"radio\" ng-repeat=\"tm in form.titleMap\">\r\n    <label>\r\n      <input type=\"radio\"\r\n             class=\"{{::form.fieldHtmlClass}}\"\r\n             sf-changed=\"form\"\r\n             ng-disabled=\"form.readonly\"\r\n             sf-field-model\r\n             ng-value=\"tm.value\"\r\n             name=\"{{::fieldId(true, false)}}\">\r\n      <span ng-bind-html=\"tm.name\"></span>\r\n    </label>\r\n  </div>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -184,7 +184,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/select.html';
-var html = "<div class=\"form-group {{::form.htmlClass + ' ' + idClass}} schema-form-select\"\r\n     ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\" for=\"{{::fieldId(true, false)}}\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id=\"{{::fieldId(true, false)}}\"\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{::fieldId(true, false)}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
+var html = "<div class=\"form-group {{::form.htmlClass + ' ' + idClass}} schema-form-select\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true && hasError(),\r\n       'has-success': form.disableSuccessState !== true && hasSuccess(),\r\n       'has-feedback': form.feedback !== false,\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-show=\"showTitle()\" for=\"{{::fieldId(true, false)}}\">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id=\"{{::fieldId(true, false)}}\"\r\n          ng-disabled=\"form.readonly\"\r\n          sf-changed=\"form\"\r\n          class=\"form-control {{::form.fieldHtmlClass}}\"\r\n          schema-validate=\"form\"\r\n          ng-options=\"item.value as item.name group by item.group for item in form.titleMap\"\r\n          name=\"{{::fieldId(true, false)}}\">\r\n  </select>\r\n  <div class=\"help-block\" sf-message=\"form.description\"></div>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -220,7 +220,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/textarea.html';
-var html = "<div class=\"form-group has-feedback {{::form.htmlClass + ' ' + idClass}} schema-form-textarea\" ng-class=\"{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{::fieldId(true, false)}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{::fieldId(true, false)}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{::fieldId(true, false)}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{::fieldId(true, false)}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
+var html = "<div class=\"form-group has-feedback {{::form.htmlClass + ' ' + idClass}} schema-form-textarea\"\r\n     ng-class=\"{\r\n       'has-error': form.disableErrorState !== true && hasError(),\r\n       'has-success': form.disableSuccessState !== true && hasSuccess(),\r\n       'has-feedback': form.feedback !== false,\r\n       'required': form.required === true\r\n     }\">\r\n  <label class=\"control-label {{::form.labelHtmlClass}}\" ng-class=\"{'sr-only': !showTitle()}\" for=\"{{::fieldId(true, false)}}\">{{form.title}}</label>\r\n\r\n  <textarea ng-if=\"!form.fieldAddonLeft && !form.fieldAddonRight\"\r\n            class=\"form-control {{::form.fieldHtmlClass}}\"\r\n            id=\"{{::fieldId(true, false)}}\"\r\n            sf-changed=\"form\"\r\n            ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n            ng-disabled=\"form.readonly\"\r\n            sf-field-model\r\n            schema-validate=\"form\"\r\n            name=\"{{::fieldId(true, false)}}\"></textarea>\r\n\r\n  <div ng-if=\"form.fieldAddonLeft || form.fieldAddonRight\"\r\n       ng-class=\"{'input-group': (form.fieldAddonLeft || form.fieldAddonRight)}\">\r\n    <span ng-if=\"form.fieldAddonLeft\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonLeft\"></span>\r\n    <textarea class=\"form-control {{::form.fieldHtmlClass}}\"\r\n              id=\"{{::fieldId(true, false)}}\"\r\n              sf-changed=\"form\"\r\n              ng-attr-placeholder=\"{{::form.placeholder}}\"\r\n              ng-disabled=\"form.readonly\"\r\n              sf-field-model\r\n              schema-validate=\"form\"\r\n              name=\"{{::fieldId(true, false)}}\"></textarea>\r\n    <span ng-if=\"form.fieldAddonRight\"\r\n          class=\"input-group-addon\"\r\n          ng-bind-html=\"form.fieldAddonRight\"></span>\r\n  </div>\r\n\r\n  <span class=\"help-block\" sf-message=\"form.description\"></span>\r\n</div>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
diff --git a/dist/angular-schema-form-bootstrap.min.js b/dist/angular-schema-form-bootstrap.min.js
index 7edc052..d24fe92 100644
--- a/dist/angular-schema-form-bootstrap.min.js
+++ b/dist/angular-schema-form-bootstrap.min.js
@@ -1,9 +1,9 @@
 /*!
  * angular-schema-form-bootstrap
- * @version 1.0.0-alpha.4
- * @date Mon, 17 Apr 2017 08:57:43 GMT
+ * @version 1.0.0-alpha.5
+ * @date Thu, 20 Apr 2017 11:28:20 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function r(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return e[a].call(l.exports,l,l.exports,r),l.l=!0,l.exports}var n={};return r.m=e,r.c=n,r.i=function(e){return e},r.d=function(e,r,n){Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},r.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return r.d(n,"a",n),n},r.o=function(e,r){return Object.prototype.hasOwnProperty.call(e,r)},r.p="",r(r.s=24)}([function(e,r,n){n(18)},,function(e,r){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{ \'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}" ng-class="{\'has-error\': form.disableErrorState !== true &&  hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true && hasSuccess(), \'has-feedback\': form.feedback !== false}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea" ng-class="{\'has-error\': form.disableErrorState !== true && hasError(), \'has-success\': form.disableSuccessState !== true &&  hasSuccess()}">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(n,a)}]),e.exports=n},function(e,r,n){"use strict";function a(e,r,n,a,l){var s=n.builders.simpleTransclusion,i=n.builders.ngModelOptions,m=n.builders.ngModel,c=n.builders.sfField,p=n.builders.condition,h=n.builders.array,v=n.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var r=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(n,a){var l="(evalExpr("+e.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=e.build(n.items,e.path+".tabs["+a+"].items",e.state);t.appendChild(s),r.appendChild(t)})}},C=function(e){if(e.form.placeholder){var r=e.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=e.form.placeholder,r.appendChild(n)}},k=[c,m,i,p];r.defineDecorator("bootstrapDecorator",{actions:{template:t.a,builder:k},array:{template:o.a,builder:[c,i,m,h,p]},button:{template:H.a,builder:k},checkbox:{template:d.a,builder:k},checkboxes:{template:f.a,builder:[c,i,m,h,p]},conditional:{template:A.a,builder:[c,s,p]},default:{template:u.a,builder:k},fieldset:{template:b.a,builder:[c,s,p]},help:{template:g.a,builder:k},number:{template:u.a,builder:k.concat(v)},password:{template:u.a,builder:k},radios:{template:$.a,builder:k},"radios-inline":{template:w.a,builder:k},radiobuttons:{template:y.a,builder:k},section:{template:A.a,builder:[c,s,p]},select:{template:E.a,builder:[C].concat(k)},submit:{template:H.a,builder:k},tabarray:{template:M.a,builder:[c,i,m,h,p]},tabs:{template:L.a,builder:[c,i,x,p]},textarea:{template:D.a,builder:k}},[])}var l=n(2),t=n.n(l),s=n(3),o=n.n(s),i=n(4),d=n.n(i),m=n(5),f=n.n(m),c=n(6),u=n.n(c),p=n(7),b=n.n(p),h=n(8),g=n.n(h),v=n(9),y=n.n(v),x=n(11),$=n.n(x),C=n(10),w=n.n(C),k=n(12),A=n.n(k),S=n(13),E=n.n(S),I=n(14),H=n.n(I),T=n(15),M=n.n(T),R=n(16),L=n.n(R),j=n(17),D=n.n(j);angular.module("schemaForm").config(a),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,,function(e,r,n){e.exports=n(0)}]);
\ No newline at end of file
+!function(r){function e(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return r[a].call(l.exports,l,l.exports,e),l.l=!0,l.exports}var n={};return e.m=r,e.c=n,e.i=function(r){return r},e.d=function(r,e,n){Object.defineProperty(r,e,{configurable:!1,enumerable:!0,get:n})},e.n=function(r){var n=r&&r.__esModule?function(){return r.default}:function(){return r};return e.d(n,"a",n),n},e.o=function(r,e){return Object.prototype.hasOwnProperty.call(r,e)},e.p="",e(e.s=24)}([function(r,e,n){n(18)},,function(r,e){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true &&  hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true &&  hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e,n){"use strict";function a(r,e,n,a,l){var s=n.builders.simpleTransclusion,i=n.builders.ngModelOptions,m=n.builders.ngModel,c=n.builders.sfField,p=n.builders.condition,h=n.builders.array,v=n.builders.numeric,x=function(r){if(r.form.tabs&&r.form.tabs.length>0){var e=r.fieldFrag.querySelector(".tab-content");r.form.tabs.forEach(function(n,a){var l="(evalExpr("+r.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=r.build(n.items,r.path+".tabs["+a+"].items",r.state);t.appendChild(s),e.appendChild(t)})}},C=function(r){if(r.form.placeholder){var e=r.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=r.form.placeholder,e.appendChild(n)}},w=[c,m,i,p];e.defineDecorator("bootstrapDecorator",{actions:{template:t.a,builder:w},array:{template:o.a,builder:[c,i,m,h,p]},button:{template:H.a,builder:w},checkbox:{template:d.a,builder:w},checkboxes:{template:f.a,builder:[c,i,m,h,p]},conditional:{template:A.a,builder:[c,s,p]},default:{template:u.a,builder:w},fieldset:{template:b.a,builder:[c,s,p]},help:{template:g.a,builder:w},number:{template:u.a,builder:w.concat(v)},password:{template:u.a,builder:w},radios:{template:$.a,builder:w},"radios-inline":{template:k.a,builder:w},radiobuttons:{template:y.a,builder:w},section:{template:A.a,builder:[c,s,p]},select:{template:E.a,builder:[C].concat(w)},submit:{template:H.a,builder:w},tabarray:{template:q.a,builder:[c,i,m,h,p]},tabs:{template:R.a,builder:[c,i,x,p]},textarea:{template:j.a,builder:w}},[])}var l=n(2),t=n.n(l),s=n(3),o=n.n(s),i=n(4),d=n.n(i),m=n(5),f=n.n(m),c=n(6),u=n.n(c),p=n(7),b=n.n(p),h=n(8),g=n.n(h),v=n(9),y=n.n(v),x=n(11),$=n.n(x),C=n(10),k=n.n(C),w=n(12),A=n.n(w),S=n(13),E=n.n(S),I=n(14),H=n.n(I),T=n(15),q=n.n(T),M=n(16),R=n.n(M),L=n(17),j=n.n(L);angular.module("schemaForm").config(a),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,,function(r,e,n){r.exports=n(0)}]);
\ No newline at end of file
diff --git a/package.json b/package.json
index 99f3248..35e5c77 100644
--- a/package.json
+++ b/package.json
@@ -1,6 +1,6 @@
 {
   "name": "angular-schema-form-bootstrap",
-  "version": "1.0.0-alpha.4",
+  "version": "1.0.0-alpha.5",
   "description": "Bootstrap 3 decorator for Angular Schema Form",
   "main": "dist/angular-schema-form-bootstrap.js",
   "scripts": {
@@ -51,7 +51,7 @@
     "sinon": "^1.17.4",
     "sinon-chai": "^2.8.0",
     "streamqueue": "^0.1.3",
-    "uglify-js": "^2.6.2",
+    "uglify-js": "github:mishoo/UglifyJS2#harmony",
     "webpack": "^2.1.0-beta.27",
     "webpack-dev-server": "^2.1.0-beta.12"
   }
diff --git a/src/bootstrap/checkbox.html b/src/bootstrap/checkbox.html
index 4e71876..d7ec7cd 100644
--- a/src/bootstrap/checkbox.html
+++ b/src/bootstrap/checkbox.html
@@ -1,5 +1,10 @@
 <div class="checkbox schema-form-checkbox {{::form.htmlClass + ' ' + idClass}}"
-     ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
+     ng-class="{
+       'has-error': form.disableErrorState !== true && hasError(),
+       'has-success': form.disableSuccessState !== true && hasSuccess(),
+       'has-feedback': form.feedback !== false,
+       'required': form.required === true
+     }">
   <label class="{{::form.labelHtmlClass}}">
     <input type="checkbox"
            sf-changed="form"
diff --git a/src/bootstrap/checkboxes.html b/src/bootstrap/checkboxes.html
index 89856af..f99adc8 100644
--- a/src/bootstrap/checkboxes.html
+++ b/src/bootstrap/checkboxes.html
@@ -1,7 +1,11 @@
 <div sf-field-model="sf-new-array"
      sf-new-array
      class="form-group schema-form-checkboxes {{::form.htmlClass + ' ' + idClass}}"
-     ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
+     ng-class="{
+       'has-error': form.disableErrorState !== true &&  hasError(),
+       'has-success': form.disableSuccessState !== true &&  hasSuccess(),
+       'required': form.required === true
+     }">
   <label class="control-label {{::form.labelHtmlClass}}"
          sf-field-model
          schema-validate="form"
diff --git a/src/bootstrap/default.html b/src/bootstrap/default.html
index f44cfa0..097a32e 100644
--- a/src/bootstrap/default.html
+++ b/src/bootstrap/default.html
@@ -1,5 +1,10 @@
 <div class="form-group {{::form.htmlClass + ' schema-form-' + form.type + ' ' + idClass}}"
-     ng-class="{ 'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false }">
+     ng-class="{
+       'has-error': form.disableErrorState !== true && hasError(),
+       'has-success': form.disableSuccessState !== true && hasSuccess(),
+       'has-feedback': form.feedback !== false,
+       'required': form.required === true
+     }">
   <label class="control-label {{::form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>
 
   <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"
diff --git a/src/bootstrap/radio-buttons.html b/src/bootstrap/radio-buttons.html
index a3dd1f8..027f06c 100644
--- a/src/bootstrap/radio-buttons.html
+++ b/src/bootstrap/radio-buttons.html
@@ -1,5 +1,9 @@
 <div class="form-group schema-form-radiobuttons {{::form.htmlClass + ' ' + idClass}}"
-     ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
+     ng-class="{
+       'has-error': form.disableErrorState !== true &&  hasError(),
+       'has-success': form.disableSuccessState !== true &&  hasSuccess(),
+       'required': form.required === true
+     }">
   <div>
     <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>
   </div>
diff --git a/src/bootstrap/radios-inline.html b/src/bootstrap/radios-inline.html
index eb94523..c58d054 100644
--- a/src/bootstrap/radios-inline.html
+++ b/src/bootstrap/radios-inline.html
@@ -1,5 +1,9 @@
 <div class="form-group schema-form-radios-inline {{::form.htmlClass + ' ' + idClass}}"
-     ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}">
+     ng-class="{
+       'has-error': form.disableErrorState !== true &&  hasError(),
+       'has-success': form.disableSuccessState !== true && hasSuccess(),
+       'required': form.required === true
+     }">
   <label class="control-label {{::form.labelHtmlClass}}"
         ng-show="showTitle()" sf-field-model
         schema-validate="form" >{{form.title}}</label>
diff --git a/src/bootstrap/radios.html b/src/bootstrap/radios.html
index 861250f..ef37d28 100644
--- a/src/bootstrap/radios.html
+++ b/src/bootstrap/radios.html
@@ -1,4 +1,9 @@
-<div class="form-group schema-form-radios {{::form.htmlClass + ' ' + idClass}}" ng-class="{'has-error': form.disableErrorState !== true &&  hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess()}">
+<div class="form-group schema-form-radios {{::form.htmlClass + ' ' + idClass}}"
+     ng-class="{
+       'has-error': form.disableErrorState !== true &&  hasError(),
+       'has-success': form.disableSuccessState !== true && hasSuccess(),
+       'required': form.required === true
+     }">
   <label class="control-label {{::form.labelHtmlClass}}"
          sf-field-model schema-validate="form"
          ng-show="showTitle()">{{form.title}}</label>
diff --git a/src/bootstrap/select.html b/src/bootstrap/select.html
index 0288717..c13ab15 100644
--- a/src/bootstrap/select.html
+++ b/src/bootstrap/select.html
@@ -1,5 +1,10 @@
 <div class="form-group {{::form.htmlClass + ' ' + idClass}} schema-form-select"
-     ng-class="{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true && hasSuccess(), 'has-feedback': form.feedback !== false}">
+     ng-class="{
+       'has-error': form.disableErrorState !== true && hasError(),
+       'has-success': form.disableSuccessState !== true && hasSuccess(),
+       'has-feedback': form.feedback !== false,
+       'required': form.required === true
+     }">
   <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">
     {{form.title}}
   </label>
diff --git a/src/bootstrap/textarea.html b/src/bootstrap/textarea.html
index 3f43779..f11a634 100644
--- a/src/bootstrap/textarea.html
+++ b/src/bootstrap/textarea.html
@@ -1,4 +1,10 @@
-<div class="form-group has-feedback {{::form.htmlClass + ' ' + idClass}} schema-form-textarea" ng-class="{'has-error': form.disableErrorState !== true && hasError(), 'has-success': form.disableSuccessState !== true &&  hasSuccess()}">
+<div class="form-group has-feedback {{::form.htmlClass + ' ' + idClass}} schema-form-textarea"
+     ng-class="{
+       'has-error': form.disableErrorState !== true && hasError(),
+       'has-success': form.disableSuccessState !== true && hasSuccess(),
+       'has-feedback': form.feedback !== false,
+       'required': form.required === true
+     }">
   <label class="control-label {{::form.labelHtmlClass}}" ng-class="{'sr-only': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>
 
   <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"

From 8a89b9b4c88f7b91afac353ea5cca2101795c9f7 Mon Sep 17 00:00:00 2001
From: Mina Nagy Zaki <mnzaki@gmail.com>
Date: Sat, 29 Apr 2017 12:27:57 +0200
Subject: [PATCH 49/50] fieldset: remove sf-key-controller

it is unnecessary for fieldsets, and breaks form.key
---
 src/bootstrap/fieldset.html | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/bootstrap/fieldset.html b/src/bootstrap/fieldset.html
index a833b5b..5e1baa4 100644
--- a/src/bootstrap/fieldset.html
+++ b/src/bootstrap/fieldset.html
@@ -1,4 +1,4 @@
-<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + ' ' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join('][')}}]" sf-index="{{$index}}">
+<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + ' ' + idClass}}">
   <legend ng-class="{'sr-only': !showTitle() }">{{ form.title }}</legend>
   <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>
 </fieldset>

From cb42c26504e4533edfb347d2cb04be7d702619f8 Mon Sep 17 00:00:00 2001
From: Marcel <iamanthropic@gmail.com>
Date: Sun, 30 Apr 2017 00:51:03 +1000
Subject: [PATCH 50/50] Update build after PR

---
 bower.json                                    |  3 +-
 dist/angular-schema-form-bootstrap-bundled.js | 29 +++++++++++++------
 ...gular-schema-form-bootstrap-bundled.min.js | 14 ++++-----
 dist/angular-schema-form-bootstrap.js         |  4 +--
 dist/angular-schema-form-bootstrap.min.js     |  4 +--
 5 files changed, 32 insertions(+), 22 deletions(-)

diff --git a/bower.json b/bower.json
index 276489f..05bd0ae 100644
--- a/bower.json
+++ b/bower.json
@@ -1,6 +1,5 @@
 {
   "name": "angular-schema-form-bootstrap",
-  "version": "1.0.0-alpha.1",
   "authors": [
     "David Jensen (Textalk) <david.lgj@gmail.com>",
     "Marcel Bennett <iamanthropic@gmail.com>"
@@ -23,7 +22,7 @@
     "tests"
   ],
   "dependencies": {
-    "angular-schema-form": "1.0.0-alpha.2"
+    "angular-schema-form": "1.0.0-alpha.4"
   },
   "devDependencies": {
     "angular-ui-ace": "bower",
diff --git a/dist/angular-schema-form-bootstrap-bundled.js b/dist/angular-schema-form-bootstrap-bundled.js
index 8417f46..96e51cd 100644
--- a/dist/angular-schema-form-bootstrap-bundled.js
+++ b/dist/angular-schema-form-bootstrap-bundled.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.5
- * @date Thu, 20 Apr 2017 11:28:20 GMT
+ * @date Sat, 29 Apr 2017 14:49:38 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -211,7 +211,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/fieldset.html';
-var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass + ' ' + idClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
+var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass + ' ' + idClass}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
@@ -464,7 +464,7 @@ function bootstrapDecoratorConfig(
 /* WEBPACK VAR INJECTION */(function(setImmediate, clearImmediate) {/*!
  * angular-schema-form
  * @version 1.0.0-alpha.5
- * @date Thu, 20 Apr 2017 11:16:31 GMT
+ * @date Wed, 26 Apr 2017 14:49:08 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -3294,7 +3294,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 })
 
 // Directives
-.directive('sfChanged', __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__["a" /* default */]).directive('sfField', ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__["a" /* default */]]).directive('sfMessage', ['$injector', 'sfErrorMessage', __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__["a" /* default */]]).directive('sfNewArray', ['sfSelect', 'sfPath', 'schemaForm', __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__["a" /* default */]]).directive('sfSchema', ['$compile', '$http', '$templateCache', '$q', 'schemaForm', 'schemaFormDecorators', 'sfSelect', 'sfPath', 'sfBuilder', __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__["a" /* default */]]).directive('schemaValidate', ['sfValidator', '$parse', 'sfSelect', __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__["a" /* default */]]).directive('sfKeyController', ['schemaForm', 'sfPath', __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__["a" /* default */]]);
+.directive('sfChanged', __WEBPACK_IMPORTED_MODULE_7_sf_changed_directive__["a" /* default */]).directive('sfField', ['$parse', '$compile', '$http', '$templateCache', '$interpolate', '$q', 'sfErrorMessage', 'sfPath', 'sfSelect', __WEBPACK_IMPORTED_MODULE_8_sf_field_directive__["a" /* default */]]).directive('sfMessage', ['$injector', 'sfErrorMessage', __WEBPACK_IMPORTED_MODULE_9_sf_message_directive__["a" /* default */]]).directive('sfNewArray', ['sfSelect', 'sfPath', 'schemaForm', __WEBPACK_IMPORTED_MODULE_10_sf_array_directive__["a" /* default */]]).directive('sfSchema', ['$compile', '$http', '$templateCache', '$q', 'schemaForm', 'schemaFormDecorators', 'sfSelect', 'sfPath', 'sfBuilder', __WEBPACK_IMPORTED_MODULE_12_sf_schema_directive__["a" /* default */]]).directive('schemaValidate', ['sfValidator', '$parse', 'sfSelect', '$interpolate', __WEBPACK_IMPORTED_MODULE_13_schema_validate_directive__["a" /* default */]]).directive('sfKeyController', ['schemaForm', 'sfPath', __WEBPACK_IMPORTED_MODULE_11_sf_key_directive__["a" /* default */]]);
 
 /***/ }),
 /* 5 */
@@ -3305,7 +3305,7 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
 /* harmony import */ var __WEBPACK_IMPORTED_MODULE_0_angular___default = __webpack_require__.n(__WEBPACK_IMPORTED_MODULE_0_angular__);
 
 
-/* harmony default export */ __webpack_exports__["a"] = function (sfValidator, $parse, sfSelect) {
+/* harmony default export */ __webpack_exports__["a"] = function (sfValidator, $parse, sfSelect, $interpolate) {
   return {
     restrict: 'A',
     scope: false,
@@ -3322,15 +3322,26 @@ __WEBPACK_IMPORTED_MODULE_1_angular___default.a.module('schemaForm', deps)
       var error = null;
       var form = scope.$eval(attrs.schemaValidate);
 
-      if (form.copyValueTo) {
+      //TODO move this out of validate
+      var copyTo = typeof form.copyValueTo === 'string' ? [form.copyValueTo] : form.copyValueTo;
+      if (copyTo && copyTo.length) {
         ngModel.$viewChangeListeners.push(function () {
-          var paths = form.copyValueTo;
-          __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(paths, function (path) {
+          var context = {
+            "model": scope.model,
+            "form": form,
+            "arrayIndex": scope.$index,
+            "arrayIndices": scope.arrayIndices,
+            "path": scope.path,
+            "$i": scope.$i,
+            "$index": scope.$index
+          };
+          __WEBPACK_IMPORTED_MODULE_0_angular___default.a.forEach(copyTo, function (copyToPath) {
+            var path = copyToPath.replace(/\[/g, "[{{ ").replace(/\]/g, " }}]").replace(/^model\./, "");
+            path = $interpolate(path)(context);
             sfSelect(path, scope.model, ngModel.$modelValue);
           });
         });
       };
-
       // Validate against the schema.
 
       var validate = function validate(viewValue, triggered) {
diff --git a/dist/angular-schema-form-bootstrap-bundled.min.js b/dist/angular-schema-form-bootstrap-bundled.min.js
index 2cb96dc..93d7111 100644
--- a/dist/angular-schema-form-bootstrap-bundled.min.js
+++ b/dist/angular-schema-form-bootstrap-bundled.min.js
@@ -1,15 +1,15 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.5
- * @date Thu, 20 Apr 2017 11:28:20 GMT
+ * @date Sat, 29 Apr 2017 14:49:38 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true &&  hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true &&  hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,y=r.builders.array,g=r.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},E=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,y,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,y,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:v.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:w.a,builder:C},"radios-inline":{template:$.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:[E].concat(C)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,y,m]},tabs:{template:I.a,builder:[d,l,x,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),y=r(8),v=r.n(y),g=r(9),b=r.n(g),x=r(11),w=r.n(x),E=r(10),$=r.n(E),C=r(12),k=r.n(C),O=r(13),T=r.n(O),A=r(14),S=r.n(A),P=r(15),M=r.n(P),j=r(16),I=r.n(j),D=r(17),_=r.n(D);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
+!function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,t,r){Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=23)}([function(e,t,r){r(18)},function(e,t,r){(function(e,n){function o(e,t){this._id=e,this._clearFn=t}var i=r(20).nextTick,a=Function.prototype.apply,s=Array.prototype.slice,l={},c=0;t.setTimeout=function(){return new o(a.call(setTimeout,window,arguments),clearTimeout)},t.setInterval=function(){return new o(a.call(setInterval,window,arguments),clearInterval)},t.clearTimeout=t.clearInterval=function(e){e.close()},o.prototype.unref=o.prototype.ref=function(){},o.prototype.close=function(){this._clearFn.call(window,this._id)},t.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},t.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},t._unrefActive=t.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},t.setImmediate="function"==typeof e?e:function(e){var r=c++,n=!(arguments.length<2)&&s.call(arguments,1);return l[r]=!0,i(function(){l[r]&&(n?e.apply(null,n):e.call(null),t.clearImmediate(r))}),r},t.clearImmediate="function"==typeof n?n:function(e){delete l[e]}}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){var r="/bootstrap/actions.html",n='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/array.html",n='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkbox.html",n='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/checkboxes.html",n='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true &&  hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/default.html",n='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/fieldset.html",n='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/help.html",n='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radio-buttons.html",n='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true &&  hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios-inline.html",n='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/radios.html",n='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/section.html",n='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/select.html",n='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/submit.html",n='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabarray.html",n='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/tabs.html",n='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t){var r="/bootstrap/textarea.html",n='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(e){e.put(r,n)}]),e.exports=r},function(e,t,r){"use strict";function n(e,t,r,n,o){var a=r.builders.simpleTransclusion,l=r.builders.ngModelOptions,u=r.builders.ngModel,d=r.builders.sfField,m=r.builders.condition,y=r.builders.array,g=r.builders.numeric,x=function(e){if(e.form.tabs&&e.form.tabs.length>0){var t=e.fieldFrag.querySelector(".tab-content");e.form.tabs.forEach(function(r,n){var o="(evalExpr("+e.path+".tabs["+n+'].condition, { model: model, "arrayIndex": $index}))',i=document.createElement("div");i.className="tab-pane",i.setAttribute("ng-disabled","form.readonly"),i.setAttribute("ng-show","selected.tab === "+n),i.setAttribute("ng-class","{active: selected.tab === "+n+"}"),r.condition&&i.setAttribute("ng-if",o);var a=e.build(r.items,e.path+".tabs["+n+"].items",e.state);i.appendChild(a),t.appendChild(i)})}},$=function(e){if(e.form.placeholder){var t=e.fieldFrag.querySelector("select"),r=document.createElement("option");r.setAttribute("value",""),r.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?r.setAttribute("ng-if","$$value$$ === undefined"):r.setAttribute("ng-show","$$value$$ === undefined"),r.textContent=e.form.placeholder,t.appendChild(r)}},C=[d,u,l,m];t.defineDecorator("bootstrapDecorator",{actions:{template:i.a,builder:C},array:{template:s.a,builder:[d,l,u,y,m]},button:{template:S.a,builder:C},checkbox:{template:c.a,builder:C},checkboxes:{template:f.a,builder:[d,l,u,y,m]},conditional:{template:k.a,builder:[d,a,m]},default:{template:p.a,builder:C},fieldset:{template:h.a,builder:[d,a,m]},help:{template:v.a,builder:C},number:{template:p.a,builder:C.concat(g)},password:{template:p.a,builder:C},radios:{template:w.a,builder:C},"radios-inline":{template:E.a,builder:C},radiobuttons:{template:b.a,builder:C},section:{template:k.a,builder:[d,a,m]},select:{template:T.a,builder:[$].concat(C)},submit:{template:S.a,builder:C},tabarray:{template:M.a,builder:[d,l,u,y,m]},tabs:{template:j.a,builder:[d,l,x,m]},textarea:{template:_.a,builder:C}},[])}var o=r(2),i=r.n(o),a=r(3),s=r.n(a),l=r(4),c=r.n(l),u=r(5),f=r.n(u),d=r(6),p=r.n(d),m=r(7),h=r.n(m),y=r(8),v=r.n(y),g=r(9),b=r.n(g),x=r(11),w=r.n(x),$=r(10),E=r.n($),C=r(12),k=r.n(C),O=r(13),T=r.n(O),A=r(14),S=r.n(A),P=r(15),M=r.n(P),I=r(16),j=r.n(I),D=r(17),_=r.n(D);angular.module("schemaForm").config(n),n.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},function(e,t,r){(function(e,t){/*!
  * angular-schema-form
  * @version 1.0.0-alpha.5
- * @date Thu, 20 Apr 2017 11:16:31 GMT
+ * @date Wed, 26 Apr 2017 14:49:08 GMT
  * @link https://github.com/json-schema-form/angular-schema-form
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -22,11 +22,11 @@
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-e.exports=function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=13)}([function(e,t,r){"use strict";function n(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(e){var o=e.slice(),i=t||"-";return n&&(o=o.filter(function(e){return"number"!=typeof e})),(0!==r.length?r+i:"")+o.join(i)}return""}Object.defineProperty(t,"__esModule",{value:!0});var o=r(2);r.n(o);r.o(o,"parse")&&r.d(t,"parse",function(){return o.parse}),r.o(o,"stringify")&&r.d(t,"stringify",function(){return o.stringify}),r.o(o,"normalize")&&r.d(t,"normalize",function(){return o.normalize}),t.name=n},function(e,t,r){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t){if(!Array.isArray(e)){var r=function(){var r=[];return t?t.forEach(function(t){r.push({name:e[t],value:t})}):Object.keys(e).forEach(function(t){r.push({name:e[t],value:t})}),{v:r}}();if("object"===("undefined"==typeof r?"undefined":n(r)))return r.v}return e}},function(e,t,r){e.exports=r(11).ObjectPath},function(e,t,r){"use strict";function n(e,t,r,o){var i=e[g(r.type)];if(i)for(var a=void 0,s=function(t,r,o){return n(e,t,r,o)},l=0;l<i.length;l++)if(a=i[l](t,r,o,s))return a.schema["x-schema-form"]&&Object.assign(a,a.schema["x-schema-form"]),a}function o(e,t,n){n=n||{};var o=n.global&&n.global.formDefaults?Object.assign({},n.global.formDefaults):{};return n.global&&n.global.supressPropertyTitles===!0?o.title=t.title:o.title=t.title||e,t.description&&(o.description=t.description),n.required!==!0&&t.required!==!0||(o.required=!0),t.maxLength&&(o.maxlength=t.maxLength),t.minLength&&(o.minlength=t.minLength),(t.readOnly||t.readonly)&&(o.readonly=!0),t.minimum&&(o.minimum=t.minimum+(t.exclusiveMinimum?1:0)),t.maximum&&(o.maximum=t.maximum-(t.exclusiveMaximum?1:0)),t.validationMessage&&(o.validationMessage=t.validationMessage),t.enumNames&&(o.titleMap=r.i(y.a)(t.enumNames,t.enum)),o.schema=t,o.ngModelOptions=o.ngModelOptions||{},o}function i(e,t,n){if("string"===g(t.type)&&!t.enum){var i=o(e,t,n);return i.key=n.path,i.type="text",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function a(e,t,n){if("number"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function s(e,t,n){if("integer"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function l(e,t,n){if("boolean"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="checkbox",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function c(e,t,n){if("string"===g(t.type)&&t.enum){var i=o(e,t,n);return i.key=n.path,i.type="select",i.titleMap||(i.titleMap=b(t.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function u(e,t,n){if("array"===g(t.type)&&t.items&&t.items.enum){var i=o(e,t,n);return i.key=n.path,i.type="checkboxes",i.titleMap||(i.titleMap=b(t.items.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function f(e,t,n,i){if("object"===g(t.type)){var a=function(){var a=o(e,t,n);return a.type="fieldset",a.key=n.path,a.items=[],n.lookup[r.i(h.stringify)(n.path)]=a,t.properties&&Object.keys(t.properties).forEach(function(e){var o=t.properties[e],s=n.path.slice();if(s.push(e),n.ignore[r.i(h.stringify)(s)]!==!0){var l=t.required&&t.required.indexOf(e)!==-1,c=i(e,o,{path:s,required:l||!1,lookup:n.lookup,ignore:n.ignore,global:n.global});c&&a.items.push(c)}}),{v:a}}();if("object"===("undefined"==typeof a?"undefined":v(a)))return a.v}}function d(e,t,n,i){if("array"===g(t.type)){var a=o(e,t,n);a.type="array",a.key=n.path,n.lookup[r.i(h.stringify)(n.path)]=a;var s=t.required&&t.required.indexOf(n.path[n.path.length-1])!==-1,l=n.path.slice();return l.push(""),a.items=[i(e,t.items,{path:l,required:s||!1,lookup:n.lookup,ignore:n.ignore,global:n.global})],a}}function p(){return{string:[c,i],object:[f],number:[a],integer:[s],boolean:[l],array:[u,d]}}function m(e,t,r,o){var i=[],a={};if(r=r||{},o=o||{},t=t||p(),!e.properties)throw new Error('Not implemented. Only type "object" allowed at root level of schema.');return Object.keys(e.properties).forEach(function(s){if(r[s]!==!0){var l=e.required&&e.required.indexOf(s)!==-1,c=n(t,s,e.properties[s],{path:[s],lookup:a,ignore:r,required:l,global:o});c&&i.push(c)}}),{form:i,lookup:a}}Object.defineProperty(t,"__esModule",{value:!0});var h=r(0),y=r(1);t.defaultFormDefinition=n,t.stdFormObj=o,t.text=i,t.number=a,t.integer=s,t.checkbox=l,t.select=c,t.checkboxes=u,t.fieldset=f,t.array=d,t.createDefaults=p,t.defaultForm=m;var v="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},g=function(e){if(Array.isArray(e)&&2===e.length){if("null"===e[0])return e[1];if("null"===e[1])return e[0]}return e},b=function(e){var t=[];return e.forEach(function(e){t.push({name:e,value:e})}),t}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(3),o=r(0),i=r(1),a=r(6);r.d(t,"merge",function(){return a.a});var s=r(8);r.d(t,"select",function(){return s.a});var l=r(7);r.d(t,"jsonref",function(){return l.a});var c=r(9);r.d(t,"traverseSchema",function(){return c.a}),r.d(t,"traverseForm",function(){return c.b});var u=r(10);r.d(t,"validate",function(){return u.a}),r.d(t,"sfPath",function(){return f}),r.d(t,"schemaDefaults",function(){return d}),r.d(t,"canonicalTitleMap",function(){return p});var f=o,d=n,p=i.a},function(e,n,o){var i,a,s,l,l,c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};!function(t){if("object"===c(n)&&"undefined"!=typeof e)e.exports=t();else{a=[],i=t,s="function"==typeof i?i.apply(n,a):i,!(void 0!==s&&(e.exports=s))}}(function(){var e;return function e(t,r,n){function o(a,s){if(!r[a]){if(!t[a]){var c="function"==typeof l&&l;if(!s&&c)return l(a,!0);if(i)return i(a,!0);var u=new Error("Cannot find module '"+a+"'");throw u.code="MODULE_NOT_FOUND",u}var f=r[a]={exports:{}};t[a][0].call(f.exports,function(e){var r=t[a][1][e];return o(r?r:e)},f,f.exports,e,t,r,n)}return r[a].exports}for(var i="function"==typeof l&&l,a=0;a<n.length;a++)o(n[a]);return o}({1:[function(e,t,r){"use strict";function n(e){var t;return m(e,"Array")?(t=[],e.forEach(function(e,r){t[r]=n(e)})):m(e,"Object")?(t={},Object.keys(e).forEach(function(r){t[r]=n(e[r])})):t=e,t}function o(e,t){function r(e){Object.keys(e).forEach(function(t){n[t]=e[t]})}var n={};return r(_.parse(e||"")),r(_.parse(t||"")),0===Object.keys(n).length?void 0:_.stringify(n)}function i(e,t){m(e,"String")&&(e=F(e)),m(t,"String")&&(t=F(t));var r,n,i=v(m(t,"Undefined")?"":t);return L.indexOf(i.reference)>-1?n=i:(r=m(e,"Undefined")?void 0:v(e),m(r,"Undefined")?n=i:(n=r,n.path=F(I.join(r.path,i.path)),n.query=o(r.query,i.query))),n.fragment=void 0,(L.indexOf(n.reference)===-1&&0===n.path.indexOf("../")?"../":"")+R.serialize(n)}function a(e,t){var r,n=[];return t.length>0&&(r=e,t.slice(0,t.length-1).forEach(function(e){e in r&&(r=r[e],n.push(r))})),n}function s(e,t,r,o,i,a,s,u,f){var d,p;if(r.length>0)try{d=c(t,r)}catch(t){"remote"===e&&(o.error=t.message,o.missing=!0)}else d=t;if(m(d,"Undefined")||(o.value=d),m(d,"Array")||m(d,"Object"))return p=n(i),"local"===e?(delete p.subDocPath,t=d):(p.relativeBase=I.dirname(a[a.length-1]),0===r.length?delete p.subDocPath:p.subDocPath=r),l(t,p,a,s,u,f)}function l(e,t,r,n,o,a){var l=Promise.resolve(),c=n.length?S(n[n.length-1]):[],u=C(e,t),f=t.subDocPath||[],p=P(f),h=["#"];return r.forEach(function(e,t){"#"!==e.charAt(0)&&h.push(n[t])}),h.reverse(),"#"!==(r[r.length-1]||"").charAt(0)&&(o.documents[P(c)]=e),Object.keys(u).forEach(function(y){var v,g,b,x,w=u[y];b=0===r.length?c.concat(S(y)):c.concat(S(y).slice(0===r.length?0:f.length)),x=P(b),m(o[x],"Undefined")&&(o.refs[x]=u[y],m(w.error,"Undefined")&&"invalid"!==w.type&&(N.indexOf(w.type)>-1?(v=i(t.relativeBase,w.uri),g=r.indexOf(v)):(v=w.uri,g=n.indexOf(v)),w.ancestorPtrs=h,w.indirect=a,g===-1?N.indexOf(w.type)>-1?l=l.then(function(){return d(v,t).then(function(e){return s("remote",e,m(w.uriDetails.fragment,"Undefined")?[]:S(decodeURI(w.uriDetails.fragment)),w,t,r.concat(v),n.concat(x),o,a)}).catch(function(e){w.error=e.message,w.missing=!0})}):0!==x.indexOf(v+"/")&&x!==v&&0!==p.indexOf(v+"/")&&p!==v?0!==v.indexOf(p+"/")&&(l=l.then(function(){return s("local",e,S(v),w,t,r.concat(v),n.concat(x),o,a||v.indexOf(p+"/")===-1&&v!==p)})):w.circular=!0:(n.slice(g).forEach(function(e){o.refs[e].circular=!0}),w.circular=!0)))}),l=l.then(function(){function e(i,a,s,l){Object.keys(o.refs).forEach(function(c){var u=o.refs[c];n.indexOf(l)===-1&&r.indexOf(s)===-1&&t.indexOf(l)===-1&&c!==s&&0===c.indexOf(l+"/")&&(a.indexOf(l)>-1?a.forEach(function(e){t.indexOf(l)===-1&&t.push(e)}):e(i.concat(s),a.concat(l),c,u.uri),r.push(s),n.push(l))})}var t=[],r=[],n=[];Object.keys(o.refs).forEach(function(r){var n=o.refs[r];"local"!==n.type||n.circular||t.indexOf(n.uri)!==-1||e([],[],r,n.uri)}),Object.keys(o.refs).forEach(function(e){var r=o.refs[e];t.indexOf(r.uri)>-1&&(r.circular=!0)})}).then(function(){return o})}function c(e,t){var r=e;return t.forEach(function(e){if(e=decodeURI(e),!(e in r))throw Error("JSON Pointer points to missing location: "+P(t));r=r[e]}),r}function u(e){return Object.keys(e).filter(function(e){return"$ref"!==e})}function f(e){var t;switch(e.uriDetails.reference){case"absolute":case"uri":t="remote";break;case"same-document":t="local";break;default:t=e.uriDetails.reference}return t}function d(e,t){var r=U[e],o=Promise.resolve(),i=n(t.loaderOptions||{});return m(r,"Undefined")?(m(i.processContent,"Undefined")&&(i.processContent=function(e,t){t(void 0,JSON.parse(e.text))}),o=D.load(decodeURI(e),i),o=o.then(function(t){return U[e]={value:t},t}).catch(function(t){throw U[e]={error:t},t})):o=o.then(function(){return r.value}),o=o.then(function(e){return n(e)})}function p(e,t){var r=!0;try{if(!m(e,"Object"))throw new Error("obj is not an Object");if(!m(e.$ref,"String"))throw new Error("obj.$ref is not a String")}catch(e){if(t)throw e;r=!1}return r}function m(e,t){return"Undefined"===t?"undefined"==typeof e:Object.prototype.toString.call(e)==="[object "+t+"]"}function h(e){var t,r;return m(e.filter,"Array")||m(e.filter,"String")?(r=m(e.filter,"String")?[e.filter]:e.filter,t=function(e){return r.indexOf(e.type)>-1||r.indexOf(f(e))>-1}):m(e.filter,"Function")?t=e.filter:m(e.filter,"Undefined")&&(t=function(){return!0}),function(r,n){return("invalid"!==r.type||e.includeInvalid===!0)&&t(r,n)}}function y(e){var t;return m(e.subDocPath,"Array")?t=e.subDocPath:m(e.subDocPath,"String")?t=S(e.subDocPath):m(e.subDocPath,"Undefined")&&(t=[]),t}function v(e){return R.parse(encodeURI(decodeURI(e)))}function g(e,t,r){c(e,t.slice(0,t.length-1))[decodeURI(t[t.length-1])]=r}function b(e,t,r,n){function o(t,o){r.push(o),b(e,t,r,n),r.pop()}var i=!0;m(n,"Function")&&(i=n(e,t,r)),e.indexOf(t)===-1&&(e.push(t),i!==!1&&(m(t,"Array")?t.forEach(function(e,t){o(e,t.toString())}):m(t,"Object")&&Object.keys(t).forEach(function(e){o(t[e],e)}))),e.pop()}function x(e,t){if(e=m(e,"Undefined")?{}:n(e),!m(e,"Object"))throw new TypeError("options must be an Object");if(!(m(e.filter,"Undefined")||m(e.filter,"Array")||m(e.filter,"Function")||m(e.filter,"String")))throw new TypeError("options.filter must be an Array, a Function of a String");if(!m(e.includeInvalid,"Undefined")&&!m(e.includeInvalid,"Boolean"))throw new TypeError("options.includeInvalid must be a Boolean");if(!m(e.refPreProcessor,"Undefined")&&!m(e.refPreProcessor,"Function"))throw new TypeError("options.refPreProcessor must be a Function");if(!m(e.refPostProcessor,"Undefined")&&!m(e.refPostProcessor,"Function"))throw new TypeError("options.refPostProcessor must be a Function");if(!m(e.subDocPath,"Undefined")&&!m(e.subDocPath,"Array")&&!T(e.subDocPath))throw new TypeError("options.subDocPath must be an Array of path segments or a valid JSON Pointer");if(e.filter=h(e),e.subDocPath=y(e),!m(t,"Undefined"))try{c(t,e.subDocPath)}catch(e){throw e.message=e.message.replace("JSON Pointer","options.subDocPath"),e}return e}function w(){U={}}function E(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),decodeURI(e.replace(/~1/g,"/").replace(/~0/g,"~"))})}function $(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),e.replace(/~/g,"~0").replace(/\//g,"~1")})}function C(e,t){var r={};if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");return t=x(t,e),b(a(e,t.subDocPath),c(e,t.subDocPath),n(t.subDocPath),function(e,o,i){var a,s=!0;return p(o)&&(m(t.refPreProcessor,"Undefined")||(o=t.refPreProcessor(n(o),i)),a=O(o),m(t.refPostProcessor,"Undefined")||(a=t.refPostProcessor(a,i)),t.filter(a,i)&&(r[P(i)]=a),u(o).length>0&&(s=!1)),s}),r}function k(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=x(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(U[e]),i=n(t),a=v(e);return m(o.refs,"Undefined")&&(delete i.filter,delete i.subDocPath,i.includeInvalid=!0,U[e].refs=C(r,i)),m(t.filter,"Undefined")||(i.filter=t.filter),m(a.fragment,"Undefined")?m(a.subDocPath,"Undefined")||(i.subDocPath=t.subDocPath):i.subDocPath=S(decodeURI(a.fragment)),{refs:C(r,i),value:r}})}function O(e){var t,r,n,o={def:e};try{p(e,!0)?(t=e.$ref,n=H[t],m(n,"Undefined")&&(n=H[t]=v(t)),o.uri=t,o.uriDetails=n,m(n.error,"Undefined")?o.type=f(o):(o.error=o.uriDetails.error,o.type="invalid"),r=u(e),r.length>0&&(o.warning="Extra JSON Reference properties will be ignored: "+r.join(", "))):o.type="invalid"}catch(e){o.error=e.message,o.type="invalid"}return o}function T(e,t){var r,n=!0;try{if(!m(e,"String"))throw new Error("ptr is not a String");if(""!==e){if(r=e.charAt(0),["#","/"].indexOf(r)===-1)throw new Error("ptr must start with a / or #/");if("#"===r&&"#"!==e&&"/"!==e.charAt(1))throw new Error("ptr must start with a / or #/");if(e.match(q))throw new Error("ptr has invalid token(s)")}}catch(e){if(t===!0)throw e;n=!1}return n}function A(e,t){return p(e,t)&&"invalid"!==O(e,t).type}function S(e){if(!T(e))throw new Error("ptr must be a JSON Pointer");var t=e.split("/");return t.shift(),E(t)}function P(e,t){if(!m(e,"Array"))throw new Error("path must be an Array");return(t!==!1?"#":"")+(e.length>0?"/":"")+$(e).join("/")}function M(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");t=x(t,e),e=n(e)}).then(function(){return l(e,t,[],[],{documents:{},refs:{}})}).then(function(t){function r(e,t){return S(e).length-S(t).length}var n={},o={};return Object.keys(t.refs).sort(r).forEach(function(r){var i=t.refs[r];i.indirect||(o[r]=i),delete i.indirect,m(i.error,"Undefined")&&"invalid"!==i.type?(m(i.value,"Undefined")&&i.circular&&(i.value=i.def),m(i.value,"Undefined")?n[r]=i:("#"===r?e=i.value:g(e,S(r),i.value),delete i.ancestorPtrs)):delete i.ancestorPtrs}),Object.keys(n).forEach(function(r){var o=n[r];o.ancestorPtrs.forEach(function(n,i){if(m(o.value,"Undefined"))try{o.value=c(t.documents[n],S(o.uri)),delete o.ancestorPtrs,g(e,S(r),o.value)}catch(e){i===o.ancestorPtrs.length-1&&(o.error=e.message,o.missing=!0,delete o.ancestorPtrs)}})}),{refs:o,resolved:e}})}function j(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=x(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(t),i=v(e);return m(i.fragment,"Undefined")||(o.subDocPath=S(decodeURI(i.fragment))),o.relativeBase=I.dirname(e),M(r,o).then(function(e){return{refs:e.refs,resolved:e.resolved,value:r}})})}var I=e("path"),D=e("path-loader"),_=e("querystring"),F=e("slash"),R=e("uri-js"),q=/~(?:[^01]|$)/g,U={},N=["relative","remote"],L=["absolute","uri"],H={};"undefined"==typeof Promise&&e("native-promise-only"),t.exports.clearCache=w,t.exports.decodePath=E,t.exports.encodePath=$,t.exports.findRefs=C,t.exports.findRefsAt=k,t.exports.getRefDetails=O,t.exports.isPtr=T,t.exports.isRef=A,t.exports.pathFromPtr=S,t.exports.pathToPtr=P,t.exports.resolveRefs=M,t.exports.resolveRefsAt=j},{"native-promise-only":3,path:4,"path-loader":5,querystring:11,slash:13,"uri-js":23}],2:[function(e,t,r){function n(e){if(e)return o(e)}function o(e){for(var t in n.prototype)e[t]=n.prototype[t];return e}t.exports=n,n.prototype.on=n.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},n.prototype.once=function(e,t){function r(){this.off(e,r),t.apply(this,arguments)}return r.fn=t,this.on(e,r),this},n.prototype.off=n.prototype.removeListener=n.prototype.removeAllListeners=n.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var n,o=0;o<r.length;o++)if(n=r[o],n===t||n.fn===t){r.splice(o,1);break}return this},n.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),r=this._callbacks["$"+e];if(r){r=r.slice(0);for(var n=0,o=r.length;n<o;++n)r[n].apply(this,t)}return this},n.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},n.prototype.hasListeners=function(e){return!!this.listeners(e).length}},{}],3:[function(n,o,i){(function(t){/*! Native Promise Only
+e.exports=function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,l:!1,exports:{}};return e[n].call(o.exports,o,o.exports,t),o.l=!0,o.exports}var r={};return t.m=e,t.c=r,t.i=function(e){return e},t.d=function(e,r,n){t.o(e,r)||Object.defineProperty(e,r,{configurable:!1,enumerable:!0,get:n})},t.n=function(e){var r=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(r,"a",r),r},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=13)}([function(e,t,r){"use strict";function n(e,t){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",n=arguments.length>3&&void 0!==arguments[3]&&arguments[3];if(e){var o=e.slice(),i=t||"-";return n&&(o=o.filter(function(e){return"number"!=typeof e})),(0!==r.length?r+i:"")+o.join(i)}return""}Object.defineProperty(t,"__esModule",{value:!0});var o=r(2);r.n(o);r.o(o,"parse")&&r.d(t,"parse",function(){return o.parse}),r.o(o,"stringify")&&r.d(t,"stringify",function(){return o.stringify}),r.o(o,"normalize")&&r.d(t,"normalize",function(){return o.normalize}),t.name=n},function(e,t,r){"use strict";var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t){if(!Array.isArray(e)){var r=function(){var r=[];return t?t.forEach(function(t){r.push({name:e[t],value:t})}):Object.keys(e).forEach(function(t){r.push({name:e[t],value:t})}),{v:r}}();if("object"===("undefined"==typeof r?"undefined":n(r)))return r.v}return e}},function(e,t,r){e.exports=r(11).ObjectPath},function(e,t,r){"use strict";function n(e,t,r,o){var i=e[g(r.type)];if(i)for(var a=void 0,s=function(t,r,o){return n(e,t,r,o)},l=0;l<i.length;l++)if(a=i[l](t,r,o,s))return a.schema["x-schema-form"]&&Object.assign(a,a.schema["x-schema-form"]),a}function o(e,t,n){n=n||{};var o=n.global&&n.global.formDefaults?Object.assign({},n.global.formDefaults):{};return n.global&&n.global.supressPropertyTitles===!0?o.title=t.title:o.title=t.title||e,t.description&&(o.description=t.description),n.required!==!0&&t.required!==!0||(o.required=!0),t.maxLength&&(o.maxlength=t.maxLength),t.minLength&&(o.minlength=t.minLength),(t.readOnly||t.readonly)&&(o.readonly=!0),t.minimum&&(o.minimum=t.minimum+(t.exclusiveMinimum?1:0)),t.maximum&&(o.maximum=t.maximum-(t.exclusiveMaximum?1:0)),t.validationMessage&&(o.validationMessage=t.validationMessage),t.enumNames&&(o.titleMap=r.i(y.a)(t.enumNames,t.enum)),o.schema=t,o.ngModelOptions=o.ngModelOptions||{},o}function i(e,t,n){if("string"===g(t.type)&&!t.enum){var i=o(e,t,n);return i.key=n.path,i.type="text",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function a(e,t,n){if("number"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function s(e,t,n){if("integer"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="number",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function l(e,t,n){if("boolean"===g(t.type)){var i=o(e,t,n);return i.key=n.path,i.type="checkbox",n.lookup[r.i(h.stringify)(n.path)]=i,i}}function c(e,t,n){if("string"===g(t.type)&&t.enum){var i=o(e,t,n);return i.key=n.path,i.type="select",i.titleMap||(i.titleMap=b(t.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function u(e,t,n){if("array"===g(t.type)&&t.items&&t.items.enum){var i=o(e,t,n);return i.key=n.path,i.type="checkboxes",i.titleMap||(i.titleMap=b(t.items.enum)),n.lookup[r.i(h.stringify)(n.path)]=i,i}}function f(e,t,n,i){if("object"===g(t.type)){var a=function(){var a=o(e,t,n);return a.type="fieldset",a.key=n.path,a.items=[],n.lookup[r.i(h.stringify)(n.path)]=a,t.properties&&Object.keys(t.properties).forEach(function(e){var o=t.properties[e],s=n.path.slice();if(s.push(e),n.ignore[r.i(h.stringify)(s)]!==!0){var l=t.required&&t.required.indexOf(e)!==-1,c=i(e,o,{path:s,required:l||!1,lookup:n.lookup,ignore:n.ignore,global:n.global});c&&a.items.push(c)}}),{v:a}}();if("object"===("undefined"==typeof a?"undefined":v(a)))return a.v}}function d(e,t,n,i){if("array"===g(t.type)){var a=o(e,t,n);a.type="array",a.key=n.path,n.lookup[r.i(h.stringify)(n.path)]=a;var s=t.required&&t.required.indexOf(n.path[n.path.length-1])!==-1,l=n.path.slice();return l.push(""),a.items=[i(e,t.items,{path:l,required:s||!1,lookup:n.lookup,ignore:n.ignore,global:n.global})],a}}function p(){return{string:[c,i],object:[f],number:[a],integer:[s],boolean:[l],array:[u,d]}}function m(e,t,r,o){var i=[],a={};if(r=r||{},o=o||{},t=t||p(),!e.properties)throw new Error('Not implemented. Only type "object" allowed at root level of schema.');return Object.keys(e.properties).forEach(function(s){if(r[s]!==!0){var l=e.required&&e.required.indexOf(s)!==-1,c=n(t,s,e.properties[s],{path:[s],lookup:a,ignore:r,required:l,global:o});c&&i.push(c)}}),{form:i,lookup:a}}Object.defineProperty(t,"__esModule",{value:!0});var h=r(0),y=r(1);t.defaultFormDefinition=n,t.stdFormObj=o,t.text=i,t.number=a,t.integer=s,t.checkbox=l,t.select=c,t.checkboxes=u,t.fieldset=f,t.array=d,t.createDefaults=p,t.defaultForm=m;var v="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},g=function(e){if(Array.isArray(e)&&2===e.length){if("null"===e[0])return e[1];if("null"===e[1])return e[0]}return e},b=function(e){var t=[];return e.forEach(function(e){t.push({name:e,value:e})}),t}},function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(3),o=r(0),i=r(1),a=r(6);r.d(t,"merge",function(){return a.a});var s=r(8);r.d(t,"select",function(){return s.a});var l=r(7);r.d(t,"jsonref",function(){return l.a});var c=r(9);r.d(t,"traverseSchema",function(){return c.a}),r.d(t,"traverseForm",function(){return c.b});var u=r(10);r.d(t,"validate",function(){return u.a}),r.d(t,"sfPath",function(){return f}),r.d(t,"schemaDefaults",function(){return d}),r.d(t,"canonicalTitleMap",function(){return p});var f=o,d=n,p=i.a},function(e,n,o){var i,a,s,l,l,c="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};!function(t){if("object"===c(n)&&"undefined"!=typeof e)e.exports=t();else{a=[],i=t,s="function"==typeof i?i.apply(n,a):i,!(void 0!==s&&(e.exports=s))}}(function(){var e;return function e(t,r,n){function o(a,s){if(!r[a]){if(!t[a]){var c="function"==typeof l&&l;if(!s&&c)return l(a,!0);if(i)return i(a,!0);var u=new Error("Cannot find module '"+a+"'");throw u.code="MODULE_NOT_FOUND",u}var f=r[a]={exports:{}};t[a][0].call(f.exports,function(e){var r=t[a][1][e];return o(r?r:e)},f,f.exports,e,t,r,n)}return r[a].exports}for(var i="function"==typeof l&&l,a=0;a<n.length;a++)o(n[a]);return o}({1:[function(e,t,r){"use strict";function n(e){var t;return m(e,"Array")?(t=[],e.forEach(function(e,r){t[r]=n(e)})):m(e,"Object")?(t={},Object.keys(e).forEach(function(r){t[r]=n(e[r])})):t=e,t}function o(e,t){function r(e){Object.keys(e).forEach(function(t){n[t]=e[t]})}var n={};return r(_.parse(e||"")),r(_.parse(t||"")),0===Object.keys(n).length?void 0:_.stringify(n)}function i(e,t){m(e,"String")&&(e=F(e)),m(t,"String")&&(t=F(t));var r,n,i=v(m(t,"Undefined")?"":t);return L.indexOf(i.reference)>-1?n=i:(r=m(e,"Undefined")?void 0:v(e),m(r,"Undefined")?n=i:(n=r,n.path=F(j.join(r.path,i.path)),n.query=o(r.query,i.query))),n.fragment=void 0,(L.indexOf(n.reference)===-1&&0===n.path.indexOf("../")?"../":"")+R.serialize(n)}function a(e,t){var r,n=[];return t.length>0&&(r=e,t.slice(0,t.length-1).forEach(function(e){e in r&&(r=r[e],n.push(r))})),n}function s(e,t,r,o,i,a,s,u,f){var d,p;if(r.length>0)try{d=c(t,r)}catch(t){"remote"===e&&(o.error=t.message,o.missing=!0)}else d=t;if(m(d,"Undefined")||(o.value=d),m(d,"Array")||m(d,"Object"))return p=n(i),"local"===e?(delete p.subDocPath,t=d):(p.relativeBase=j.dirname(a[a.length-1]),0===r.length?delete p.subDocPath:p.subDocPath=r),l(t,p,a,s,u,f)}function l(e,t,r,n,o,a){var l=Promise.resolve(),c=n.length?S(n[n.length-1]):[],u=C(e,t),f=t.subDocPath||[],p=P(f),h=["#"];return r.forEach(function(e,t){"#"!==e.charAt(0)&&h.push(n[t])}),h.reverse(),"#"!==(r[r.length-1]||"").charAt(0)&&(o.documents[P(c)]=e),Object.keys(u).forEach(function(y){var v,g,b,x,w=u[y];b=0===r.length?c.concat(S(y)):c.concat(S(y).slice(0===r.length?0:f.length)),x=P(b),m(o[x],"Undefined")&&(o.refs[x]=u[y],m(w.error,"Undefined")&&"invalid"!==w.type&&(N.indexOf(w.type)>-1?(v=i(t.relativeBase,w.uri),g=r.indexOf(v)):(v=w.uri,g=n.indexOf(v)),w.ancestorPtrs=h,w.indirect=a,g===-1?N.indexOf(w.type)>-1?l=l.then(function(){return d(v,t).then(function(e){return s("remote",e,m(w.uriDetails.fragment,"Undefined")?[]:S(decodeURI(w.uriDetails.fragment)),w,t,r.concat(v),n.concat(x),o,a)}).catch(function(e){w.error=e.message,w.missing=!0})}):0!==x.indexOf(v+"/")&&x!==v&&0!==p.indexOf(v+"/")&&p!==v?0!==v.indexOf(p+"/")&&(l=l.then(function(){return s("local",e,S(v),w,t,r.concat(v),n.concat(x),o,a||v.indexOf(p+"/")===-1&&v!==p)})):w.circular=!0:(n.slice(g).forEach(function(e){o.refs[e].circular=!0}),w.circular=!0)))}),l=l.then(function(){function e(i,a,s,l){Object.keys(o.refs).forEach(function(c){var u=o.refs[c];n.indexOf(l)===-1&&r.indexOf(s)===-1&&t.indexOf(l)===-1&&c!==s&&0===c.indexOf(l+"/")&&(a.indexOf(l)>-1?a.forEach(function(e){t.indexOf(l)===-1&&t.push(e)}):e(i.concat(s),a.concat(l),c,u.uri),r.push(s),n.push(l))})}var t=[],r=[],n=[];Object.keys(o.refs).forEach(function(r){var n=o.refs[r];"local"!==n.type||n.circular||t.indexOf(n.uri)!==-1||e([],[],r,n.uri)}),Object.keys(o.refs).forEach(function(e){var r=o.refs[e];t.indexOf(r.uri)>-1&&(r.circular=!0)})}).then(function(){return o})}function c(e,t){var r=e;return t.forEach(function(e){if(e=decodeURI(e),!(e in r))throw Error("JSON Pointer points to missing location: "+P(t));r=r[e]}),r}function u(e){return Object.keys(e).filter(function(e){return"$ref"!==e})}function f(e){var t;switch(e.uriDetails.reference){case"absolute":case"uri":t="remote";break;case"same-document":t="local";break;default:t=e.uriDetails.reference}return t}function d(e,t){var r=U[e],o=Promise.resolve(),i=n(t.loaderOptions||{});return m(r,"Undefined")?(m(i.processContent,"Undefined")&&(i.processContent=function(e,t){t(void 0,JSON.parse(e.text))}),o=D.load(decodeURI(e),i),o=o.then(function(t){return U[e]={value:t},t}).catch(function(t){throw U[e]={error:t},t})):o=o.then(function(){return r.value}),o=o.then(function(e){return n(e)})}function p(e,t){var r=!0;try{if(!m(e,"Object"))throw new Error("obj is not an Object");if(!m(e.$ref,"String"))throw new Error("obj.$ref is not a String")}catch(e){if(t)throw e;r=!1}return r}function m(e,t){return"Undefined"===t?"undefined"==typeof e:Object.prototype.toString.call(e)==="[object "+t+"]"}function h(e){var t,r;return m(e.filter,"Array")||m(e.filter,"String")?(r=m(e.filter,"String")?[e.filter]:e.filter,t=function(e){return r.indexOf(e.type)>-1||r.indexOf(f(e))>-1}):m(e.filter,"Function")?t=e.filter:m(e.filter,"Undefined")&&(t=function(){return!0}),function(r,n){return("invalid"!==r.type||e.includeInvalid===!0)&&t(r,n)}}function y(e){var t;return m(e.subDocPath,"Array")?t=e.subDocPath:m(e.subDocPath,"String")?t=S(e.subDocPath):m(e.subDocPath,"Undefined")&&(t=[]),t}function v(e){return R.parse(encodeURI(decodeURI(e)))}function g(e,t,r){c(e,t.slice(0,t.length-1))[decodeURI(t[t.length-1])]=r}function b(e,t,r,n){function o(t,o){r.push(o),b(e,t,r,n),r.pop()}var i=!0;m(n,"Function")&&(i=n(e,t,r)),e.indexOf(t)===-1&&(e.push(t),i!==!1&&(m(t,"Array")?t.forEach(function(e,t){o(e,t.toString())}):m(t,"Object")&&Object.keys(t).forEach(function(e){o(t[e],e)}))),e.pop()}function x(e,t){if(e=m(e,"Undefined")?{}:n(e),!m(e,"Object"))throw new TypeError("options must be an Object");if(!(m(e.filter,"Undefined")||m(e.filter,"Array")||m(e.filter,"Function")||m(e.filter,"String")))throw new TypeError("options.filter must be an Array, a Function of a String");if(!m(e.includeInvalid,"Undefined")&&!m(e.includeInvalid,"Boolean"))throw new TypeError("options.includeInvalid must be a Boolean");if(!m(e.refPreProcessor,"Undefined")&&!m(e.refPreProcessor,"Function"))throw new TypeError("options.refPreProcessor must be a Function");if(!m(e.refPostProcessor,"Undefined")&&!m(e.refPostProcessor,"Function"))throw new TypeError("options.refPostProcessor must be a Function");if(!m(e.subDocPath,"Undefined")&&!m(e.subDocPath,"Array")&&!T(e.subDocPath))throw new TypeError("options.subDocPath must be an Array of path segments or a valid JSON Pointer");if(e.filter=h(e),e.subDocPath=y(e),!m(t,"Undefined"))try{c(t,e.subDocPath)}catch(e){throw e.message=e.message.replace("JSON Pointer","options.subDocPath"),e}return e}function w(){U={}}function $(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),decodeURI(e.replace(/~1/g,"/").replace(/~0/g,"~"))})}function E(e){if(!m(e,"Array"))throw new TypeError("path must be an array");return e.map(function(e){return m(e,"String")||(e=JSON.stringify(e)),e.replace(/~/g,"~0").replace(/\//g,"~1")})}function C(e,t){var r={};if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");return t=x(t,e),b(a(e,t.subDocPath),c(e,t.subDocPath),n(t.subDocPath),function(e,o,i){var a,s=!0;return p(o)&&(m(t.refPreProcessor,"Undefined")||(o=t.refPreProcessor(n(o),i)),a=O(o),m(t.refPostProcessor,"Undefined")||(a=t.refPostProcessor(a,i)),t.filter(a,i)&&(r[P(i)]=a),u(o).length>0&&(s=!1)),s}),r}function k(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=x(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(U[e]),i=n(t),a=v(e);return m(o.refs,"Undefined")&&(delete i.filter,delete i.subDocPath,i.includeInvalid=!0,U[e].refs=C(r,i)),m(t.filter,"Undefined")||(i.filter=t.filter),m(a.fragment,"Undefined")?m(a.subDocPath,"Undefined")||(i.subDocPath=t.subDocPath):i.subDocPath=S(decodeURI(a.fragment)),{refs:C(r,i),value:r}})}function O(e){var t,r,n,o={def:e};try{p(e,!0)?(t=e.$ref,n=H[t],m(n,"Undefined")&&(n=H[t]=v(t)),o.uri=t,o.uriDetails=n,m(n.error,"Undefined")?o.type=f(o):(o.error=o.uriDetails.error,o.type="invalid"),r=u(e),r.length>0&&(o.warning="Extra JSON Reference properties will be ignored: "+r.join(", "))):o.type="invalid"}catch(e){o.error=e.message,o.type="invalid"}return o}function T(e,t){var r,n=!0;try{if(!m(e,"String"))throw new Error("ptr is not a String");if(""!==e){if(r=e.charAt(0),["#","/"].indexOf(r)===-1)throw new Error("ptr must start with a / or #/");if("#"===r&&"#"!==e&&"/"!==e.charAt(1))throw new Error("ptr must start with a / or #/");if(e.match(q))throw new Error("ptr has invalid token(s)")}}catch(e){if(t===!0)throw e;n=!1}return n}function A(e,t){return p(e,t)&&"invalid"!==O(e,t).type}function S(e){if(!T(e))throw new Error("ptr must be a JSON Pointer");var t=e.split("/");return t.shift(),$(t)}function P(e,t){if(!m(e,"Array"))throw new Error("path must be an Array");return(t!==!1?"#":"")+(e.length>0?"/":"")+E(e).join("/")}function M(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"Array")&&!m(e,"Object"))throw new TypeError("obj must be an Array or an Object");t=x(t,e),e=n(e)}).then(function(){return l(e,t,[],[],{documents:{},refs:{}})}).then(function(t){function r(e,t){return S(e).length-S(t).length}var n={},o={};return Object.keys(t.refs).sort(r).forEach(function(r){var i=t.refs[r];i.indirect||(o[r]=i),delete i.indirect,m(i.error,"Undefined")&&"invalid"!==i.type?(m(i.value,"Undefined")&&i.circular&&(i.value=i.def),m(i.value,"Undefined")?n[r]=i:("#"===r?e=i.value:g(e,S(r),i.value),delete i.ancestorPtrs)):delete i.ancestorPtrs}),Object.keys(n).forEach(function(r){var o=n[r];o.ancestorPtrs.forEach(function(n,i){if(m(o.value,"Undefined"))try{o.value=c(t.documents[n],S(o.uri)),delete o.ancestorPtrs,g(e,S(r),o.value)}catch(e){i===o.ancestorPtrs.length-1&&(o.error=e.message,o.missing=!0,delete o.ancestorPtrs)}})}),{refs:o,resolved:e}})}function I(e,t){var r=Promise.resolve();return r=r.then(function(){if(!m(e,"String"))throw new TypeError("location must be a string");return t=x(t),e=i(t.relativeBase,e),d(e,t)}).then(function(r){var o=n(t),i=v(e);return m(i.fragment,"Undefined")||(o.subDocPath=S(decodeURI(i.fragment))),o.relativeBase=j.dirname(e),M(r,o).then(function(e){return{refs:e.refs,resolved:e.resolved,value:r}})})}var j=e("path"),D=e("path-loader"),_=e("querystring"),F=e("slash"),R=e("uri-js"),q=/~(?:[^01]|$)/g,U={},N=["relative","remote"],L=["absolute","uri"],H={};"undefined"==typeof Promise&&e("native-promise-only"),t.exports.clearCache=w,t.exports.decodePath=$,t.exports.encodePath=E,t.exports.findRefs=C,t.exports.findRefsAt=k,t.exports.getRefDetails=O,t.exports.isPtr=T,t.exports.isRef=A,t.exports.pathFromPtr=S,t.exports.pathToPtr=P,t.exports.resolveRefs=M,t.exports.resolveRefsAt=I},{"native-promise-only":3,path:4,"path-loader":5,querystring:11,slash:13,"uri-js":23}],2:[function(e,t,r){function n(e){if(e)return o(e)}function o(e){for(var t in n.prototype)e[t]=n.prototype[t];return e}t.exports=n,n.prototype.on=n.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this},n.prototype.once=function(e,t){function r(){this.off(e,r),t.apply(this,arguments)}return r.fn=t,this.on(e,r),this},n.prototype.off=n.prototype.removeListener=n.prototype.removeAllListeners=n.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},0==arguments.length)return this._callbacks={},this;var r=this._callbacks["$"+e];if(!r)return this;if(1==arguments.length)return delete this._callbacks["$"+e],this;for(var n,o=0;o<r.length;o++)if(n=r[o],n===t||n.fn===t){r.splice(o,1);break}return this},n.prototype.emit=function(e){this._callbacks=this._callbacks||{};var t=[].slice.call(arguments,1),r=this._callbacks["$"+e];if(r){r=r.slice(0);for(var n=0,o=r.length;n<o;++n)r[n].apply(this,t)}return this},n.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]},n.prototype.hasListeners=function(e){return!!this.listeners(e).length}},{}],3:[function(n,o,i){(function(t){/*! Native Promise Only
     v0.8.1 (c) Kyle Simpson
     MIT License: http://getify.mit-license.org
 */
-!function(t,r,n){r[t]=r[t]||n(),"undefined"!=typeof o&&o.exports?o.exports=r[t]:"function"==typeof e&&e.amd&&e(function(){return r[t]})}("Promise","undefined"!=typeof t?t:this,function(){"use strict";function e(e,t){m.add(e,t),p||(p=y(m.drain))}function t(e){var t,r="undefined"==typeof e?"undefined":c(e);return null==e||"object"!=r&&"function"!=r||(t=e.then),"function"==typeof t&&t}function n(){for(var e=0;e<this.chain.length;e++)o(this,1===this.state?this.chain[e].success:this.chain[e].failure,this.chain[e]);this.chain.length=0}function o(e,r,n){var o,i;try{r===!1?n.reject(e.msg):(o=r===!0?e.msg:r.call(void 0,e.msg),o===n.promise?n.reject(TypeError("Promise-chain cycle")):(i=t(o))?i.call(o,n.resolve,n.reject):n.resolve(o))}catch(e){n.reject(e)}}function i(r){var o,s=this;if(!s.triggered){s.triggered=!0,s.def&&(s=s.def);try{(o=t(r))?e(function(){var e=new l(s);try{o.call(r,function(){i.apply(e,arguments)},function(){a.apply(e,arguments)})}catch(t){a.call(e,t)}}):(s.msg=r,s.state=1,s.chain.length>0&&e(n,s))}catch(e){a.call(new l(s),e)}}}function a(t){var r=this;r.triggered||(r.triggered=!0,r.def&&(r=r.def),r.msg=t,r.state=2,r.chain.length>0&&e(n,r))}function s(e,t,r,n){for(var o=0;o<t.length;o++)!function(o){e.resolve(t[o]).then(function(e){r(o,e)},n)}(o)}function l(e){this.def=e,this.triggered=!1}function u(e){this.promise=e,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function f(t){if("function"!=typeof t)throw TypeError("Not a function");if(0!==this.__NPO__)throw TypeError("Not a promise");this.__NPO__=1;var r=new u(this);this.then=function(t,o){var i={success:"function"!=typeof t||t,failure:"function"==typeof o&&o};return i.promise=new this.constructor(function(e,t){if("function"!=typeof e||"function"!=typeof t)throw TypeError("Not a function");i.resolve=e,i.reject=t}),r.chain.push(i),0!==r.state&&e(n,r),i.promise},this.catch=function(e){return this.then(void 0,e)};try{t.call(void 0,function(e){i.call(r,e)},function(e){a.call(r,e)})}catch(e){a.call(r,e)}}var d,p,m,h=Object.prototype.toString,y="undefined"!=typeof r?function(e){return r(e)}:setTimeout;try{Object.defineProperty({},"x",{}),d=function(e,t,r,n){return Object.defineProperty(e,t,{value:r,writable:!0,configurable:n!==!1})}}catch(e){d=function(e,t,r){return e[t]=r,e}}m=function(){function e(e,t){this.fn=e,this.self=t,this.next=void 0}var t,r,n;return{add:function(o,i){n=new e(o,i),r?r.next=n:t=n,r=n,n=void 0},drain:function(){var e=t;for(t=r=p=void 0;e;)e.fn.call(e.self),e=e.next}}}();var v=d({},"constructor",f,!1);return f.prototype=v,d(v,"__NPO__",0,!1),d(f,"resolve",function(e){var t=this;return e&&"object"==("undefined"==typeof e?"undefined":c(e))&&1===e.__NPO__?e:new t(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");t(e)})}),d(f,"reject",function(e){return new this(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");r(e)})}),d(f,"all",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):0===e.length?t.resolve([]):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");var o=e.length,i=Array(o),a=0;s(t,e,function(e,t){i[e]=t,++a===o&&r(i)},n)})}),d(f,"race",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");s(t,e,function(e,t){r(t)},n)})}),f})}).call(this,"undefined"!=typeof t?t:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],4:[function(e,t,r){(function(e){function t(e,t){for(var r=0,n=e.length-1;n>=0;n--){var o=e[n];"."===o?e.splice(n,1):".."===o?(e.splice(n,1),r++):r&&(e.splice(n,1),r--)}if(t)for(;r--;r)e.unshift("..");return e}function n(e,t){if(e.filter)return e.filter(t);for(var r=[],n=0;n<e.length;n++)t(e[n],n,e)&&r.push(e[n]);return r}var o=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,i=function(e){return o.exec(e).slice(1)};r.resolve=function(){for(var r="",o=!1,i=arguments.length-1;i>=-1&&!o;i--){var a=i>=0?arguments[i]:e.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(r=a+"/"+r,o="/"===a.charAt(0))}return r=t(n(r.split("/"),function(e){return!!e}),!o).join("/"),(o?"/":"")+r||"."},r.normalize=function(e){var o=r.isAbsolute(e),i="/"===a(e,-1);return e=t(n(e.split("/"),function(e){return!!e}),!o).join("/"),e||o||(e="."),e&&i&&(e+="/"),(o?"/":"")+e},r.isAbsolute=function(e){return"/"===e.charAt(0)},r.join=function(){var e=Array.prototype.slice.call(arguments,0);return r.normalize(n(e,function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e}).join("/"))},r.relative=function(e,t){function n(e){for(var t=0;t<e.length&&""===e[t];t++);for(var r=e.length-1;r>=0&&""===e[r];r--);return t>r?[]:e.slice(t,r-t+1)}e=r.resolve(e).substr(1),t=r.resolve(t).substr(1);for(var o=n(e.split("/")),i=n(t.split("/")),a=Math.min(o.length,i.length),s=a,l=0;l<a;l++)if(o[l]!==i[l]){s=l;break}for(var c=[],l=s;l<o.length;l++)c.push("..");return c=c.concat(i.slice(s)),c.join("/")},r.sep="/",r.delimiter=":",r.dirname=function(e){var t=i(e),r=t[0],n=t[1];return r||n?(n&&(n=n.substr(0,n.length-1)),r+n):"."},r.basename=function(e,t){var r=i(e)[2];return t&&r.substr(-1*t.length)===t&&(r=r.substr(0,r.length-t.length)),r},r.extname=function(e){return i(e)[3]};var a="b"==="ab".substr(-1)?function(e,t,r){return e.substr(t,r)}:function(e,t,r){return t<0&&(t=e.length+t),e.substr(t,r)}}).call(this,e("_process"))},{_process:8}],5:[function(e,t,r){"use strict";function n(e){return"undefined"!=typeof e&&(e=e.indexOf("://")===-1?"":e.split("://")[0]),e}function o(e){var t=n(e),r=i[t];if("undefined"==typeof r){if(""!==t)throw new Error("Unsupported scheme: "+t);r=a}return r}var i={file:e("./lib/loaders/file"),http:e("./lib/loaders/http"),https:e("./lib/loaders/http")},a="object"===("undefined"==typeof window?"undefined":c(window))||"function"==typeof importScripts?i.http:i.file;"undefined"==typeof Promise&&e("native-promise-only"),t.exports.load=function(e,t){var r=Promise.resolve();return"undefined"==typeof t&&(t={}),r=r.then(function(){if("undefined"==typeof e)throw new TypeError("location is required");if("string"!=typeof e)throw new TypeError("location must be a string");if("undefined"!=typeof t){if("object"!==("undefined"==typeof t?"undefined":c(t)))throw new TypeError("options must be an object");if("undefined"!=typeof t.processContent&&"function"!=typeof t.processContent)throw new TypeError("options.processContent must be a function")}}),r=r.then(function(){return new Promise(function(r,n){var i=o(e);i.load(e,t||{},function(e,t){e?n(e):r(t)})})}).then(function(e){return t.processContent?new Promise(function(r,n){t.processContent("object"===("undefined"==typeof e?"undefined":c(e))?e:{text:e},function(e,t){e?n(e):r(t)})}):"object"===("undefined"==typeof e?"undefined":c(e))?e.text:e})}},{"./lib/loaders/file":6,"./lib/loaders/http":7,"native-promise-only":3}],6:[function(e,t,r){"use strict";var n=new TypeError("The 'file' scheme is not supported in the browser");t.exports.getBase=function(){throw n},t.exports.load=function(){var e=arguments[arguments.length-1];if("function"!=typeof e)throw n;e(n)}},{}],7:[function(e,t,r){"use strict";var n=e("superagent"),o=["delete","get","head","patch","post","put"];t.exports.load=function(e,t,r){function i(e,t){e?r(e):("function"==typeof t.buffer&&t.buffer(!0),t.end(function(e,t){e?r(e):r(void 0,t)}))}var a,s,l=t.method?t.method.toLowerCase():"get";if("undefined"!=typeof t.method?"string"!=typeof t.method?a=new TypeError("options.method must be a string"):o.indexOf(t.method)===-1&&(a=new TypeError("options.method must be one of the following: "+o.slice(0,o.length-1).join(", ")+" or "+o[o.length-1])):"undefined"!=typeof t.prepareRequest&&"function"!=typeof t.prepareRequest&&(a=new TypeError("options.prepareRequest must be a function")),a)r(a);else if(s=n["delete"===l?"del":l](e),t.prepareRequest)try{t.prepareRequest(s,i)}catch(e){r(e)}else i(void 0,s)}},{superagent:14}],8:[function(e,t,r){function n(){u=!1,s.length?c=s.concat(c):f=-1,c.length&&o()}function o(){if(!u){var e=setTimeout(n);u=!0;for(var t=c.length;t;){for(s=c,c=[];++f<t;)s&&s[f].run();f=-1,t=c.length}s=null,u=!1,clearTimeout(e)}}function i(e,t){this.fun=e,this.array=t}function a(){}var s,l=t.exports={},c=[],u=!1,f=-1;l.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];c.push(new i(e,t)),1!==c.length||u||setTimeout(o,0)},i.prototype.run=function(){this.fun.apply(null,this.array)},l.title="browser",l.browser=!0,l.env={},l.argv=[],l.version="",l.versions={},l.on=a,l.addListener=a,l.once=a,l.off=a,l.removeListener=a,l.removeAllListeners=a,l.emit=a,l.binding=function(e){throw new Error("process.binding is not supported")},l.cwd=function(){return"/"},l.chdir=function(e){throw new Error("process.chdir is not supported")},l.umask=function(){return 0}},{}],9:[function(e,t,r){"use strict";function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.exports=function(e,t,r,i){t=t||"&",r=r||"=";var a={};if("string"!=typeof e||0===e.length)return a;var s=/\+/g;e=e.split(t);var l=1e3;i&&"number"==typeof i.maxKeys&&(l=i.maxKeys);var c=e.length;l>0&&c>l&&(c=l);for(var u=0;u<c;++u){var f,d,p,m,h=e[u].replace(s,"%20"),y=h.indexOf(r);y>=0?(f=h.substr(0,y),d=h.substr(y+1)):(f=h,d=""),p=decodeURIComponent(f),m=decodeURIComponent(d),n(a,p)?o(a[p])?a[p].push(m):a[p]=[a[p],m]:a[p]=m}return a};var o=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},{}],10:[function(e,t,r){"use strict";function n(e,t){if(e.map)return e.map(t);for(var r=[],n=0;n<e.length;n++)r.push(t(e[n],n));return r}var o=function(e){switch("undefined"==typeof e?"undefined":c(e)){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};t.exports=function(e,t,r,s){return t=t||"&",r=r||"=",null===e&&(e=void 0),"object"===("undefined"==typeof e?"undefined":c(e))?n(a(e),function(a){var s=encodeURIComponent(o(a))+r;return i(e[a])?n(e[a],function(e){return s+encodeURIComponent(o(e))}).join(t):s+encodeURIComponent(o(e[a]))}).join(t):s?encodeURIComponent(o(s))+r+encodeURIComponent(o(e)):""};var i=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},a=Object.keys||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t}},{}],11:[function(e,t,r){"use strict";r.decode=r.parse=e("./decode"),r.encode=r.stringify=e("./encode")},{"./decode":9,"./encode":10}],12:[function(e,t,r){t.exports=function(e,t,r){for(var n=0,o=e.length,i=3==arguments.length?r:e[n++];n<o;)i=t.call(null,i,e[n],++n,e);return i}},{}],13:[function(e,t,r){"use strict";t.exports=function(e){var t=/^\\\\\?\\/.test(e),r=/[^\x00-\x80]+/.test(e);return t||r?e:e.replace(/\\/g,"/")}},{}],14:[function(e,t,r){function n(){}function o(e){var t={}.toString.call(e);switch(t){case"[object File]":case"[object Blob]":case"[object FormData]":return!0;default:return!1}}function i(e){if(!b(e))return e;var t=[];for(var r in e)null!=e[r]&&a(t,r,e[r]);return t.join("&")}function a(e,t,r){return Array.isArray(r)?r.forEach(function(r){a(e,t,r)}):void e.push(encodeURIComponent(t)+"="+encodeURIComponent(r))}function s(e){for(var t,r,n={},o=e.split("&"),i=0,a=o.length;i<a;++i)r=o[i],t=r.split("="),n[decodeURIComponent(t[0])]=decodeURIComponent(t[1]);return n}function l(e){var t,r,n,o,i=e.split(/\r?\n/),a={};i.pop();for(var s=0,l=i.length;s<l;++s)r=i[s],t=r.indexOf(":"),n=r.slice(0,t).toLowerCase(),o=w(r.slice(t+1)),a[n]=o;return a}function c(e){return/[\/+]json\b/.test(e)}function u(e){return e.split(/ *; */).shift()}function f(e){return v(e.split(/ *; */),function(e,t){var r=t.split(/ *= */),n=r.shift(),o=r.shift();return n&&o&&(e[n]=o),e},{})}function d(e,t){t=t||{},this.req=e,this.xhr=this.req.xhr,this.text="HEAD"!=this.req.method&&(""===this.xhr.responseType||"text"===this.xhr.responseType)||"undefined"==typeof this.xhr.responseType?this.xhr.responseText:null,this.statusText=this.req.xhr.statusText,this.setStatusProperties(this.xhr.status),this.header=this.headers=l(this.xhr.getAllResponseHeaders()),this.header["content-type"]=this.xhr.getResponseHeader("content-type"),this.setHeaderProperties(this.header),this.body="HEAD"!=this.req.method?this.parseBody(this.text?this.text:this.xhr.response):null}function p(e,t){var r=this;this._query=this._query||[],this.method=e,this.url=t,this.header={},this._header={},this.on("end",function(){var e=null,t=null;try{t=new d(r)}catch(t){return e=new Error("Parser is unable to parse the response"),e.parse=!0,e.original=t,e.rawResponse=r.xhr&&r.xhr.responseText?r.xhr.responseText:null,e.statusCode=r.xhr&&r.xhr.status?r.xhr.status:null,r.callback(e)}if(r.emit("response",t),e)return r.callback(e,t);if(t.status>=200&&t.status<300)return r.callback(e,t);var n=new Error(t.statusText||"Unsuccessful HTTP response");n.original=e,n.response=t,n.status=t.status,r.callback(n,t)})}function m(e,t){var r=x("DELETE",e);return t&&r.end(t),r}var h,y=e("emitter"),v=e("reduce"),g=e("./request-base"),b=e("./is-object");h="undefined"!=typeof window?window:"undefined"!=typeof self?self:this;var x=t.exports=e("./request").bind(null,p);x.getXHR=function(){if(!(!h.XMLHttpRequest||h.location&&"file:"==h.location.protocol&&h.ActiveXObject))return new XMLHttpRequest;try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(e){}return!1};var w="".trim?function(e){return e.trim()}:function(e){return e.replace(/(^\s*|\s*$)/g,"")};x.serializeObject=i,x.parseString=s,x.types={html:"text/html",json:"application/json",xml:"application/xml",urlencoded:"application/x-www-form-urlencoded",form:"application/x-www-form-urlencoded","form-data":"application/x-www-form-urlencoded"},x.serialize={"application/x-www-form-urlencoded":i,"application/json":JSON.stringify},x.parse={"application/x-www-form-urlencoded":s,"application/json":JSON.parse},d.prototype.get=function(e){return this.header[e.toLowerCase()]},d.prototype.setHeaderProperties=function(e){var t=this.header["content-type"]||"";this.type=u(t);var r=f(t);for(var n in r)this[n]=r[n]},d.prototype.parseBody=function(e){var t=x.parse[this.type];return!t&&c(this.type)&&(t=x.parse["application/json"]),t&&e&&(e.length||e instanceof Object)?t(e):null},d.prototype.setStatusProperties=function(e){1223===e&&(e=204);var t=e/100|0;this.status=this.statusCode=e,this.statusType=t,this.info=1==t,this.ok=2==t,this.clientError=4==t,this.serverError=5==t,this.error=(4==t||5==t)&&this.toError(),this.accepted=202==e,this.noContent=204==e,this.badRequest=400==e,this.unauthorized=401==e,this.notAcceptable=406==e,this.notFound=404==e,this.forbidden=403==e},d.prototype.toError=function(){var e=this.req,t=e.method,r=e.url,n="cannot "+t+" "+r+" ("+this.status+")",o=new Error(n);return o.status=this.status,o.method=t,o.url=r,o},x.Response=d,y(p.prototype);for(var E in g)p.prototype[E]=g[E];p.prototype.abort=function(){if(!this.aborted)return this.aborted=!0,this.xhr.abort(),this.clearTimeout(),this.emit("abort"),this},p.prototype.type=function(e){return this.set("Content-Type",x.types[e]||e),this},p.prototype.responseType=function(e){return this._responseType=e,this},p.prototype.accept=function(e){return this.set("Accept",x.types[e]||e),this},p.prototype.auth=function(e,t,r){switch(r||(r={type:"basic"}),r.type){case"basic":var n=btoa(e+":"+t);this.set("Authorization","Basic "+n);break;case"auto":this.username=e,this.password=t}return this},p.prototype.query=function(e){return"string"!=typeof e&&(e=i(e)),e&&this._query.push(e),this},p.prototype.attach=function(e,t,r){return this._getFormData().append(e,t,r||t.name),this},p.prototype._getFormData=function(){return this._formData||(this._formData=new h.FormData),this._formData},p.prototype.send=function(e){var t=b(e),r=this._header["content-type"];if(t&&b(this._data))for(var n in e)this._data[n]=e[n];else"string"==typeof e?(r||this.type("form"),r=this._header["content-type"],"application/x-www-form-urlencoded"==r?this._data=this._data?this._data+"&"+e:e:this._data=(this._data||"")+e):this._data=e;return!t||o(e)?this:(r||this.type("json"),this)},d.prototype.parse=function(e){return h.console&&console.warn("Client-side parse() method has been renamed to serialize(). This method is not compatible with superagent v2.0"),this.serialize(e),this},d.prototype.serialize=function(e){return this._parser=e,this},p.prototype.callback=function(e,t){var r=this._callback;this.clearTimeout(),r(e,t)},p.prototype.crossDomainError=function(){var e=new Error("Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.");e.crossDomain=!0,e.status=this.status,e.method=this.method,e.url=this.url,this.callback(e)},p.prototype.timeoutError=function(){var e=this._timeout,t=new Error("timeout of "+e+"ms exceeded");t.timeout=e,this.callback(t)},p.prototype.withCredentials=function(){return this._withCredentials=!0,this},p.prototype.end=function(e){var t=this,r=this.xhr=x.getXHR(),i=this._query.join("&"),a=this._timeout,s=this._formData||this._data;this._callback=e||n,r.onreadystatechange=function(){if(4==r.readyState){var e;try{e=r.status}catch(t){e=0}if(0==e){if(t.timedout)return t.timeoutError();if(t.aborted)return;return t.crossDomainError()}t.emit("end")}};var l=function(e){e.total>0&&(e.percent=e.loaded/e.total*100),e.direction="download",t.emit("progress",e)};this.hasListeners("progress")&&(r.onprogress=l);try{r.upload&&this.hasListeners("progress")&&(r.upload.onprogress=l)}catch(e){}if(a&&!this._timer&&(this._timer=setTimeout(function(){t.timedout=!0,t.abort()},a)),i&&(i=x.serializeObject(i),this.url+=~this.url.indexOf("?")?"&"+i:"?"+i),this.username&&this.password?r.open(this.method,this.url,!0,this.username,this.password):r.open(this.method,this.url,!0),this._withCredentials&&(r.withCredentials=!0),"GET"!=this.method&&"HEAD"!=this.method&&"string"!=typeof s&&!o(s)){var u=this._header["content-type"],f=this._parser||x.serialize[u?u.split(";")[0]:""];!f&&c(u)&&(f=x.serialize["application/json"]),f&&(s=f(s))}for(var d in this.header)null!=this.header[d]&&r.setRequestHeader(d,this.header[d]);return this._responseType&&(r.responseType=this._responseType),this.emit("request",this),r.send("undefined"!=typeof s?s:null),this},x.Request=p,x.get=function(e,t,r){var n=x("GET",e);return"function"==typeof t&&(r=t,t=null),t&&n.query(t),r&&n.end(r),n},x.head=function(e,t,r){var n=x("HEAD",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.del=m,x.delete=m,x.patch=function(e,t,r){var n=x("PATCH",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.post=function(e,t,r){var n=x("POST",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.put=function(e,t,r){var n=x("PUT",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n}},{"./is-object":15,"./request":17,"./request-base":16,emitter:2,reduce:12}],15:[function(e,t,r){function n(e){return null!=e&&"object"==("undefined"==typeof e?"undefined":c(e))}t.exports=n},{}],16:[function(e,t,r){var n=e("./is-object");r.clearTimeout=function(){return this._timeout=0,clearTimeout(this._timer),this},r.parse=function(e){return this._parser=e,this},r.timeout=function(e){return this._timeout=e,this},r.then=function(e,t){return this.end(function(r,n){r?t(r):e(n)})},r.use=function(e){return e(this),this},r.get=function(e){return this._header[e.toLowerCase()]},r.getHeader=r.get,r.set=function(e,t){if(n(e)){for(var r in e)this.set(r,e[r]);return this}return this._header[e.toLowerCase()]=t,this.header[e]=t,this},r.unset=function(e){return delete this._header[e.toLowerCase()],delete this.header[e],this},r.field=function(e,t){return this._getFormData().append(e,t),this}},{"./is-object":15}],17:[function(e,t,r){function n(e,t,r){return"function"==typeof r?new e("GET",t).end(r):2==arguments.length?new e("GET",t):new e(t,r)}t.exports=n},{}],18:[function(e,t,r){/*! https://mths.be/punycode v1.3.2 by @mathias, modified for URI.js */var n=function(){function e(e){throw new RangeError(k[e])}function t(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function r(e,r){var n=e.split("@"),o="";n.length>1&&(o=n[0]+"@",e=n[1]),e=e.replace(C,".");var i=e.split("."),a=t(i,r).join(".");return o+a}function n(e){for(var t,r,n=[],o=0,i=e.length;o<i;)t=e.charCodeAt(o++),t>=55296&&t<=56319&&o<i?(r=e.charCodeAt(o++),56320==(64512&r)?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),o--)):n.push(t);return n}function o(e){return t(e,function(e){var t="";return e>65535&&(e-=65536,t+=A(e>>>10&1023|55296),e=56320|1023&e),t+=A(e)}).join("")}function i(e){return e-48<10?e-22:e-65<26?e-65:e-97<26?e-97:m}function a(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function s(e,t,r){var n=0;for(e=r?T(e/g):e>>1,e+=T(e/t);e>O*y>>1;n+=m)e=T(e/O);return T(n+(O+1)*e/(e+v))}function l(t){var r,n,a,l,c,u,f,d,v,g,E=[],$=t.length,C=0,k=x,O=b;for(n=t.lastIndexOf(w),n<0&&(n=0),a=0;a<n;++a)t.charCodeAt(a)>=128&&e("not-basic"),E.push(t.charCodeAt(a));for(l=n>0?n+1:0;l<$;){for(c=C,u=1,f=m;l>=$&&e("invalid-input"),d=i(t.charCodeAt(l++)),(d>=m||d>T((p-C)/u))&&e("overflow"),C+=d*u,v=f<=O?h:f>=O+y?y:f-O,!(d<v);f+=m)g=m-v,u>T(p/g)&&e("overflow"),u*=g;r=E.length+1,O=s(C-c,r,0==c),T(C/r)>p-k&&e("overflow"),k+=T(C/r),C%=r,E.splice(C++,0,k)}return o(E)}function c(t){var r,o,i,l,c,u,f,d,v,g,E,$,C,k,O,S=[];for(t=n(t),$=t.length,r=x,o=0,c=b,u=0;u<$;++u)E=t[u],E<128&&S.push(A(E));for(i=l=S.length,l&&S.push(w);i<$;){for(f=p,u=0;u<$;++u)E=t[u],E>=r&&E<f&&(f=E);for(C=i+1,f-r>T((p-o)/C)&&e("overflow"),o+=(f-r)*C,r=f,u=0;u<$;++u)if(E=t[u],E<r&&++o>p&&e("overflow"),E==r){for(d=o,v=m;g=v<=c?h:v>=c+y?y:v-c,!(d<g);v+=m)O=d-g,k=m-g,S.push(A(a(g+O%k,0))),d=T(O/k);S.push(A(a(d,0))),c=s(o,C,i==l),o=0,++i}++o,++r}return S.join("")}function u(e){return r(e,function(e){return E.test(e)?l(e.slice(4).toLowerCase()):e})}function f(e){return r(e,function(e){return $.test(e)?"xn--"+c(e):e})}var d,p=2147483647,m=36,h=1,y=26,v=38,g=700,b=72,x=128,w="-",E=/^xn--/,$=/[^\x20-\x7E]/,C=/[\x2E\u3002\uFF0E\uFF61]/g,k={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},O=m-h,T=Math.floor,A=String.fromCharCode;return d={version:"1.3.2",ucs2:{decode:n,encode:o},decode:l,encode:c,toASCII:f,toUnicode:u}}();"undefined"==typeof COMPILED&&"undefined"!=typeof t&&(t.exports=n)},{}],19:[function(e,t,r){e("./schemes/http"),e("./schemes/urn"),e("./schemes/mailto")},{"./schemes/http":20,"./schemes/mailto":21,"./schemes/urn":22}],20:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");n.SCHEMES.http=n.SCHEMES.https={domainHost:!0,parse:function(e,t){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e},serialize:function(e,t){return e.port!==("https"!==String(e.scheme).toLowerCase()?80:443)&&""!==e.port||(e.port=void 0),e.path||(e.path="/"),e}}},{"../uri":23}],21:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri"),o=e("../punycode");!function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(e){return e.toUpperCase()}function i(e){var t=n.pctDecChars(e);return t.match(M)?t:e}function a(e){return void 0!==e&&null!==e?e instanceof Array&&!e.callee?e:"number"!=typeof e.length||e.split||e.setInterval||e.call?[e]:Array.prototype.slice.call(e):[]}var s={},l=n.IRI_SUPPORT,c="[A-Za-z0-9\\-\\.\\_\\~"+(l?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",u="[0-9A-Fa-f]",f=t(t("%[EFef]"+u+"%"+u+u+"%"+u+u)+"|"+t("%[89A-Fa-f]"+u+"%"+u+u)+"|"+t("%"+u+u)),d="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",p="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",m=e(p,'[\\"\\\\]'),h=t(d+"+"+t("\\."+d+"+")+"*"),y=t("\\\\"+m),v=t(p+"|"+y),g=t('\\"'+v+'*\\"'),b="[\\x21-\\x5A\\x5E-\\x7E]",x="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",w=t(c+"|"+f+"|"+x),E=t(h+"|\\["+b+"*\\]"),$=t(h+"|"+g),C=t($+"\\@"+E),k=t(C+t("\\,"+C)+"*"),O=t(w+"*"),T=O,A=t(O+"\\="+T),S=t(A+t("\\&"+A)+"*"),P=t("\\?"+S),M=(n.VALIDATE_SUPPORT&&new RegExp("^mailto\\:"+k+"?"+P+"?$"),new RegExp(c,"g")),j=new RegExp(f,"g"),I=new RegExp(e("[^]",d,"[\\.]",'[\\"]',m),"g"),D=new RegExp(e("[^]",d,"[\\.]","[\\[]",b,"[\\]]"),"g"),_=new RegExp(e("[^]",c,x),"g"),F=_,R=n.VALIDATE_SUPPORT&&new RegExp("^"+k+"$"),q=n.VALIDATE_SUPPORT&&new RegExp("^"+S+"$");n.SCHEMES.mailto={parse:function(e,t){n.VALIDATE_SUPPORT&&!e.error&&(e.path&&!R.test(e.path)?e.error="Email address is not valid":e.query&&!q.test(e.query)&&(e.error="Header fields are invalid"));var r=e.to=e.path?e.path.split(","):[];if(e.path=void 0,e.query){for(var i=!1,a={},s=e.query.split("&"),l=0,c=s.length;l<c;++l){var u=s[l].split("=");switch(u[0]){case"to":for(var f=u[1].split(","),d=0,p=f.length;d<p;++d)r.push(f[d]);break;case"subject":e.subject=n.unescapeComponent(u[1],t);break;case"body":e.body=n.unescapeComponent(u[1],t);break;default:i=!0,a[n.unescapeComponent(u[0],t)]=n.unescapeComponent(u[1],t)}}i&&(e.headers=a)}e.query=void 0;for(var l=0,c=r.length;l<c;++l){var m=r[l].split("@");if(m[0]=n.unescapeComponent(m[0]),"undefined"==typeof o||t.unicodeSupport)m[1]=n.unescapeComponent(m[1],t).toLowerCase();else try{m[1]=o.toASCII(n.unescapeComponent(m[1],t).toLowerCase())}catch(t){e.error=e.error||"Email address's domain name can not be converted to ASCII via punycode: "+t}r[l]=m.join("@")}return e},serialize:function(e,t){var l=a(e.to);if(l){for(var c=0,u=l.length;c<u;++c){var f=String(l[c]),d=f.lastIndexOf("@"),p=f.slice(0,d),m=f.slice(d+1);if(p=p.replace(j,i).replace(j,r).replace(I,n.pctEncChar),"undefined"!=typeof o)try{m=t.iri?o.toUnicode(m):o.toASCII(n.unescapeComponent(m,t).toLowerCase())}catch(r){e.error=e.error||"Email address's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}else m=m.replace(j,i).toLowerCase().replace(j,r).replace(D,n.pctEncChar);l[c]=p+"@"+m}e.path=l.join(",")}var h=e.headers=e.headers||{};e.subject&&(h.subject=e.subject),e.body&&(h.body=e.body);var y=[];for(var v in h)h[v]!==s[v]&&y.push(v.replace(j,i).replace(j,r).replace(_,n.pctEncChar)+"="+h[v].replace(j,i).replace(j,r).replace(F,n.pctEncChar));return y.length&&(e.query=y.join("&")),e}}}()},{"../punycode":18,"../uri":23}],22:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");!function(){var e=n.pctEncChar,t="(?:[0-9A-Za-z][0-9A-Za-z\\-]{1,31})",r="(?:\\%[0-9A-Fa-f]{2})",o="[0-9A-Za-z\\(\\)\\+\\,\\-\\.\\:\\=\\@\\;\\$\\_\\!\\*\\'\\/\\?\\#]",i="(?:(?:"+r+"|"+o+")+)",a=new RegExp("^urn\\:("+t+")$"),s=new RegExp("^("+t+")\\:("+i+")$"),l=/^([^\:]+)\:(.*)/,c=/[\x00-\x20\\\"\&\<\>\[\]\^\`\{\|\}\~\x7F-\xFF]/g,u=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/;n.SCHEMES.urn={parse:function(e,t){var r,o,i=e.path.match(s);return i||(t.tolerant||(e.error=e.error||"URN is not strictly valid."),i=e.path.match(l)),i?(r="urn:"+i[1].toLowerCase(),o=n.SCHEMES[r],o||(o=n.SCHEMES[r]={parse:function(e,t){return e},serialize:n.SCHEMES.urn.serialize}),e.scheme=r,e.path=i[2],e=o.parse(e,t)):e.error=e.error||"URN can not be parsed.",e},serialize:function(t,r){var n,o=t.scheme||r.scheme;if(o&&"urn"!==o){var n=o.match(a);n||(n=["urn:"+o,o]),t.scheme="urn",t.path=n[1]+":"+(t.path?t.path.replace(c,e):"")}return t}},n.SCHEMES["urn:uuid"]={parse:function(e,t){return t.tolerant||e.path&&e.path.match(u)||(e.error=e.error||"UUID is not valid."),e},serialize:function(e,t){return t.tolerant||e.path&&e.path.match(u)?e.path=(e.path||"").toLowerCase():e.scheme=void 0,n.SCHEMES.urn.serialize(e,t)}}}()},{"../uri":23}],23:[function(e,t,r){/**
+!function(t,r,n){r[t]=r[t]||n(),"undefined"!=typeof o&&o.exports?o.exports=r[t]:"function"==typeof e&&e.amd&&e(function(){return r[t]})}("Promise","undefined"!=typeof t?t:this,function(){"use strict";function e(e,t){m.add(e,t),p||(p=y(m.drain))}function t(e){var t,r="undefined"==typeof e?"undefined":c(e);return null==e||"object"!=r&&"function"!=r||(t=e.then),"function"==typeof t&&t}function n(){for(var e=0;e<this.chain.length;e++)o(this,1===this.state?this.chain[e].success:this.chain[e].failure,this.chain[e]);this.chain.length=0}function o(e,r,n){var o,i;try{r===!1?n.reject(e.msg):(o=r===!0?e.msg:r.call(void 0,e.msg),o===n.promise?n.reject(TypeError("Promise-chain cycle")):(i=t(o))?i.call(o,n.resolve,n.reject):n.resolve(o))}catch(e){n.reject(e)}}function i(r){var o,s=this;if(!s.triggered){s.triggered=!0,s.def&&(s=s.def);try{(o=t(r))?e(function(){var e=new l(s);try{o.call(r,function(){i.apply(e,arguments)},function(){a.apply(e,arguments)})}catch(t){a.call(e,t)}}):(s.msg=r,s.state=1,s.chain.length>0&&e(n,s))}catch(e){a.call(new l(s),e)}}}function a(t){var r=this;r.triggered||(r.triggered=!0,r.def&&(r=r.def),r.msg=t,r.state=2,r.chain.length>0&&e(n,r))}function s(e,t,r,n){for(var o=0;o<t.length;o++)!function(o){e.resolve(t[o]).then(function(e){r(o,e)},n)}(o)}function l(e){this.def=e,this.triggered=!1}function u(e){this.promise=e,this.state=0,this.triggered=!1,this.chain=[],this.msg=void 0}function f(t){if("function"!=typeof t)throw TypeError("Not a function");if(0!==this.__NPO__)throw TypeError("Not a promise");this.__NPO__=1;var r=new u(this);this.then=function(t,o){var i={success:"function"!=typeof t||t,failure:"function"==typeof o&&o};return i.promise=new this.constructor(function(e,t){if("function"!=typeof e||"function"!=typeof t)throw TypeError("Not a function");i.resolve=e,i.reject=t}),r.chain.push(i),0!==r.state&&e(n,r),i.promise},this.catch=function(e){return this.then(void 0,e)};try{t.call(void 0,function(e){i.call(r,e)},function(e){a.call(r,e)})}catch(e){a.call(r,e)}}var d,p,m,h=Object.prototype.toString,y="undefined"!=typeof r?function(e){return r(e)}:setTimeout;try{Object.defineProperty({},"x",{}),d=function(e,t,r,n){return Object.defineProperty(e,t,{value:r,writable:!0,configurable:n!==!1})}}catch(e){d=function(e,t,r){return e[t]=r,e}}m=function(){function e(e,t){this.fn=e,this.self=t,this.next=void 0}var t,r,n;return{add:function(o,i){n=new e(o,i),r?r.next=n:t=n,r=n,n=void 0},drain:function(){var e=t;for(t=r=p=void 0;e;)e.fn.call(e.self),e=e.next}}}();var v=d({},"constructor",f,!1);return f.prototype=v,d(v,"__NPO__",0,!1),d(f,"resolve",function(e){var t=this;return e&&"object"==("undefined"==typeof e?"undefined":c(e))&&1===e.__NPO__?e:new t(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");t(e)})}),d(f,"reject",function(e){return new this(function(t,r){if("function"!=typeof t||"function"!=typeof r)throw TypeError("Not a function");r(e)})}),d(f,"all",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):0===e.length?t.resolve([]):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");var o=e.length,i=Array(o),a=0;s(t,e,function(e,t){i[e]=t,++a===o&&r(i)},n)})}),d(f,"race",function(e){var t=this;return"[object Array]"!=h.call(e)?t.reject(TypeError("Not an array")):new t(function(r,n){if("function"!=typeof r||"function"!=typeof n)throw TypeError("Not a function");s(t,e,function(e,t){r(t)},n)})}),f})}).call(this,"undefined"!=typeof t?t:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],4:[function(e,t,r){(function(e){function t(e,t){for(var r=0,n=e.length-1;n>=0;n--){var o=e[n];"."===o?e.splice(n,1):".."===o?(e.splice(n,1),r++):r&&(e.splice(n,1),r--)}if(t)for(;r--;r)e.unshift("..");return e}function n(e,t){if(e.filter)return e.filter(t);for(var r=[],n=0;n<e.length;n++)t(e[n],n,e)&&r.push(e[n]);return r}var o=/^(\/?|)([\s\S]*?)((?:\.{1,2}|[^\/]+?|)(\.[^.\/]*|))(?:[\/]*)$/,i=function(e){return o.exec(e).slice(1)};r.resolve=function(){for(var r="",o=!1,i=arguments.length-1;i>=-1&&!o;i--){var a=i>=0?arguments[i]:e.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(r=a+"/"+r,o="/"===a.charAt(0))}return r=t(n(r.split("/"),function(e){return!!e}),!o).join("/"),(o?"/":"")+r||"."},r.normalize=function(e){var o=r.isAbsolute(e),i="/"===a(e,-1);return e=t(n(e.split("/"),function(e){return!!e}),!o).join("/"),e||o||(e="."),e&&i&&(e+="/"),(o?"/":"")+e},r.isAbsolute=function(e){return"/"===e.charAt(0)},r.join=function(){var e=Array.prototype.slice.call(arguments,0);return r.normalize(n(e,function(e,t){if("string"!=typeof e)throw new TypeError("Arguments to path.join must be strings");return e}).join("/"))},r.relative=function(e,t){function n(e){for(var t=0;t<e.length&&""===e[t];t++);for(var r=e.length-1;r>=0&&""===e[r];r--);return t>r?[]:e.slice(t,r-t+1)}e=r.resolve(e).substr(1),t=r.resolve(t).substr(1);for(var o=n(e.split("/")),i=n(t.split("/")),a=Math.min(o.length,i.length),s=a,l=0;l<a;l++)if(o[l]!==i[l]){s=l;break}for(var c=[],l=s;l<o.length;l++)c.push("..");return c=c.concat(i.slice(s)),c.join("/")},r.sep="/",r.delimiter=":",r.dirname=function(e){var t=i(e),r=t[0],n=t[1];return r||n?(n&&(n=n.substr(0,n.length-1)),r+n):"."},r.basename=function(e,t){var r=i(e)[2];return t&&r.substr(-1*t.length)===t&&(r=r.substr(0,r.length-t.length)),r},r.extname=function(e){return i(e)[3]};var a="b"==="ab".substr(-1)?function(e,t,r){return e.substr(t,r)}:function(e,t,r){return t<0&&(t=e.length+t),e.substr(t,r)}}).call(this,e("_process"))},{_process:8}],5:[function(e,t,r){"use strict";function n(e){return"undefined"!=typeof e&&(e=e.indexOf("://")===-1?"":e.split("://")[0]),e}function o(e){var t=n(e),r=i[t];if("undefined"==typeof r){if(""!==t)throw new Error("Unsupported scheme: "+t);r=a}return r}var i={file:e("./lib/loaders/file"),http:e("./lib/loaders/http"),https:e("./lib/loaders/http")},a="object"===("undefined"==typeof window?"undefined":c(window))||"function"==typeof importScripts?i.http:i.file;"undefined"==typeof Promise&&e("native-promise-only"),t.exports.load=function(e,t){var r=Promise.resolve();return"undefined"==typeof t&&(t={}),r=r.then(function(){if("undefined"==typeof e)throw new TypeError("location is required");if("string"!=typeof e)throw new TypeError("location must be a string");if("undefined"!=typeof t){if("object"!==("undefined"==typeof t?"undefined":c(t)))throw new TypeError("options must be an object");if("undefined"!=typeof t.processContent&&"function"!=typeof t.processContent)throw new TypeError("options.processContent must be a function")}}),r=r.then(function(){return new Promise(function(r,n){var i=o(e);i.load(e,t||{},function(e,t){e?n(e):r(t)})})}).then(function(e){return t.processContent?new Promise(function(r,n){t.processContent("object"===("undefined"==typeof e?"undefined":c(e))?e:{text:e},function(e,t){e?n(e):r(t)})}):"object"===("undefined"==typeof e?"undefined":c(e))?e.text:e})}},{"./lib/loaders/file":6,"./lib/loaders/http":7,"native-promise-only":3}],6:[function(e,t,r){"use strict";var n=new TypeError("The 'file' scheme is not supported in the browser");t.exports.getBase=function(){throw n},t.exports.load=function(){var e=arguments[arguments.length-1];if("function"!=typeof e)throw n;e(n)}},{}],7:[function(e,t,r){"use strict";var n=e("superagent"),o=["delete","get","head","patch","post","put"];t.exports.load=function(e,t,r){function i(e,t){e?r(e):("function"==typeof t.buffer&&t.buffer(!0),t.end(function(e,t){e?r(e):r(void 0,t)}))}var a,s,l=t.method?t.method.toLowerCase():"get";if("undefined"!=typeof t.method?"string"!=typeof t.method?a=new TypeError("options.method must be a string"):o.indexOf(t.method)===-1&&(a=new TypeError("options.method must be one of the following: "+o.slice(0,o.length-1).join(", ")+" or "+o[o.length-1])):"undefined"!=typeof t.prepareRequest&&"function"!=typeof t.prepareRequest&&(a=new TypeError("options.prepareRequest must be a function")),a)r(a);else if(s=n["delete"===l?"del":l](e),t.prepareRequest)try{t.prepareRequest(s,i)}catch(e){r(e)}else i(void 0,s)}},{superagent:14}],8:[function(e,t,r){function n(){u=!1,s.length?c=s.concat(c):f=-1,c.length&&o()}function o(){if(!u){var e=setTimeout(n);u=!0;for(var t=c.length;t;){for(s=c,c=[];++f<t;)s&&s[f].run();f=-1,t=c.length}s=null,u=!1,clearTimeout(e)}}function i(e,t){this.fun=e,this.array=t}function a(){}var s,l=t.exports={},c=[],u=!1,f=-1;l.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];c.push(new i(e,t)),1!==c.length||u||setTimeout(o,0)},i.prototype.run=function(){this.fun.apply(null,this.array)},l.title="browser",l.browser=!0,l.env={},l.argv=[],l.version="",l.versions={},l.on=a,l.addListener=a,l.once=a,l.off=a,l.removeListener=a,l.removeAllListeners=a,l.emit=a,l.binding=function(e){throw new Error("process.binding is not supported")},l.cwd=function(){return"/"},l.chdir=function(e){throw new Error("process.chdir is not supported")},l.umask=function(){return 0}},{}],9:[function(e,t,r){"use strict";function n(e,t){return Object.prototype.hasOwnProperty.call(e,t)}t.exports=function(e,t,r,i){t=t||"&",r=r||"=";var a={};if("string"!=typeof e||0===e.length)return a;var s=/\+/g;e=e.split(t);var l=1e3;i&&"number"==typeof i.maxKeys&&(l=i.maxKeys);var c=e.length;l>0&&c>l&&(c=l);for(var u=0;u<c;++u){var f,d,p,m,h=e[u].replace(s,"%20"),y=h.indexOf(r);y>=0?(f=h.substr(0,y),d=h.substr(y+1)):(f=h,d=""),p=decodeURIComponent(f),m=decodeURIComponent(d),n(a,p)?o(a[p])?a[p].push(m):a[p]=[a[p],m]:a[p]=m}return a};var o=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)}},{}],10:[function(e,t,r){"use strict";function n(e,t){if(e.map)return e.map(t);for(var r=[],n=0;n<e.length;n++)r.push(t(e[n],n));return r}var o=function(e){switch("undefined"==typeof e?"undefined":c(e)){case"string":return e;case"boolean":return e?"true":"false";case"number":return isFinite(e)?e:"";default:return""}};t.exports=function(e,t,r,s){return t=t||"&",r=r||"=",null===e&&(e=void 0),"object"===("undefined"==typeof e?"undefined":c(e))?n(a(e),function(a){var s=encodeURIComponent(o(a))+r;return i(e[a])?n(e[a],function(e){return s+encodeURIComponent(o(e))}).join(t):s+encodeURIComponent(o(e[a]))}).join(t):s?encodeURIComponent(o(s))+r+encodeURIComponent(o(e)):""};var i=Array.isArray||function(e){return"[object Array]"===Object.prototype.toString.call(e)},a=Object.keys||function(e){var t=[];for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.push(r);return t}},{}],11:[function(e,t,r){"use strict";r.decode=r.parse=e("./decode"),r.encode=r.stringify=e("./encode")},{"./decode":9,"./encode":10}],12:[function(e,t,r){t.exports=function(e,t,r){for(var n=0,o=e.length,i=3==arguments.length?r:e[n++];n<o;)i=t.call(null,i,e[n],++n,e);return i}},{}],13:[function(e,t,r){"use strict";t.exports=function(e){var t=/^\\\\\?\\/.test(e),r=/[^\x00-\x80]+/.test(e);return t||r?e:e.replace(/\\/g,"/")}},{}],14:[function(e,t,r){function n(){}function o(e){var t={}.toString.call(e);switch(t){case"[object File]":case"[object Blob]":case"[object FormData]":return!0;default:return!1}}function i(e){if(!b(e))return e;var t=[];for(var r in e)null!=e[r]&&a(t,r,e[r]);return t.join("&")}function a(e,t,r){return Array.isArray(r)?r.forEach(function(r){a(e,t,r)}):void e.push(encodeURIComponent(t)+"="+encodeURIComponent(r))}function s(e){for(var t,r,n={},o=e.split("&"),i=0,a=o.length;i<a;++i)r=o[i],t=r.split("="),n[decodeURIComponent(t[0])]=decodeURIComponent(t[1]);return n}function l(e){var t,r,n,o,i=e.split(/\r?\n/),a={};i.pop();for(var s=0,l=i.length;s<l;++s)r=i[s],t=r.indexOf(":"),n=r.slice(0,t).toLowerCase(),o=w(r.slice(t+1)),a[n]=o;return a}function c(e){return/[\/+]json\b/.test(e)}function u(e){return e.split(/ *; */).shift()}function f(e){return v(e.split(/ *; */),function(e,t){var r=t.split(/ *= */),n=r.shift(),o=r.shift();return n&&o&&(e[n]=o),e},{})}function d(e,t){t=t||{},this.req=e,this.xhr=this.req.xhr,this.text="HEAD"!=this.req.method&&(""===this.xhr.responseType||"text"===this.xhr.responseType)||"undefined"==typeof this.xhr.responseType?this.xhr.responseText:null,this.statusText=this.req.xhr.statusText,this.setStatusProperties(this.xhr.status),this.header=this.headers=l(this.xhr.getAllResponseHeaders()),this.header["content-type"]=this.xhr.getResponseHeader("content-type"),this.setHeaderProperties(this.header),this.body="HEAD"!=this.req.method?this.parseBody(this.text?this.text:this.xhr.response):null}function p(e,t){var r=this;this._query=this._query||[],this.method=e,this.url=t,this.header={},this._header={},this.on("end",function(){var e=null,t=null;try{t=new d(r)}catch(t){return e=new Error("Parser is unable to parse the response"),e.parse=!0,e.original=t,e.rawResponse=r.xhr&&r.xhr.responseText?r.xhr.responseText:null,e.statusCode=r.xhr&&r.xhr.status?r.xhr.status:null,r.callback(e)}if(r.emit("response",t),e)return r.callback(e,t);if(t.status>=200&&t.status<300)return r.callback(e,t);var n=new Error(t.statusText||"Unsuccessful HTTP response");n.original=e,n.response=t,n.status=t.status,r.callback(n,t)})}function m(e,t){var r=x("DELETE",e);return t&&r.end(t),r}var h,y=e("emitter"),v=e("reduce"),g=e("./request-base"),b=e("./is-object");h="undefined"!=typeof window?window:"undefined"!=typeof self?self:this;var x=t.exports=e("./request").bind(null,p);x.getXHR=function(){if(!(!h.XMLHttpRequest||h.location&&"file:"==h.location.protocol&&h.ActiveXObject))return new XMLHttpRequest;try{return new ActiveXObject("Microsoft.XMLHTTP")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.6.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP.3.0")}catch(e){}try{return new ActiveXObject("Msxml2.XMLHTTP")}catch(e){}return!1};var w="".trim?function(e){return e.trim()}:function(e){return e.replace(/(^\s*|\s*$)/g,"")};x.serializeObject=i,x.parseString=s,x.types={html:"text/html",json:"application/json",xml:"application/xml",urlencoded:"application/x-www-form-urlencoded",form:"application/x-www-form-urlencoded","form-data":"application/x-www-form-urlencoded"},x.serialize={"application/x-www-form-urlencoded":i,"application/json":JSON.stringify},x.parse={"application/x-www-form-urlencoded":s,"application/json":JSON.parse},d.prototype.get=function(e){return this.header[e.toLowerCase()]},d.prototype.setHeaderProperties=function(e){var t=this.header["content-type"]||"";this.type=u(t);var r=f(t);for(var n in r)this[n]=r[n]},d.prototype.parseBody=function(e){var t=x.parse[this.type];return!t&&c(this.type)&&(t=x.parse["application/json"]),t&&e&&(e.length||e instanceof Object)?t(e):null},d.prototype.setStatusProperties=function(e){1223===e&&(e=204);var t=e/100|0;this.status=this.statusCode=e,this.statusType=t,this.info=1==t,this.ok=2==t,this.clientError=4==t,this.serverError=5==t,this.error=(4==t||5==t)&&this.toError(),this.accepted=202==e,this.noContent=204==e,this.badRequest=400==e,this.unauthorized=401==e,this.notAcceptable=406==e,this.notFound=404==e,this.forbidden=403==e},d.prototype.toError=function(){var e=this.req,t=e.method,r=e.url,n="cannot "+t+" "+r+" ("+this.status+")",o=new Error(n);return o.status=this.status,o.method=t,o.url=r,o},x.Response=d,y(p.prototype);for(var $ in g)p.prototype[$]=g[$];p.prototype.abort=function(){if(!this.aborted)return this.aborted=!0,this.xhr.abort(),this.clearTimeout(),this.emit("abort"),this},p.prototype.type=function(e){return this.set("Content-Type",x.types[e]||e),this},p.prototype.responseType=function(e){return this._responseType=e,this},p.prototype.accept=function(e){return this.set("Accept",x.types[e]||e),this},p.prototype.auth=function(e,t,r){switch(r||(r={type:"basic"}),r.type){case"basic":var n=btoa(e+":"+t);this.set("Authorization","Basic "+n);break;case"auto":this.username=e,this.password=t}return this},p.prototype.query=function(e){return"string"!=typeof e&&(e=i(e)),e&&this._query.push(e),this},p.prototype.attach=function(e,t,r){return this._getFormData().append(e,t,r||t.name),this},p.prototype._getFormData=function(){return this._formData||(this._formData=new h.FormData),this._formData},p.prototype.send=function(e){var t=b(e),r=this._header["content-type"];if(t&&b(this._data))for(var n in e)this._data[n]=e[n];else"string"==typeof e?(r||this.type("form"),r=this._header["content-type"],"application/x-www-form-urlencoded"==r?this._data=this._data?this._data+"&"+e:e:this._data=(this._data||"")+e):this._data=e;return!t||o(e)?this:(r||this.type("json"),this)},d.prototype.parse=function(e){return h.console&&console.warn("Client-side parse() method has been renamed to serialize(). This method is not compatible with superagent v2.0"),this.serialize(e),this},d.prototype.serialize=function(e){return this._parser=e,this},p.prototype.callback=function(e,t){var r=this._callback;this.clearTimeout(),r(e,t)},p.prototype.crossDomainError=function(){var e=new Error("Request has been terminated\nPossible causes: the network is offline, Origin is not allowed by Access-Control-Allow-Origin, the page is being unloaded, etc.");e.crossDomain=!0,e.status=this.status,e.method=this.method,e.url=this.url,this.callback(e)},p.prototype.timeoutError=function(){var e=this._timeout,t=new Error("timeout of "+e+"ms exceeded");t.timeout=e,this.callback(t)},p.prototype.withCredentials=function(){return this._withCredentials=!0,this},p.prototype.end=function(e){var t=this,r=this.xhr=x.getXHR(),i=this._query.join("&"),a=this._timeout,s=this._formData||this._data;this._callback=e||n,r.onreadystatechange=function(){if(4==r.readyState){var e;try{e=r.status}catch(t){e=0}if(0==e){if(t.timedout)return t.timeoutError();if(t.aborted)return;return t.crossDomainError()}t.emit("end")}};var l=function(e){e.total>0&&(e.percent=e.loaded/e.total*100),e.direction="download",t.emit("progress",e)};this.hasListeners("progress")&&(r.onprogress=l);try{r.upload&&this.hasListeners("progress")&&(r.upload.onprogress=l)}catch(e){}if(a&&!this._timer&&(this._timer=setTimeout(function(){t.timedout=!0,t.abort()},a)),i&&(i=x.serializeObject(i),this.url+=~this.url.indexOf("?")?"&"+i:"?"+i),this.username&&this.password?r.open(this.method,this.url,!0,this.username,this.password):r.open(this.method,this.url,!0),this._withCredentials&&(r.withCredentials=!0),"GET"!=this.method&&"HEAD"!=this.method&&"string"!=typeof s&&!o(s)){var u=this._header["content-type"],f=this._parser||x.serialize[u?u.split(";")[0]:""];!f&&c(u)&&(f=x.serialize["application/json"]),f&&(s=f(s))}for(var d in this.header)null!=this.header[d]&&r.setRequestHeader(d,this.header[d]);return this._responseType&&(r.responseType=this._responseType),this.emit("request",this),r.send("undefined"!=typeof s?s:null),this},x.Request=p,x.get=function(e,t,r){var n=x("GET",e);return"function"==typeof t&&(r=t,t=null),t&&n.query(t),r&&n.end(r),n},x.head=function(e,t,r){var n=x("HEAD",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.del=m,x.delete=m,x.patch=function(e,t,r){var n=x("PATCH",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.post=function(e,t,r){var n=x("POST",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n},x.put=function(e,t,r){var n=x("PUT",e);return"function"==typeof t&&(r=t,t=null),t&&n.send(t),r&&n.end(r),n}},{"./is-object":15,"./request":17,"./request-base":16,emitter:2,reduce:12}],15:[function(e,t,r){function n(e){return null!=e&&"object"==("undefined"==typeof e?"undefined":c(e))}t.exports=n},{}],16:[function(e,t,r){var n=e("./is-object");r.clearTimeout=function(){return this._timeout=0,clearTimeout(this._timer),this},r.parse=function(e){return this._parser=e,this},r.timeout=function(e){return this._timeout=e,this},r.then=function(e,t){return this.end(function(r,n){r?t(r):e(n)})},r.use=function(e){return e(this),this},r.get=function(e){return this._header[e.toLowerCase()]},r.getHeader=r.get,r.set=function(e,t){if(n(e)){for(var r in e)this.set(r,e[r]);return this}return this._header[e.toLowerCase()]=t,this.header[e]=t,this},r.unset=function(e){return delete this._header[e.toLowerCase()],delete this.header[e],this},r.field=function(e,t){return this._getFormData().append(e,t),this}},{"./is-object":15}],17:[function(e,t,r){function n(e,t,r){return"function"==typeof r?new e("GET",t).end(r):2==arguments.length?new e("GET",t):new e(t,r)}t.exports=n},{}],18:[function(e,t,r){/*! https://mths.be/punycode v1.3.2 by @mathias, modified for URI.js */var n=function(){function e(e){throw new RangeError(k[e])}function t(e,t){for(var r=e.length,n=[];r--;)n[r]=t(e[r]);return n}function r(e,r){var n=e.split("@"),o="";n.length>1&&(o=n[0]+"@",e=n[1]),e=e.replace(C,".");var i=e.split("."),a=t(i,r).join(".");return o+a}function n(e){for(var t,r,n=[],o=0,i=e.length;o<i;)t=e.charCodeAt(o++),t>=55296&&t<=56319&&o<i?(r=e.charCodeAt(o++),56320==(64512&r)?n.push(((1023&t)<<10)+(1023&r)+65536):(n.push(t),o--)):n.push(t);return n}function o(e){return t(e,function(e){var t="";return e>65535&&(e-=65536,t+=A(e>>>10&1023|55296),e=56320|1023&e),t+=A(e)}).join("")}function i(e){return e-48<10?e-22:e-65<26?e-65:e-97<26?e-97:m}function a(e,t){return e+22+75*(e<26)-((0!=t)<<5)}function s(e,t,r){var n=0;for(e=r?T(e/g):e>>1,e+=T(e/t);e>O*y>>1;n+=m)e=T(e/O);return T(n+(O+1)*e/(e+v))}function l(t){var r,n,a,l,c,u,f,d,v,g,$=[],E=t.length,C=0,k=x,O=b;for(n=t.lastIndexOf(w),n<0&&(n=0),a=0;a<n;++a)t.charCodeAt(a)>=128&&e("not-basic"),$.push(t.charCodeAt(a));for(l=n>0?n+1:0;l<E;){for(c=C,u=1,f=m;l>=E&&e("invalid-input"),d=i(t.charCodeAt(l++)),(d>=m||d>T((p-C)/u))&&e("overflow"),C+=d*u,v=f<=O?h:f>=O+y?y:f-O,!(d<v);f+=m)g=m-v,u>T(p/g)&&e("overflow"),u*=g;r=$.length+1,O=s(C-c,r,0==c),T(C/r)>p-k&&e("overflow"),k+=T(C/r),C%=r,$.splice(C++,0,k)}return o($)}function c(t){var r,o,i,l,c,u,f,d,v,g,$,E,C,k,O,S=[];for(t=n(t),E=t.length,r=x,o=0,c=b,u=0;u<E;++u)$=t[u],$<128&&S.push(A($));for(i=l=S.length,l&&S.push(w);i<E;){for(f=p,u=0;u<E;++u)$=t[u],$>=r&&$<f&&(f=$);for(C=i+1,f-r>T((p-o)/C)&&e("overflow"),o+=(f-r)*C,r=f,u=0;u<E;++u)if($=t[u],$<r&&++o>p&&e("overflow"),$==r){for(d=o,v=m;g=v<=c?h:v>=c+y?y:v-c,!(d<g);v+=m)O=d-g,k=m-g,S.push(A(a(g+O%k,0))),d=T(O/k);S.push(A(a(d,0))),c=s(o,C,i==l),o=0,++i}++o,++r}return S.join("")}function u(e){return r(e,function(e){return $.test(e)?l(e.slice(4).toLowerCase()):e})}function f(e){return r(e,function(e){return E.test(e)?"xn--"+c(e):e})}var d,p=2147483647,m=36,h=1,y=26,v=38,g=700,b=72,x=128,w="-",$=/^xn--/,E=/[^\x20-\x7E]/,C=/[\x2E\u3002\uFF0E\uFF61]/g,k={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},O=m-h,T=Math.floor,A=String.fromCharCode;return d={version:"1.3.2",ucs2:{decode:n,encode:o},decode:l,encode:c,toASCII:f,toUnicode:u}}();"undefined"==typeof COMPILED&&"undefined"!=typeof t&&(t.exports=n)},{}],19:[function(e,t,r){e("./schemes/http"),e("./schemes/urn"),e("./schemes/mailto")},{"./schemes/http":20,"./schemes/mailto":21,"./schemes/urn":22}],20:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");n.SCHEMES.http=n.SCHEMES.https={domainHost:!0,parse:function(e,t){return e.host||(e.error=e.error||"HTTP URIs must have a host."),e},serialize:function(e,t){return e.port!==("https"!==String(e.scheme).toLowerCase()?80:443)&&""!==e.port||(e.port=void 0),e.path||(e.path="/"),e}}},{"../uri":23}],21:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri"),o=e("../punycode");!function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(e){return e.toUpperCase()}function i(e){var t=n.pctDecChars(e);return t.match(M)?t:e}function a(e){return void 0!==e&&null!==e?e instanceof Array&&!e.callee?e:"number"!=typeof e.length||e.split||e.setInterval||e.call?[e]:Array.prototype.slice.call(e):[]}var s={},l=n.IRI_SUPPORT,c="[A-Za-z0-9\\-\\.\\_\\~"+(l?"\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF":"")+"]",u="[0-9A-Fa-f]",f=t(t("%[EFef]"+u+"%"+u+u+"%"+u+u)+"|"+t("%[89A-Fa-f]"+u+"%"+u+u)+"|"+t("%"+u+u)),d="[A-Za-z0-9\\!\\$\\%\\'\\*\\+\\-\\^\\_\\`\\{\\|\\}\\~]",p="[\\!\\$\\%\\'\\(\\)\\*\\+\\,\\-\\.0-9\\<\\>A-Z\\x5E-\\x7E]",m=e(p,'[\\"\\\\]'),h=t(d+"+"+t("\\."+d+"+")+"*"),y=t("\\\\"+m),v=t(p+"|"+y),g=t('\\"'+v+'*\\"'),b="[\\x21-\\x5A\\x5E-\\x7E]",x="[\\!\\$\\'\\(\\)\\*\\+\\,\\;\\:\\@]",w=t(c+"|"+f+"|"+x),$=t(h+"|\\["+b+"*\\]"),E=t(h+"|"+g),C=t(E+"\\@"+$),k=t(C+t("\\,"+C)+"*"),O=t(w+"*"),T=O,A=t(O+"\\="+T),S=t(A+t("\\&"+A)+"*"),P=t("\\?"+S),M=(n.VALIDATE_SUPPORT&&new RegExp("^mailto\\:"+k+"?"+P+"?$"),new RegExp(c,"g")),I=new RegExp(f,"g"),j=new RegExp(e("[^]",d,"[\\.]",'[\\"]',m),"g"),D=new RegExp(e("[^]",d,"[\\.]","[\\[]",b,"[\\]]"),"g"),_=new RegExp(e("[^]",c,x),"g"),F=_,R=n.VALIDATE_SUPPORT&&new RegExp("^"+k+"$"),q=n.VALIDATE_SUPPORT&&new RegExp("^"+S+"$");n.SCHEMES.mailto={parse:function(e,t){n.VALIDATE_SUPPORT&&!e.error&&(e.path&&!R.test(e.path)?e.error="Email address is not valid":e.query&&!q.test(e.query)&&(e.error="Header fields are invalid"));var r=e.to=e.path?e.path.split(","):[];if(e.path=void 0,e.query){for(var i=!1,a={},s=e.query.split("&"),l=0,c=s.length;l<c;++l){var u=s[l].split("=");switch(u[0]){case"to":for(var f=u[1].split(","),d=0,p=f.length;d<p;++d)r.push(f[d]);break;case"subject":e.subject=n.unescapeComponent(u[1],t);break;case"body":e.body=n.unescapeComponent(u[1],t);break;default:i=!0,a[n.unescapeComponent(u[0],t)]=n.unescapeComponent(u[1],t)}}i&&(e.headers=a)}e.query=void 0;for(var l=0,c=r.length;l<c;++l){var m=r[l].split("@");if(m[0]=n.unescapeComponent(m[0]),"undefined"==typeof o||t.unicodeSupport)m[1]=n.unescapeComponent(m[1],t).toLowerCase();else try{m[1]=o.toASCII(n.unescapeComponent(m[1],t).toLowerCase())}catch(t){e.error=e.error||"Email address's domain name can not be converted to ASCII via punycode: "+t}r[l]=m.join("@")}return e},serialize:function(e,t){var l=a(e.to);if(l){for(var c=0,u=l.length;c<u;++c){var f=String(l[c]),d=f.lastIndexOf("@"),p=f.slice(0,d),m=f.slice(d+1);if(p=p.replace(I,i).replace(I,r).replace(j,n.pctEncChar),"undefined"!=typeof o)try{m=t.iri?o.toUnicode(m):o.toASCII(n.unescapeComponent(m,t).toLowerCase())}catch(r){e.error=e.error||"Email address's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}else m=m.replace(I,i).toLowerCase().replace(I,r).replace(D,n.pctEncChar);l[c]=p+"@"+m}e.path=l.join(",")}var h=e.headers=e.headers||{};e.subject&&(h.subject=e.subject),e.body&&(h.body=e.body);var y=[];for(var v in h)h[v]!==s[v]&&y.push(v.replace(I,i).replace(I,r).replace(_,n.pctEncChar)+"="+h[v].replace(I,i).replace(I,r).replace(F,n.pctEncChar));return y.length&&(e.query=y.join("&")),e}}}()},{"../punycode":18,"../uri":23}],22:[function(e,t,r){if("undefined"==typeof COMPILED&&"undefined"==typeof n&&"function"==typeof e)var n=e("../uri");!function(){var e=n.pctEncChar,t="(?:[0-9A-Za-z][0-9A-Za-z\\-]{1,31})",r="(?:\\%[0-9A-Fa-f]{2})",o="[0-9A-Za-z\\(\\)\\+\\,\\-\\.\\:\\=\\@\\;\\$\\_\\!\\*\\'\\/\\?\\#]",i="(?:(?:"+r+"|"+o+")+)",a=new RegExp("^urn\\:("+t+")$"),s=new RegExp("^("+t+")\\:("+i+")$"),l=/^([^\:]+)\:(.*)/,c=/[\x00-\x20\\\"\&\<\>\[\]\^\`\{\|\}\~\x7F-\xFF]/g,u=/^[0-9A-Fa-f]{8}(?:\-[0-9A-Fa-f]{4}){3}\-[0-9A-Fa-f]{12}$/;n.SCHEMES.urn={parse:function(e,t){var r,o,i=e.path.match(s);return i||(t.tolerant||(e.error=e.error||"URN is not strictly valid."),i=e.path.match(l)),i?(r="urn:"+i[1].toLowerCase(),o=n.SCHEMES[r],o||(o=n.SCHEMES[r]={parse:function(e,t){return e},serialize:n.SCHEMES.urn.serialize}),e.scheme=r,e.path=i[2],e=o.parse(e,t)):e.error=e.error||"URN can not be parsed.",e},serialize:function(t,r){var n,o=t.scheme||r.scheme;if(o&&"urn"!==o){var n=o.match(a);n||(n=["urn:"+o,o]),t.scheme="urn",t.path=n[1]+":"+(t.path?t.path.replace(c,e):"")}return t}},n.SCHEMES["urn:uuid"]={parse:function(e,t){return t.tolerant||e.path&&e.path.match(u)||(e.error=e.error||"UUID is not valid."),e},serialize:function(e,t){return t.tolerant||e.path&&e.path.match(u)?e.path=(e.path||"").toLowerCase():e.scheme=void 0,n.SCHEMES.urn.serialize(e,t)}}}()},{"../uri":23}],23:[function(e,t,r){/**
  * URI.js
  *
  * @fileoverview An RFC 3986 compliant, scheme extendable URI parsing/validating/resolving library for JavaScript.
@@ -35,5 +35,5 @@ e.exports=function(e){function t(n){if(r[n])return r[n].exports;var o=r[n]={i:n,
  * @see http://github.com/garycourt/uri-js
  * @license URI.js v2.0.0 (c) 2011 Gary Court. License: http://github.com/garycourt/uri-js
  */
-var n=!1,o=!0,i=!0,a=function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(r){var n="[A-Za-z]",o="[0-9]",a=e(o,"[A-Fa-f]"),s=t(t("%[EFef]"+a+"%"+a+a+"%"+a+a)+"|"+t("%[89A-Fa-f]"+a+"%"+a+a)+"|"+t("%"+a+a)),l="[\\:\\/\\?\\#\\[\\]\\@]",c="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",u=e(l,c),f=r?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",d=r?"[\\uE000-\\uF8FF]":"[]",p=e(n,o,"[\\-\\.\\_\\~]",f),m=t(n+e(n,o,"[\\+\\-\\.]")+"*"),h=t(t(s+"|"+e(p,c,"[\\:]"))+"*"),y=t(t("25[0-5]")+"|"+t("2[0-4]"+o)+"|"+t("1"+o+o)+"|"+t("[1-9]"+o)+"|"+o),v=t(y+"\\."+y+"\\."+y+"\\."+y),g=t(a+"{1,4}"),b=(t(t(g+"\\:"+g)+"|"+v),t(e(p,c,"[\\:]")+"+")),x=t("v"+a+"+\\."+e(p,c,"[\\:]")+"+"),w=t("\\["+t(b+"|"+x)+"\\]"),E=t(t(s+"|"+e(p,c))+"*"),$=t(w+"|"+v+"(?!"+E+")|"+E),C=t(o+"*"),k=t(t(h+"@")+"?"+$+t("\\:"+C)+"?"),O=t(s+"|"+e(p,c,"[\\:\\@]")),T=t(O+"*"),A=t(O+"+"),S=t(t(s+"|"+e(p,c,"[\\@]"))+"+"),P=t(t("\\/"+T)+"*"),M=t("\\/"+t(A+P)+"?"),j=t(S+P),I=t(A+P),D="(?!"+O+")",_=(t(P+"|"+M+"|"+j+"|"+I+"|"+D),t(t(O+"|"+e("[\\/\\?]",d))+"*")),F=t(t(O+"|[\\/\\?]")+"*"),R=t(t("\\/\\/"+k+P)+"|"+M+"|"+I+"|"+D),q=t(m+"\\:"+R+t("\\?"+_)+"?"+t("\\#"+F)+"?"),U=t(t("\\/\\/"+k+P)+"|"+M+"|"+j+"|"+D),N=t(U+t("\\?"+_)+"?"+t("\\#"+F)+"?"),L=(t(q+"|"+N),t(m+"\\:"+R+t("\\?"+_)+"?"),"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+I+"|"+D+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$"),H="^(){0}"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+j+"|"+D+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$";"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+I+"|"+D+")")+t("\\?("+_+")")+"?$","^"+t("\\#("+F+")")+"?$","^"+t("("+h+")@")+"?("+$+")"+t("\\:("+C+")")+"?$";return{URI_REF:i&&new RegExp("("+L+")|("+H+")"),NOT_SCHEME:new RegExp(e("[^]",n,o,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(e("[^\\%\\:]",p,c),"g"),NOT_HOST:new RegExp(e("[^\\%]",p,c),"g"),NOT_PATH:new RegExp(e("[^\\%\\/\\:\\@]",p,c),"g"),NOT_PATH_NOSCHEME:new RegExp(e("[^\\%\\/\\@]",p,c),"g"),NOT_QUERY:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]",d),"g"),NOT_FRAGMENT:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(e("[^]",p,c),"g"),UNRESERVED:new RegExp(p,"g"),OTHER_CHARS:new RegExp(e("[^\\%]",p,u),"g"),PCT_ENCODED:new RegExp(s,"g")}}function n(e){var t,r=e.charCodeAt(0);return t=r<16?"%0"+r.toString(16).toUpperCase():r<128?"%"+r.toString(16).toUpperCase():r<2048?"%"+(r>>6|192).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase():"%"+(r>>12|224).toString(16).toUpperCase()+"%"+(r>>6&63|128).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase()}function a(e){for(var t,r,n,o="",i=0,a=e.length;i<a;)t=parseInt(e.substr(i+1,2),16),t<128?(o+=String.fromCharCode(t),i+=3):t>=194&&t<224?(a-i>=6?(r=parseInt(e.substr(i+4,2),16),o+=String.fromCharCode((31&t)<<6|63&r)):o+=e.substr(i,6),i+=6):t>=224?(a-i>=9?(r=parseInt(e.substr(i+4,2),16),n=parseInt(e.substr(i+7,2),16),o+=String.fromCharCode((15&t)<<12|(63&r)<<6|63&n)):o+=e.substr(i,9),i+=9):(o+=e.substr(i,3),i+=3);return o}function l(e){return void 0===e?"undefined":null===e?"null":Object.prototype.toString.call(e).split(" ").pop().split("]").shift().toLowerCase()}function c(e){return e.toUpperCase()}function u(e,t){function r(e){var r=a(e);return r.match(t.UNRESERVED)?r:e}return e.scheme&&(e.scheme=String(e.scheme).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_SCHEME,"")),void 0!==e.userinfo&&(e.userinfo=String(e.userinfo).replace(t.PCT_ENCODED,r).replace(t.NOT_USERINFO,n).replace(t.PCT_ENCODED,c)),void 0!==e.host&&(e.host=String(e.host).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_HOST,n).replace(t.PCT_ENCODED,c)),void 0!==e.path&&(e.path=String(e.path).replace(t.PCT_ENCODED,r).replace(e.scheme?t.NOT_PATH:t.NOT_PATH_NOSCHEME,n).replace(t.PCT_ENCODED,c)),void 0!==e.query&&(e.query=String(e.query).replace(t.PCT_ENCODED,r).replace(t.NOT_QUERY,n).replace(t.PCT_ENCODED,c)),void 0!==e.fragment&&(e.fragment=String(e.fragment).replace(t.PCT_ENCODED,r).replace(t.NOT_FRAGMENT,n).replace(t.PCT_ENCODED,c)),e}function f(e,t){void 0===t&&(t={});var r,n,l=o&&t.iri!==!1?E:w,c=!1,f={};if("suffix"===t.reference&&(e=(t.scheme?t.scheme+":":"")+"//"+e),i?(r=e.match(l.URI_REF),r&&(r=r[1]?r.slice(1,10):r.slice(10,19)),r||(c=!0,t.tolerant||(f.error=f.error||"URI is not strictly valid."),r=e.match($))):r=e.match($),r){if(A?(f.scheme=r[1],f.userinfo=r[3],f.host=r[4],f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=r[7],f.fragment=r[8],isNaN(f.port)&&(f.port=r[5])):(f.scheme=r[1]||void 0,f.userinfo=e.indexOf("@")!==-1?r[3]:void 0,f.host=e.indexOf("//")!==-1?r[4]:void 0,f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=e.indexOf("?")!==-1?r[7]:void 0,f.fragment=e.indexOf("#")!==-1?r[8]:void 0,isNaN(f.port)&&(f.port=e.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?r[4]:void 0)),void 0!==f.scheme||void 0!==f.userinfo||void 0!==f.host||void 0!==f.port||f.path||void 0!==f.query?void 0===f.scheme?f.reference="relative":void 0===f.fragment?f.reference="absolute":f.reference="uri":f.reference="same-document",t.reference&&"suffix"!==t.reference&&t.reference!==f.reference&&(f.error=f.error||"URI is not a "+t.reference+" reference."),n=S[(t.scheme||f.scheme||"").toLowerCase()],!o||"undefined"==typeof s||t.unicodeSupport||n&&n.unicodeSupport)u(f,l);else{if(f.host&&(t.domainHost||n&&n.domainHost))try{f.host=s.toASCII(f.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(e){f.error=f.error||"Host's domain name can not be converted to ASCII via punycode: "+e}u(f,w)}n&&n.parse&&n.parse(f,t)}else c=!0,f.error=f.error||"URI can not be parsed.";return f}function d(e,t){var r=[];return void 0!==e.userinfo&&(r.push(e.userinfo),r.push("@")),void 0!==e.host&&r.push(e.host),"number"==typeof e.port&&(r.push(":"),r.push(e.port.toString(10))),r.length?r.join(""):void 0}function p(e){for(var t,r=[];e.length;)e.match(C)?e=e.replace(C,""):e.match(k)?e=e.replace(k,"/"):e.match(O)?(e=e.replace(O,"/"),r.pop()):"."===e||".."===e?e="":(t=e.match(T)[0],e=e.slice(t.length),r.push(t));return r.join("")}function m(e,t){void 0===t&&(t={});var r,n,i,l=o&&t.iri?E:w,c=[];if(r=S[(t.scheme||e.scheme||"").toLowerCase()],r&&r.serialize&&r.serialize(e,t),o&&"undefined"!=typeof s&&e.host&&(t.domainHost||r&&r.domainHost))try{e.host=t.iri?s.toUnicode(e.host):s.toASCII(e.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(r){e.error=e.error||"Host's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}return u(e,l),"suffix"!==t.reference&&e.scheme&&(c.push(e.scheme),c.push(":")),n=d(e,t),void 0!==n&&("suffix"!==t.reference&&c.push("//"),c.push(n),e.path&&"/"!==e.path.charAt(0)&&c.push("/")),void 0!==e.path&&(i=e.path,t.absolutePath||r&&r.absolutePath||(i=p(i)),void 0===n&&(i=i.replace(/^\/\//,"/%2F")),c.push(i)),void 0!==e.query&&(c.push("?"),c.push(e.query)),void 0!==e.fragment&&(c.push("#"),c.push(e.fragment)),c.join("")}function h(e,t,r,n){void 0===r&&(r={});var o={};return n||(e=f(m(e,r),r),t=f(m(t,r),r)),r=r||{},!r.tolerant&&t.scheme?(o.scheme=t.scheme,o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(t.path?("/"===t.path.charAt(0)?o.path=p(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?o.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:o.path=t.path:o.path="/"+t.path,o.path=p(o.path)),o.query=t.query):(o.path=e.path,void 0!==t.query?o.query=t.query:o.query=e.query),o.userinfo=e.userinfo,o.host=e.host,o.port=e.port),o.scheme=e.scheme),o.fragment=t.fragment,o}function y(e,t,r){return m(h(f(e,r),f(t,r),r,!0),r)}function v(e,t){return"string"==typeof e?e=m(f(e,t),t):"object"===l(e)&&(e=f(m(e,t),t)),e}function g(e,t,r){return"string"==typeof e?e=m(f(e,r),r):"object"===l(e)&&(e=m(e,r)),"string"==typeof t?t=m(f(t,r),r):"object"===l(t)&&(t=m(t,r)),e===t}function b(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.ESCAPE:w.ESCAPE,n)}function x(e,t){return e&&e.toString().replace(o&&t&&t.iri?E.PCT_ENCODED:w.PCT_ENCODED,a)}var w=r(!1),E=o?r(!0):void 0,$=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?([^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n)*))?/i,C=/^\.\.?\//,k=/^\/\.(\/|$)/,O=/^\/\.\.(\/|$)/,T=/^\/?(?:.|\n)*?(?=\/|$)/,A=void 0==="".match(/(){0}/)[1],S={};return{IRI_SUPPORT:o,VALIDATE_SUPPORT:i,pctEncChar:n,pctDecChars:a,SCHEMES:S,parse:f,_recomposeAuthority:d,removeDotSegments:p,serialize:m,resolveComponents:h,resolve:y,normalize:v,equal:g,escapeComponent:b,unescapeComponent:x}}();if(!n&&"undefined"!=typeof t&&"function"==typeof e){var s=e("./punycode");t.exports=a,e("./schemes")}},{"./punycode":18,"./schemes":19}]},{},[1])(1)})},function(e,t,r){"use strict";function n(e,t){var l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:r.i(i.createDefaults)(),c=arguments[3],u=arguments[4],f=arguments[5],d=arguments[6],p=[],m=[];t=t||[];var h=t.indexOf("*");u=u||{};var y={},v=t.indexOf("...");if("object"===("undefined"==typeof e?"undefined":s(e))&&e.hasOwnProperty("properties")){f=f||e.readonly||e.readOnly,y=r.i(i.defaultForm)(e,l,c,u);var g=y.lookup;e=g||e,p=p.concat(y.form)}return h!==-1&&(t=t.slice(0,h).concat(p).concat(t.slice(h+1))),y.form&&v!==-1&&!function(){var e=t.map(function(e){return"string"==typeof e?e:e.key?e.key:void 0}).filter(function(e){return void 0!==e});m=m.concat(y.form.map(function(t){var r=e.indexOf(t.key[0])!==-1;if(!r)return t}).filter(function(e){return void 0!==e}))}(),v!==-1&&(t=t.slice(0,v).concat(m).concat(t.slice(v+1))),t.map(function(t){if("string"==typeof t&&(t={key:t}),t.key&&"string"==typeof t.key&&(t.key=r.i(o.parse)(t.key)),t.titleMap&&(t.titleMap=r.i(a.a)(t.titleMap)),t.key){var i=r.i(o.stringify)(t.key);e[i]&&!function(){var r=e[i];r&&Object.keys(r).forEach(function(e){void 0===t[e]&&(t[e]=r[e])})}()}return f===!0&&(t.readonly=!0),t.items&&(t.items=n(e,t.items,l,c,u,t.readonly,d)),t.tabs&&t.tabs.forEach(function(r){r.items&&(r.items=n(e,r.items,l,c,u,t.readonly,d))}),"checkbox"===t.type&&(void 0===t.schema?t.schema={default:!1}:void 0===t.schema.default&&(t.schema.default=!1)),d&&"template"===t.type&&!t.template&&t.templateUrl&&d.push(t),t})}var o=r(0),i=r(3),a=r(1);t.a=n;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e}},function(e,t,r){"use strict";function n(e,t){var r=new Promise(function(t,r){o.resolveRefs(e,{filter:["relative","local","remote"]}).then(function(e){t(e.resolved)}).catch(function(e){r(new Error(e))})});return"function"!=typeof t?r:void r.then(function(e){t(null,e)}).catch(function(e){t(e)})}var o=r(5);r.n(o);t.a=n},function(e,t,r){"use strict";function n(e,t,r){t||(t=this);var n="string"==typeof e?o.parse(e):e;if("undefined"!=typeof r&&1===n.length)return t[n[0]]=r,t;"undefined"!=typeof r&&"undefined"==typeof t[n[0]]&&(t[n[0]]=n.length>2&&i.test(n[1])?[]:{});for(var a=t[n[0]],s=1;s<n.length;s++){if(""===n[s])return;if("undefined"!=typeof r){if(s===n.length-1)return a[n[s]]=r,r;var l=a[n[s]];"undefined"!=typeof l&&null!==l||(l=i.test(n[s+1])?[]:{},a[n[s]]=l),a=l}else a&&(a=a[n[s]])}return a}var o=r(0);t.a=n;var i=/^\d+$/},function(e,t,r){"use strict";function n(e,t,r,n){n=void 0===n||n,r=r||[];var o=function e(t,r,o){if(r(t,o),t.properties&&Object.keys(t.properties).forEach(function(n){var i=o.slice();i.push(n),e(t.properties[n],r,i)}),!n&&t.items){var i=o.slice();i.push(""),e(t.items,r,i)}};o(e,t,r||[])}function o(e,t){t(e),e.items&&e.items.forEach(function(e){o(e,t)}),e.tabs&&e.tabs.forEach(function(e){e.items&&e.items.forEach(function(e){o(e,t)})})}t.a=n,t.b=o},function(e,t,r){"use strict";function n(e,t){if(!e)return{valid:!0};var r=e.schema;if(!r)return{valid:!0};""===t&&(t=void 0),"number"===e.type&&null===t&&(t=void 0);var n={type:"object",properties:{},required:void 0},o=e.key[e.key.length-1];n.properties[o]=r,e.required&&(n.required=[o]);var a={};return"undefined"!=typeof t&&(a[o]=t),i.a.validateResult(a,n)}var o=r(12),i=r.n(o);t.a=n},function(e,t,r){"use strict";var n;!function(o){var i={parse:function(e){if("string"!=typeof e)throw new TypeError("ObjectPath.parse must be passed a string");for(var t,r,n,o,i=0,a=[];i<e.length;)if(t=e.indexOf(".",i),r=e.indexOf("[",i),t===-1&&r===-1)a.push(e.slice(i,e.length)),i=e.length;else if(r===-1||t!==-1&&t<r)a.push(e.slice(i,t)),i=t+1;else if(r>i&&(a.push(e.slice(i,r)),i=r),n=e.slice(r+1,r+2),'"'!==n&&"'"!==n)o=e.indexOf("]",r),o===-1&&(o=e.length),a.push(e.slice(i+1,o)),i="."===e.slice(o+1,o+2)?o+2:o+1;else{for(o=e.indexOf(n+"]",r),o===-1&&(o=e.length);"\\"===e.slice(o-1,o)&&r<e.length;)r++,o=e.indexOf(n+"]",r);a.push(e.slice(i+2,o).replace(new RegExp("\\"+n,"g"),n)),i="."===e.slice(o+2,o+3)?o+3:o+2}return a},stringify:function(e,t){return Array.isArray(e)||(e=[e.toString()]),t='"'===t?'"':"'",e.map(function(e){return"["+t+e.toString().replace(new RegExp(t,"g"),"\\"+t)+t+"]"}).join("")},normalize:function(e,t){return i.stringify(Array.isArray(e)?e:i.parse(e),t)},registerModule:function(e){e.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=i.parse,this.stringify=i.stringify,this.normalize=i.normalize,this.$get=function(){return i}})}};n=function(){return{ObjectPath:i}}.call(t,r,t,e),!(n!==o&&(e.exports=n))}()},function(e,t){e.exports=tv4},function(e,t,r){e.exports=r(4)}])}).call(t,r(2),r(19).setImmediate)},function(e,t){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(r=window)}e.exports=r},,function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(1),o=(r.n(n),r(0)),i=r.n(o),a=r(14),s=r(12),l=r(13),c=r(15),u=r(16),f=r(7),d=r(8),p=r(10),m=r(6),h=r(9),y=r(11),v=r(5),g=[];try{i.a.module("ngSanitize"),g.push("ngSanitize")}catch(e){}try{i.a.module("ui.sortable"),g.push("ui.sortable")}catch(e){}try{i.a.module("angularSpectrumColorpicker"),g.push("angularSpectrumColorpicker")}catch(e){}i.a.module("schemaForm",g).provider("sfPath",u.a).provider("sfBuilder",["sfPathProvider",a.a]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",s.a]).provider("sfErrorMessage",c.a).provider("schemaForm",["sfPathProvider",l.a]).factory("sfSelect",function(){return n.select}).factory("sfValidator",function(){return n.validate}).directive("sfChanged",f.a).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",d.a]).directive("sfMessage",["$injector","sfErrorMessage",p.a]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",m.a]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",y.a]).directive("schemaValidate",["sfValidator","$parse","sfSelect",v.a]).directive("sfKeyController",["schemaForm","sfPath",h.a])},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r){return{restrict:"A",scope:!1,priority:500,require:"ngModel",link:function(t,n,i,a){t.$emit("schemaFormPropagateNgModelController",a);var s=null,l=t.$eval(i.schemaValidate);l.copyValueTo&&a.$viewChangeListeners.push(function(){var e=l.copyValueTo;o.a.forEach(e,function(e){r(e,t.model,a.$modelValue)})});var c=function(r,n){if(!l)return r;if(t.options&&t.options.tv4Validation===!1)return r;var o=e(l,r);Object.keys(a.$error).filter(function(e){return 0===e.indexOf("tv4-")}).forEach(function(e){a.$setValidity(e,!0)});{if(o.valid||a.$pristine&&!n)return r;if(a.$setValidity("tv4-"+o.error.code,!1),s=o.error,a.$validators)return r}};"function"==typeof l.ngModel&&l.ngModel(a),["$parsers","$viewChangeListeners","$formatters"].forEach(function(e){l[e]&&a[e]&&l[e].forEach(function(t){a[e].push(t)})}),["$validators","$asyncValidators"].forEach(function(e){l[e]&&a[e]&&o.a.forEach(l[e],function(r,n){a[e][n]=function(e,n){return r(e,n,t.model,l)}})}),a.$parsers.push(c),a.$validators&&(a.$validators.schemaForm=function(){return!Object.keys(a.$error).some(function(e){return"schemaForm"!==e})});var u=l.schema;t.validateField=function(e,t){var r=void 0===e;(r||a.$$parentForm.$name===e)&&((r||u&&u.type.indexOf("array")!==-1)&&c(a.$modelValue,t),a.$setDirty?(a.$setDirty(),a.$setViewValue(a.$viewValue),a.$commitViewValue(),"checkbox"===l.type?l.required&&void 0===a.$modelValue&&a.$setValidity("tv4-302",!1):l.required&&a.$isEmpty(a.$modelValue)&&a.$setValidity("tv4-302",!1)):a.$setViewValue(a.$viewValue))};var f=!0;a.$formatters.push(function(e){return!a.$pristine||!f||t.options&&t.options.validateOnRender===!0?(c(a.$modelValue),e):(f=!1,e)}),t.$on("schemaFormValidate",function(e,r){t.validateField(r,!0)}),t.schemaError=function(){return s}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r){return{scope:!0,controller:["$scope",function(e){this.key=e.form&&e.form.key?e.form.key.splice(0,-2):[]}],link:function(n,a,s){n.min=0,n.trackBy=function(e,t){return e&&"object"===("undefined"==typeof e?"undefined":i(e))?e:t},n.modelArray=n.$eval(s.sfNewArray);var l=function(){n.modelArray=n.$eval(s.sfNewArray),n.ngModel&&n.ngModel.$pristine&&n.firstDigest&&(!n.options||n.options.validateOnRender!==!0)||n.validateField&&n.validateField()},c=function(){n.form&&n.form.onChange&&(o.a.isFunction(n.form.onChange)?n.form.onChange(n.modelArray,n.form):n.evalExpr(n.form.onChange,{modelValue:n.modelArray,form:n.form}))},u=function(){var r=n.modelArray;if(!r){var o=t.parse(s.sfNewArray);r=[],e(o,n,r),n.modelArray=r}return r},f=n.$watch("form",function(e){if(e){if(e.titleMap||e.startEmpty===!0||n.modelArray&&0!==n.modelArray.length||n.appendToArray(),n.$watch(function(e){return JSON.stringify(e.modelArray)},function(){l(),c()}),e.titleMap&&e.titleMap.length>0){n.titleMapValues=[];var t=function(t){n.titleMapValues=[],t=t||[],e.titleMap.forEach(function(e){n.titleMapValues.push(t.indexOf(e.value)!==-1)})};t(n.modelArray),n.$watchCollection("modelArray",t),n.$watchCollection("titleMapValues",function(t,r){if(t&&t!==r){var o=u();e.titleMap.forEach(function(e,r){var n=o.indexOf(e.value);n===-1&&t[r]&&o.push(e.value),n===-1||t[r]||o.splice(n,1)}),n.validateField&&n.validateField()}})}f()}});n.appendToArray=function(){var t,i=u();if(n.form&&n.form.schema&&n.form.schema.items){var a=n.form.schema.items;a.type&&a.type.indexOf("object")!==-1?(t={},n.options&&n.options.setSchemaDefaults===!1||(t=o.a.isDefined(a.default)?a.default:t,t&&r.traverseSchema(a,function(r,n){o.a.isDefined(r.default)&&e(n,t,r.default)}))):(a.type&&(a.type.indexOf("array")!==-1?t=[]:a.type.indexOf("string")===-1&&a.type.indexOf("number")===-1||(t="")),n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t))}return i.push(t),i},n.deleteFromArray=function(e){var t=n.modelArray.indexOf(e),r=n.modelArray;return r&&r.splice(t,1),e.$$hashKey&&(n.destroyed=e.$$hashKey),r};var d=function(e){return function(t){t.key&&(t.key[t.key.indexOf("")]=e)}},p={};n.copyWithIndex=function(e){var t=n.form;if(!p[e]){var i=t.items[0];if(t.items.length>1&&(i={type:"section",items:t.items.map(function(e){return e.ngModelOptions=t.ngModelOptions,o.a.isUndefined(e.readonly)&&(e.readonly=t.readonly),e})}),i){var a=o.a.copy(i);a.arrayIndex=e,r.traverseForm(a,d(e)),p[e]=a}}return p[e]}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){return{require:"ngModel",restrict:"AC",scope:!1,link:function(e,t,r,n){var i=e.$eval(r.sfChanged);i&&i.onChange&&n.$viewChangeListeners.push(function(){o.a.isFunction(i.onChange)?i.onChange(n.$modelValue,i):e.evalExpr(i.onChange,{modelValue:n.$modelValue,form:i,arrayIndex:e.$index,arrayIndices:e.arrayIndices,path:e.path,$i:e.$i,$index:e.$index})})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r,n,a,s,l,c,u){var f={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function(e,t,r,n){var o=n[0];n[1],n[2];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.initialForm=Object.assign({},o.lookup["f"+r.sfField]),e.form=o.lookup["f"+r.sfField]},post:function(e,t,r,n){var s=n[0],d=n[1];n[2];e.getKey=function(t){var r=t||f.COMPLETE,n=e.parentKey?e.parentKey.slice(0,e.parentKey.length-1):[];if(e.completeKey!==e.form.key&&("number"==typeof e.$index&&(n=n.concat(e.$index)),e.form.key&&e.form.key.length))if("number"==typeof n[n.length-1]&&e.form.key.length>=1){var o=e.form.key.length-n.length;e.completeKey=n.concat(e.form.key.slice(-o))}else e.completeKey=e.form.key.slice();if(Array.isArray(e.completeKey))return r===f.COMPLETE?e.completeKey:e.completeKey.reduce(function(e,t,n){return-1!==[r].indexOf("undefined"==typeof t?"undefined":i(t))?e.concat(t):e},[])},e.form.key&&(e.form.key=e.completeKey=e.getKey()),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=r||!1,o=t&&d&&d.$name?d.$name:void 0,i=e.completeKey;return Array.isArray(i)?c.name(i,"-",o,n):""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(s?s.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return s?s.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&a(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.errors===!1?e.ngModel.$invalid&&!e.ngModel.$pristine:e.ngModel.$invalid)},e.errorMessage=function(t){return l.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)},e.form.htmlClass=e.form.htmlClass||"",e.idClass=e.fieldId(!1)+" "+e.fieldId(!1,!0);var p=e.form;p.key&&(e.$on("schemaForm.error."+p.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(p.validationMessage||(p.validationMessage={}),p.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){var t=e.getKey();"number"==typeof e.arrayIndex?e.arrayIndex+1:0;if(!e.externalDestructionInProgress){var r=p.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(t&&"retain"!==r){var n=e.model;if(t.length>1&&(n=u(t.slice(0,t.length-1),n)),n&&e.destroyed&&n.$$hashKey&&n.$$hashKey!==e.destroyed)return;if(void 0===n)return;var o=p.schema&&p.schema.type||"";"empty"===r&&o.indexOf("string")!==-1?n[t.slice(-1)]="":"empty"===r&&o.indexOf("object")!==-1?n[t.slice(-1)]={}:"empty"===r&&o.indexOf("array")!==-1?n[t.slice(-1)]=[]:"null"===r?n[t.slice(-1)]=null:delete n[t.slice(-1)]}}}))}}}}},function(e,t,r){"use strict";t.a=function(e,t){return{scope:!0,require:["?^^sfNewArray"],link:{pre:function(e,r,n,o){e.parentKey=e.parentKey||[];var i=t.parse(n.sfParentKey),a=i.length-e.parentKey.length;i.length>1&&(i=i.splice(-a)),e.parentKey=e.parentKey.concat(i,Number(n.sfIndex)),e.arrayIndex=Number(n.sfIndex),e.arrayIndices=e.arrayIndices||[],e.arrayIndices=e.arrayIndices.concat(e.arrayIndex),e.$i=e.arrayIndices,e.path=function(t){var r=-1;return t=t.replace(/\[\]/gi,function(t){return r++,"["+e.$i[r]+"]"}),e.evalExpr(t,e)}}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r=e.has("$sanitize")?e.get("$sanitize"):function(e){return e};return{scope:!1,restrict:"EA",link:function(e,n,i){var a="";i.sfMessage&&e.$watch(i.sfMessage,function(t){t&&(a=r(t),c(!!e.ngModel))});var s,l=function(e){e!==s&&(n.html(e),s=e)},c=function(r){if(r)if(e.hasError()){var n=[];o.a.forEach(e.ngModel&&e.ngModel.$error,function(e,t){e&&n.push(t)}),n=n.filter(function(e){return"schemaForm"!==e});var i=n[0];l(i?t.interpolate(i,e.ngModel.$modelValue,e.ngModel.$viewValue,e.form,e.options&&e.options.validationMessage):a)}else l(a);else l(a)};c();var u=e.$watch("ngModel",function(e){e&&(e.$parsers.push(function(e){return c(!0),e}),e.$formatters.push(function(e){return c(!0),e}),u())});e.$watchCollection("ngModel.$error",function(){c(!!e.ngModel)})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r,n,i,a,s,l,c){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function(e){this.$onInit=function(){this.evalInParentScope=function(t,r){return e.$parent.$eval(t,r)};var t=this;e.lookup=function(e){return e&&(t.lookup=e),t.lookup}},1===o.a.version.major&&o.a.version.minor<5&&this.$onInit()}],replace:!1,restrict:"A",transclude:!0,require:"?form",link:function(l,u,f,d,p){l.formCtrl=d;var m={};p(l,function(e){if(e.addClass("schema-form-ignore"),u.prepend(e),u[0].querySelectorAll){var t=u[0].querySelectorAll("[ng-model]");if(t)for(var r=0;r<t.length;r++){var n=t[r].getAttribute("ng-model");m[n.substring(n.indexOf(".")+1)]=!0}}});var h,y={};l.resolveReferences=function(e,t){i.jsonref(e).then(function(e){l.render(e,t)}).catch(function(e){new Error(e)})},l.render=function(e,o){var a=[],s=i.merge(e,o,void 0,m,l.options,void 0,a);a.length>0?n.all(a.map(function(e){return t.get(e.templateUrl,{cache:r}).then(function(t){e.template=t.data})})).then(function(){l.internalRender(e,o,s)}):l.internalRender(e,o,s)},l.internalRender=function(t,r,n){h&&(l.externalDestructionInProgress=!0,h.$destroy(),l.externalDestructionInProgress=!1),h=l.$new(),h.schemaForm={form:n,schema:t},Array.prototype.forEach.call(u.children(),function(e){var t=o.a.element(e);!1===t.hasClass("schema-form-ignore")&&t.remove()});for(var d={},p=u[0].querySelectorAll("*[sf-insert-field]"),m=0;m<p.length;m++)d[p[m].getAttribute("sf-insert-field")]=p[m];var y=a.decorator(f.sfUseDecorator),v=Object.create(null);l.lookup(v),u[0].appendChild(c.build(n,y,d,v)),h.firstDigest=!0,setTimeout(function(){h.firstDigest=!1,l.$apply()},0),e(u.children())(h),l.options&&l.options.setSchemaDefaults===!1||i.traverseSchema(t,function(e,t){if(o.a.isDefined(e.default)){var r=s(t,l.model);o.a.isUndefined(r)&&s(t,l.model,e.default)}}),l.$emit("sf-render-finished",u)};var v=["*"];l.$watch(function(){var e=l.schema,t=l.initialForm||v;t&&e&&e.type&&(y.form!==t||y.schema!==e)&&((!e.properties||0===Object.keys(e.properties).length)&&(t.indexOf("*")||t.indexOf("...")),y.schema=e,y.form=t,l.resolveReferences(e,t))}),l.$on("schemaFormRedraw",function(){var e=l.schema,t=l.initialForm?o.a.copy(l.initialForm):["*"];e&&l.resolveReferences(e,t)}),l.$on("$destroy",function(){l.externalDestructionInProgress=!0}),l.evalExpr=function(e,t){return l.$parent.$eval(e,t)}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r="",n={},i=function(e,t){"sfDecorator"===e&&(e=r);var o=n[e];return o[t.type]?o[t.type].template:o.default.template},a=function(r){e.directive(r,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function(e,n,a,s,l,c,u,f,d){return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["?^sfSchema","?^form"],link:function(e,p,m,h){var y=h[0],v=h[1];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=e.parentKey||[];if(e.form.key){if("number"==typeof n[n.length-1]){var o=n.concat(e.form.key.slice(-1)),i=t&&v&&v.$name?v.$name:void 0;return f.name(o,"-",i,r)}var i=t&&v&&v.$name?v.$name:void 0;return f.name(e.form.key,"-",i,r)}return""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(y?y.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return y?y.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&l(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.ngModel.$invalid&&!e.ngModel.$pristine)},e.errorMessage=function(t){return u.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)};var g=e.$watch(m.form,function(l){if(l){l.ngModelOptions=l.ngModelOptions||{},e.form=l;var u;if("template"===l.type&&l.template)u=c.when(l.template);else{var m="template"===l.type?l.templateUrl:i(r,l);u=a.get(m,{cache:s}).then(function(e){return e.data})}u.then(function(r){if(l.key){var i=l.key?t.stringify(l.key).replace(/"/g,"&quot;"):"";r=r.replace(/\$\$value\$\$/g,"model"+("["!==i[0]?".":"")+i)}if(p.html(r),l.condition){var a='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';l.key&&(a='evalExpr(form.condition, {model: model, "arrayIndex": arrayIndex, "modelValue": model'+f.stringify(l.key)+"})"),o.a.forEach(p.children(),function(e){var t=e.getAttribute("ng-if");e.setAttribute("ng-if",t?"("+t+") || ("+a+")":a)})}n(p.contents())(e)}),l.key&&(e.$on("schemaForm.error."+l.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(l.validationMessage||(l.validationMessage={}),l.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){if(!e.externalDestructionInProgress){var t=l.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(l.key&&"retain"!==t){var r=e.model;if(l.key.length>1&&(r=d(l.key.slice(0,l.key.length-1),r)),void 0===r)return;var n=l.schema&&l.schema.type||"";"empty"===t&&n.indexOf("string")!==-1?r[l.key.slice(-1)]="":"empty"===t&&n.indexOf("object")!==-1?r[l.key.slice(-1)]={}:"empty"===t&&n.indexOf("array")!==-1?r[l.key.slice(-1)]=[]:"null"===t?r[l.key.slice(-1)]=null:delete r[l.key.slice(-1)]}}})),g()}})}}}])},s=function(t,r,n){n=!!o.a.isDefined(n)&&n,e.directive("sf"+o.a.uppercase(t[0])+t.substr(1),function(){return{restrict:"EAC",scope:!0,replace:!0,transclude:n,template:'<sf-decorator form="form"></sf-decorator>',link:function(e,r,n){var i={items:"c",titleMap:"c",schema:"c"
-},a={type:t},s=!0;o.a.forEach(n,function(t,r){if("$"!==r[0]&&0!==r.indexOf("ng")&&"sfField"!==r){var l=function(t){o.a.isDefined(t)&&t!==a[r]&&(a[r]=t,s&&a.type&&(a.key||o.a.isUndefined(n.key))&&(e.form=a,s=!1))};"model"===r?e.$watch(t,function(t){t&&e.model!==t&&(e.model=t)}):"c"===i[r]?e.$watchCollection(t,l):n.$observe(r,l)}})}}})};this.createDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){n[e][r]={template:t,replace:!1,builder:[]}}),n[r]||(r=e),a(e)},this.defineDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){t.builder=t.builder||[],t.replace=!o.a.isDefined(t.replace)||t.replace,n[e][r]=t}),n[r]||(r=e),a(e)},this.createDirective=s,this.createDirectives=function(e){o.a.forEach(e,function(e,t){s(t,e)})},this.decorator=function(e){return e=e||r,n[e]},this.addMapping=function(e,t,r,o,i){n[e]&&(n[e][t]={template:r,builder:o,replace:!!i})},this.defineAddOn=function(e,t,r,o){n[e]&&(n[e][t]={template:r,builder:o,replace:!0})},this.$get=function(){return{decorator:function(e){return n[e]||n[r]},defaultDecorator:r}},a("sfDecorator")}},function(e,t,r){"use strict";var n=r(0),o=(r.n(n),r(1));r.n(o);t.a=function(){var e=function(e){return e},t=o.schemaDefaults.createDefaults();this.defaults=t,this.stdFormObj=o.schemaDefaults.stdFormObj,this.defaultFormDefinition=o.schemaDefaults.defaultFormDefinition,this.postProcess=function(t){e=t},this.appendRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].push(t)},this.prependRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].unshift(t)},this.createStandardForm=o.schemaDefaults.stdFormObj,this.$get=function(){var t={},n=this.defaults;return t.jsonref=o.jsonref,t.defaults=function(e,t,r,i){var a=t||n;return o.schemaDefaults.defaultForm(e,a,r,i)},t.merge=function(n){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["*"],a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.typeDefault,s=arguments[3],l=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},c=arguments.length>5&&void 0!==arguments[5]&&arguments[5],u=arguments[6],f=r.i(o.merge)(n,i,a,s,l,c,u);return e(f)},t.typeDefault=n,t.traverseSchema=o.traverseSchema,t.traverseForm=o.traverseForm,t}}},function(e,t,r){"use strict";t.a=function(e){var t=/[A-Z]/g,r=function(e,r){return r=r||"_",e.replace(t,function(e,t){return(t?r:"")+e.toLowerCase()})},n=0;"firstElementChild"in document.createDocumentFragment()||Object.defineProperty(DocumentFragment.prototype,"firstElementChild",{get:function(){for(var e,t=this.childNodes,r=0,n=t.length;r<n;++r)if(e=t[r],1===e.nodeType)return e;return null}});var o={sfField:function(e){e.fieldFrag.firstElementChild.setAttribute("sf-field",n),e.lookup["f"+n]=e.form,n++},ngModel:function(t){if(t.form.key){var r=t.form.key;t.state.keyRedaction&&(r=r.slice(t.state.keyRedaction));var n;if(t.state.modelValue)n=t.state.modelValue;else{var o=e.stringify(r).replace(/"/g,"&quot;");n=t.state.modelName||"model",o&&(n+=("["!==o[0]?".":"")+o)}for(var i=t.fieldFrag.querySelectorAll("[sf-field-model]"),a=0;a<i.length;a++){var s=i[a],l=s.getAttribute("sf-field-model");if(l&&""!==l)if("replaceAll"===l)for(var c=s.attributes,u=0;u<c.length;u++)c[u].value&&c[u].value.indexOf("$$value")!==-1&&(c[u].value=c[u].value.replace(/\$\$value\$\$/g,n));else{var f=s.getAttribute(l);f&&f.indexOf("$$value$$")?s.setAttribute(l,f.replace(/\$\$value\$\$/g,n)):s.setAttribute(l,n)}else s.setAttribute("ng-model",n)}}},simpleTransclusion:function(e){var t=e.build(e.form.items,e.path+".items",e.state);e.fieldFrag.firstChild.appendChild(t)},ngModelOptions:function(e){e.form.ngModelOptions&&Object.keys(e.form.ngModelOptions).length>0&&e.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(e.form.ngModelOptions))},transclusion:function(e){var t=e.fieldFrag.querySelectorAll("[sf-field-transclude]");if(t.length)for(var r=0;r<t.length;r++){var n=t[r],o=n.getAttribute("sf-field-transclude")||"items",i=e.form[o];if(i){var a=e.build(i,e.path+"."+o,e.state);n.appendChild(a)}}},condition:function(t){var r="",n="undefined",o="";if(t.form.condition){t.form.key&&(r=e.stringify(t.form.key),n="model"+("["===r[0]?"":".")+r);for(var i="evalExpr("+t.path+'.condition, { model: model, "arrayIndex": $index, "arrayIndices": arrayIndices, "path": path, "$i": $i, "$index": $index, "modelValue": '+n+"})",a=t.fieldFrag.children||t.fieldFrag.childNodes,s=0;s<a.length;s++){var l=a[s];l.hasAttribute&&l.hasAttribute("ng-if")&&(o=l.getAttribute("ng-if")),l.setAttribute&&l.setAttribute("ng-if",o?"("+o+") || ("+i+")":i)}}},array:function(t){var r=t.fieldFrag.querySelector("[schema-form-array-items]");if(t.form.key){t.form.key.filter(function(e){return""===e}).length}if(r){var n=angular.copy(t.state);if(n.keyRedaction=0,n.keyRedaction+=t.form.key.length+1,t.form.schema&&t.form.schema.items&&t.form.schema.items.type&&t.form.schema.items.type.indexOf("object")===-1&&t.form.schema.items.type.indexOf("array")===-1){e.stringify(t.form.key).replace(/"/g,"&quot;")+"[$index]";n.modelValue="modelArray[$index]"}else n.modelName="item";n.arrayCompatFlag=!0;var o=t.build(t.form.items,t.path+".items",n);r.appendChild(o)}},numeric:function(e){var t=e.fieldFrag.querySelector("input"),r=e.form.maximum||!1,n=e.form.exclusiveMaximum||!1,o=e.form.minimum||!1,i=e.form.exclusiveMinimum||!1,a=e.form.multipleOf||!1;t&&(a!==!1&&t.setAttribute("step",a),r!==!1&&(n!==!1&&a!==!1&&(r-=a),t.setAttribute("max",r)),o!==!1&&(i!==!1&&a!==!1&&(o+=a),t.setAttribute("min",o)))}};this.builders=o;var i=[o.sfField,o.ngModel,o.ngModelOptions,o.condition];this.stdBuilders=i,this.$get=["$templateCache","schemaFormDecorators","sfPath",function(e,t,n){var a=function(e,t){if(e.key){var r=t[n.stringify(e.key)];if(r){for(;r.firstChild;)r.removeChild(r.firstChild);return r}}},s=function e(t,n,o,i,s,l,c){l=l||{},l=l||{},c=c||Object.create(null),s=s||"schemaForm.form";var u=document.createDocumentFragment();return t.reduce(function(t,u,f){if(!u.type)return t;var d=n[u.type]||n.default;if(d.replace){var p;l.arrayCompatFlag=!1;var m=document.createElement("div"),h=o(u,d)||o(u,n.default);for(m.innerHTML=h,p=document.createDocumentFragment();m.childNodes.length>0;)p.appendChild(m.childNodes[0]);var y={fieldFrag:p,form:u,lookup:c,state:l,path:s+"["+f+"]",build:function(t,r,a){return e(t,n,o,i,r,a,c)}},v=u.builder||d.builder;"function"==typeof v?v(y):v.forEach(function(e){e(y)}),(a(u,i)||t).appendChild(p)}else{var g=document.createElement(r(n.__name,"-"));l.arrayCompatFlag?g.setAttribute("form","copyWithIndex($index)"):g.setAttribute("form",s+"["+f+"]"),(a(u,i)||t).appendChild(g)}return t},u),u};return{build:function(t,r,n,o){return s(t,r,function(t,r){return"template"===t.type?t.template:e.get(r.template)},n,void 0,void 0,o)},builder:o,stdBuilders:i,internalBuild:s}}]}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){var e={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};e.number=e[105],e.required=e[302],e.min=e[101],e.max=e[103],e.maxlength=e[201],e.minlength=e[200],e.pattern=e[202],this.setDefaultMessages=function(t){e=t},this.getDefaultMessages=function(){return e},this.setDefaultMessage=function(t,r){e[t]=r},this.$get=["$interpolate",function(t){var r={};return r.defaultMessages=e,r.interpolate=function(r,n,i,a,s){s=s||{};var l=a.validationMessage||{};0===r.indexOf("tv4-")&&(r=r.substring(4));var c=l.default||s.default||"";[l,s,e].some(function(e){return o.a.isString(e)||o.a.isFunction(e)?(c=e,!0):e&&e[r]?(c=e[r],!0):void 0});var u={error:r,value:n,viewValue:i,form:a,schema:a.schema,title:a.title||a.schema&&a.schema.title};return o.a.isFunction(c)?c(u):t(c)(u)},r}]}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=r(1),i=(r.n(o),r(0)),a=(r.n(i),function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}()),s=function(){function e(){n(this,e),this.name=o.sfPath.name,this.parse=o.sfPath.parse,this.stringify=o.sfPath.stringify,this.normalize=o.sfPath.normalize}return a(e,[{key:"$get",value:function(){return o.sfPath}}]),e}();t.a=s},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):y=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++y<t;)p&&p[y].run();y=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,y=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},function(e,t,r){(function(e,t){!function(e,r){"use strict";function n(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var n={callback:e,args:t};return h[m]=n,p(m),m++}function o(e){delete h[e]}function i(e){var t=e.callback,n=e.args;switch(n.length){case 0:t();break;case 1:t(n[0]);break;case 2:t(n[0],n[1]);break;case 3:t(n[0],n[1],n[2]);break;default:t.apply(r,n)}}function a(e){if(y)setTimeout(a,0,e);else{var t=h[e];if(t){y=!0;try{i(t)}finally{o(e),y=!1}}}}function s(){p=function(e){t.nextTick(function(){a(e)})}}function l(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}function c(){var t="setImmediate$"+Math.random()+"$",r=function(r){r.source===e&&"string"==typeof r.data&&0===r.data.indexOf(t)&&a(+r.data.slice(t.length))};e.addEventListener?e.addEventListener("message",r,!1):e.attachEvent("onmessage",r),p=function(r){e.postMessage(t+r,"*")}}function u(){var e=new MessageChannel;e.port1.onmessage=function(e){var t=e.data;a(t)},p=function(t){e.port2.postMessage(t)}}function f(){var e=v.documentElement;p=function(t){var r=v.createElement("script");r.onreadystatechange=function(){a(t),r.onreadystatechange=null,e.removeChild(r),r=null},e.appendChild(r)}}function d(){p=function(e){setTimeout(a,0,e)}}if(!e.setImmediate){var p,m=1,h={},y=!1,v=e.document,g=Object.getPrototypeOf&&Object.getPrototypeOf(e);g=g&&g.setTimeout?g:e,"[object process]"==={}.toString.call(e.process)?s():l()?c():e.MessageChannel?u():v&&"onreadystatechange"in v.createElement("script")?f():d(),g.setImmediate=n,g.clearImmediate=o}}("undefined"==typeof self?"undefined"==typeof e?this:e:self)}).call(t,r(2),r(17))},function(r,n,o){function i(e,t){this._id=e,this._clearFn=t}var a=Function.prototype.apply;n.setTimeout=function(){return new i(a.call(setTimeout,window,arguments),clearTimeout)},n.setInterval=function(){return new i(a.call(setInterval,window,arguments),clearInterval)},n.clearTimeout=n.clearInterval=function(e){e&&e.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(window,this._id)},n.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},n.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},n._unrefActive=n.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},o(18),n.setImmediate=e,n.clearImmediate=t},,function(e,t,r){r(1),e.exports=r(4)}])}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):y=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++y<t;)p&&p[y].run();y=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,y=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},,,function(e,t,r){r(19),e.exports=r(0)}]);
\ No newline at end of file
+var n=!1,o=!0,i=!0,a=function(){function e(){for(var e=[],t=0;t<arguments.length;t++)e[t-0]=arguments[t];if(e.length>1){e[0]=e[0].slice(0,-1);for(var r=e.length-1,n=1;n<r;++n)e[n]=e[n].slice(1,-1);return e[r]=e[r].slice(1),e.join("")}return e[0]}function t(e){return"(?:"+e+")"}function r(r){var n="[A-Za-z]",o="[0-9]",a=e(o,"[A-Fa-f]"),s=t(t("%[EFef]"+a+"%"+a+a+"%"+a+a)+"|"+t("%[89A-Fa-f]"+a+"%"+a+a)+"|"+t("%"+a+a)),l="[\\:\\/\\?\\#\\[\\]\\@]",c="[\\!\\$\\&\\'\\(\\)\\*\\+\\,\\;\\=]",u=e(l,c),f=r?"[\\xA0-\\u200D\\u2010-\\u2029\\u202F-\\uD7FF\\uF900-\\uFDCF\\uFDF0-\\uFFEF]":"[]",d=r?"[\\uE000-\\uF8FF]":"[]",p=e(n,o,"[\\-\\.\\_\\~]",f),m=t(n+e(n,o,"[\\+\\-\\.]")+"*"),h=t(t(s+"|"+e(p,c,"[\\:]"))+"*"),y=t(t("25[0-5]")+"|"+t("2[0-4]"+o)+"|"+t("1"+o+o)+"|"+t("[1-9]"+o)+"|"+o),v=t(y+"\\."+y+"\\."+y+"\\."+y),g=t(a+"{1,4}"),b=(t(t(g+"\\:"+g)+"|"+v),t(e(p,c,"[\\:]")+"+")),x=t("v"+a+"+\\."+e(p,c,"[\\:]")+"+"),w=t("\\["+t(b+"|"+x)+"\\]"),$=t(t(s+"|"+e(p,c))+"*"),E=t(w+"|"+v+"(?!"+$+")|"+$),C=t(o+"*"),k=t(t(h+"@")+"?"+E+t("\\:"+C)+"?"),O=t(s+"|"+e(p,c,"[\\:\\@]")),T=t(O+"*"),A=t(O+"+"),S=t(t(s+"|"+e(p,c,"[\\@]"))+"+"),P=t(t("\\/"+T)+"*"),M=t("\\/"+t(A+P)+"?"),I=t(S+P),j=t(A+P),D="(?!"+O+")",_=(t(P+"|"+M+"|"+I+"|"+j+"|"+D),t(t(O+"|"+e("[\\/\\?]",d))+"*")),F=t(t(O+"|[\\/\\?]")+"*"),R=t(t("\\/\\/"+k+P)+"|"+M+"|"+j+"|"+D),q=t(m+"\\:"+R+t("\\?"+_)+"?"+t("\\#"+F)+"?"),U=t(t("\\/\\/"+k+P)+"|"+M+"|"+I+"|"+D),N=t(U+t("\\?"+_)+"?"+t("\\#"+F)+"?"),L=(t(q+"|"+N),t(m+"\\:"+R+t("\\?"+_)+"?"),"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+E+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+j+"|"+D+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$"),H="^(){0}"+t(t("\\/\\/("+t("("+h+")@")+"?("+E+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+I+"|"+D+")")+t("\\?("+_+")")+"?"+t("\\#("+F+")")+"?$";"^("+m+")\\:"+t(t("\\/\\/("+t("("+h+")@")+"?("+E+")"+t("\\:("+C+")")+"?)")+"?("+P+"|"+M+"|"+j+"|"+D+")")+t("\\?("+_+")")+"?$","^"+t("\\#("+F+")")+"?$","^"+t("("+h+")@")+"?("+E+")"+t("\\:("+C+")")+"?$";return{URI_REF:i&&new RegExp("("+L+")|("+H+")"),NOT_SCHEME:new RegExp(e("[^]",n,o,"[\\+\\-\\.]"),"g"),NOT_USERINFO:new RegExp(e("[^\\%\\:]",p,c),"g"),NOT_HOST:new RegExp(e("[^\\%]",p,c),"g"),NOT_PATH:new RegExp(e("[^\\%\\/\\:\\@]",p,c),"g"),NOT_PATH_NOSCHEME:new RegExp(e("[^\\%\\/\\@]",p,c),"g"),NOT_QUERY:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]",d),"g"),NOT_FRAGMENT:new RegExp(e("[^\\%]",p,c,"[\\:\\@\\/\\?]"),"g"),ESCAPE:new RegExp(e("[^]",p,c),"g"),UNRESERVED:new RegExp(p,"g"),OTHER_CHARS:new RegExp(e("[^\\%]",p,u),"g"),PCT_ENCODED:new RegExp(s,"g")}}function n(e){var t,r=e.charCodeAt(0);return t=r<16?"%0"+r.toString(16).toUpperCase():r<128?"%"+r.toString(16).toUpperCase():r<2048?"%"+(r>>6|192).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase():"%"+(r>>12|224).toString(16).toUpperCase()+"%"+(r>>6&63|128).toString(16).toUpperCase()+"%"+(63&r|128).toString(16).toUpperCase()}function a(e){for(var t,r,n,o="",i=0,a=e.length;i<a;)t=parseInt(e.substr(i+1,2),16),t<128?(o+=String.fromCharCode(t),i+=3):t>=194&&t<224?(a-i>=6?(r=parseInt(e.substr(i+4,2),16),o+=String.fromCharCode((31&t)<<6|63&r)):o+=e.substr(i,6),i+=6):t>=224?(a-i>=9?(r=parseInt(e.substr(i+4,2),16),n=parseInt(e.substr(i+7,2),16),o+=String.fromCharCode((15&t)<<12|(63&r)<<6|63&n)):o+=e.substr(i,9),i+=9):(o+=e.substr(i,3),i+=3);return o}function l(e){return void 0===e?"undefined":null===e?"null":Object.prototype.toString.call(e).split(" ").pop().split("]").shift().toLowerCase()}function c(e){return e.toUpperCase()}function u(e,t){function r(e){var r=a(e);return r.match(t.UNRESERVED)?r:e}return e.scheme&&(e.scheme=String(e.scheme).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_SCHEME,"")),void 0!==e.userinfo&&(e.userinfo=String(e.userinfo).replace(t.PCT_ENCODED,r).replace(t.NOT_USERINFO,n).replace(t.PCT_ENCODED,c)),void 0!==e.host&&(e.host=String(e.host).replace(t.PCT_ENCODED,r).toLowerCase().replace(t.NOT_HOST,n).replace(t.PCT_ENCODED,c)),void 0!==e.path&&(e.path=String(e.path).replace(t.PCT_ENCODED,r).replace(e.scheme?t.NOT_PATH:t.NOT_PATH_NOSCHEME,n).replace(t.PCT_ENCODED,c)),void 0!==e.query&&(e.query=String(e.query).replace(t.PCT_ENCODED,r).replace(t.NOT_QUERY,n).replace(t.PCT_ENCODED,c)),void 0!==e.fragment&&(e.fragment=String(e.fragment).replace(t.PCT_ENCODED,r).replace(t.NOT_FRAGMENT,n).replace(t.PCT_ENCODED,c)),e}function f(e,t){void 0===t&&(t={});var r,n,l=o&&t.iri!==!1?$:w,c=!1,f={};if("suffix"===t.reference&&(e=(t.scheme?t.scheme+":":"")+"//"+e),i?(r=e.match(l.URI_REF),r&&(r=r[1]?r.slice(1,10):r.slice(10,19)),r||(c=!0,t.tolerant||(f.error=f.error||"URI is not strictly valid."),r=e.match(E))):r=e.match(E),r){if(A?(f.scheme=r[1],f.userinfo=r[3],f.host=r[4],f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=r[7],f.fragment=r[8],isNaN(f.port)&&(f.port=r[5])):(f.scheme=r[1]||void 0,f.userinfo=e.indexOf("@")!==-1?r[3]:void 0,f.host=e.indexOf("//")!==-1?r[4]:void 0,f.port=parseInt(r[5],10),f.path=r[6]||"",f.query=e.indexOf("?")!==-1?r[7]:void 0,f.fragment=e.indexOf("#")!==-1?r[8]:void 0,isNaN(f.port)&&(f.port=e.match(/\/\/(?:.|\n)*\:(?:\/|\?|\#|$)/)?r[4]:void 0)),void 0!==f.scheme||void 0!==f.userinfo||void 0!==f.host||void 0!==f.port||f.path||void 0!==f.query?void 0===f.scheme?f.reference="relative":void 0===f.fragment?f.reference="absolute":f.reference="uri":f.reference="same-document",t.reference&&"suffix"!==t.reference&&t.reference!==f.reference&&(f.error=f.error||"URI is not a "+t.reference+" reference."),n=S[(t.scheme||f.scheme||"").toLowerCase()],!o||"undefined"==typeof s||t.unicodeSupport||n&&n.unicodeSupport)u(f,l);else{if(f.host&&(t.domainHost||n&&n.domainHost))try{f.host=s.toASCII(f.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(e){f.error=f.error||"Host's domain name can not be converted to ASCII via punycode: "+e}u(f,w)}n&&n.parse&&n.parse(f,t)}else c=!0,f.error=f.error||"URI can not be parsed.";return f}function d(e,t){var r=[];return void 0!==e.userinfo&&(r.push(e.userinfo),r.push("@")),void 0!==e.host&&r.push(e.host),"number"==typeof e.port&&(r.push(":"),r.push(e.port.toString(10))),r.length?r.join(""):void 0}function p(e){for(var t,r=[];e.length;)e.match(C)?e=e.replace(C,""):e.match(k)?e=e.replace(k,"/"):e.match(O)?(e=e.replace(O,"/"),r.pop()):"."===e||".."===e?e="":(t=e.match(T)[0],e=e.slice(t.length),r.push(t));return r.join("")}function m(e,t){void 0===t&&(t={});var r,n,i,l=o&&t.iri?$:w,c=[];if(r=S[(t.scheme||e.scheme||"").toLowerCase()],r&&r.serialize&&r.serialize(e,t),o&&"undefined"!=typeof s&&e.host&&(t.domainHost||r&&r.domainHost))try{e.host=t.iri?s.toUnicode(e.host):s.toASCII(e.host.replace(l.PCT_ENCODED,a).toLowerCase())}catch(r){e.error=e.error||"Host's domain name can not be converted to "+(t.iri?"Unicode":"ASCII")+" via punycode: "+r}return u(e,l),"suffix"!==t.reference&&e.scheme&&(c.push(e.scheme),c.push(":")),n=d(e,t),void 0!==n&&("suffix"!==t.reference&&c.push("//"),c.push(n),e.path&&"/"!==e.path.charAt(0)&&c.push("/")),void 0!==e.path&&(i=e.path,t.absolutePath||r&&r.absolutePath||(i=p(i)),void 0===n&&(i=i.replace(/^\/\//,"/%2F")),c.push(i)),void 0!==e.query&&(c.push("?"),c.push(e.query)),void 0!==e.fragment&&(c.push("#"),c.push(e.fragment)),c.join("")}function h(e,t,r,n){void 0===r&&(r={});var o={};return n||(e=f(m(e,r),r),t=f(m(t,r),r)),r=r||{},!r.tolerant&&t.scheme?(o.scheme=t.scheme,o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(void 0!==t.userinfo||void 0!==t.host||void 0!==t.port?(o.userinfo=t.userinfo,o.host=t.host,o.port=t.port,o.path=p(t.path),o.query=t.query):(t.path?("/"===t.path.charAt(0)?o.path=p(t.path):(void 0===e.userinfo&&void 0===e.host&&void 0===e.port||e.path?e.path?o.path=e.path.slice(0,e.path.lastIndexOf("/")+1)+t.path:o.path=t.path:o.path="/"+t.path,o.path=p(o.path)),o.query=t.query):(o.path=e.path,void 0!==t.query?o.query=t.query:o.query=e.query),o.userinfo=e.userinfo,o.host=e.host,o.port=e.port),o.scheme=e.scheme),o.fragment=t.fragment,o}function y(e,t,r){return m(h(f(e,r),f(t,r),r,!0),r)}function v(e,t){return"string"==typeof e?e=m(f(e,t),t):"object"===l(e)&&(e=f(m(e,t),t)),e}function g(e,t,r){return"string"==typeof e?e=m(f(e,r),r):"object"===l(e)&&(e=m(e,r)),"string"==typeof t?t=m(f(t,r),r):"object"===l(t)&&(t=m(t,r)),e===t}function b(e,t){return e&&e.toString().replace(o&&t&&t.iri?$.ESCAPE:w.ESCAPE,n)}function x(e,t){return e&&e.toString().replace(o&&t&&t.iri?$.PCT_ENCODED:w.PCT_ENCODED,a)}var w=r(!1),$=o?r(!0):void 0,E=/^(?:([^:\/?#]+):)?(?:\/\/((?:([^\/?#@]*)@)?([^\/?#:]*)(?:\:(\d*))?))?([^?#]*)(?:\?([^#]*))?(?:#((?:.|\n)*))?/i,C=/^\.\.?\//,k=/^\/\.(\/|$)/,O=/^\/\.\.(\/|$)/,T=/^\/?(?:.|\n)*?(?=\/|$)/,A=void 0==="".match(/(){0}/)[1],S={};return{IRI_SUPPORT:o,VALIDATE_SUPPORT:i,pctEncChar:n,pctDecChars:a,SCHEMES:S,parse:f,_recomposeAuthority:d,removeDotSegments:p,serialize:m,resolveComponents:h,resolve:y,normalize:v,equal:g,escapeComponent:b,unescapeComponent:x}}();if(!n&&"undefined"!=typeof t&&"function"==typeof e){var s=e("./punycode");t.exports=a,e("./schemes")}},{"./punycode":18,"./schemes":19}]},{},[1])(1)})},function(e,t,r){"use strict";function n(e,t){var l=arguments.length>2&&void 0!==arguments[2]?arguments[2]:r.i(i.createDefaults)(),c=arguments[3],u=arguments[4],f=arguments[5],d=arguments[6],p=[],m=[];t=t||[];var h=t.indexOf("*");u=u||{};var y={},v=t.indexOf("...");if("object"===("undefined"==typeof e?"undefined":s(e))&&e.hasOwnProperty("properties")){f=f||e.readonly||e.readOnly,y=r.i(i.defaultForm)(e,l,c,u);var g=y.lookup;e=g||e,p=p.concat(y.form)}return h!==-1&&(t=t.slice(0,h).concat(p).concat(t.slice(h+1))),y.form&&v!==-1&&!function(){var e=t.map(function(e){return"string"==typeof e?e:e.key?e.key:void 0}).filter(function(e){return void 0!==e});m=m.concat(y.form.map(function(t){var r=e.indexOf(t.key[0])!==-1;if(!r)return t}).filter(function(e){return void 0!==e}))}(),v!==-1&&(t=t.slice(0,v).concat(m).concat(t.slice(v+1))),t.map(function(t){if("string"==typeof t&&(t={key:t}),t.key&&"string"==typeof t.key&&(t.key=r.i(o.parse)(t.key)),t.titleMap&&(t.titleMap=r.i(a.a)(t.titleMap)),t.key){var i=r.i(o.stringify)(t.key);e[i]&&!function(){var r=e[i];r&&Object.keys(r).forEach(function(e){void 0===t[e]&&(t[e]=r[e])})}()}return f===!0&&(t.readonly=!0),t.items&&(t.items=n(e,t.items,l,c,u,t.readonly,d)),t.tabs&&t.tabs.forEach(function(r){r.items&&(r.items=n(e,r.items,l,c,u,t.readonly,d))}),"checkbox"===t.type&&(void 0===t.schema?t.schema={default:!1}:void 0===t.schema.default&&(t.schema.default=!1)),d&&"template"===t.type&&!t.template&&t.templateUrl&&d.push(t),t})}var o=r(0),i=r(3),a=r(1);t.a=n;var s="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e}},function(e,t,r){"use strict";function n(e,t){var r=new Promise(function(t,r){o.resolveRefs(e,{filter:["relative","local","remote"]}).then(function(e){t(e.resolved)}).catch(function(e){r(new Error(e))})});return"function"!=typeof t?r:void r.then(function(e){t(null,e)}).catch(function(e){t(e)})}var o=r(5);r.n(o);t.a=n},function(e,t,r){"use strict";function n(e,t,r){t||(t=this);var n="string"==typeof e?o.parse(e):e;if("undefined"!=typeof r&&1===n.length)return t[n[0]]=r,t;"undefined"!=typeof r&&"undefined"==typeof t[n[0]]&&(t[n[0]]=n.length>2&&i.test(n[1])?[]:{});for(var a=t[n[0]],s=1;s<n.length;s++){if(""===n[s])return;if("undefined"!=typeof r){if(s===n.length-1)return a[n[s]]=r,r;var l=a[n[s]];"undefined"!=typeof l&&null!==l||(l=i.test(n[s+1])?[]:{},a[n[s]]=l),a=l}else a&&(a=a[n[s]])}return a}var o=r(0);t.a=n;var i=/^\d+$/},function(e,t,r){"use strict";function n(e,t,r,n){n=void 0===n||n,r=r||[];var o=function e(t,r,o){if(r(t,o),t.properties&&Object.keys(t.properties).forEach(function(n){var i=o.slice();i.push(n),e(t.properties[n],r,i)}),!n&&t.items){var i=o.slice();i.push(""),e(t.items,r,i)}};o(e,t,r||[])}function o(e,t){t(e),e.items&&e.items.forEach(function(e){o(e,t)}),e.tabs&&e.tabs.forEach(function(e){e.items&&e.items.forEach(function(e){o(e,t)})})}t.a=n,t.b=o},function(e,t,r){"use strict";function n(e,t){if(!e)return{valid:!0};var r=e.schema;if(!r)return{valid:!0};""===t&&(t=void 0),"number"===e.type&&null===t&&(t=void 0);var n={type:"object",properties:{},required:void 0},o=e.key[e.key.length-1];n.properties[o]=r,e.required&&(n.required=[o]);var a={};return"undefined"!=typeof t&&(a[o]=t),i.a.validateResult(a,n)}var o=r(12),i=r.n(o);t.a=n},function(e,t,r){"use strict";var n;!function(o){var i={parse:function(e){if("string"!=typeof e)throw new TypeError("ObjectPath.parse must be passed a string");for(var t,r,n,o,i=0,a=[];i<e.length;)if(t=e.indexOf(".",i),r=e.indexOf("[",i),t===-1&&r===-1)a.push(e.slice(i,e.length)),i=e.length;else if(r===-1||t!==-1&&t<r)a.push(e.slice(i,t)),i=t+1;else if(r>i&&(a.push(e.slice(i,r)),i=r),n=e.slice(r+1,r+2),'"'!==n&&"'"!==n)o=e.indexOf("]",r),o===-1&&(o=e.length),a.push(e.slice(i+1,o)),i="."===e.slice(o+1,o+2)?o+2:o+1;else{for(o=e.indexOf(n+"]",r),o===-1&&(o=e.length);"\\"===e.slice(o-1,o)&&r<e.length;)r++,o=e.indexOf(n+"]",r);a.push(e.slice(i+2,o).replace(new RegExp("\\"+n,"g"),n)),i="."===e.slice(o+2,o+3)?o+3:o+2}return a},stringify:function(e,t){return Array.isArray(e)||(e=[e.toString()]),t='"'===t?'"':"'",e.map(function(e){return"["+t+e.toString().replace(new RegExp(t,"g"),"\\"+t)+t+"]"}).join("")},normalize:function(e,t){return i.stringify(Array.isArray(e)?e:i.parse(e),t)},registerModule:function(e){e.module("ObjectPath",[]).provider("ObjectPath",function(){this.parse=i.parse,this.stringify=i.stringify,this.normalize=i.normalize,this.$get=function(){return i}})}};n=function(){return{ObjectPath:i}}.call(t,r,t,e),!(n!==o&&(e.exports=n))}()},function(e,t){e.exports=tv4},function(e,t,r){e.exports=r(4)}])}).call(t,r(2),r(19).setImmediate)},function(e,t){var r;r=function(){return this}();try{r=r||Function("return this")()||(0,eval)("this")}catch(e){"object"==typeof window&&(r=window)}e.exports=r},,function(e,t,r){"use strict";Object.defineProperty(t,"__esModule",{value:!0});var n=r(1),o=(r.n(n),r(0)),i=r.n(o),a=r(14),s=r(12),l=r(13),c=r(15),u=r(16),f=r(7),d=r(8),p=r(10),m=r(6),h=r(9),y=r(11),v=r(5),g=[];try{i.a.module("ngSanitize"),g.push("ngSanitize")}catch(e){}try{i.a.module("ui.sortable"),g.push("ui.sortable")}catch(e){}try{i.a.module("angularSpectrumColorpicker"),g.push("angularSpectrumColorpicker")}catch(e){}i.a.module("schemaForm",g).provider("sfPath",u.a).provider("sfBuilder",["sfPathProvider",a.a]).provider("schemaFormDecorators",["$compileProvider","sfPathProvider",s.a]).provider("sfErrorMessage",c.a).provider("schemaForm",["sfPathProvider",l.a]).factory("sfSelect",function(){return n.select}).factory("sfValidator",function(){return n.validate}).directive("sfChanged",f.a).directive("sfField",["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",d.a]).directive("sfMessage",["$injector","sfErrorMessage",p.a]).directive("sfNewArray",["sfSelect","sfPath","schemaForm",m.a]).directive("sfSchema",["$compile","$http","$templateCache","$q","schemaForm","schemaFormDecorators","sfSelect","sfPath","sfBuilder",y.a]).directive("schemaValidate",["sfValidator","$parse","sfSelect","$interpolate",v.a]).directive("sfKeyController",["schemaForm","sfPath",h.a])},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r,n){return{restrict:"A",scope:!1,priority:500,require:"ngModel",link:function(t,i,a,s){t.$emit("schemaFormPropagateNgModelController",s);var l=null,c=t.$eval(a.schemaValidate),u="string"==typeof c.copyValueTo?[c.copyValueTo]:c.copyValueTo;u&&u.length&&s.$viewChangeListeners.push(function(){var e={model:t.model,form:c,arrayIndex:t.$index,arrayIndices:t.arrayIndices,path:t.path,$i:t.$i,$index:t.$index};o.a.forEach(u,function(o){var i=o.replace(/\[/g,"[{{ ").replace(/\]/g," }}]").replace(/^model\./,"");i=n(i)(e),r(i,t.model,s.$modelValue)})});var f=function(r,n){if(!c)return r;if(t.options&&t.options.tv4Validation===!1)return r;var o=e(c,r);Object.keys(s.$error).filter(function(e){return 0===e.indexOf("tv4-")}).forEach(function(e){s.$setValidity(e,!0)});{if(o.valid||s.$pristine&&!n)return r;if(s.$setValidity("tv4-"+o.error.code,!1),l=o.error,s.$validators)return r}};"function"==typeof c.ngModel&&c.ngModel(s),["$parsers","$viewChangeListeners","$formatters"].forEach(function(e){c[e]&&s[e]&&c[e].forEach(function(t){s[e].push(t)})}),["$validators","$asyncValidators"].forEach(function(e){c[e]&&s[e]&&o.a.forEach(c[e],function(r,n){s[e][n]=function(e,n){return r(e,n,t.model,c)}})}),s.$parsers.push(f),s.$validators&&(s.$validators.schemaForm=function(){return!Object.keys(s.$error).some(function(e){return"schemaForm"!==e})});var d=c.schema;t.validateField=function(e,t){var r=void 0===e;(r||s.$$parentForm.$name===e)&&((r||d&&d.type.indexOf("array")!==-1)&&f(s.$modelValue,t),s.$setDirty?(s.$setDirty(),s.$setViewValue(s.$viewValue),s.$commitViewValue(),"checkbox"===c.type?c.required&&void 0===s.$modelValue&&s.$setValidity("tv4-302",!1):c.required&&s.$isEmpty(s.$modelValue)&&s.$setValidity("tv4-302",!1)):s.$setViewValue(s.$viewValue))};var p=!0;s.$formatters.push(function(e){return!s.$pristine||!p||t.options&&t.options.validateOnRender===!0?(f(s.$modelValue),e):(p=!1,e)}),t.$on("schemaFormValidate",function(e,r){t.validateField(r,!0)}),t.schemaError=function(){return l}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r){return{scope:!0,controller:["$scope",function(e){this.key=e.form&&e.form.key?e.form.key.splice(0,-2):[]}],link:function(n,a,s){n.min=0,n.trackBy=function(e,t){return e&&"object"===("undefined"==typeof e?"undefined":i(e))?e:t},n.modelArray=n.$eval(s.sfNewArray);var l=function(){n.modelArray=n.$eval(s.sfNewArray),n.ngModel&&n.ngModel.$pristine&&n.firstDigest&&(!n.options||n.options.validateOnRender!==!0)||n.validateField&&n.validateField()},c=function(){n.form&&n.form.onChange&&(o.a.isFunction(n.form.onChange)?n.form.onChange(n.modelArray,n.form):n.evalExpr(n.form.onChange,{modelValue:n.modelArray,form:n.form}))},u=function(){var r=n.modelArray;if(!r){var o=t.parse(s.sfNewArray);r=[],e(o,n,r),n.modelArray=r}return r},f=n.$watch("form",function(e){if(e){if(e.titleMap||e.startEmpty===!0||n.modelArray&&0!==n.modelArray.length||n.appendToArray(),n.$watch(function(e){return JSON.stringify(e.modelArray)},function(){l(),c()}),e.titleMap&&e.titleMap.length>0){n.titleMapValues=[];var t=function(t){n.titleMapValues=[],t=t||[],e.titleMap.forEach(function(e){n.titleMapValues.push(t.indexOf(e.value)!==-1)})};t(n.modelArray),n.$watchCollection("modelArray",t),n.$watchCollection("titleMapValues",function(t,r){if(t&&t!==r){var o=u();e.titleMap.forEach(function(e,r){var n=o.indexOf(e.value);n===-1&&t[r]&&o.push(e.value),n===-1||t[r]||o.splice(n,1)}),n.validateField&&n.validateField()}})}f()}});n.appendToArray=function(){var t,i=u();if(n.form&&n.form.schema&&n.form.schema.items){var a=n.form.schema.items;a.type&&a.type.indexOf("object")!==-1?(t={},n.options&&n.options.setSchemaDefaults===!1||(t=o.a.isDefined(a.default)?a.default:t,t&&r.traverseSchema(a,function(r,n){o.a.isDefined(r.default)&&e(n,t,r.default)}))):(a.type&&(a.type.indexOf("array")!==-1?t=[]:a.type.indexOf("string")===-1&&a.type.indexOf("number")===-1||(t="")),n.options&&n.options.setSchemaDefaults===!1||(t=a.default||t))}return i.push(t),i},n.deleteFromArray=function(e){var t=n.modelArray.indexOf(e),r=n.modelArray;return r&&r.splice(t,1),e.$$hashKey&&(n.destroyed=e.$$hashKey),r};var d=function(e){return function(t){t.key&&(t.key[t.key.indexOf("")]=e)}},p={};n.copyWithIndex=function(e){var t=n.form;if(!p[e]){var i=t.items[0];if(t.items.length>1&&(i={type:"section",items:t.items.map(function(e){return e.ngModelOptions=t.ngModelOptions,o.a.isUndefined(e.readonly)&&(e.readonly=t.readonly),e})}),i){var a=o.a.copy(i);a.arrayIndex=e,r.traverseForm(a,d(e)),p[e]=a}}return p[e]}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){return{require:"ngModel",restrict:"AC",scope:!1,link:function(e,t,r,n){var i=e.$eval(r.sfChanged);i&&i.onChange&&n.$viewChangeListeners.push(function(){o.a.isFunction(i.onChange)?i.onChange(n.$modelValue,i):e.evalExpr(i.onChange,{modelValue:n.$modelValue,form:i,arrayIndex:e.$index,arrayIndices:e.arrayIndices,path:e.path,$i:e.$i,$index:e.$index})})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n),i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e};t.a=function(e,t,r,n,a,s,l,c,u){var f={COMPLETE:"*",PATH:"string",INDICES:"number"};return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["^sfSchema","?^form","?^^sfKeyController"],link:{pre:function(e,t,r,n){var o=n[0];n[1],n[2];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.initialForm=Object.assign({},o.lookup["f"+r.sfField]),e.form=o.lookup["f"+r.sfField]},post:function(e,t,r,n){var s=n[0],d=n[1];n[2];e.getKey=function(t){var r=t||f.COMPLETE,n=e.parentKey?e.parentKey.slice(0,e.parentKey.length-1):[];if(e.completeKey!==e.form.key&&("number"==typeof e.$index&&(n=n.concat(e.$index)),e.form.key&&e.form.key.length))if("number"==typeof n[n.length-1]&&e.form.key.length>=1){var o=e.form.key.length-n.length;e.completeKey=n.concat(e.form.key.slice(-o))}else e.completeKey=e.form.key.slice();if(Array.isArray(e.completeKey))return r===f.COMPLETE?e.completeKey:e.completeKey.reduce(function(e,t,n){return-1!==[r].indexOf("undefined"==typeof t?"undefined":i(t))?e.concat(t):e},[])},e.form.key&&(e.form.key=e.completeKey=e.getKey()),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=r||!1,o=t&&d&&d.$name?d.$name:void 0,i=e.completeKey;return Array.isArray(i)?c.name(i,"-",o,n):""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(s?s.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return s?s.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&a(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.errors===!1?e.ngModel.$invalid&&!e.ngModel.$pristine:e.ngModel.$invalid)},e.errorMessage=function(t){return l.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)},e.form.htmlClass=e.form.htmlClass||"",e.idClass=e.fieldId(!1)+" "+e.fieldId(!1,!0);var p=e.form;p.key&&(e.$on("schemaForm.error."+p.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(p.validationMessage||(p.validationMessage={}),p.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){var t=e.getKey();"number"==typeof e.arrayIndex?e.arrayIndex+1:0;if(!e.externalDestructionInProgress){var r=p.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(t&&"retain"!==r){var n=e.model;if(t.length>1&&(n=u(t.slice(0,t.length-1),n)),n&&e.destroyed&&n.$$hashKey&&n.$$hashKey!==e.destroyed)return;if(void 0===n)return;var o=p.schema&&p.schema.type||"";"empty"===r&&o.indexOf("string")!==-1?n[t.slice(-1)]="":"empty"===r&&o.indexOf("object")!==-1?n[t.slice(-1)]={}:"empty"===r&&o.indexOf("array")!==-1?n[t.slice(-1)]=[]:"null"===r?n[t.slice(-1)]=null:delete n[t.slice(-1)]}}}))}}}}},function(e,t,r){"use strict";t.a=function(e,t){return{scope:!0,require:["?^^sfNewArray"],link:{pre:function(e,r,n,o){e.parentKey=e.parentKey||[];var i=t.parse(n.sfParentKey),a=i.length-e.parentKey.length;i.length>1&&(i=i.splice(-a)),e.parentKey=e.parentKey.concat(i,Number(n.sfIndex)),e.arrayIndex=Number(n.sfIndex),e.arrayIndices=e.arrayIndices||[],e.arrayIndices=e.arrayIndices.concat(e.arrayIndex),e.$i=e.arrayIndices,e.path=function(t){var r=-1;return t=t.replace(/\[\]/gi,function(t){return r++,"["+e.$i[r]+"]"}),e.evalExpr(t,e)}}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r=e.has("$sanitize")?e.get("$sanitize"):function(e){return e};return{scope:!1,restrict:"EA",link:function(e,n,i){var a="";i.sfMessage&&e.$watch(i.sfMessage,function(t){t&&(a=r(t),c(!!e.ngModel))});var s,l=function(e){e!==s&&(n.html(e),s=e)},c=function(r){if(r)if(e.hasError()){var n=[];o.a.forEach(e.ngModel&&e.ngModel.$error,function(e,t){e&&n.push(t)}),n=n.filter(function(e){return"schemaForm"!==e});var i=n[0];l(i?t.interpolate(i,e.ngModel.$modelValue,e.ngModel.$viewValue,e.form,e.options&&e.options.validationMessage):a)}else l(a);else l(a)};c();var u=e.$watch("ngModel",function(e){e&&(e.$parsers.push(function(e){return c(!0),e}),e.$formatters.push(function(e){return c(!0),e}),u())});e.$watchCollection("ngModel.$error",function(){c(!!e.ngModel)})}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t,r,n,i,a,s,l,c){return{scope:{schema:"=sfSchema",initialForm:"=sfForm",model:"=sfModel",options:"=sfOptions"},controller:["$scope",function(e){this.$onInit=function(){this.evalInParentScope=function(t,r){return e.$parent.$eval(t,r)};var t=this;e.lookup=function(e){return e&&(t.lookup=e),t.lookup}},1===o.a.version.major&&o.a.version.minor<5&&this.$onInit()}],replace:!1,restrict:"A",transclude:!0,require:"?form",link:function(l,u,f,d,p){l.formCtrl=d;var m={};p(l,function(e){if(e.addClass("schema-form-ignore"),u.prepend(e),u[0].querySelectorAll){var t=u[0].querySelectorAll("[ng-model]");if(t)for(var r=0;r<t.length;r++){var n=t[r].getAttribute("ng-model");m[n.substring(n.indexOf(".")+1)]=!0}}});var h,y={};l.resolveReferences=function(e,t){i.jsonref(e).then(function(e){l.render(e,t)}).catch(function(e){new Error(e)})},l.render=function(e,o){var a=[],s=i.merge(e,o,void 0,m,l.options,void 0,a);a.length>0?n.all(a.map(function(e){return t.get(e.templateUrl,{cache:r}).then(function(t){e.template=t.data})})).then(function(){l.internalRender(e,o,s)}):l.internalRender(e,o,s)},l.internalRender=function(t,r,n){h&&(l.externalDestructionInProgress=!0,h.$destroy(),l.externalDestructionInProgress=!1),h=l.$new(),h.schemaForm={form:n,schema:t},Array.prototype.forEach.call(u.children(),function(e){var t=o.a.element(e);!1===t.hasClass("schema-form-ignore")&&t.remove()});for(var d={},p=u[0].querySelectorAll("*[sf-insert-field]"),m=0;m<p.length;m++)d[p[m].getAttribute("sf-insert-field")]=p[m];var y=a.decorator(f.sfUseDecorator),v=Object.create(null);l.lookup(v),u[0].appendChild(c.build(n,y,d,v)),h.firstDigest=!0,setTimeout(function(){h.firstDigest=!1,l.$apply()},0),e(u.children())(h),l.options&&l.options.setSchemaDefaults===!1||i.traverseSchema(t,function(e,t){if(o.a.isDefined(e.default)){var r=s(t,l.model);o.a.isUndefined(r)&&s(t,l.model,e.default)}}),l.$emit("sf-render-finished",u)};var v=["*"];l.$watch(function(){var e=l.schema,t=l.initialForm||v;t&&e&&e.type&&(y.form!==t||y.schema!==e)&&((!e.properties||0===Object.keys(e.properties).length)&&(t.indexOf("*")||t.indexOf("...")),y.schema=e,y.form=t,l.resolveReferences(e,t))}),l.$on("schemaFormRedraw",function(){var e=l.schema,t=l.initialForm?o.a.copy(l.initialForm):["*"];e&&l.resolveReferences(e,t)}),l.$on("$destroy",function(){l.externalDestructionInProgress=!0}),l.evalExpr=function(e,t){return l.$parent.$eval(e,t)}}}}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(e,t){var r="",n={},i=function(e,t){"sfDecorator"===e&&(e=r);var o=n[e];return o[t.type]?o[t.type].template:o.default.template},a=function(r){e.directive(r,["$parse","$compile","$http","$templateCache","$interpolate","$q","sfErrorMessage","sfPath","sfSelect",function(e,n,a,s,l,c,u,f,d){return{restrict:"AE",replace:!1,transclude:!1,scope:!0,require:["?^sfSchema","?^form"],link:function(e,p,m,h){var y=h[0],v=h[1];e.$on("schemaFormPropagateNgModelController",function(t,r){t.stopPropagation(),t.preventDefault(),e.ngModel=r}),e.showTitle=function(){return e.form&&e.form.notitle!==!0&&e.form.title},e.fieldId=function(t,r){var n=e.parentKey||[];if(e.form.key){if("number"==typeof n[n.length-1]){var o=n.concat(e.form.key.slice(-1)),i=t&&v&&v.$name?v.$name:void 0;return f.name(o,"-",i,r)}var i=t&&v&&v.$name?v.$name:void 0;return f.name(e.form.key,"-",i,r)}return""},e.listToCheckboxValues=function(e){var t={};return o.a.forEach(e,function(e){t[e]=!0}),t},e.checkboxValuesToList=function(e){var t=[];return o.a.forEach(e,function(e,r){e&&t.push(r)}),t},e.buttonClick=function(t,r){o.a.isFunction(r.onClick)?r.onClick(t,r):o.a.isString(r.onClick)&&(y?y.evalInParentScope(r.onClick,{$event:t,form:r}):e.$eval(r.onClick,{$event:t,form:r}))},e.evalExpr=function(t,r){return y?y.evalInParentScope(t,r):e.$eval(t,r)},e.evalInScope=function(t,r){if(t)return e.$eval(t,r)},e.interp=function(e,t){return e&&l(e)(t)},e.hasSuccess=function(){return!!e.ngModel&&(e.options&&e.options.pristine&&e.options.pristine.success===!1?e.ngModel.$valid&&!e.ngModel.$pristine&&!e.ngModel.$isEmpty(e.ngModel.$modelValue):e.ngModel.$valid&&(!e.ngModel.$pristine||!e.ngModel.$isEmpty(e.ngModel.$modelValue)))},e.hasError=function(){return!!e.ngModel&&(e.ngModel.$invalid&&!e.ngModel.$pristine)},e.errorMessage=function(t){return u.interpolate(t&&t.code+""||"default",e.ngModel&&e.ngModel.$modelValue||"",e.ngModel&&e.ngModel.$viewValue||"",e.form,e.options&&e.options.validationMessage)};var g=e.$watch(m.form,function(l){if(l){l.ngModelOptions=l.ngModelOptions||{},e.form=l;var u;if("template"===l.type&&l.template)u=c.when(l.template);else{var m="template"===l.type?l.templateUrl:i(r,l);u=a.get(m,{cache:s}).then(function(e){return e.data})}u.then(function(r){if(l.key){var i=l.key?t.stringify(l.key).replace(/"/g,"&quot;"):"";r=r.replace(/\$\$value\$\$/g,"model"+("["!==i[0]?".":"")+i)}if(p.html(r),l.condition){var a='evalExpr(form.condition,{ model: model, "arrayIndex": arrayIndex})';l.key&&(a='evalExpr(form.condition, {model: model, "arrayIndex": arrayIndex, "modelValue": model'+f.stringify(l.key)+"})"),o.a.forEach(p.children(),function(e){var t=e.getAttribute("ng-if");e.setAttribute("ng-if",t?"("+t+") || ("+a+")":a)})}n(p.contents())(e)}),l.key&&(e.$on("schemaForm.error."+l.key.join("."),function(t,r,n,o,i){i=o,n!==!0&&n!==!1||(o=n,n=void 0),void 0!=i&&e.ngModel.$$parentForm.$name!==i||void 0!=i&&e.ngModel.$$parentForm.$name!==i||e.ngModel&&r&&(e.ngModel.$setDirty?e.ngModel.$setDirty():(e.ngModel.$dirty=!0,e.ngModel.$pristine=!1),n&&(l.validationMessage||(l.validationMessage={}),l.validationMessage[r]=n),e.ngModel.$setValidity(r,o===!0),o===!0&&(e.ngModel.$validate(),e.$broadcast("schemaFormValidate")))}),e.$on("$destroy",function(){if(!e.externalDestructionInProgress){var t=l.destroyStrategy||e.options&&e.options.destroyStrategy||"remove";if(l.key&&"retain"!==t){var r=e.model;if(l.key.length>1&&(r=d(l.key.slice(0,l.key.length-1),r)),void 0===r)return;var n=l.schema&&l.schema.type||"";"empty"===t&&n.indexOf("string")!==-1?r[l.key.slice(-1)]="":"empty"===t&&n.indexOf("object")!==-1?r[l.key.slice(-1)]={}:"empty"===t&&n.indexOf("array")!==-1?r[l.key.slice(-1)]=[]:"null"===t?r[l.key.slice(-1)]=null:delete r[l.key.slice(-1)]}}})),g()}})}}}])},s=function(t,r,n){
+n=!!o.a.isDefined(n)&&n,e.directive("sf"+o.a.uppercase(t[0])+t.substr(1),function(){return{restrict:"EAC",scope:!0,replace:!0,transclude:n,template:'<sf-decorator form="form"></sf-decorator>',link:function(e,r,n){var i={items:"c",titleMap:"c",schema:"c"},a={type:t},s=!0;o.a.forEach(n,function(t,r){if("$"!==r[0]&&0!==r.indexOf("ng")&&"sfField"!==r){var l=function(t){o.a.isDefined(t)&&t!==a[r]&&(a[r]=t,s&&a.type&&(a.key||o.a.isUndefined(n.key))&&(e.form=a,s=!1))};"model"===r?e.$watch(t,function(t){t&&e.model!==t&&(e.model=t)}):"c"===i[r]?e.$watchCollection(t,l):n.$observe(r,l)}})}}})};this.createDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){n[e][r]={template:t,replace:!1,builder:[]}}),n[r]||(r=e),a(e)},this.defineDecorator=function(e,t){n[e]={__name:e},o.a.forEach(t,function(t,r){t.builder=t.builder||[],t.replace=!o.a.isDefined(t.replace)||t.replace,n[e][r]=t}),n[r]||(r=e),a(e)},this.createDirective=s,this.createDirectives=function(e){o.a.forEach(e,function(e,t){s(t,e)})},this.decorator=function(e){return e=e||r,n[e]},this.addMapping=function(e,t,r,o,i){n[e]&&(n[e][t]={template:r,builder:o,replace:!!i})},this.defineAddOn=function(e,t,r,o){n[e]&&(n[e][t]={template:r,builder:o,replace:!0})},this.$get=function(){return{decorator:function(e){return n[e]||n[r]},defaultDecorator:r}},a("sfDecorator")}},function(e,t,r){"use strict";var n=r(0),o=(r.n(n),r(1));r.n(o);t.a=function(){var e=function(e){return e},t=o.schemaDefaults.createDefaults();this.defaults=t,this.stdFormObj=o.schemaDefaults.stdFormObj,this.defaultFormDefinition=o.schemaDefaults.defaultFormDefinition,this.postProcess=function(t){e=t},this.appendRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].push(t)},this.prependRule=function(e,t){this.defaults[e]||(this.defaults[e]=[]),this.defaults[e].unshift(t)},this.createStandardForm=o.schemaDefaults.stdFormObj,this.$get=function(){var t={},n=this.defaults;return t.jsonref=o.jsonref,t.defaults=function(e,t,r,i){var a=t||n;return o.schemaDefaults.defaultForm(e,a,r,i)},t.merge=function(n){var i=arguments.length>1&&void 0!==arguments[1]?arguments[1]:["*"],a=arguments.length>2&&void 0!==arguments[2]?arguments[2]:t.typeDefault,s=arguments[3],l=arguments.length>4&&void 0!==arguments[4]?arguments[4]:{},c=arguments.length>5&&void 0!==arguments[5]&&arguments[5],u=arguments[6],f=r.i(o.merge)(n,i,a,s,l,c,u);return e(f)},t.typeDefault=n,t.traverseSchema=o.traverseSchema,t.traverseForm=o.traverseForm,t}}},function(e,t,r){"use strict";t.a=function(e){var t=/[A-Z]/g,r=function(e,r){return r=r||"_",e.replace(t,function(e,t){return(t?r:"")+e.toLowerCase()})},n=0;"firstElementChild"in document.createDocumentFragment()||Object.defineProperty(DocumentFragment.prototype,"firstElementChild",{get:function(){for(var e,t=this.childNodes,r=0,n=t.length;r<n;++r)if(e=t[r],1===e.nodeType)return e;return null}});var o={sfField:function(e){e.fieldFrag.firstElementChild.setAttribute("sf-field",n),e.lookup["f"+n]=e.form,n++},ngModel:function(t){if(t.form.key){var r=t.form.key;t.state.keyRedaction&&(r=r.slice(t.state.keyRedaction));var n;if(t.state.modelValue)n=t.state.modelValue;else{var o=e.stringify(r).replace(/"/g,"&quot;");n=t.state.modelName||"model",o&&(n+=("["!==o[0]?".":"")+o)}for(var i=t.fieldFrag.querySelectorAll("[sf-field-model]"),a=0;a<i.length;a++){var s=i[a],l=s.getAttribute("sf-field-model");if(l&&""!==l)if("replaceAll"===l)for(var c=s.attributes,u=0;u<c.length;u++)c[u].value&&c[u].value.indexOf("$$value")!==-1&&(c[u].value=c[u].value.replace(/\$\$value\$\$/g,n));else{var f=s.getAttribute(l);f&&f.indexOf("$$value$$")?s.setAttribute(l,f.replace(/\$\$value\$\$/g,n)):s.setAttribute(l,n)}else s.setAttribute("ng-model",n)}}},simpleTransclusion:function(e){var t=e.build(e.form.items,e.path+".items",e.state);e.fieldFrag.firstChild.appendChild(t)},ngModelOptions:function(e){e.form.ngModelOptions&&Object.keys(e.form.ngModelOptions).length>0&&e.fieldFrag.firstChild.setAttribute("ng-model-options",JSON.stringify(e.form.ngModelOptions))},transclusion:function(e){var t=e.fieldFrag.querySelectorAll("[sf-field-transclude]");if(t.length)for(var r=0;r<t.length;r++){var n=t[r],o=n.getAttribute("sf-field-transclude")||"items",i=e.form[o];if(i){var a=e.build(i,e.path+"."+o,e.state);n.appendChild(a)}}},condition:function(t){var r="",n="undefined",o="";if(t.form.condition){t.form.key&&(r=e.stringify(t.form.key),n="model"+("["===r[0]?"":".")+r);for(var i="evalExpr("+t.path+'.condition, { model: model, "arrayIndex": $index, "arrayIndices": arrayIndices, "path": path, "$i": $i, "$index": $index, "modelValue": '+n+"})",a=t.fieldFrag.children||t.fieldFrag.childNodes,s=0;s<a.length;s++){var l=a[s];l.hasAttribute&&l.hasAttribute("ng-if")&&(o=l.getAttribute("ng-if")),l.setAttribute&&l.setAttribute("ng-if",o?"("+o+") || ("+i+")":i)}}},array:function(t){var r=t.fieldFrag.querySelector("[schema-form-array-items]");if(t.form.key){t.form.key.filter(function(e){return""===e}).length}if(r){var n=angular.copy(t.state);if(n.keyRedaction=0,n.keyRedaction+=t.form.key.length+1,t.form.schema&&t.form.schema.items&&t.form.schema.items.type&&t.form.schema.items.type.indexOf("object")===-1&&t.form.schema.items.type.indexOf("array")===-1){e.stringify(t.form.key).replace(/"/g,"&quot;")+"[$index]";n.modelValue="modelArray[$index]"}else n.modelName="item";n.arrayCompatFlag=!0;var o=t.build(t.form.items,t.path+".items",n);r.appendChild(o)}},numeric:function(e){var t=e.fieldFrag.querySelector("input"),r=e.form.maximum||!1,n=e.form.exclusiveMaximum||!1,o=e.form.minimum||!1,i=e.form.exclusiveMinimum||!1,a=e.form.multipleOf||!1;t&&(a!==!1&&t.setAttribute("step",a),r!==!1&&(n!==!1&&a!==!1&&(r-=a),t.setAttribute("max",r)),o!==!1&&(i!==!1&&a!==!1&&(o+=a),t.setAttribute("min",o)))}};this.builders=o;var i=[o.sfField,o.ngModel,o.ngModelOptions,o.condition];this.stdBuilders=i,this.$get=["$templateCache","schemaFormDecorators","sfPath",function(e,t,n){var a=function(e,t){if(e.key){var r=t[n.stringify(e.key)];if(r){for(;r.firstChild;)r.removeChild(r.firstChild);return r}}},s=function e(t,n,o,i,s,l,c){l=l||{},l=l||{},c=c||Object.create(null),s=s||"schemaForm.form";var u=document.createDocumentFragment();return t.reduce(function(t,u,f){if(!u.type)return t;var d=n[u.type]||n.default;if(d.replace){var p;l.arrayCompatFlag=!1;var m=document.createElement("div"),h=o(u,d)||o(u,n.default);for(m.innerHTML=h,p=document.createDocumentFragment();m.childNodes.length>0;)p.appendChild(m.childNodes[0]);var y={fieldFrag:p,form:u,lookup:c,state:l,path:s+"["+f+"]",build:function(t,r,a){return e(t,n,o,i,r,a,c)}},v=u.builder||d.builder;"function"==typeof v?v(y):v.forEach(function(e){e(y)}),(a(u,i)||t).appendChild(p)}else{var g=document.createElement(r(n.__name,"-"));l.arrayCompatFlag?g.setAttribute("form","copyWithIndex($index)"):g.setAttribute("form",s+"["+f+"]"),(a(u,i)||t).appendChild(g)}return t},u),u};return{build:function(t,r,n,o){return s(t,r,function(t,r){return"template"===t.type?t.template:e.get(r.template)},n,void 0,void 0,o)},builder:o,stdBuilders:i,internalBuild:s}}]}},function(e,t,r){"use strict";var n=r(0),o=r.n(n);t.a=function(){var e={default:"Field does not validate",0:"Invalid type, expected {{schema.type}}",1:"No enum match for: {{viewValue}}",10:'Data does not match any schemas from "anyOf"',11:'Data does not match any schemas from "oneOf"',12:'Data is valid against more than one schema from "oneOf"',13:'Data matches schema from "not"',100:"Value is not a multiple of {{schema.multipleOf}}",101:"{{viewValue}} is less than the allowed minimum of {{schema.minimum}}",102:"{{viewValue}} is equal to the exclusive minimum {{schema.minimum}}",103:"{{viewValue}} is greater than the allowed maximum of {{schema.maximum}}",104:"{{viewValue}} is equal to the exclusive maximum {{schema.maximum}}",105:"Value is not a valid number",200:"String is too short ({{viewValue.length}} chars), minimum {{schema.minLength}}",201:"String is too long ({{viewValue.length}} chars), maximum {{schema.maxLength}}",202:"String does not match pattern: {{schema.pattern}}",300:"Too few properties defined, minimum {{schema.minProperties}}",301:"Too many properties defined, maximum {{schema.maxProperties}}",302:"Required",303:"Additional properties not allowed",304:"Dependency failed - key must exist",400:"Array is too short ({{value.length}}), minimum {{schema.minItems}}",401:"Array is too long ({{value.length}}), maximum {{schema.maxItems}}",402:"Array items are not unique",403:"Additional items not allowed",500:"Format validation failed",501:'Keyword failed: "{{title}}"',600:"Circular $refs",1e3:"Unknown property (not in schema)"};e.number=e[105],e.required=e[302],e.min=e[101],e.max=e[103],e.maxlength=e[201],e.minlength=e[200],e.pattern=e[202],this.setDefaultMessages=function(t){e=t},this.getDefaultMessages=function(){return e},this.setDefaultMessage=function(t,r){e[t]=r},this.$get=["$interpolate",function(t){var r={};return r.defaultMessages=e,r.interpolate=function(r,n,i,a,s){s=s||{};var l=a.validationMessage||{};0===r.indexOf("tv4-")&&(r=r.substring(4));var c=l.default||s.default||"";[l,s,e].some(function(e){return o.a.isString(e)||o.a.isFunction(e)?(c=e,!0):e&&e[r]?(c=e[r],!0):void 0});var u={error:r,value:n,viewValue:i,form:a,schema:a.schema,title:a.title||a.schema&&a.schema.title};return o.a.isFunction(c)?c(u):t(c)(u)},r}]}},function(e,t,r){"use strict";function n(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var o=r(1),i=(r.n(o),r(0)),a=(r.n(i),function(){function e(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,n.key,n)}}return function(t,r,n){return r&&e(t.prototype,r),n&&e(t,n),t}}()),s=function(){function e(){n(this,e),this.name=o.sfPath.name,this.parse=o.sfPath.parse,this.stringify=o.sfPath.stringify,this.normalize=o.sfPath.normalize}return a(e,[{key:"$get",value:function(){return o.sfPath}}]),e}();t.a=s},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):y=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++y<t;)p&&p[y].run();y=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,y=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},function(e,t,r){(function(e,t){!function(e,r){"use strict";function n(e){"function"!=typeof e&&(e=new Function(""+e));for(var t=new Array(arguments.length-1),r=0;r<t.length;r++)t[r]=arguments[r+1];var n={callback:e,args:t};return h[m]=n,p(m),m++}function o(e){delete h[e]}function i(e){var t=e.callback,n=e.args;switch(n.length){case 0:t();break;case 1:t(n[0]);break;case 2:t(n[0],n[1]);break;case 3:t(n[0],n[1],n[2]);break;default:t.apply(r,n)}}function a(e){if(y)setTimeout(a,0,e);else{var t=h[e];if(t){y=!0;try{i(t)}finally{o(e),y=!1}}}}function s(){p=function(e){t.nextTick(function(){a(e)})}}function l(){if(e.postMessage&&!e.importScripts){var t=!0,r=e.onmessage;return e.onmessage=function(){t=!1},e.postMessage("","*"),e.onmessage=r,t}}function c(){var t="setImmediate$"+Math.random()+"$",r=function(r){r.source===e&&"string"==typeof r.data&&0===r.data.indexOf(t)&&a(+r.data.slice(t.length))};e.addEventListener?e.addEventListener("message",r,!1):e.attachEvent("onmessage",r),p=function(r){e.postMessage(t+r,"*")}}function u(){var e=new MessageChannel;e.port1.onmessage=function(e){var t=e.data;a(t)},p=function(t){e.port2.postMessage(t)}}function f(){var e=v.documentElement;p=function(t){var r=v.createElement("script");r.onreadystatechange=function(){a(t),r.onreadystatechange=null,e.removeChild(r),r=null},e.appendChild(r)}}function d(){p=function(e){setTimeout(a,0,e)}}if(!e.setImmediate){var p,m=1,h={},y=!1,v=e.document,g=Object.getPrototypeOf&&Object.getPrototypeOf(e);g=g&&g.setTimeout?g:e,"[object process]"==={}.toString.call(e.process)?s():l()?c():e.MessageChannel?u():v&&"onreadystatechange"in v.createElement("script")?f():d(),g.setImmediate=n,g.clearImmediate=o}}("undefined"==typeof self?"undefined"==typeof e?this:e:self)}).call(t,r(2),r(17))},function(r,n,o){function i(e,t){this._id=e,this._clearFn=t}var a=Function.prototype.apply;n.setTimeout=function(){return new i(a.call(setTimeout,window,arguments),clearTimeout)},n.setInterval=function(){return new i(a.call(setInterval,window,arguments),clearInterval)},n.clearTimeout=n.clearInterval=function(e){e&&e.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(window,this._id)},n.enroll=function(e,t){clearTimeout(e._idleTimeoutId),e._idleTimeout=t},n.unenroll=function(e){clearTimeout(e._idleTimeoutId),e._idleTimeout=-1},n._unrefActive=n.active=function(e){clearTimeout(e._idleTimeoutId);var t=e._idleTimeout;t>=0&&(e._idleTimeoutId=setTimeout(function(){e._onTimeout&&e._onTimeout()},t))},o(18),n.setImmediate=e,n.clearImmediate=t},,function(e,t,r){r(1),e.exports=r(4)}])}).call(t,r(1).setImmediate,r(1).clearImmediate)},function(e,t){function r(){throw new Error("setTimeout has not been defined")}function n(){throw new Error("clearTimeout has not been defined")}function o(e){if(u===setTimeout)return setTimeout(e,0);if((u===r||!u)&&setTimeout)return u=setTimeout,setTimeout(e,0);try{return u(e,0)}catch(t){try{return u.call(null,e,0)}catch(t){return u.call(this,e,0)}}}function i(e){if(f===clearTimeout)return clearTimeout(e);if((f===n||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(e);try{return f(e)}catch(t){try{return f.call(null,e)}catch(t){return f.call(this,e)}}}function a(){h&&p&&(h=!1,p.length?m=p.concat(m):y=-1,m.length&&s())}function s(){if(!h){var e=o(a);h=!0;for(var t=m.length;t;){for(p=m,m=[];++y<t;)p&&p[y].run();y=-1,t=m.length}p=null,h=!1,i(e)}}function l(e,t){this.fun=e,this.array=t}function c(){}var u,f,d=e.exports={};!function(){try{u="function"==typeof setTimeout?setTimeout:r}catch(e){u=r}try{f="function"==typeof clearTimeout?clearTimeout:n}catch(e){f=n}}();var p,m=[],h=!1,y=-1;d.nextTick=function(e){var t=new Array(arguments.length-1);if(arguments.length>1)for(var r=1;r<arguments.length;r++)t[r-1]=arguments[r];m.push(new l(e,t)),1!==m.length||h||o(s)},l.prototype.run=function(){this.fun.apply(null,this.array)},d.title="browser",d.browser=!0,d.env={},d.argv=[],d.version="",d.versions={},d.on=c,d.addListener=c,d.once=c,d.off=c,d.removeListener=c,d.removeAllListeners=c,d.emit=c,d.binding=function(e){throw new Error("process.binding is not supported")},d.cwd=function(){return"/"},d.chdir=function(e){throw new Error("process.chdir is not supported")},d.umask=function(){return 0}},,,function(e,t,r){r(19),e.exports=r(0)}]);
\ No newline at end of file
diff --git a/dist/angular-schema-form-bootstrap.js b/dist/angular-schema-form-bootstrap.js
index f2722c2..2aaa73d 100644
--- a/dist/angular-schema-form-bootstrap.js
+++ b/dist/angular-schema-form-bootstrap.js
@@ -1,7 +1,7 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.5
- * @date Thu, 20 Apr 2017 11:28:20 GMT
+ * @date Sat, 29 Apr 2017 14:49:38 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
@@ -130,7 +130,7 @@ module.exports = path;
 /***/ function(module, exports) {
 
 var path = '/bootstrap/fieldset.html';
-var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass + ' ' + idClass}}\" sf-key-controller sf-parent-key=\"[{{form.key.join('][')}}]\" sf-index=\"{{$index}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
+var html = "<fieldset ng-disabled=\"form.readonly\" class=\"schema-form-fieldset {{::form.htmlClass + ' ' + idClass}}\">\r\n  <legend ng-class=\"{'sr-only': !showTitle() }\">{{ form.title }}</legend>\r\n  <div class=\"help-block\" ng-show=\"form.description\" ng-bind-html=\"form.description\"></div>\r\n</fieldset>\r\n";
 window.angular.module('ng').run(['$templateCache', function(c) { c.put(path, html) }]);
 module.exports = path;
 
diff --git a/dist/angular-schema-form-bootstrap.min.js b/dist/angular-schema-form-bootstrap.min.js
index d24fe92..fbeaf02 100644
--- a/dist/angular-schema-form-bootstrap.min.js
+++ b/dist/angular-schema-form-bootstrap.min.js
@@ -1,9 +1,9 @@
 /*!
  * angular-schema-form-bootstrap
  * @version 1.0.0-alpha.5
- * @date Thu, 20 Apr 2017 11:28:20 GMT
+ * @date Sat, 29 Apr 2017 14:49:38 GMT
  * @link https://github.com/json-schema-form/angular-schema-form-bootstrap
  * @license MIT
  * Copyright (c) 2014-2017 JSON Schema Form
  */
-!function(r){function e(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return r[a].call(l.exports,l,l.exports,e),l.l=!0,l.exports}var n={};return e.m=r,e.c=n,e.i=function(r){return r},e.d=function(r,e,n){Object.defineProperty(r,e,{configurable:!1,enumerable:!0,get:n})},e.n=function(r){var n=r&&r.__esModule?function(){return r.default}:function(){return r};return e.d(n,"a",n),n},e.o=function(r,e){return Object.prototype.hasOwnProperty.call(r,e)},e.p="",e(e.s=24)}([function(r,e,n){n(18)},,function(r,e){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true &&  hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true &&  hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e,n){"use strict";function a(r,e,n,a,l){var s=n.builders.simpleTransclusion,i=n.builders.ngModelOptions,m=n.builders.ngModel,c=n.builders.sfField,p=n.builders.condition,h=n.builders.array,v=n.builders.numeric,x=function(r){if(r.form.tabs&&r.form.tabs.length>0){var e=r.fieldFrag.querySelector(".tab-content");r.form.tabs.forEach(function(n,a){var l="(evalExpr("+r.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=r.build(n.items,r.path+".tabs["+a+"].items",r.state);t.appendChild(s),e.appendChild(t)})}},C=function(r){if(r.form.placeholder){var e=r.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=r.form.placeholder,e.appendChild(n)}},w=[c,m,i,p];e.defineDecorator("bootstrapDecorator",{actions:{template:t.a,builder:w},array:{template:o.a,builder:[c,i,m,h,p]},button:{template:H.a,builder:w},checkbox:{template:d.a,builder:w},checkboxes:{template:f.a,builder:[c,i,m,h,p]},conditional:{template:A.a,builder:[c,s,p]},default:{template:u.a,builder:w},fieldset:{template:b.a,builder:[c,s,p]},help:{template:g.a,builder:w},number:{template:u.a,builder:w.concat(v)},password:{template:u.a,builder:w},radios:{template:$.a,builder:w},"radios-inline":{template:k.a,builder:w},radiobuttons:{template:y.a,builder:w},section:{template:A.a,builder:[c,s,p]},select:{template:E.a,builder:[C].concat(w)},submit:{template:H.a,builder:w},tabarray:{template:q.a,builder:[c,i,m,h,p]},tabs:{template:R.a,builder:[c,i,x,p]},textarea:{template:j.a,builder:w}},[])}var l=n(2),t=n.n(l),s=n(3),o=n.n(s),i=n(4),d=n.n(i),m=n(5),f=n.n(m),c=n(6),u=n.n(c),p=n(7),b=n.n(p),h=n(8),g=n.n(h),v=n(9),y=n.n(v),x=n(11),$=n.n(x),C=n(10),k=n.n(C),w=n(12),A=n.n(w),S=n(13),E=n.n(S),I=n(14),H=n.n(I),T=n(15),q=n.n(T),M=n(16),R=n.n(M),L=n(17),j=n.n(L);angular.module("schemaForm").config(a),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,,function(r,e,n){r.exports=n(0)}]);
\ No newline at end of file
+!function(r){function e(a){if(n[a])return n[a].exports;var l=n[a]={i:a,l:!1,exports:{}};return r[a].call(l.exports,l,l.exports,e),l.l=!0,l.exports}var n={};return e.m=r,e.c=n,e.i=function(r){return r},e.d=function(r,e,n){Object.defineProperty(r,e,{configurable:!1,enumerable:!0,get:n})},e.n=function(r){var n=r&&r.__esModule?function(){return r.default}:function(){return r};return e.d(n,"a",n),n},e.o=function(r,e){return Object.prototype.hasOwnProperty.call(r,e)},e.p="",e(e.s=24)}([function(r,e,n){n(18)},,function(r,e){var n="/bootstrap/actions.html",a='<div class="btn-group schema-form-actions {{::form.htmlClass + \' \' + idClass}}">\r\n  <input ng-repeat-start="item in form.items"\r\n         type="submit"\r\n         class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{item.title}}"\r\n         ng-if="item.type === \'submit\'">\r\n  <button ng-repeat-end\r\n          class="btn {{ item.style || \'btn-default\' }} {{::form.fieldHtmlClass}}"\r\n          type="button"\r\n          ng-disabled="form.readonly"\r\n          ng-if="item.type !== \'submit\'"\r\n          ng-click="buttonClick($event,item)"><span ng-if="item.icon" class="{{item.icon}}"></span>{{item.title}}</button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/array.html",a='<div  class="schema-form-array {{::form.htmlClass + \' \' + idClass}}"\r\n      sf-field-model="sf-new-array"\r\n      sf-new-array>\r\n  <label class="control-label" ng-show="showTitle()">{{ form.title }}</label>\r\n  <ol class="list-group" sf-field-model ui-sortable="form.sortOptions">\r\n    <li class="list-group-item {{::form.fieldHtmlClass}}"\r\n        sf-field-model="ng-repeat"\r\n        ng-repeat="item in $$value$$ track by $id(trackBy(item, $index))">\r\n      <button ng-hide="form.readonly || form.remove === null"\r\n              ng-click="deleteFromArray(item)"\r\n              ng-disabled="form.schema.minItems >= modelArray.length"\r\n              style="position: relative; z-index: 20;"\r\n              type="button" class="close pull-right">\r\n              <span aria-hidden="true">&times;</span><span class="sr-only">Close</span>\r\n      </button>\r\n      <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n    </li>\r\n  </ol>\r\n  <div class="clearfix" style="padding: 15px;" ng-model="modelArray" schema-validate="form">\r\n    <div class="help-block"\r\n         ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n         ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n\r\n    <button ng-hide="form.readonly || form.add === null"\r\n            ng-click="appendToArray()"\r\n            ng-disabled="form.schema.maxItems <= modelArray.length"\r\n            type="button"\r\n            class="btn {{ form.style.add || \'btn-default\' }} pull-right">\r\n      <i class="glyphicon glyphicon-plus"></i>\r\n      {{ form.add || \'Add\'}}\r\n    </button>\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/checkbox.html",a='<div class="checkbox schema-form-checkbox {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="{{::form.labelHtmlClass}}">\r\n    <input type="checkbox"\r\n           sf-changed="form"\r\n           ng-disabled="form.readonly"\r\n           sf-field-model\r\n           schema-validate="form"\r\n           class="{{::form.fieldHtmlClass}}"\r\n           name="{{::fieldId(true, false)}}">\r\n    <span ng-bind-html="form.title"></span>\r\n  </label>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/checkboxes.html",a='<div sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="form-group schema-form-checkboxes {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true &&  hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model\r\n         schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n\r\n  <div class="checkbox" ng-repeat="val in titleMapValues track by $index" >\r\n    <label>\r\n      <input type="checkbox"\r\n             ng-disabled="form.readonly"\r\n             sf-changed="form"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             ng-model="titleMapValues[$index]"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="form.titleMap[$index].name"></span>\r\n    </label>\r\n\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/default.html",a='<div class="form-group {{::form.htmlClass + \' schema-form-\' + form.type + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <input ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n         ng-show="::form.key"\r\n         type="{{::form.type}}"\r\n         step="any"\r\n         sf-changed="form"\r\n         placeholder="{{::form.placeholder}}"\r\n         class="form-control {{::form.fieldHtmlClass}}"\r\n         id="{{::fieldId(true, false)}}"\r\n         sf-field-model\r\n         ng-disabled="form.readonly"\r\n         schema-validate="form"\r\n         name="{{::fieldId(true, false)}}"\r\n         aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <input ng-show="::form.key"\r\n           type="{{::form.type}}"\r\n           step="any"\r\n           sf-changed="form"\r\n           placeholder="{{::form.placeholder}}"\r\n           class="form-control {{::form.fieldHtmlClass}}"\r\n           id="{{::fieldId(true, false)}}"\r\n           sf-field-model\r\n           ng-disabled="form.readonly"\r\n           schema-validate="form"\r\n           name="{{::fieldId(true, false)}}"\r\n           aria-describedby="{{::fieldId(true, true) + \'-status\'}}">\r\n\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span ng-if="form.feedback !== false"\r\n        class="form-control-feedback"\r\n        ng-class="evalInScope(form.feedback) || {\'glyphicon\': true, \'glyphicon-ok\': form.disableSuccessState !== true && hasSuccess(), \'glyphicon-remove\': form.disableErrorState !== true && hasError() }"\r\n        aria-hidden="true"></span>\r\n\r\n  <span ng-if="hasError() || hasSuccess()"\r\n        id="{{::fieldId(true, true) + \'-status\'}}"\r\n        class="sr-only">{{ hasSuccess() ? \'(success)\' : \'(error)\' }}</span>\r\n\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/fieldset.html",a='<fieldset ng-disabled="form.readonly" class="schema-form-fieldset {{::form.htmlClass + \' \' + idClass}}">\r\n  <legend ng-class="{\'sr-only\': !showTitle() }">{{ form.title }}</legend>\r\n  <div class="help-block" ng-show="form.description" ng-bind-html="form.description"></div>\r\n</fieldset>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/help.html",a='<div class="helpvalue schema-form-helpvalue {{::form.htmlClass + \' \' + idClass}}" ng-bind-html="form.helpvalue"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/radio-buttons.html",a='<div class="form-group schema-form-radiobuttons {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true &&  hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <div>\r\n    <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()">{{form.title}}</label>\r\n  </div>\r\n  <div class="btn-group">\r\n    <label sf-field-model="replaceAll" class="btn {{ (tm.value === $$value$$) ? form.style.selected || \'btn-default\' : form.style.unselected || \'btn-default\'; }}"\r\n           ng-class="{ active: tm.value === $$value$$ }"\r\n           ng-repeat="tm in form.titleMap">\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             style="display: none;"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             schema-validate="form"\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/radios-inline.html",a='<div class="form-group schema-form-radios-inline {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n        ng-show="showTitle()" sf-field-model\r\n        schema-validate="form" >{{form.title}}</label>\r\n  <div>\r\n      <label class="radio-inline" ng-repeat="tm in form.titleMap" >\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/radios.html",a='<div class="form-group schema-form-radios {{::form.htmlClass + \' \' + idClass}}"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true &&  hasError(),\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}"\r\n         sf-field-model schema-validate="form"\r\n         ng-show="showTitle()">{{form.title}}</label>\r\n  <div class="radio" ng-repeat="tm in form.titleMap">\r\n    <label>\r\n      <input type="radio"\r\n             class="{{::form.fieldHtmlClass}}"\r\n             sf-changed="form"\r\n             ng-disabled="form.readonly"\r\n             sf-field-model\r\n             ng-value="tm.value"\r\n             name="{{::fieldId(true, false)}}">\r\n      <span ng-bind-html="tm.name"></span>\r\n    </label>\r\n  </div>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/section.html",a='<div class="schema-form-section {{::form.htmlClass + \' \' + idClass}}" sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/select.html",a='<div class="form-group {{::form.htmlClass + \' \' + idClass}} schema-form-select"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-show="showTitle()" for="{{::fieldId(true, false)}}">\r\n    {{form.title}}\r\n  </label>\r\n  <select sf-field-model\r\n          id="{{::fieldId(true, false)}}"\r\n          ng-disabled="form.readonly"\r\n          sf-changed="form"\r\n          class="form-control {{::form.fieldHtmlClass}}"\r\n          schema-validate="form"\r\n          ng-options="item.value as item.name group by item.group for item in form.titleMap"\r\n          name="{{::fieldId(true, false)}}">\r\n  </select>\r\n  <div class="help-block" sf-message="form.description"></div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/submit.html",a='<div class="form-group schema-form-submit {{::form.htmlClass + \' \' + idClass}}">\r\n  <input type="submit"\r\n         class="btn {{ form.style || \'btn-primary\' }} {{::form.fieldHtmlClass}}"\r\n         value="{{form.title}}"\r\n         ng-disabled="form.readonly"\r\n         ng-if="form.type === \'submit\'">\r\n  <button class="btn {{ form.style || \'btn-default\' }}"\r\n          type="button"\r\n          ng-click="buttonClick($event,form)"\r\n          ng-disabled="form.readonly"\r\n          ng-if="form.type !== \'submit\'">\r\n      <span ng-if="form.icon" class="{{form.icon}}"></span>\r\n      {{form.title}}\r\n  </button>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/tabarray.html",a='<div ng-init="selected = { tab: 0 }"\r\n     ng-model="modelArray" schema-validate="form"\r\n     sf-field-model="sf-new-array"\r\n     sf-new-array\r\n     class="clearfix schema-form-tabarray schema-form-tabarray-{{form.tabType || \'left\'}} {{::form.htmlClass + \' \' + idClass}}">\r\n  <div ng-if="!form.tabType || form.tabType !== \'right\'"\r\n       ng-class="{\'col-xs-3\': !form.tabType || form.tabType === \'left\'}">\r\n    <ol class="nav nav-tabs"\r\n        ng-class="{ \'tabs-left\': !form.tabType || form.tabType === \'left\'}"\r\n        sf-field-model ui-sortable="form.sortOptions">\r\n      <li sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ol>\r\n  </div>\r\n\r\n  <div ng-class="{\'col-xs-9\': !form.tabType || form.tabType === \'left\' || form.tabType === \'right\'}">\r\n    <div class="tab-content {{::form.fieldHtmlClass}}">\r\n      <div class="tab-pane clearfix tab{{selected.tab}} index{{$index}}"\r\n           sf-field-model="ng-repeat"\r\n           ng-repeat="item in $$value$$ track by $index"\r\n           ng-show="selected.tab === $index"\r\n           ng-class="{active: selected.tab === $index}">\r\n\r\n           <div schema-form-array-items sf-key-controller sf-parent-key="[{{form.key.join(\'][\')}}]" sf-index="{{$index}}"></div>\r\n\r\n           <button ng-hide="form.readonly || form.remove === null"\r\n                   ng-click="selected.tab = deleteFromArray($index).length - 1"\r\n                   ng-disabled="form.schema.minItems >= modelArray.length"\r\n                   type="button"\r\n                   class="btn {{ form.style.remove || \'btn-default\' }} pull-right">\r\n             <i class="glyphicon glyphicon-trash"></i>\r\n             {{ form.remove || \'Remove\'}}\r\n           </button>\r\n      </div>\r\n      <div class="help-block"\r\n           ng-show="(hasError() && errorMessage(schemaError())) || form.description"\r\n           ng-bind-html="(hasError() && errorMessage(schemaError())) || form.description"></div>\r\n      </div>\r\n    </div>\r\n  </div>\r\n\r\n  <div ng-if="form.tabType === \'right\'" class="col-xs-3">\r\n    <ul class="nav nav-tabs tabs-right">\r\n      <li  sf-field-model="ng-repeat"\r\n          ng-repeat="item in $$value$$ track by $index"\r\n          ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n          ng-class="{active: selected.tab === $index}">\r\n          <a href="#">{{interp(form.title,{\'$index\':$index, value: item}) || $index}}</a>\r\n      </li>\r\n      <li ng-hide="form.readonly || form.add === null"\r\n          ng-disabled="form.schema.maxItems <= modelArray.length"\r\n          ng-click="$event.preventDefault() || (selected.tab = appendToArray().length - 1)">\r\n        <a href="#">\r\n          <i class="glyphicon glyphicon-plus"></i>\r\n          {{ form.add || \'Add\'}}\r\n          </a>\r\n      </li>\r\n    </ul>\r\n  </div>\r\n\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/tabs.html",a='<div ng-init="selected = { tab: 0 }" class="schema-form-tabs {{::form.htmlClass + \' \' + idClass}}">\r\n  <ul class="nav nav-tabs">\r\n    <li ng-repeat="tab in form.tabs"\r\n        ng-disabled="form.readonly"\r\n        ng-click="$event.preventDefault() || (selected.tab = $index)"\r\n        ng-class="{active: selected.tab === $index}">\r\n        <a href="#">{{ tab.title }}</a>\r\n    </li>\r\n  </ul>\r\n\r\n  <div class="tab-content {{::form.fieldHtmlClass}}">\r\n  </div>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e){var n="/bootstrap/textarea.html",a='<div class="form-group has-feedback {{::form.htmlClass + \' \' + idClass}} schema-form-textarea"\r\n     ng-class="{\r\n       \'has-error\': form.disableErrorState !== true && hasError(),\r\n       \'has-success\': form.disableSuccessState !== true && hasSuccess(),\r\n       \'has-feedback\': form.feedback !== false,\r\n       \'required\': form.required === true\r\n     }">\r\n  <label class="control-label {{::form.labelHtmlClass}}" ng-class="{\'sr-only\': !showTitle()}" for="{{::fieldId(true, false)}}">{{form.title}}</label>\r\n\r\n  <textarea ng-if="!form.fieldAddonLeft && !form.fieldAddonRight"\r\n            class="form-control {{::form.fieldHtmlClass}}"\r\n            id="{{::fieldId(true, false)}}"\r\n            sf-changed="form"\r\n            ng-attr-placeholder="{{::form.placeholder}}"\r\n            ng-disabled="form.readonly"\r\n            sf-field-model\r\n            schema-validate="form"\r\n            name="{{::fieldId(true, false)}}"></textarea>\r\n\r\n  <div ng-if="form.fieldAddonLeft || form.fieldAddonRight"\r\n       ng-class="{\'input-group\': (form.fieldAddonLeft || form.fieldAddonRight)}">\r\n    <span ng-if="form.fieldAddonLeft"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonLeft"></span>\r\n    <textarea class="form-control {{::form.fieldHtmlClass}}"\r\n              id="{{::fieldId(true, false)}}"\r\n              sf-changed="form"\r\n              ng-attr-placeholder="{{::form.placeholder}}"\r\n              ng-disabled="form.readonly"\r\n              sf-field-model\r\n              schema-validate="form"\r\n              name="{{::fieldId(true, false)}}"></textarea>\r\n    <span ng-if="form.fieldAddonRight"\r\n          class="input-group-addon"\r\n          ng-bind-html="form.fieldAddonRight"></span>\r\n  </div>\r\n\r\n  <span class="help-block" sf-message="form.description"></span>\r\n</div>\r\n';window.angular.module("ng").run(["$templateCache",function(r){r.put(n,a)}]),r.exports=n},function(r,e,n){"use strict";function a(r,e,n,a,l){var s=n.builders.simpleTransclusion,i=n.builders.ngModelOptions,m=n.builders.ngModel,c=n.builders.sfField,p=n.builders.condition,h=n.builders.array,v=n.builders.numeric,$=function(r){if(r.form.tabs&&r.form.tabs.length>0){var e=r.fieldFrag.querySelector(".tab-content");r.form.tabs.forEach(function(n,a){var l="(evalExpr("+r.path+".tabs["+a+'].condition, { model: model, "arrayIndex": $index}))',t=document.createElement("div");t.className="tab-pane",t.setAttribute("ng-disabled","form.readonly"),t.setAttribute("ng-show","selected.tab === "+a),t.setAttribute("ng-class","{active: selected.tab === "+a+"}"),n.condition&&t.setAttribute("ng-if",l);var s=r.build(n.items,r.path+".tabs["+a+"].items",r.state);t.appendChild(s),e.appendChild(t)})}},C=function(r){if(r.form.placeholder){var e=r.fieldFrag.querySelector("select"),n=document.createElement("option");n.setAttribute("value",""),n.setAttribute("sf-field-model","replaceAll"),1===angular.version.major&&angular.version.minor<4?n.setAttribute("ng-if","$$value$$ === undefined"):n.setAttribute("ng-show","$$value$$ === undefined"),n.textContent=r.form.placeholder,e.appendChild(n)}},w=[c,m,i,p];e.defineDecorator("bootstrapDecorator",{actions:{template:t.a,builder:w},array:{template:o.a,builder:[c,i,m,h,p]},button:{template:H.a,builder:w},checkbox:{template:d.a,builder:w},checkboxes:{template:f.a,builder:[c,i,m,h,p]},conditional:{template:A.a,builder:[c,s,p]},default:{template:u.a,builder:w},fieldset:{template:b.a,builder:[c,s,p]},help:{template:g.a,builder:w},number:{template:u.a,builder:w.concat(v)},password:{template:u.a,builder:w},radios:{template:x.a,builder:w},"radios-inline":{template:k.a,builder:w},radiobuttons:{template:y.a,builder:w},section:{template:A.a,builder:[c,s,p]},select:{template:E.a,builder:[C].concat(w)},submit:{template:H.a,builder:w},tabarray:{template:q.a,builder:[c,i,m,h,p]},tabs:{template:R.a,builder:[c,i,$,p]},textarea:{template:j.a,builder:w}},[])}var l=n(2),t=n.n(l),s=n(3),o=n.n(s),i=n(4),d=n.n(i),m=n(5),f=n.n(m),c=n(6),u=n.n(c),p=n(7),b=n.n(p),h=n(8),g=n.n(h),v=n(9),y=n.n(v),$=n(11),x=n.n($),C=n(10),k=n.n(C),w=n(12),A=n.n(w),S=n(13),E=n.n(S),I=n(14),H=n.n(I),T=n(15),q=n.n(T),M=n(16),R=n.n(M),L=n(17),j=n.n(L);angular.module("schemaForm").config(a),a.$inject=["schemaFormProvider","schemaFormDecoratorsProvider","sfBuilderProvider","sfPathProvider","$injector"]},,,,,,function(r,e,n){r.exports=n(0)}]);
\ No newline at end of file
