Bläddra i källkod

迁移校园资讯游览器客户端

nn 8 år sedan
incheckning
35a927ef98
100 ändrade filer med 33390 tillägg och 0 borttagningar
  1. BIN
      CampusInfo-borwers.exe
  2. 20 0
      LICENSE
  3. BIN
      blink_image_resources_200_percent.pak
  4. BIN
      content_resources_200_percent.pak
  5. BIN
      content_shell.pak
  6. BIN
      d3dcompiler_47.dll
  7. BIN
      ffmpeg.dll
  8. BIN
      icudtl.dat
  9. BIN
      libEGL.dll
  10. BIN
      libGLESv2.dll
  11. BIN
      locales/en-US.pak
  12. BIN
      locales/zh-CN.pak
  13. BIN
      msvcp140.dll
  14. 9674 0
      natives_blob.bin
  15. BIN
      node.dll
  16. BIN
      pdf_viewer_resources.pak
  17. 8 0
      resources/app/.idea/app.iml
  18. 8 0
      resources/app/.idea/modules.xml
  19. 1929 0
      resources/app/.idea/workspace.xml
  20. 62 0
      resources/app/browser.html
  21. 15 0
      resources/app/node_modules/.bin/asar
  22. 7 0
      resources/app/node_modules/.bin/asar.cmd
  23. 15 0
      resources/app/node_modules/.bin/decompress-zip
  24. 7 0
      resources/app/node_modules/.bin/decompress-zip.cmd
  25. 15 0
      resources/app/node_modules/.bin/electron
  26. 15 0
      resources/app/node_modules/.bin/electron-download
  27. 7 0
      resources/app/node_modules/.bin/electron-download.cmd
  28. 15 0
      resources/app/node_modules/.bin/electron-osx-flat
  29. 7 0
      resources/app/node_modules/.bin/electron-osx-flat.cmd
  30. 15 0
      resources/app/node_modules/.bin/electron-osx-sign
  31. 7 0
      resources/app/node_modules/.bin/electron-osx-sign.cmd
  32. 15 0
      resources/app/node_modules/.bin/electron-packager
  33. 7 0
      resources/app/node_modules/.bin/electron-packager.cmd
  34. 7 0
      resources/app/node_modules/.bin/electron.cmd
  35. 15 0
      resources/app/node_modules/.bin/extract-zip
  36. 7 0
      resources/app/node_modules/.bin/extract-zip.cmd
  37. 15 0
      resources/app/node_modules/.bin/mkdirp
  38. 7 0
      resources/app/node_modules/.bin/mkdirp.cmd
  39. 15 0
      resources/app/node_modules/.bin/nopt
  40. 7 0
      resources/app/node_modules/.bin/nopt.cmd
  41. 15 0
      resources/app/node_modules/.bin/nugget
  42. 7 0
      resources/app/node_modules/.bin/nugget.cmd
  43. 15 0
      resources/app/node_modules/.bin/pretty-bytes
  44. 7 0
      resources/app/node_modules/.bin/pretty-bytes.cmd
  45. 15 0
      resources/app/node_modules/.bin/rc
  46. 7 0
      resources/app/node_modules/.bin/rc.cmd
  47. 15 0
      resources/app/node_modules/.bin/rimraf
  48. 7 0
      resources/app/node_modules/.bin/rimraf.cmd
  49. 15 0
      resources/app/node_modules/.bin/semver
  50. 7 0
      resources/app/node_modules/.bin/semver.cmd
  51. 15 0
      resources/app/node_modules/.bin/sshpk-conv
  52. 7 0
      resources/app/node_modules/.bin/sshpk-conv.cmd
  53. 15 0
      resources/app/node_modules/.bin/sshpk-sign
  54. 7 0
      resources/app/node_modules/.bin/sshpk-sign.cmd
  55. 15 0
      resources/app/node_modules/.bin/sshpk-verify
  56. 7 0
      resources/app/node_modules/.bin/sshpk-verify.cmd
  57. 15 0
      resources/app/node_modules/.bin/strip-indent
  58. 7 0
      resources/app/node_modules/.bin/strip-indent.cmd
  59. 15 0
      resources/app/node_modules/.bin/uuid
  60. 7 0
      resources/app/node_modules/.bin/uuid.cmd
  61. 21 0
      resources/app/node_modules/@types/node/LICENSE
  62. 16 0
      resources/app/node_modules/@types/node/README.md
  63. 7186 0
      resources/app/node_modules/@types/node/index.d.ts
  64. 2488 0
      resources/app/node_modules/@types/node/inspector.d.ts
  65. 123 0
      resources/app/node_modules/@types/node/package.json
  66. 46 0
      resources/app/node_modules/abbrev/LICENSE
  67. 23 0
      resources/app/node_modules/abbrev/README.md
  68. 61 0
      resources/app/node_modules/abbrev/abbrev.js
  69. 61 0
      resources/app/node_modules/abbrev/package.json
  70. 20 0
      resources/app/node_modules/ajv/.tonic_example.js
  71. 22 0
      resources/app/node_modules/ajv/LICENSE
  72. 1327 0
      resources/app/node_modules/ajv/README.md
  73. 7345 0
      resources/app/node_modules/ajv/dist/ajv.bundle.js
  74. 3 0
      resources/app/node_modules/ajv/dist/ajv.min.js
  75. 1 0
      resources/app/node_modules/ajv/dist/ajv.min.js.map
  76. 2 0
      resources/app/node_modules/ajv/dist/nodent.min.js
  77. 2 0
      resources/app/node_modules/ajv/dist/regenerator.min.js
  78. 49 0
      resources/app/node_modules/ajv/lib/$data.js
  79. 358 0
      resources/app/node_modules/ajv/lib/ajv.d.ts
  80. 502 0
      resources/app/node_modules/ajv/lib/ajv.js
  81. 26 0
      resources/app/node_modules/ajv/lib/cache.js
  82. 31 0
      resources/app/node_modules/ajv/lib/compile/_rules.js
  83. 90 0
      resources/app/node_modules/ajv/lib/compile/async.js
  84. 3 0
      resources/app/node_modules/ajv/lib/compile/equal.js
  85. 34 0
      resources/app/node_modules/ajv/lib/compile/error_classes.js
  86. 135 0
      resources/app/node_modules/ajv/lib/compile/formats.js
  87. 380 0
      resources/app/node_modules/ajv/lib/compile/index.js
  88. 271 0
      resources/app/node_modules/ajv/lib/compile/resolve.js
  89. 58 0
      resources/app/node_modules/ajv/lib/compile/rules.js
  90. 9 0
      resources/app/node_modules/ajv/lib/compile/schema_obj.js
  91. 20 0
      resources/app/node_modules/ajv/lib/compile/ucs2length.js
  92. 267 0
      resources/app/node_modules/ajv/lib/compile/util.js
  93. 96 0
      resources/app/node_modules/ajv/lib/dot/_limit.jst
  94. 10 0
      resources/app/node_modules/ajv/lib/dot/_limitItems.jst
  95. 10 0
      resources/app/node_modules/ajv/lib/dot/_limitLength.jst
  96. 10 0
      resources/app/node_modules/ajv/lib/dot/_limitProperties.jst
  97. 34 0
      resources/app/node_modules/ajv/lib/dot/allOf.jst
  98. 48 0
      resources/app/node_modules/ajv/lib/dot/anyOf.jst
  99. 61 0
      resources/app/node_modules/ajv/lib/dot/coerce.def
  100. 0 0
      resources/app/node_modules/ajv/lib/dot/const.jst

BIN
CampusInfo-borwers.exe


+ 20 - 0
LICENSE

@@ -0,0 +1,20 @@
+Copyright (c) 2013-2017 GitHub Inc.
+
+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.

BIN
blink_image_resources_200_percent.pak


BIN
content_resources_200_percent.pak


BIN
content_shell.pak


BIN
d3dcompiler_47.dll


BIN
ffmpeg.dll


BIN
icudtl.dat


BIN
libEGL.dll


BIN
libGLESv2.dll


BIN
locales/en-US.pak


BIN
locales/zh-CN.pak


BIN
msvcp140.dll


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 9674 - 0
natives_blob.bin


BIN
node.dll


BIN
pdf_viewer_resources.pak


+ 8 - 0
resources/app/.idea/app.iml

@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<module type="WEB_MODULE" version="4">
+  <component name="NewModuleRootManager">
+    <content url="file://$MODULE_DIR$" />
+    <orderEntry type="inheritedJdk" />
+    <orderEntry type="sourceFolder" forTests="false" />
+  </component>
+</module>

+ 8 - 0
resources/app/.idea/modules.xml

@@ -0,0 +1,8 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<project version="4">
+  <component name="ProjectModuleManager">
+    <modules>
+      <module fileurl="file://$PROJECT_DIR$/.idea/app.iml" filepath="$PROJECT_DIR$/.idea/app.iml" />
+    </modules>
+  </component>
+</project>

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 1929 - 0
resources/app/.idea/workspace.xml


+ 62 - 0
resources/app/browser.html

@@ -0,0 +1,62 @@
+<!DOCTYPE html>
+<html lang="en">
+<head>
+    <meta charset="UTF-8">
+    <meta name="viewport" content="width=device-width, initial-scale=1.0">
+    <meta http-equiv="X-UA-Compatible" content="ie=edge">
+    <meta>
+    <title>Document</title>
+    <link rel="stylesheet" href="./public/css/uform.css">
+    <link rel="stylesheet" href="./public/css/browser.css">
+</head>
+<body>
+    <section style="-webkit-app-region: drag" class="bowerHeader">
+      <section style="-webkit-app-region: no-drag" class="bowerHeaderMenu clearfix">
+        <button type="button" style="display: none">max</button>
+        <button type="button" class="icon-minus"></button>
+        <button type="button" class="icon-cancel"></button>
+      </section>
+    </section>
+    <ul class="bowerCreaterWindow">
+        <button class="BrowwerAdd"></button>
+    </ul>
+    <ul class="bowerHeaderSeach" id="CampusInfoBrowserHeaderSeach">
+        <li onclick="CampusInfoBrowser.goBackWebView()"><span class="icon-left"></span></li>
+        <li onclick="CampusInfoBrowser.goForwardWebView()"><span class="icon-right"></span></li>
+        <li onclick="CampusInfoBrowser.reFresh()"><span class="refresh icon-ccw"></span></li>
+        <li class="bowerSeach">
+          <span class="icon-lock"></span>
+          <input type="text" placeholder="网址" id="seachInput">
+        </li>
+        <li class="bowerMenu" id="bowerMenu">
+          <span class="icon-menu"></span>
+        </li>
+    </ul>
+    <ul class="MouseMenuMain" id="CampusInfoBrowserMenu">
+        <li onclick="CampusInfoBrowser.MouseMenuCallBack.GoBack();">返回</li>
+        <li onclick="CampusInfoBrowser.MouseMenuCallBack.canGoForward();">前进</li>
+        <li onclick="CampusInfoBrowser.MouseMenuCallBack.reload();">重新加载</li>
+        <li class="MouseMenuMainStep"></li>
+        <li onclick="CampusInfoBrowser.MouseMenuCallBack.SaveAs();">另存为</li>
+        <li onclick="CampusInfoBrowser.MouseMenuCallBack.SourceCode();">查看源代码</li>
+        <li onclick="CampusInfoBrowser.MouseMenuCallBack.openDevToolsDown();">检查</li>
+    </ul>
+</body>
+<script src="./public/js/uform.js"></script>
+<script src="./public/js/browser.js"></script>
+<script>
+    const electron = require('electron');//electron主进程
+    const ipc = electron.ipcRenderer;//ipc命令集合
+    var bowerHeaderMenu=$(".bowerHeaderMenu button");
+    bowerHeaderMenu[0].addEventListener('click',function (){
+        ipc.send('window-max');
+    });
+    bowerHeaderMenu[1].addEventListener('click',function (){
+        ipc.send('window-min');
+    });
+    bowerHeaderMenu[2].addEventListener('click',function (){
+        ipc.send('window-close');
+    });
+    
+</script>
+</html>

+ 15 - 0
resources/app/node_modules/.bin/asar

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../asar/bin/asar.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../asar/bin/asar.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/asar.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\asar\bin\asar.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\asar\bin\asar.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/decompress-zip

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../decompress-zip/bin/decompress-zip" "$@"
+  ret=$?
+else 
+  node  "$basedir/../decompress-zip/bin/decompress-zip" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/decompress-zip.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\decompress-zip\bin\decompress-zip" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\decompress-zip\bin\decompress-zip" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/electron

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../electron/cli.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../electron/cli.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 15 - 0
resources/app/node_modules/.bin/electron-download

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../electron-download/lib/cli.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../electron-download/lib/cli.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/electron-download.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\electron-download\lib\cli.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\electron-download\lib\cli.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/electron-osx-flat

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../electron-osx-sign/bin/electron-osx-flat.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../electron-osx-sign/bin/electron-osx-flat.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/electron-osx-flat.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\electron-osx-sign\bin\electron-osx-flat.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\electron-osx-sign\bin\electron-osx-flat.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/electron-osx-sign

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../electron-osx-sign/bin/electron-osx-sign.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../electron-osx-sign/bin/electron-osx-sign.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/electron-osx-sign.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\electron-osx-sign\bin\electron-osx-sign.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\electron-osx-sign\bin\electron-osx-sign.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/electron-packager

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../electron-packager/cli.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../electron-packager/cli.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/electron-packager.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\electron-packager\cli.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\electron-packager\cli.js" %*
+)

+ 7 - 0
resources/app/node_modules/.bin/electron.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\electron\cli.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\electron\cli.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/extract-zip

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../extract-zip/cli.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../extract-zip/cli.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/extract-zip.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\extract-zip\cli.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\extract-zip\cli.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/mkdirp

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../mkdirp/bin/cmd.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../mkdirp/bin/cmd.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/mkdirp.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\mkdirp\bin\cmd.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\mkdirp\bin\cmd.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/nopt

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../nopt/bin/nopt.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../nopt/bin/nopt.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/nopt.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\nopt\bin\nopt.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\nopt\bin\nopt.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/nugget

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../nugget/bin.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../nugget/bin.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/nugget.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\nugget\bin.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\nugget\bin.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/pretty-bytes

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../pretty-bytes/cli.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../pretty-bytes/cli.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/pretty-bytes.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\pretty-bytes\cli.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\pretty-bytes\cli.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/rc

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../rc/cli.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../rc/cli.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/rc.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\rc\cli.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\rc\cli.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/rimraf

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../rimraf/bin.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../rimraf/bin.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/rimraf.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\rimraf\bin.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\rimraf\bin.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/semver

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../semver/bin/semver" "$@"
+  ret=$?
+else 
+  node  "$basedir/../semver/bin/semver" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/semver.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\semver\bin\semver" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\semver\bin\semver" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/sshpk-conv

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../sshpk/bin/sshpk-conv" "$@"
+  ret=$?
+else 
+  node  "$basedir/../sshpk/bin/sshpk-conv" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/sshpk-conv.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\sshpk\bin\sshpk-conv" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\sshpk\bin\sshpk-conv" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/sshpk-sign

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../sshpk/bin/sshpk-sign" "$@"
+  ret=$?
+else 
+  node  "$basedir/../sshpk/bin/sshpk-sign" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/sshpk-sign.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\sshpk\bin\sshpk-sign" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\sshpk\bin\sshpk-sign" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/sshpk-verify

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../sshpk/bin/sshpk-verify" "$@"
+  ret=$?
+else 
+  node  "$basedir/../sshpk/bin/sshpk-verify" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/sshpk-verify.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\sshpk\bin\sshpk-verify" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\sshpk\bin\sshpk-verify" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/strip-indent

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../strip-indent/cli.js" "$@"
+  ret=$?
+else 
+  node  "$basedir/../strip-indent/cli.js" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/strip-indent.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\strip-indent\cli.js" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\strip-indent\cli.js" %*
+)

+ 15 - 0
resources/app/node_modules/.bin/uuid

@@ -0,0 +1,15 @@
+#!/bin/sh
+basedir=$(dirname "$(echo "$0" | sed -e 's,\\,/,g')")
+
+case `uname` in
+    *CYGWIN*) basedir=`cygpath -w "$basedir"`;;
+esac
+
+if [ -x "$basedir/node" ]; then
+  "$basedir/node"  "$basedir/../uuid/bin/uuid" "$@"
+  ret=$?
+else 
+  node  "$basedir/../uuid/bin/uuid" "$@"
+  ret=$?
+fi
+exit $ret

+ 7 - 0
resources/app/node_modules/.bin/uuid.cmd

@@ -0,0 +1,7 @@
+@IF EXIST "%~dp0\node.exe" (
+  "%~dp0\node.exe"  "%~dp0\..\uuid\bin\uuid" %*
+) ELSE (
+  @SETLOCAL
+  @SET PATHEXT=%PATHEXT:;.JS;=;%
+  node  "%~dp0\..\uuid\bin\uuid" %*
+)

+ 21 - 0
resources/app/node_modules/@types/node/LICENSE

@@ -0,0 +1,21 @@
+    MIT License
+
+    Copyright (c) Microsoft Corporation. All rights reserved.
+
+    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

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 16 - 0
resources/app/node_modules/@types/node/README.md


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 7186 - 0
resources/app/node_modules/@types/node/index.d.ts


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 2488 - 0
resources/app/node_modules/@types/node/inspector.d.ts


+ 123 - 0
resources/app/node_modules/@types/node/package.json

@@ -0,0 +1,123 @@
+{
+  "_from": "@types/node@^8.0.24",
+  "_id": "@types/node@8.10.7",
+  "_inBundle": false,
+  "_integrity": "sha512-5QC0YAHH7aXzrrbgQ+faSeBKbJwTaUyYuaywYzDTr1Myz5C0knx5FHOV5QyhBeE1x8n2xfkBUGE/C0X1paLp+Q==",
+  "_location": "/@types/node",
+  "_phantomChildren": {},
+  "_requested": {
+    "type": "range",
+    "registry": true,
+    "raw": "@types/node@^8.0.24",
+    "name": "@types/node",
+    "escapedName": "@types%2fnode",
+    "scope": "@types",
+    "rawSpec": "^8.0.24",
+    "saveSpec": null,
+    "fetchSpec": "^8.0.24"
+  },
+  "_requiredBy": [
+    "/electron"
+  ],
+  "_resolved": "https://registry.npmjs.org/@types/node/-/node-8.10.7.tgz",
+  "_shasum": "40c0058c115bd42ee9bf35d7a217eeef1acd2716",
+  "_spec": "@types/node@^8.0.24",
+  "_where": "E:\\vscode\\UseStudio.Desktop\\resources\\app\\node_modules\\electron",
+  "bundleDependencies": false,
+  "contributors": [
+    {
+      "name": "Microsoft TypeScript",
+      "url": "http://typescriptlang.org"
+    },
+    {
+      "name": "DefinitelyTyped",
+      "url": "https://github.com/DefinitelyTyped/DefinitelyTyped"
+    },
+    {
+      "name": "Parambir Singh",
+      "url": "https://github.com/parambirs"
+    },
+    {
+      "name": "Christian Vaagland Tellnes",
+      "url": "https://github.com/tellnes"
+    },
+    {
+      "name": "Wilco Bakker",
+      "url": "https://github.com/WilcoBakker"
+    },
+    {
+      "name": "Nicolas Voigt",
+      "url": "https://github.com/octo-sniffle"
+    },
+    {
+      "name": "Chigozirim C.",
+      "url": "https://github.com/smac89"
+    },
+    {
+      "name": "Flarna",
+      "url": "https://github.com/Flarna"
+    },
+    {
+      "name": "Mariusz Wiktorczyk",
+      "url": "https://github.com/mwiktorczyk"
+    },
+    {
+      "name": "wwwy3y3",
+      "url": "https://github.com/wwwy3y3"
+    },
+    {
+      "name": "Deividas Bakanas",
+      "url": "https://github.com/DeividasBakanas"
+    },
+    {
+      "name": "Kelvin Jin",
+      "url": "https://github.com/kjin"
+    },
+    {
+      "name": "Alvis HT Tang",
+      "url": "https://github.com/alvis"
+    },
+    {
+      "name": "Oliver Joseph Ash",
+      "url": "https://github.com/OliverJAsh"
+    },
+    {
+      "name": "Sebastian Silbermann",
+      "url": "https://github.com/eps1lon"
+    },
+    {
+      "name": "Hannes Magnusson",
+      "url": "https://github.com/Hannes-Magnusson-CK"
+    },
+    {
+      "name": "Alberto Schiabel",
+      "url": "https://github.com/jkomyno"
+    },
+    {
+      "name": "Huw",
+      "url": "https://github.com/hoo29"
+    },
+    {
+      "name": "Nicolas Even",
+      "url": "https://github.com/n-e"
+    },
+    {
+      "name": "Hoàng Văn Khải",
+      "url": "https://github.com/KSXGitHub"
+    }
+  ],
+  "dependencies": {},
+  "deprecated": false,
+  "description": "TypeScript definitions for Node.js",
+  "license": "MIT",
+  "main": "",
+  "name": "@types/node",
+  "repository": {
+    "type": "git",
+    "url": "https://www.github.com/DefinitelyTyped/DefinitelyTyped.git"
+  },
+  "scripts": {},
+  "typeScriptVersion": "2.1",
+  "typesPublisherContentHash": "b58b6f23fe1dc8db77712c5c5d2037be72a7065b53b3ec95cd64421b3262f890",
+  "version": "8.10.7"
+}

+ 46 - 0
resources/app/node_modules/abbrev/LICENSE

@@ -0,0 +1,46 @@
+This software is dual-licensed under the ISC and MIT licenses.
+You may use this software under EITHER of the following licenses.
+
+----------
+
+The ISC License
+
+Copyright (c) Isaac Z. Schlueter and Contributors
+
+Permission to use, copy, modify, and/or distribute this software for any
+purpose with or without fee is hereby granted, provided that the above
+copyright notice and this permission notice appear in all copies.
+
+THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
+WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
+ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
+WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
+ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR
+IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
+
+----------
+
+Copyright Isaac Z. Schlueter and Contributors
+All rights reserved.
+
+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.

+ 23 - 0
resources/app/node_modules/abbrev/README.md

@@ -0,0 +1,23 @@
+# abbrev-js
+
+Just like [ruby's Abbrev](http://apidock.com/ruby/Abbrev).
+
+Usage:
+
+    var abbrev = require("abbrev");
+    abbrev("foo", "fool", "folding", "flop");
+    
+    // returns:
+    { fl: 'flop'
+    , flo: 'flop'
+    , flop: 'flop'
+    , fol: 'folding'
+    , fold: 'folding'
+    , foldi: 'folding'
+    , foldin: 'folding'
+    , folding: 'folding'
+    , foo: 'foo'
+    , fool: 'fool'
+    }
+
+This is handy for command-line scripts, or other cases where you want to be able to accept shorthands.

+ 61 - 0
resources/app/node_modules/abbrev/abbrev.js

@@ -0,0 +1,61 @@
+module.exports = exports = abbrev.abbrev = abbrev
+
+abbrev.monkeyPatch = monkeyPatch
+
+function monkeyPatch () {
+  Object.defineProperty(Array.prototype, 'abbrev', {
+    value: function () { return abbrev(this) },
+    enumerable: false, configurable: true, writable: true
+  })
+
+  Object.defineProperty(Object.prototype, 'abbrev', {
+    value: function () { return abbrev(Object.keys(this)) },
+    enumerable: false, configurable: true, writable: true
+  })
+}
+
+function abbrev (list) {
+  if (arguments.length !== 1 || !Array.isArray(list)) {
+    list = Array.prototype.slice.call(arguments, 0)
+  }
+  for (var i = 0, l = list.length, args = [] ; i < l ; i ++) {
+    args[i] = typeof list[i] === "string" ? list[i] : String(list[i])
+  }
+
+  // sort them lexicographically, so that they're next to their nearest kin
+  args = args.sort(lexSort)
+
+  // walk through each, seeing how much it has in common with the next and previous
+  var abbrevs = {}
+    , prev = ""
+  for (var i = 0, l = args.length ; i < l ; i ++) {
+    var current = args[i]
+      , next = args[i + 1] || ""
+      , nextMatches = true
+      , prevMatches = true
+    if (current === next) continue
+    for (var j = 0, cl = current.length ; j < cl ; j ++) {
+      var curChar = current.charAt(j)
+      nextMatches = nextMatches && curChar === next.charAt(j)
+      prevMatches = prevMatches && curChar === prev.charAt(j)
+      if (!nextMatches && !prevMatches) {
+        j ++
+        break
+      }
+    }
+    prev = current
+    if (j === cl) {
+      abbrevs[current] = current
+      continue
+    }
+    for (var a = current.substr(0, j) ; j <= cl ; j ++) {
+      abbrevs[a] = current
+      a += current.charAt(j)
+    }
+  }
+  return abbrevs
+}
+
+function lexSort (a, b) {
+  return a === b ? 0 : a > b ? 1 : -1
+}

+ 61 - 0
resources/app/node_modules/abbrev/package.json

@@ -0,0 +1,61 @@
+{
+  "_args": [
+    [
+      "abbrev@1.1.1",
+      "E:\\vscode\\UseStudio.Desktop\\resources\\app"
+    ]
+  ],
+  "_development": true,
+  "_from": "abbrev@1.1.1",
+  "_id": "abbrev@1.1.1",
+  "_inBundle": false,
+  "_integrity": "sha512-nne9/IiQ/hzIhY6pdDnbBtz7DjPTKrY00P/zvPSm5pOFkl6xuGrGnXn/VtTNNfNtAfZ9/1RtehkszU9qcTii0Q==",
+  "_location": "/abbrev",
+  "_phantomChildren": {},
+  "_requested": {
+    "type": "version",
+    "registry": true,
+    "raw": "abbrev@1.1.1",
+    "name": "abbrev",
+    "escapedName": "abbrev",
+    "rawSpec": "1.1.1",
+    "saveSpec": null,
+    "fetchSpec": "1.1.1"
+  },
+  "_requiredBy": [
+    "/nopt",
+    "/touch/nopt"
+  ],
+  "_resolved": "https://registry.npmjs.org/abbrev/-/abbrev-1.1.1.tgz",
+  "_spec": "1.1.1",
+  "_where": "E:\\vscode\\UseStudio.Desktop\\resources\\app",
+  "author": {
+    "name": "Isaac Z. Schlueter",
+    "email": "i@izs.me"
+  },
+  "bugs": {
+    "url": "https://github.com/isaacs/abbrev-js/issues"
+  },
+  "description": "Like ruby's abbrev module, but in js",
+  "devDependencies": {
+    "tap": "^10.1"
+  },
+  "files": [
+    "abbrev.js"
+  ],
+  "homepage": "https://github.com/isaacs/abbrev-js#readme",
+  "license": "ISC",
+  "main": "abbrev.js",
+  "name": "abbrev",
+  "repository": {
+    "type": "git",
+    "url": "git+ssh://git@github.com/isaacs/abbrev-js.git"
+  },
+  "scripts": {
+    "postpublish": "git push origin --all; git push origin --tags",
+    "postversion": "npm publish",
+    "preversion": "npm test",
+    "test": "tap test.js --100"
+  },
+  "version": "1.1.1"
+}

+ 20 - 0
resources/app/node_modules/ajv/.tonic_example.js

@@ -0,0 +1,20 @@
+var Ajv = require('ajv');
+var ajv = new Ajv({allErrors: true});
+
+var schema = {
+  "properties": {
+    "foo": { "type": "string" },
+    "bar": { "type": "number", "maximum": 3 }
+  }
+};
+
+var validate = ajv.compile(schema);
+
+test({"foo": "abc", "bar": 2});
+test({"foo": 2, "bar": 4});
+
+function test(data) {
+  var valid = validate(data);
+  if (valid) console.log('Valid!');
+  else console.log('Invalid: ' + ajv.errorsText(validate.errors));
+}

+ 22 - 0
resources/app/node_modules/ajv/LICENSE

@@ -0,0 +1,22 @@
+The MIT License (MIT)
+
+Copyright (c) 2015 Evgeny Poberezkin
+
+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.
+

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 1327 - 0
resources/app/node_modules/ajv/README.md


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 7345 - 0
resources/app/node_modules/ajv/dist/ajv.bundle.js


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 3 - 0
resources/app/node_modules/ajv/dist/ajv.min.js


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 1 - 0
resources/app/node_modules/ajv/dist/ajv.min.js.map


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 2 - 0
resources/app/node_modules/ajv/dist/nodent.min.js


Filskillnaden har hållts tillbaka eftersom den är för stor
+ 2 - 0
resources/app/node_modules/ajv/dist/regenerator.min.js


+ 49 - 0
resources/app/node_modules/ajv/lib/$data.js

@@ -0,0 +1,49 @@
+'use strict';
+
+var KEYWORDS = [
+  'multipleOf',
+  'maximum',
+  'exclusiveMaximum',
+  'minimum',
+  'exclusiveMinimum',
+  'maxLength',
+  'minLength',
+  'pattern',
+  'additionalItems',
+  'maxItems',
+  'minItems',
+  'uniqueItems',
+  'maxProperties',
+  'minProperties',
+  'required',
+  'additionalProperties',
+  'enum',
+  'format',
+  'const'
+];
+
+module.exports = function (metaSchema, keywordsJsonPointers) {
+  for (var i=0; i<keywordsJsonPointers.length; i++) {
+    metaSchema = JSON.parse(JSON.stringify(metaSchema));
+    var segments = keywordsJsonPointers[i].split('/');
+    var keywords = metaSchema;
+    var j;
+    for (j=1; j<segments.length; j++)
+      keywords = keywords[segments[j]];
+
+    for (j=0; j<KEYWORDS.length; j++) {
+      var key = KEYWORDS[j];
+      var schema = keywords[key];
+      if (schema) {
+        keywords[key] = {
+          anyOf: [
+            schema,
+            { $ref: 'https://raw.githubusercontent.com/epoberezkin/ajv/master/lib/refs/$data.json#' }
+          ]
+        };
+      }
+    }
+  }
+
+  return metaSchema;
+};

+ 358 - 0
resources/app/node_modules/ajv/lib/ajv.d.ts

@@ -0,0 +1,358 @@
+declare var ajv: { 
+  (options?: ajv.Options): ajv.Ajv;
+  new (options?: ajv.Options): ajv.Ajv;
+  ValidationError: ValidationError;
+  MissingRefError: MissingRefError;
+  $dataMetaSchema: object;
+}
+
+declare namespace ajv {
+  interface Ajv {
+    /**
+    * Validate data using schema
+    * Schema will be compiled and cached (using serialized JSON as key, [fast-json-stable-stringify](https://github.com/epoberezkin/fast-json-stable-stringify) is used to serialize by default).
+    * @param  {string|object|Boolean} schemaKeyRef key, ref or schema object
+    * @param  {Any} data to be validated
+    * @return {Boolean} validation result. Errors from the last validation will be available in `ajv.errors` (and also in compiled schema: `schema.errors`).
+    */
+    validate(schemaKeyRef: object | string | boolean, data: any): boolean | Thenable<any>;
+    /**
+    * Create validating function for passed schema.
+    * @param  {object|Boolean} schema schema object
+    * @return {Function} validating function
+    */
+    compile(schema: object | boolean): ValidateFunction;
+    /**
+    * Creates validating function for passed schema with asynchronous loading of missing schemas.
+    * `loadSchema` option should be a function that accepts schema uri and node-style callback.
+    * @this  Ajv
+    * @param {object|Boolean} schema schema object
+    * @param {Boolean} meta optional true to compile meta-schema; this parameter can be skipped
+    * @param {Function} callback optional node-style callback, it is always called with 2 parameters: error (or null) and validating function.
+    * @return {Thenable<ValidateFunction>} validating function
+    */
+    compileAsync(schema: object | boolean, meta?: Boolean, callback?: (err: Error, validate: ValidateFunction) => any): Thenable<ValidateFunction>;
+    /**
+    * Adds schema to the instance.
+    * @param {object|Array} schema schema or array of schemas. If array is passed, `key` and other parameters will be ignored.
+    * @param {string} key Optional schema key. Can be passed to `validate` method instead of schema object or id/ref. One schema per instance can have empty `id` and `key`.
+    * @return {Ajv} this for method chaining
+    */
+    addSchema(schema: Array<object> | object, key?: string): Ajv;
+    /**
+    * Add schema that will be used to validate other schemas
+    * options in META_IGNORE_OPTIONS are alway set to false
+    * @param {object} schema schema object
+    * @param {string} key optional schema key
+    * @return {Ajv} this for method chaining
+    */
+    addMetaSchema(schema: object, key?: string): Ajv;
+    /**
+    * Validate schema
+    * @param {object|Boolean} schema schema to validate
+    * @return {Boolean} true if schema is valid
+    */
+    validateSchema(schema: object | boolean): boolean;
+    /**
+    * Get compiled schema from the instance by `key` or `ref`.
+    * @param  {string} keyRef `key` that was passed to `addSchema` or full schema reference (`schema.id` or resolved id).
+    * @return {Function} schema validating function (with property `schema`).
+    */
+    getSchema(keyRef: string): ValidateFunction;
+    /**
+    * Remove cached schema(s).
+    * If no parameter is passed all schemas but meta-schemas are removed.
+    * If RegExp is passed all schemas with key/id matching pattern but meta-schemas are removed.
+    * Even if schema is referenced by other schemas it still can be removed as other schemas have local references.
+    * @param  {string|object|RegExp|Boolean} schemaKeyRef key, ref, pattern to match key/ref or schema object
+    * @return {Ajv} this for method chaining
+    */
+    removeSchema(schemaKeyRef?: object | string | RegExp | boolean): Ajv;
+    /**
+    * Add custom format
+    * @param {string} name format name
+    * @param {string|RegExp|Function} format string is converted to RegExp; function should return boolean (true when valid)
+    * @return {Ajv} this for method chaining
+    */
+    addFormat(name: string, format: FormatValidator | FormatDefinition): Ajv;
+    /**
+    * Define custom keyword
+    * @this  Ajv
+    * @param {string} keyword custom keyword, should be a valid identifier, should be different from all standard, custom and macro keywords.
+    * @param {object} definition keyword definition object with properties `type` (type(s) which the keyword applies to), `validate` or `compile`.
+    * @return {Ajv} this for method chaining
+    */
+    addKeyword(keyword: string, definition: KeywordDefinition): Ajv;
+    /**
+    * Get keyword definition
+    * @this  Ajv
+    * @param {string} keyword pre-defined or custom keyword.
+    * @return {object|Boolean} custom keyword definition, `true` if it is a predefined keyword, `false` otherwise.
+    */
+    getKeyword(keyword: string): object | boolean;
+    /**
+    * Remove keyword
+    * @this  Ajv
+    * @param {string} keyword pre-defined or custom keyword.
+    * @return {Ajv} this for method chaining
+    */
+    removeKeyword(keyword: string): Ajv;
+    /**
+    * Convert array of error message objects to string
+    * @param  {Array<object>} errors optional array of validation errors, if not passed errors from the instance are used.
+    * @param  {object} options optional options with properties `separator` and `dataVar`.
+    * @return {string} human readable string with all errors descriptions
+    */
+    errorsText(errors?: Array<ErrorObject>, options?: ErrorsTextOptions): string;
+    errors?: Array<ErrorObject>;
+  }
+
+  interface Thenable <R> {
+    then <U> (onFulfilled?: (value: R) => U | Thenable<U>, onRejected?: (error: any) => U | Thenable<U>): Thenable<U>;
+  }
+
+  interface ValidateFunction {
+    (
+      data: any,
+      dataPath?: string,
+      parentData?: object | Array<any>,
+      parentDataProperty?: string | number,
+      rootData?: object | Array<any>
+    ): boolean | Thenable<any>;
+    schema?: object | boolean;
+    errors?: null | Array<ErrorObject>;
+    refs?: object;
+    refVal?: Array<any>;
+    root?: ValidateFunction | object;
+    $async?: true;
+    source?: object;
+  }
+
+  interface Options {
+    $data?: boolean;
+    allErrors?: boolean;
+    verbose?: boolean;
+    jsonPointers?: boolean;
+    uniqueItems?: boolean;
+    unicode?: boolean;
+    format?: string;
+    formats?: object;
+    unknownFormats?: true | string[] | 'ignore';
+    schemas?: Array<object> | object;
+    schemaId?: '$id' | 'id';
+    missingRefs?: true | 'ignore' | 'fail';
+    extendRefs?: true | 'ignore' | 'fail';
+    loadSchema?: (uri: string, cb?: (err: Error, schema: object) => void) => Thenable<object | boolean>;
+    removeAdditional?: boolean | 'all' | 'failing';
+    useDefaults?: boolean | 'shared';
+    coerceTypes?: boolean | 'array';
+    async?: boolean | string;
+    transpile?: string | ((code: string) => string);
+    meta?: boolean | object;
+    validateSchema?: boolean | 'log';
+    addUsedSchema?: boolean;
+    inlineRefs?: boolean | number;
+    passContext?: boolean;
+    loopRequired?: number;
+    ownProperties?: boolean;
+    multipleOfPrecision?: boolean | number;
+    errorDataPath?: string,
+    messages?: boolean;
+    sourceCode?: boolean;
+    processCode?: (code: string) => string;
+    cache?: object;
+  }
+
+  type FormatValidator = string | RegExp | ((data: string) => boolean | Thenable<any>);
+
+  interface FormatDefinition {
+    validate: FormatValidator;
+    compare: (data1: string, data2: string) => number;
+    async?: boolean;
+  }
+
+  interface KeywordDefinition {
+    type?: string | Array<string>;
+    async?: boolean;
+    $data?: boolean;
+    errors?: boolean | string;
+    metaSchema?: object;
+    // schema: false makes validate not to expect schema (ValidateFunction)
+    schema?: boolean;
+    modifying?: boolean;
+    valid?: boolean;
+    // one and only one of the following properties should be present
+    validate?: SchemaValidateFunction | ValidateFunction;
+    compile?: (schema: any, parentSchema: object, it: CompilationContext) => ValidateFunction;
+    macro?: (schema: any, parentSchema: object, it: CompilationContext) => object | boolean;
+    inline?: (it: CompilationContext, keyword: string, schema: any, parentSchema: object) => string;
+  }
+
+  interface CompilationContext {
+    level: number;
+    dataLevel: number;
+    schema: any;
+    schemaPath: string;
+    baseId: string;
+    async: boolean;
+    opts: Options;
+    formats: {
+      [index: string]: FormatDefinition | undefined;
+    };
+    compositeRule: boolean;
+    validate: (schema: object) => boolean;
+    util: {
+      copy(obj: any, target?: any): any;
+      toHash(source: string[]): { [index: string]: true | undefined };
+      equal(obj: any, target: any): boolean;
+      getProperty(str: string): string;
+      schemaHasRules(schema: object, rules: any): string;
+      escapeQuotes(str: string): string;
+      toQuotedString(str: string): string;
+      getData(jsonPointer: string, dataLevel: number, paths: string[]): string;
+      escapeJsonPointer(str: string): string;
+      unescapeJsonPointer(str: string): string;
+      escapeFragment(str: string): string;
+      unescapeFragment(str: string): string;
+    };
+    self: Ajv;
+  }
+
+  interface SchemaValidateFunction {
+    (
+      schema: any,
+      data: any,
+      parentSchema?: object,
+      dataPath?: string,
+      parentData?: object | Array<any>,
+      parentDataProperty?: string | number,
+      rootData?: object | Array<any>
+    ): boolean | Thenable<any>;
+    errors?: Array<ErrorObject>;
+  }
+
+  interface ErrorsTextOptions {
+    separator?: string;
+    dataVar?: string;
+  }
+
+  interface ErrorObject {
+    keyword: string;
+    dataPath: string;
+    schemaPath: string;
+    params: ErrorParameters;
+    // Added to validation errors of propertyNames keyword schema
+    propertyName?: string;
+    // Excluded if messages set to false.
+    message?: string;
+    // These are added with the `verbose` option.
+    schema?: any;
+    parentSchema?: object;
+    data?: any;
+  }
+
+  type ErrorParameters = RefParams | LimitParams | AdditionalPropertiesParams |
+                          DependenciesParams | FormatParams | ComparisonParams |
+                          MultipleOfParams | PatternParams | RequiredParams |
+                          TypeParams | UniqueItemsParams | CustomParams |
+                          PatternGroupsParams | PatternRequiredParams |
+                          PropertyNamesParams | SwitchParams | NoParams | EnumParams;
+
+  interface RefParams {
+    ref: string;
+  }
+
+  interface LimitParams {
+    limit: number;
+  }
+
+  interface AdditionalPropertiesParams {
+    additionalProperty: string;
+  }
+
+  interface DependenciesParams {
+    property: string;
+    missingProperty: string;
+    depsCount: number;
+    deps: string;
+  }
+
+  interface FormatParams {
+    format: string
+  }
+
+  interface ComparisonParams {
+    comparison: string;
+    limit: number | string;
+    exclusive: boolean;
+  }
+
+  interface MultipleOfParams {
+    multipleOf: number;
+  }
+
+  interface PatternParams {
+    pattern: string;
+  }
+
+  interface RequiredParams {
+    missingProperty: string;
+  }
+
+  interface TypeParams {
+    type: string;
+  }
+
+  interface UniqueItemsParams {
+    i: number;
+    j: number;
+  }
+
+  interface CustomParams {
+    keyword: string;
+  }
+
+  interface PatternGroupsParams {
+    reason: string;
+    limit: number;
+    pattern: string;
+  }
+
+  interface PatternRequiredParams {
+    missingPattern: string;
+  }
+
+  interface PropertyNamesParams {
+    propertyName: string;
+  }
+
+  interface SwitchParams {
+    caseIndex: number;
+  }
+
+  interface NoParams {}
+
+  interface EnumParams {
+    allowedValues: Array<any>;
+  }
+}
+
+declare class ValidationError extends Error {
+  constructor(errors: Array<ajv.ErrorObject>);
+
+  message: string;
+  errors: Array<ajv.ErrorObject>;
+  ajv: true;
+  validation: true;
+}
+
+declare class MissingRefError extends Error {
+  constructor(baseId: string, ref: string, message?: string);
+  static message: (baseId: string, ref: string) => string;
+
+  message: string;
+  missingRef: string;
+  missingSchema: string;
+}
+
+export = ajv;

+ 502 - 0
resources/app/node_modules/ajv/lib/ajv.js

@@ -0,0 +1,502 @@
+'use strict';
+
+var compileSchema = require('./compile')
+  , resolve = require('./compile/resolve')
+  , Cache = require('./cache')
+  , SchemaObject = require('./compile/schema_obj')
+  , stableStringify = require('fast-json-stable-stringify')
+  , formats = require('./compile/formats')
+  , rules = require('./compile/rules')
+  , $dataMetaSchema = require('./$data')
+  , patternGroups = require('./patternGroups')
+  , util = require('./compile/util')
+  , co = require('co');
+
+module.exports = Ajv;
+
+Ajv.prototype.validate = validate;
+Ajv.prototype.compile = compile;
+Ajv.prototype.addSchema = addSchema;
+Ajv.prototype.addMetaSchema = addMetaSchema;
+Ajv.prototype.validateSchema = validateSchema;
+Ajv.prototype.getSchema = getSchema;
+Ajv.prototype.removeSchema = removeSchema;
+Ajv.prototype.addFormat = addFormat;
+Ajv.prototype.errorsText = errorsText;
+
+Ajv.prototype._addSchema = _addSchema;
+Ajv.prototype._compile = _compile;
+
+Ajv.prototype.compileAsync = require('./compile/async');
+var customKeyword = require('./keyword');
+Ajv.prototype.addKeyword = customKeyword.add;
+Ajv.prototype.getKeyword = customKeyword.get;
+Ajv.prototype.removeKeyword = customKeyword.remove;
+
+var errorClasses = require('./compile/error_classes');
+Ajv.ValidationError = errorClasses.Validation;
+Ajv.MissingRefError = errorClasses.MissingRef;
+Ajv.$dataMetaSchema = $dataMetaSchema;
+
+var META_SCHEMA_ID = 'http://json-schema.org/draft-06/schema';
+
+var META_IGNORE_OPTIONS = [ 'removeAdditional', 'useDefaults', 'coerceTypes' ];
+var META_SUPPORT_DATA = ['/properties'];
+
+/**
+ * Creates validator instance.
+ * Usage: `Ajv(opts)`
+ * @param {Object} opts optional options
+ * @return {Object} ajv instance
+ */
+function Ajv(opts) {
+  if (!(this instanceof Ajv)) return new Ajv(opts);
+  opts = this._opts = util.copy(opts) || {};
+  setLogger(this);
+  this._schemas = {};
+  this._refs = {};
+  this._fragments = {};
+  this._formats = formats(opts.format);
+  var schemaUriFormat = this._schemaUriFormat = this._formats['uri-reference'];
+  this._schemaUriFormatFunc = function (str) { return schemaUriFormat.test(str); };
+
+  this._cache = opts.cache || new Cache;
+  this._loadingSchemas = {};
+  this._compilations = [];
+  this.RULES = rules();
+  this._getId = chooseGetId(opts);
+
+  opts.loopRequired = opts.loopRequired || Infinity;
+  if (opts.errorDataPath == 'property') opts._errorDataPathProperty = true;
+  if (opts.serialize === undefined) opts.serialize = stableStringify;
+  this._metaOpts = getMetaSchemaOptions(this);
+
+  if (opts.formats) addInitialFormats(this);
+  addDraft6MetaSchema(this);
+  if (typeof opts.meta == 'object') this.addMetaSchema(opts.meta);
+  addInitialSchemas(this);
+  if (opts.patternGroups) patternGroups(this);
+}
+
+
+
+/**
+ * Validate data using schema
+ * Schema will be compiled and cached (using serialized JSON as key. [fast-json-stable-stringify](https://github.com/epoberezkin/fast-json-stable-stringify) is used to serialize.
+ * @this   Ajv
+ * @param  {String|Object} schemaKeyRef key, ref or schema object
+ * @param  {Any} data to be validated
+ * @return {Boolean} validation result. Errors from the last validation will be available in `ajv.errors` (and also in compiled schema: `schema.errors`).
+ */
+function validate(schemaKeyRef, data) {
+  var v;
+  if (typeof schemaKeyRef == 'string') {
+    v = this.getSchema(schemaKeyRef);
+    if (!v) throw new Error('no schema with key or ref "' + schemaKeyRef + '"');
+  } else {
+    var schemaObj = this._addSchema(schemaKeyRef);
+    v = schemaObj.validate || this._compile(schemaObj);
+  }
+
+  var valid = v(data);
+  if (v.$async === true)
+    return this._opts.async == '*' ? co(valid) : valid;
+  this.errors = v.errors;
+  return valid;
+}
+
+
+/**
+ * Create validating function for passed schema.
+ * @this   Ajv
+ * @param  {Object} schema schema object
+ * @param  {Boolean} _meta true if schema is a meta-schema. Used internally to compile meta schemas of custom keywords.
+ * @return {Function} validating function
+ */
+function compile(schema, _meta) {
+  var schemaObj = this._addSchema(schema, undefined, _meta);
+  return schemaObj.validate || this._compile(schemaObj);
+}
+
+
+/**
+ * Adds schema to the instance.
+ * @this   Ajv
+ * @param {Object|Array} schema schema or array of schemas. If array is passed, `key` and other parameters will be ignored.
+ * @param {String} key Optional schema key. Can be passed to `validate` method instead of schema object or id/ref. One schema per instance can have empty `id` and `key`.
+ * @param {Boolean} _skipValidation true to skip schema validation. Used internally, option validateSchema should be used instead.
+ * @param {Boolean} _meta true if schema is a meta-schema. Used internally, addMetaSchema should be used instead.
+ * @return {Ajv} this for method chaining
+ */
+function addSchema(schema, key, _skipValidation, _meta) {
+  if (Array.isArray(schema)){
+    for (var i=0; i<schema.length; i++) this.addSchema(schema[i], undefined, _skipValidation, _meta);
+    return this;
+  }
+  var id = this._getId(schema);
+  if (id !== undefined && typeof id != 'string')
+    throw new Error('schema id must be string');
+  key = resolve.normalizeId(key || id);
+  checkUnique(this, key);
+  this._schemas[key] = this._addSchema(schema, _skipValidation, _meta, true);
+  return this;
+}
+
+
+/**
+ * Add schema that will be used to validate other schemas
+ * options in META_IGNORE_OPTIONS are alway set to false
+ * @this   Ajv
+ * @param {Object} schema schema object
+ * @param {String} key optional schema key
+ * @param {Boolean} skipValidation true to skip schema validation, can be used to override validateSchema option for meta-schema
+ * @return {Ajv} this for method chaining
+ */
+function addMetaSchema(schema, key, skipValidation) {
+  this.addSchema(schema, key, skipValidation, true);
+  return this;
+}
+
+
+/**
+ * Validate schema
+ * @this   Ajv
+ * @param {Object} schema schema to validate
+ * @param {Boolean} throwOrLogError pass true to throw (or log) an error if invalid
+ * @return {Boolean} true if schema is valid
+ */
+function validateSchema(schema, throwOrLogError) {
+  var $schema = schema.$schema;
+  if ($schema !== undefined && typeof $schema != 'string')
+    throw new Error('$schema must be a string');
+  $schema = $schema || this._opts.defaultMeta || defaultMeta(this);
+  if (!$schema) {
+    this.logger.warn('meta-schema not available');
+    this.errors = null;
+    return true;
+  }
+  var currentUriFormat = this._formats.uri;
+  this._formats.uri = typeof currentUriFormat == 'function'
+                      ? this._schemaUriFormatFunc
+                      : this._schemaUriFormat;
+  var valid;
+  try { valid = this.validate($schema, schema); }
+  finally { this._formats.uri = currentUriFormat; }
+  if (!valid && throwOrLogError) {
+    var message = 'schema is invalid: ' + this.errorsText();
+    if (this._opts.validateSchema == 'log') this.logger.error(message);
+    else throw new Error(message);
+  }
+  return valid;
+}
+
+
+function defaultMeta(self) {
+  var meta = self._opts.meta;
+  self._opts.defaultMeta = typeof meta == 'object'
+                            ? self._getId(meta) || meta
+                            : self.getSchema(META_SCHEMA_ID)
+                              ? META_SCHEMA_ID
+                              : undefined;
+  return self._opts.defaultMeta;
+}
+
+
+/**
+ * Get compiled schema from the instance by `key` or `ref`.
+ * @this   Ajv
+ * @param  {String} keyRef `key` that was passed to `addSchema` or full schema reference (`schema.id` or resolved id).
+ * @return {Function} schema validating function (with property `schema`).
+ */
+function getSchema(keyRef) {
+  var schemaObj = _getSchemaObj(this, keyRef);
+  switch (typeof schemaObj) {
+    case 'object': return schemaObj.validate || this._compile(schemaObj);
+    case 'string': return this.getSchema(schemaObj);
+    case 'undefined': return _getSchemaFragment(this, keyRef);
+  }
+}
+
+
+function _getSchemaFragment(self, ref) {
+  var res = resolve.schema.call(self, { schema: {} }, ref);
+  if (res) {
+    var schema = res.schema
+      , root = res.root
+      , baseId = res.baseId;
+    var v = compileSchema.call(self, schema, root, undefined, baseId);
+    self._fragments[ref] = new SchemaObject({
+      ref: ref,
+      fragment: true,
+      schema: schema,
+      root: root,
+      baseId: baseId,
+      validate: v
+    });
+    return v;
+  }
+}
+
+
+function _getSchemaObj(self, keyRef) {
+  keyRef = resolve.normalizeId(keyRef);
+  return self._schemas[keyRef] || self._refs[keyRef] || self._fragments[keyRef];
+}
+
+
+/**
+ * Remove cached schema(s).
+ * If no parameter is passed all schemas but meta-schemas are removed.
+ * If RegExp is passed all schemas with key/id matching pattern but meta-schemas are removed.
+ * Even if schema is referenced by other schemas it still can be removed as other schemas have local references.
+ * @this   Ajv
+ * @param  {String|Object|RegExp} schemaKeyRef key, ref, pattern to match key/ref or schema object
+ * @return {Ajv} this for method chaining
+ */
+function removeSchema(schemaKeyRef) {
+  if (schemaKeyRef instanceof RegExp) {
+    _removeAllSchemas(this, this._schemas, schemaKeyRef);
+    _removeAllSchemas(this, this._refs, schemaKeyRef);
+    return this;
+  }
+  switch (typeof schemaKeyRef) {
+    case 'undefined':
+      _removeAllSchemas(this, this._schemas);
+      _removeAllSchemas(this, this._refs);
+      this._cache.clear();
+      return this;
+    case 'string':
+      var schemaObj = _getSchemaObj(this, schemaKeyRef);
+      if (schemaObj) this._cache.del(schemaObj.cacheKey);
+      delete this._schemas[schemaKeyRef];
+      delete this._refs[schemaKeyRef];
+      return this;
+    case 'object':
+      var serialize = this._opts.serialize;
+      var cacheKey = serialize ? serialize(schemaKeyRef) : schemaKeyRef;
+      this._cache.del(cacheKey);
+      var id = this._getId(schemaKeyRef);
+      if (id) {
+        id = resolve.normalizeId(id);
+        delete this._schemas[id];
+        delete this._refs[id];
+      }
+  }
+  return this;
+}
+
+
+function _removeAllSchemas(self, schemas, regex) {
+  for (var keyRef in schemas) {
+    var schemaObj = schemas[keyRef];
+    if (!schemaObj.meta && (!regex || regex.test(keyRef))) {
+      self._cache.del(schemaObj.cacheKey);
+      delete schemas[keyRef];
+    }
+  }
+}
+
+
+/* @this   Ajv */
+function _addSchema(schema, skipValidation, meta, shouldAddSchema) {
+  if (typeof schema != 'object' && typeof schema != 'boolean')
+    throw new Error('schema should be object or boolean');
+  var serialize = this._opts.serialize;
+  var cacheKey = serialize ? serialize(schema) : schema;
+  var cached = this._cache.get(cacheKey);
+  if (cached) return cached;
+
+  shouldAddSchema = shouldAddSchema || this._opts.addUsedSchema !== false;
+
+  var id = resolve.normalizeId(this._getId(schema));
+  if (id && shouldAddSchema) checkUnique(this, id);
+
+  var willValidate = this._opts.validateSchema !== false && !skipValidation;
+  var recursiveMeta;
+  if (willValidate && !(recursiveMeta = id && id == resolve.normalizeId(schema.$schema)))
+    this.validateSchema(schema, true);
+
+  var localRefs = resolve.ids.call(this, schema);
+
+  var schemaObj = new SchemaObject({
+    id: id,
+    schema: schema,
+    localRefs: localRefs,
+    cacheKey: cacheKey,
+    meta: meta
+  });
+
+  if (id[0] != '#' && shouldAddSchema) this._refs[id] = schemaObj;
+  this._cache.put(cacheKey, schemaObj);
+
+  if (willValidate && recursiveMeta) this.validateSchema(schema, true);
+
+  return schemaObj;
+}
+
+
+/* @this   Ajv */
+function _compile(schemaObj, root) {
+  if (schemaObj.compiling) {
+    schemaObj.validate = callValidate;
+    callValidate.schema = schemaObj.schema;
+    callValidate.errors = null;
+    callValidate.root = root ? root : callValidate;
+    if (schemaObj.schema.$async === true)
+      callValidate.$async = true;
+    return callValidate;
+  }
+  schemaObj.compiling = true;
+
+  var currentOpts;
+  if (schemaObj.meta) {
+    currentOpts = this._opts;
+    this._opts = this._metaOpts;
+  }
+
+  var v;
+  try { v = compileSchema.call(this, schemaObj.schema, root, schemaObj.localRefs); }
+  finally {
+    schemaObj.compiling = false;
+    if (schemaObj.meta) this._opts = currentOpts;
+  }
+
+  schemaObj.validate = v;
+  schemaObj.refs = v.refs;
+  schemaObj.refVal = v.refVal;
+  schemaObj.root = v.root;
+  return v;
+
+
+  function callValidate() {
+    var _validate = schemaObj.validate;
+    var result = _validate.apply(null, arguments);
+    callValidate.errors = _validate.errors;
+    return result;
+  }
+}
+
+
+function chooseGetId(opts) {
+  switch (opts.schemaId) {
+    case '$id': return _get$Id;
+    case 'id': return _getId;
+    default: return _get$IdOrId;
+  }
+}
+
+/* @this   Ajv */
+function _getId(schema) {
+  if (schema.$id) this.logger.warn('schema $id ignored', schema.$id);
+  return schema.id;
+}
+
+/* @this   Ajv */
+function _get$Id(schema) {
+  if (schema.id) this.logger.warn('schema id ignored', schema.id);
+  return schema.$id;
+}
+
+
+function _get$IdOrId(schema) {
+  if (schema.$id && schema.id && schema.$id != schema.id)
+    throw new Error('schema $id is different from id');
+  return schema.$id || schema.id;
+}
+
+
+/**
+ * Convert array of error message objects to string
+ * @this   Ajv
+ * @param  {Array<Object>} errors optional array of validation errors, if not passed errors from the instance are used.
+ * @param  {Object} options optional options with properties `separator` and `dataVar`.
+ * @return {String} human readable string with all errors descriptions
+ */
+function errorsText(errors, options) {
+  errors = errors || this.errors;
+  if (!errors) return 'No errors';
+  options = options || {};
+  var separator = options.separator === undefined ? ', ' : options.separator;
+  var dataVar = options.dataVar === undefined ? 'data' : options.dataVar;
+
+  var text = '';
+  for (var i=0; i<errors.length; i++) {
+    var e = errors[i];
+    if (e) text += dataVar + e.dataPath + ' ' + e.message + separator;
+  }
+  return text.slice(0, -separator.length);
+}
+
+
+/**
+ * Add custom format
+ * @this   Ajv
+ * @param {String} name format name
+ * @param {String|RegExp|Function} format string is converted to RegExp; function should return boolean (true when valid)
+ * @return {Ajv} this for method chaining
+ */
+function addFormat(name, format) {
+  if (typeof format == 'string') format = new RegExp(format);
+  this._formats[name] = format;
+  return this;
+}
+
+
+function addDraft6MetaSchema(self) {
+  var $dataSchema;
+  if (self._opts.$data) {
+    $dataSchema = require('./refs/$data.json');
+    self.addMetaSchema($dataSchema, $dataSchema.$id, true);
+  }
+  if (self._opts.meta === false) return;
+  var metaSchema = require('./refs/json-schema-draft-06.json');
+  if (self._opts.$data) metaSchema = $dataMetaSchema(metaSchema, META_SUPPORT_DATA);
+  self.addMetaSchema(metaSchema, META_SCHEMA_ID, true);
+  self._refs['http://json-schema.org/schema'] = META_SCHEMA_ID;
+}
+
+
+function addInitialSchemas(self) {
+  var optsSchemas = self._opts.schemas;
+  if (!optsSchemas) return;
+  if (Array.isArray(optsSchemas)) self.addSchema(optsSchemas);
+  else for (var key in optsSchemas) self.addSchema(optsSchemas[key], key);
+}
+
+
+function addInitialFormats(self) {
+  for (var name in self._opts.formats) {
+    var format = self._opts.formats[name];
+    self.addFormat(name, format);
+  }
+}
+
+
+function checkUnique(self, id) {
+  if (self._schemas[id] || self._refs[id])
+    throw new Error('schema with key or id "' + id + '" already exists');
+}
+
+
+function getMetaSchemaOptions(self) {
+  var metaOpts = util.copy(self._opts);
+  for (var i=0; i<META_IGNORE_OPTIONS.length; i++)
+    delete metaOpts[META_IGNORE_OPTIONS[i]];
+  return metaOpts;
+}
+
+
+function setLogger(self) {
+  var logger = self._opts.logger;
+  if (logger === false) {
+    self.logger = {log: noop, warn: noop, error: noop};
+  } else {
+    if (logger === undefined) logger = console;
+    if (!(typeof logger == 'object' && logger.log && logger.warn && logger.error))
+      throw new Error('logger must implement log, warn and error methods');
+    self.logger = logger;
+  }
+}
+
+
+function noop() {}

+ 26 - 0
resources/app/node_modules/ajv/lib/cache.js

@@ -0,0 +1,26 @@
+'use strict';
+
+
+var Cache = module.exports = function Cache() {
+  this._cache = {};
+};
+
+
+Cache.prototype.put = function Cache_put(key, value) {
+  this._cache[key] = value;
+};
+
+
+Cache.prototype.get = function Cache_get(key) {
+  return this._cache[key];
+};
+
+
+Cache.prototype.del = function Cache_del(key) {
+  delete this._cache[key];
+};
+
+
+Cache.prototype.clear = function Cache_clear() {
+  this._cache = {};
+};

+ 31 - 0
resources/app/node_modules/ajv/lib/compile/_rules.js

@@ -0,0 +1,31 @@
+'use strict';
+
+//all requires must be explicit because browserify won't work with dynamic requires
+module.exports = {
+  '$ref': require('../dotjs/ref'),
+  allOf: require('../dotjs/allOf'),
+  anyOf: require('../dotjs/anyOf'),
+  const: require('../dotjs/const'),
+  contains: require('../dotjs/contains'),
+  dependencies: require('../dotjs/dependencies'),
+  'enum': require('../dotjs/enum'),
+  format: require('../dotjs/format'),
+  items: require('../dotjs/items'),
+  maximum: require('../dotjs/_limit'),
+  minimum: require('../dotjs/_limit'),
+  maxItems: require('../dotjs/_limitItems'),
+  minItems: require('../dotjs/_limitItems'),
+  maxLength: require('../dotjs/_limitLength'),
+  minLength: require('../dotjs/_limitLength'),
+  maxProperties: require('../dotjs/_limitProperties'),
+  minProperties: require('../dotjs/_limitProperties'),
+  multipleOf: require('../dotjs/multipleOf'),
+  not: require('../dotjs/not'),
+  oneOf: require('../dotjs/oneOf'),
+  pattern: require('../dotjs/pattern'),
+  properties: require('../dotjs/properties'),
+  propertyNames: require('../dotjs/propertyNames'),
+  required: require('../dotjs/required'),
+  uniqueItems: require('../dotjs/uniqueItems'),
+  validate: require('../dotjs/validate')
+};

+ 90 - 0
resources/app/node_modules/ajv/lib/compile/async.js

@@ -0,0 +1,90 @@
+'use strict';
+
+var MissingRefError = require('./error_classes').MissingRef;
+
+module.exports = compileAsync;
+
+
+/**
+ * Creates validating function for passed schema with asynchronous loading of missing schemas.
+ * `loadSchema` option should be a function that accepts schema uri and returns promise that resolves with the schema.
+ * @this  Ajv
+ * @param {Object}   schema schema object
+ * @param {Boolean}  meta optional true to compile meta-schema; this parameter can be skipped
+ * @param {Function} callback an optional node-style callback, it is called with 2 parameters: error (or null) and validating function.
+ * @return {Promise} promise that resolves with a validating function.
+ */
+function compileAsync(schema, meta, callback) {
+  /* eslint no-shadow: 0 */
+  /* global Promise */
+  /* jshint validthis: true */
+  var self = this;
+  if (typeof this._opts.loadSchema != 'function')
+    throw new Error('options.loadSchema should be a function');
+
+  if (typeof meta == 'function') {
+    callback = meta;
+    meta = undefined;
+  }
+
+  var p = loadMetaSchemaOf(schema).then(function () {
+    var schemaObj = self._addSchema(schema, undefined, meta);
+    return schemaObj.validate || _compileAsync(schemaObj);
+  });
+
+  if (callback) {
+    p.then(
+      function(v) { callback(null, v); },
+      callback
+    );
+  }
+
+  return p;
+
+
+  function loadMetaSchemaOf(sch) {
+    var $schema = sch.$schema;
+    return $schema && !self.getSchema($schema)
+            ? compileAsync.call(self, { $ref: $schema }, true)
+            : Promise.resolve();
+  }
+
+
+  function _compileAsync(schemaObj) {
+    try { return self._compile(schemaObj); }
+    catch(e) {
+      if (e instanceof MissingRefError) return loadMissingSchema(e);
+      throw e;
+    }
+
+
+    function loadMissingSchema(e) {
+      var ref = e.missingSchema;
+      if (added(ref)) throw new Error('Schema ' + ref + ' is loaded but ' + e.missingRef + ' cannot be resolved');
+
+      var schemaPromise = self._loadingSchemas[ref];
+      if (!schemaPromise) {
+        schemaPromise = self._loadingSchemas[ref] = self._opts.loadSchema(ref);
+        schemaPromise.then(removePromise, removePromise);
+      }
+
+      return schemaPromise.then(function (sch) {
+        if (!added(ref)) {
+          return loadMetaSchemaOf(sch).then(function () {
+            if (!added(ref)) self.addSchema(sch, ref, undefined, meta);
+          });
+        }
+      }).then(function() {
+        return _compileAsync(schemaObj);
+      });
+
+      function removePromise() {
+        delete self._loadingSchemas[ref];
+      }
+
+      function added(ref) {
+        return self._refs[ref] || self._schemas[ref];
+      }
+    }
+  }
+}

+ 3 - 0
resources/app/node_modules/ajv/lib/compile/equal.js

@@ -0,0 +1,3 @@
+'use strict';
+
+module.exports = require('fast-deep-equal');

+ 34 - 0
resources/app/node_modules/ajv/lib/compile/error_classes.js

@@ -0,0 +1,34 @@
+'use strict';
+
+var resolve = require('./resolve');
+
+module.exports = {
+  Validation: errorSubclass(ValidationError),
+  MissingRef: errorSubclass(MissingRefError)
+};
+
+
+function ValidationError(errors) {
+  this.message = 'validation failed';
+  this.errors = errors;
+  this.ajv = this.validation = true;
+}
+
+
+MissingRefError.message = function (baseId, ref) {
+  return 'can\'t resolve reference ' + ref + ' from id ' + baseId;
+};
+
+
+function MissingRefError(baseId, ref, message) {
+  this.message = message || MissingRefError.message(baseId, ref);
+  this.missingRef = resolve.url(baseId, ref);
+  this.missingSchema = resolve.normalizeId(resolve.fullPath(this.missingRef));
+}
+
+
+function errorSubclass(Subclass) {
+  Subclass.prototype = Object.create(Error.prototype);
+  Subclass.prototype.constructor = Subclass;
+  return Subclass;
+}

Filskillnaden har hållts tillbaka eftersom den är för stor
+ 135 - 0
resources/app/node_modules/ajv/lib/compile/formats.js


+ 380 - 0
resources/app/node_modules/ajv/lib/compile/index.js

@@ -0,0 +1,380 @@
+'use strict';
+
+var resolve = require('./resolve')
+  , util = require('./util')
+  , errorClasses = require('./error_classes')
+  , stableStringify = require('fast-json-stable-stringify');
+
+var validateGenerator = require('../dotjs/validate');
+
+/**
+ * Functions below are used inside compiled validations function
+ */
+
+var co = require('co');
+var ucs2length = util.ucs2length;
+var equal = require('fast-deep-equal');
+
+// this error is thrown by async schemas to return validation errors via exception
+var ValidationError = errorClasses.Validation;
+
+module.exports = compile;
+
+
+/**
+ * Compiles schema to validation function
+ * @this   Ajv
+ * @param  {Object} schema schema object
+ * @param  {Object} root object with information about the root schema for this schema
+ * @param  {Object} localRefs the hash of local references inside the schema (created by resolve.id), used for inline resolution
+ * @param  {String} baseId base ID for IDs in the schema
+ * @return {Function} validation function
+ */
+function compile(schema, root, localRefs, baseId) {
+  /* jshint validthis: true, evil: true */
+  /* eslint no-shadow: 0 */
+  var self = this
+    , opts = this._opts
+    , refVal = [ undefined ]
+    , refs = {}
+    , patterns = []
+    , patternsHash = {}
+    , defaults = []
+    , defaultsHash = {}
+    , customRules = [];
+
+  root = root || { schema: schema, refVal: refVal, refs: refs };
+
+  var c = checkCompiling.call(this, schema, root, baseId);
+  var compilation = this._compilations[c.index];
+  if (c.compiling) return (compilation.callValidate = callValidate);
+
+  var formats = this._formats;
+  var RULES = this.RULES;
+
+  try {
+    var v = localCompile(schema, root, localRefs, baseId);
+    compilation.validate = v;
+    var cv = compilation.callValidate;
+    if (cv) {
+      cv.schema = v.schema;
+      cv.errors = null;
+      cv.refs = v.refs;
+      cv.refVal = v.refVal;
+      cv.root = v.root;
+      cv.$async = v.$async;
+      if (opts.sourceCode) cv.source = v.source;
+    }
+    return v;
+  } finally {
+    endCompiling.call(this, schema, root, baseId);
+  }
+
+  function callValidate() {
+    var validate = compilation.validate;
+    var result = validate.apply(null, arguments);
+    callValidate.errors = validate.errors;
+    return result;
+  }
+
+  function localCompile(_schema, _root, localRefs, baseId) {
+    var isRoot = !_root || (_root && _root.schema == _schema);
+    if (_root.schema != root.schema)
+      return compile.call(self, _schema, _root, localRefs, baseId);
+
+    var $async = _schema.$async === true;
+
+    var sourceCode = validateGenerator({
+      isTop: true,
+      schema: _schema,
+      isRoot: isRoot,
+      baseId: baseId,
+      root: _root,
+      schemaPath: '',
+      errSchemaPath: '#',
+      errorPath: '""',
+      MissingRefError: errorClasses.MissingRef,
+      RULES: RULES,
+      validate: validateGenerator,
+      util: util,
+      resolve: resolve,
+      resolveRef: resolveRef,
+      usePattern: usePattern,
+      useDefault: useDefault,
+      useCustomRule: useCustomRule,
+      opts: opts,
+      formats: formats,
+      logger: self.logger,
+      self: self
+    });
+
+    sourceCode = vars(refVal, refValCode) + vars(patterns, patternCode)
+                   + vars(defaults, defaultCode) + vars(customRules, customRuleCode)
+                   + sourceCode;
+
+    if (opts.processCode) sourceCode = opts.processCode(sourceCode);
+    // console.log('\n\n\n *** \n', JSON.stringify(sourceCode));
+    var validate;
+    try {
+      var makeValidate = new Function(
+        'self',
+        'RULES',
+        'formats',
+        'root',
+        'refVal',
+        'defaults',
+        'customRules',
+        'co',
+        'equal',
+        'ucs2length',
+        'ValidationError',
+        sourceCode
+      );
+
+      validate = makeValidate(
+        self,
+        RULES,
+        formats,
+        root,
+        refVal,
+        defaults,
+        customRules,
+        co,
+        equal,
+        ucs2length,
+        ValidationError
+      );
+
+      refVal[0] = validate;
+    } catch(e) {
+      self.logger.error('Error compiling schema, function code:', sourceCode);
+      throw e;
+    }
+
+    validate.schema = _schema;
+    validate.errors = null;
+    validate.refs = refs;
+    validate.refVal = refVal;
+    validate.root = isRoot ? validate : _root;
+    if ($async) validate.$async = true;
+    if (opts.sourceCode === true) {
+      validate.source = {
+        code: sourceCode,
+        patterns: patterns,
+        defaults: defaults
+      };
+    }
+
+    return validate;
+  }
+
+  function resolveRef(baseId, ref, isRoot) {
+    ref = resolve.url(baseId, ref);
+    var refIndex = refs[ref];
+    var _refVal, refCode;
+    if (refIndex !== undefined) {
+      _refVal = refVal[refIndex];
+      refCode = 'refVal[' + refIndex + ']';
+      return resolvedRef(_refVal, refCode);
+    }
+    if (!isRoot && root.refs) {
+      var rootRefId = root.refs[ref];
+      if (rootRefId !== undefined) {
+        _refVal = root.refVal[rootRefId];
+        refCode = addLocalRef(ref, _refVal);
+        return resolvedRef(_refVal, refCode);
+      }
+    }
+
+    refCode = addLocalRef(ref);
+    var v = resolve.call(self, localCompile, root, ref);
+    if (v === undefined) {
+      var localSchema = localRefs && localRefs[ref];
+      if (localSchema) {
+        v = resolve.inlineRef(localSchema, opts.inlineRefs)
+            ? localSchema
+            : compile.call(self, localSchema, root, localRefs, baseId);
+      }
+    }
+
+    if (v === undefined) {
+      removeLocalRef(ref);
+    } else {
+      replaceLocalRef(ref, v);
+      return resolvedRef(v, refCode);
+    }
+  }
+
+  function addLocalRef(ref, v) {
+    var refId = refVal.length;
+    refVal[refId] = v;
+    refs[ref] = refId;
+    return 'refVal' + refId;
+  }
+
+  function removeLocalRef(ref) {
+    delete refs[ref];
+  }
+
+  function replaceLocalRef(ref, v) {
+    var refId = refs[ref];
+    refVal[refId] = v;
+  }
+
+  function resolvedRef(refVal, code) {
+    return typeof refVal == 'object' || typeof refVal == 'boolean'
+            ? { code: code, schema: refVal, inline: true }
+            : { code: code, $async: refVal && refVal.$async };
+  }
+
+  function usePattern(regexStr) {
+    var index = patternsHash[regexStr];
+    if (index === undefined) {
+      index = patternsHash[regexStr] = patterns.length;
+      patterns[index] = regexStr;
+    }
+    return 'pattern' + index;
+  }
+
+  function useDefault(value) {
+    switch (typeof value) {
+      case 'boolean':
+      case 'number':
+        return '' + value;
+      case 'string':
+        return util.toQuotedString(value);
+      case 'object':
+        if (value === null) return 'null';
+        var valueStr = stableStringify(value);
+        var index = defaultsHash[valueStr];
+        if (index === undefined) {
+          index = defaultsHash[valueStr] = defaults.length;
+          defaults[index] = value;
+        }
+        return 'default' + index;
+    }
+  }
+
+  function useCustomRule(rule, schema, parentSchema, it) {
+    var validateSchema = rule.definition.validateSchema;
+    if (validateSchema && self._opts.validateSchema !== false) {
+      var valid = validateSchema(schema);
+      if (!valid) {
+        var message = 'keyword schema is invalid: ' + self.errorsText(validateSchema.errors);
+        if (self._opts.validateSchema == 'log') self.logger.error(message);
+        else throw new Error(message);
+      }
+    }
+
+    var compile = rule.definition.compile
+      , inline = rule.definition.inline
+      , macro = rule.definition.macro;
+
+    var validate;
+    if (compile) {
+      validate = compile.call(self, schema, parentSchema, it);
+    } else if (macro) {
+      validate = macro.call(self, schema, parentSchema, it);
+      if (opts.validateSchema !== false) self.validateSchema(validate, true);
+    } else if (inline) {
+      validate = inline.call(self, it, rule.keyword, schema, parentSchema);
+    } else {
+      validate = rule.definition.validate;
+      if (!validate) return;
+    }
+
+    if (validate === undefined)
+      throw new Error('custom keyword "' + rule.keyword + '"failed to compile');
+
+    var index = customRules.length;
+    customRules[index] = validate;
+
+    return {
+      code: 'customRule' + index,
+      validate: validate
+    };
+  }
+}
+
+
+/**
+ * Checks if the schema is currently compiled
+ * @this   Ajv
+ * @param  {Object} schema schema to compile
+ * @param  {Object} root root object
+ * @param  {String} baseId base schema ID
+ * @return {Object} object with properties "index" (compilation index) and "compiling" (boolean)
+ */
+function checkCompiling(schema, root, baseId) {
+  /* jshint validthis: true */
+  var index = compIndex.call(this, schema, root, baseId);
+  if (index >= 0) return { index: index, compiling: true };
+  index = this._compilations.length;
+  this._compilations[index] = {
+    schema: schema,
+    root: root,
+    baseId: baseId
+  };
+  return { index: index, compiling: false };
+}
+
+
+/**
+ * Removes the schema from the currently compiled list
+ * @this   Ajv
+ * @param  {Object} schema schema to compile
+ * @param  {Object} root root object
+ * @param  {String} baseId base schema ID
+ */
+function endCompiling(schema, root, baseId) {
+  /* jshint validthis: true */
+  var i = compIndex.call(this, schema, root, baseId);
+  if (i >= 0) this._compilations.splice(i, 1);
+}
+
+
+/**
+ * Index of schema compilation in the currently compiled list
+ * @this   Ajv
+ * @param  {Object} schema schema to compile
+ * @param  {Object} root root object
+ * @param  {String} baseId base schema ID
+ * @return {Integer} compilation index
+ */
+function compIndex(schema, root, baseId) {
+  /* jshint validthis: true */
+  for (var i=0; i<this._compilations.length; i++) {
+    var c = this._compilations[i];
+    if (c.schema == schema && c.root == root && c.baseId == baseId) return i;
+  }
+  return -1;
+}
+
+
+function patternCode(i, patterns) {
+  return 'var pattern' + i + ' = new RegExp(' + util.toQuotedString(patterns[i]) + ');';
+}
+
+
+function defaultCode(i) {
+  return 'var default' + i + ' = defaults[' + i + '];';
+}
+
+
+function refValCode(i, refVal) {
+  return refVal[i] === undefined ? '' : 'var refVal' + i + ' = refVal[' + i + '];';
+}
+
+
+function customRuleCode(i) {
+  return 'var customRule' + i + ' = customRules[' + i + '];';
+}
+
+
+function vars(arr, statement) {
+  if (!arr.length) return '';
+  var code = '';
+  for (var i=0; i<arr.length; i++)
+    code += statement(i, arr);
+  return code;
+}

+ 271 - 0
resources/app/node_modules/ajv/lib/compile/resolve.js

@@ -0,0 +1,271 @@
+'use strict';
+
+var url = require('url')
+  , equal = require('fast-deep-equal')
+  , util = require('./util')
+  , SchemaObject = require('./schema_obj')
+  , traverse = require('json-schema-traverse');
+
+module.exports = resolve;
+
+resolve.normalizeId = normalizeId;
+resolve.fullPath = getFullPath;
+resolve.url = resolveUrl;
+resolve.ids = resolveIds;
+resolve.inlineRef = inlineRef;
+resolve.schema = resolveSchema;
+
+/**
+ * [resolve and compile the references ($ref)]
+ * @this   Ajv
+ * @param  {Function} compile reference to schema compilation funciton (localCompile)
+ * @param  {Object} root object with information about the root schema for the current schema
+ * @param  {String} ref reference to resolve
+ * @return {Object|Function} schema object (if the schema can be inlined) or validation function
+ */
+function resolve(compile, root, ref) {
+  /* jshint validthis: true */
+  var refVal = this._refs[ref];
+  if (typeof refVal == 'string') {
+    if (this._refs[refVal]) refVal = this._refs[refVal];
+    else return resolve.call(this, compile, root, refVal);
+  }
+
+  refVal = refVal || this._schemas[ref];
+  if (refVal instanceof SchemaObject) {
+    return inlineRef(refVal.schema, this._opts.inlineRefs)
+            ? refVal.schema
+            : refVal.validate || this._compile(refVal);
+  }
+
+  var res = resolveSchema.call(this, root, ref);
+  var schema, v, baseId;
+  if (res) {
+    schema = res.schema;
+    root = res.root;
+    baseId = res.baseId;
+  }
+
+  if (schema instanceof SchemaObject) {
+    v = schema.validate || compile.call(this, schema.schema, root, undefined, baseId);
+  } else if (schema !== undefined) {
+    v = inlineRef(schema, this._opts.inlineRefs)
+        ? schema
+        : compile.call(this, schema, root, undefined, baseId);
+  }
+
+  return v;
+}
+
+
+/**
+ * Resolve schema, its root and baseId
+ * @this Ajv
+ * @param  {Object} root root object with properties schema, refVal, refs
+ * @param  {String} ref  reference to resolve
+ * @return {Object} object with properties schema, root, baseId
+ */
+function resolveSchema(root, ref) {
+  /* jshint validthis: true */
+  var p = url.parse(ref, false, true)
+    , refPath = _getFullPath(p)
+    , baseId = getFullPath(this._getId(root.schema));
+  if (refPath !== baseId) {
+    var id = normalizeId(refPath);
+    var refVal = this._refs[id];
+    if (typeof refVal == 'string') {
+      return resolveRecursive.call(this, root, refVal, p);
+    } else if (refVal instanceof SchemaObject) {
+      if (!refVal.validate) this._compile(refVal);
+      root = refVal;
+    } else {
+      refVal = this._schemas[id];
+      if (refVal instanceof SchemaObject) {
+        if (!refVal.validate) this._compile(refVal);
+        if (id == normalizeId(ref))
+          return { schema: refVal, root: root, baseId: baseId };
+        root = refVal;
+      } else {
+        return;
+      }
+    }
+    if (!root.schema) return;
+    baseId = getFullPath(this._getId(root.schema));
+  }
+  return getJsonPointer.call(this, p, baseId, root.schema, root);
+}
+
+
+/* @this Ajv */
+function resolveRecursive(root, ref, parsedRef) {
+  /* jshint validthis: true */
+  var res = resolveSchema.call(this, root, ref);
+  if (res) {
+    var schema = res.schema;
+    var baseId = res.baseId;
+    root = res.root;
+    var id = this._getId(schema);
+    if (id) baseId = resolveUrl(baseId, id);
+    return getJsonPointer.call(this, parsedRef, baseId, schema, root);
+  }
+}
+
+
+var PREVENT_SCOPE_CHANGE = util.toHash(['properties', 'patternProperties', 'enum', 'dependencies', 'definitions']);
+/* @this Ajv */
+function getJsonPointer(parsedRef, baseId, schema, root) {
+  /* jshint validthis: true */
+  parsedRef.hash = parsedRef.hash || '';
+  if (parsedRef.hash.slice(0,2) != '#/') return;
+  var parts = parsedRef.hash.split('/');
+
+  for (var i = 1; i < parts.length; i++) {
+    var part = parts[i];
+    if (part) {
+      part = util.unescapeFragment(part);
+      schema = schema[part];
+      if (schema === undefined) break;
+      var id;
+      if (!PREVENT_SCOPE_CHANGE[part]) {
+        id = this._getId(schema);
+        if (id) baseId = resolveUrl(baseId, id);
+        if (schema.$ref) {
+          var $ref = resolveUrl(baseId, schema.$ref);
+          var res = resolveSchema.call(this, root, $ref);
+          if (res) {
+            schema = res.schema;
+            root = res.root;
+            baseId = res.baseId;
+          }
+        }
+      }
+    }
+  }
+  if (schema !== undefined && schema !== root.schema)
+    return { schema: schema, root: root, baseId: baseId };
+}
+
+
+var SIMPLE_INLINED = util.toHash([
+  'type', 'format', 'pattern',
+  'maxLength', 'minLength',
+  'maxProperties', 'minProperties',
+  'maxItems', 'minItems',
+  'maximum', 'minimum',
+  'uniqueItems', 'multipleOf',
+  'required', 'enum'
+]);
+function inlineRef(schema, limit) {
+  if (limit === false) return false;
+  if (limit === undefined || limit === true) return checkNoRef(schema);
+  else if (limit) return countKeys(schema) <= limit;
+}
+
+
+function checkNoRef(schema) {
+  var item;
+  if (Array.isArray(schema)) {
+    for (var i=0; i<schema.length; i++) {
+      item = schema[i];
+      if (typeof item == 'object' && !checkNoRef(item)) return false;
+    }
+  } else {
+    for (var key in schema) {
+      if (key == '$ref') return false;
+      item = schema[key];
+      if (typeof item == 'object' && !checkNoRef(item)) return false;
+    }
+  }
+  return true;
+}
+
+
+function countKeys(schema) {
+  var count = 0, item;
+  if (Array.isArray(schema)) {
+    for (var i=0; i<schema.length; i++) {
+      item = schema[i];
+      if (typeof item == 'object') count += countKeys(item);
+      if (count == Infinity) return Infinity;
+    }
+  } else {
+    for (var key in schema) {
+      if (key == '$ref') return Infinity;
+      if (SIMPLE_INLINED[key]) {
+        count++;
+      } else {
+        item = schema[key];
+        if (typeof item == 'object') count += countKeys(item) + 1;
+        if (count == Infinity) return Infinity;
+      }
+    }
+  }
+  return count;
+}
+
+
+function getFullPath(id, normalize) {
+  if (normalize !== false) id = normalizeId(id);
+  var p = url.parse(id, false, true);
+  return _getFullPath(p);
+}
+
+
+function _getFullPath(p) {
+  var protocolSeparator = p.protocol || p.href.slice(0,2) == '//' ? '//' : '';
+  return (p.protocol||'') + protocolSeparator + (p.host||'') + (p.path||'')  + '#';
+}
+
+
+var TRAILING_SLASH_HASH = /#\/?$/;
+function normalizeId(id) {
+  return id ? id.replace(TRAILING_SLASH_HASH, '') : '';
+}
+
+
+function resolveUrl(baseId, id) {
+  id = normalizeId(id);
+  return url.resolve(baseId, id);
+}
+
+
+/* @this Ajv */
+function resolveIds(schema) {
+  var schemaId = normalizeId(this._getId(schema));
+  var baseIds = {'': schemaId};
+  var fullPaths = {'': getFullPath(schemaId, false)};
+  var localRefs = {};
+  var self = this;
+
+  traverse(schema, {allKeys: true}, function(sch, jsonPtr, rootSchema, parentJsonPtr, parentKeyword, parentSchema, keyIndex) {
+    if (jsonPtr === '') return;
+    var id = self._getId(sch);
+    var baseId = baseIds[parentJsonPtr];
+    var fullPath = fullPaths[parentJsonPtr] + '/' + parentKeyword;
+    if (keyIndex !== undefined)
+      fullPath += '/' + (typeof keyIndex == 'number' ? keyIndex : util.escapeFragment(keyIndex));
+
+    if (typeof id == 'string') {
+      id = baseId = normalizeId(baseId ? url.resolve(baseId, id) : id);
+
+      var refVal = self._refs[id];
+      if (typeof refVal == 'string') refVal = self._refs[refVal];
+      if (refVal && refVal.schema) {
+        if (!equal(sch, refVal.schema))
+          throw new Error('id "' + id + '" resolves to more than one schema');
+      } else if (id != normalizeId(fullPath)) {
+        if (id[0] == '#') {
+          if (localRefs[id] && !equal(sch, localRefs[id]))
+            throw new Error('id "' + id + '" resolves to more than one schema');
+          localRefs[id] = sch;
+        } else {
+          self._refs[id] = fullPath;
+        }
+      }
+    }
+    baseIds[jsonPtr] = baseId;
+    fullPaths[jsonPtr] = fullPath;
+  });
+
+  return localRefs;
+}

+ 58 - 0
resources/app/node_modules/ajv/lib/compile/rules.js

@@ -0,0 +1,58 @@
+'use strict';
+
+var ruleModules = require('./_rules')
+  , toHash = require('./util').toHash;
+
+module.exports = function rules() {
+  var RULES = [
+    { type: 'number',
+      rules: [ { 'maximum': ['exclusiveMaximum'] },
+               { 'minimum': ['exclusiveMinimum'] }, 'multipleOf', 'format'] },
+    { type: 'string',
+      rules: [ 'maxLength', 'minLength', 'pattern', 'format' ] },
+    { type: 'array',
+      rules: [ 'maxItems', 'minItems', 'uniqueItems', 'contains', 'items' ] },
+    { type: 'object',
+      rules: [ 'maxProperties', 'minProperties', 'required', 'dependencies', 'propertyNames',
+               { 'properties': ['additionalProperties', 'patternProperties'] } ] },
+    { rules: [ '$ref', 'const', 'enum', 'not', 'anyOf', 'oneOf', 'allOf' ] }
+  ];
+
+  var ALL = [ 'type' ];
+  var KEYWORDS = [
+    'additionalItems', '$schema', '$id', 'id', 'title',
+    'description', 'default', 'definitions'
+  ];
+  var TYPES = [ 'number', 'integer', 'string', 'array', 'object', 'boolean', 'null' ];
+  RULES.all = toHash(ALL);
+  RULES.types = toHash(TYPES);
+
+  RULES.forEach(function (group) {
+    group.rules = group.rules.map(function (keyword) {
+      var implKeywords;
+      if (typeof keyword == 'object') {
+        var key = Object.keys(keyword)[0];
+        implKeywords = keyword[key];
+        keyword = key;
+        implKeywords.forEach(function (k) {
+          ALL.push(k);
+          RULES.all[k] = true;
+        });
+      }
+      ALL.push(keyword);
+      var rule = RULES.all[keyword] = {
+        keyword: keyword,
+        code: ruleModules[keyword],
+        implements: implKeywords
+      };
+      return rule;
+    });
+
+    if (group.type) RULES.types[group.type] = group;
+  });
+
+  RULES.keywords = toHash(ALL.concat(KEYWORDS));
+  RULES.custom = {};
+
+  return RULES;
+};

+ 9 - 0
resources/app/node_modules/ajv/lib/compile/schema_obj.js

@@ -0,0 +1,9 @@
+'use strict';
+
+var util = require('./util');
+
+module.exports = SchemaObject;
+
+function SchemaObject(obj) {
+  util.copy(obj, this);
+}

+ 20 - 0
resources/app/node_modules/ajv/lib/compile/ucs2length.js

@@ -0,0 +1,20 @@
+'use strict';
+
+// https://mathiasbynens.be/notes/javascript-encoding
+// https://github.com/bestiejs/punycode.js - punycode.ucs2.decode
+module.exports = function ucs2length(str) {
+  var length = 0
+    , len = str.length
+    , pos = 0
+    , value;
+  while (pos < len) {
+    length++;
+    value = str.charCodeAt(pos++);
+    if (value >= 0xD800 && value <= 0xDBFF && pos < len) {
+      // high surrogate, and there is a next character
+      value = str.charCodeAt(pos);
+      if ((value & 0xFC00) == 0xDC00) pos++; // low surrogate
+    }
+  }
+  return length;
+};

+ 267 - 0
resources/app/node_modules/ajv/lib/compile/util.js

@@ -0,0 +1,267 @@
+'use strict';
+
+
+module.exports = {
+  copy: copy,
+  checkDataType: checkDataType,
+  checkDataTypes: checkDataTypes,
+  coerceToTypes: coerceToTypes,
+  toHash: toHash,
+  getProperty: getProperty,
+  escapeQuotes: escapeQuotes,
+  equal: require('fast-deep-equal'),
+  ucs2length: require('./ucs2length'),
+  varOccurences: varOccurences,
+  varReplace: varReplace,
+  cleanUpCode: cleanUpCode,
+  finalCleanUpCode: finalCleanUpCode,
+  schemaHasRules: schemaHasRules,
+  schemaHasRulesExcept: schemaHasRulesExcept,
+  toQuotedString: toQuotedString,
+  getPathExpr: getPathExpr,
+  getPath: getPath,
+  getData: getData,
+  unescapeFragment: unescapeFragment,
+  unescapeJsonPointer: unescapeJsonPointer,
+  escapeFragment: escapeFragment,
+  escapeJsonPointer: escapeJsonPointer
+};
+
+
+function copy(o, to) {
+  to = to || {};
+  for (var key in o) to[key] = o[key];
+  return to;
+}
+
+
+function checkDataType(dataType, data, negate) {
+  var EQUAL = negate ? ' !== ' : ' === '
+    , AND = negate ? ' || ' : ' && '
+    , OK = negate ? '!' : ''
+    , NOT = negate ? '' : '!';
+  switch (dataType) {
+    case 'null': return data + EQUAL + 'null';
+    case 'array': return OK + 'Array.isArray(' + data + ')';
+    case 'object': return '(' + OK + data + AND +
+                          'typeof ' + data + EQUAL + '"object"' + AND +
+                          NOT + 'Array.isArray(' + data + '))';
+    case 'integer': return '(typeof ' + data + EQUAL + '"number"' + AND +
+                           NOT + '(' + data + ' % 1)' +
+                           AND + data + EQUAL + data + ')';
+    default: return 'typeof ' + data + EQUAL + '"' + dataType + '"';
+  }
+}
+
+
+function checkDataTypes(dataTypes, data) {
+  switch (dataTypes.length) {
+    case 1: return checkDataType(dataTypes[0], data, true);
+    default:
+      var code = '';
+      var types = toHash(dataTypes);
+      if (types.array && types.object) {
+        code = types.null ? '(': '(!' + data + ' || ';
+        code += 'typeof ' + data + ' !== "object")';
+        delete types.null;
+        delete types.array;
+        delete types.object;
+      }
+      if (types.number) delete types.integer;
+      for (var t in types)
+        code += (code ? ' && ' : '' ) + checkDataType(t, data, true);
+
+      return code;
+  }
+}
+
+
+var COERCE_TO_TYPES = toHash([ 'string', 'number', 'integer', 'boolean', 'null' ]);
+function coerceToTypes(optionCoerceTypes, dataTypes) {
+  if (Array.isArray(dataTypes)) {
+    var types = [];
+    for (var i=0; i<dataTypes.length; i++) {
+      var t = dataTypes[i];
+      if (COERCE_TO_TYPES[t]) types[types.length] = t;
+      else if (optionCoerceTypes === 'array' && t === 'array') types[types.length] = t;
+    }
+    if (types.length) return types;
+  } else if (COERCE_TO_TYPES[dataTypes]) {
+    return [dataTypes];
+  } else if (optionCoerceTypes === 'array' && dataTypes === 'array') {
+    return ['array'];
+  }
+}
+
+
+function toHash(arr) {
+  var hash = {};
+  for (var i=0; i<arr.length; i++) hash[arr[i]] = true;
+  return hash;
+}
+
+
+var IDENTIFIER = /^[a-z$_][a-z$_0-9]*$/i;
+var SINGLE_QUOTE = /'|\\/g;
+function getProperty(key) {
+  return typeof key == 'number'
+          ? '[' + key + ']'
+          : IDENTIFIER.test(key)
+            ? '.' + key
+            : "['" + escapeQuotes(key) + "']";
+}
+
+
+function escapeQuotes(str) {
+  return str.replace(SINGLE_QUOTE, '\\$&')
+            .replace(/\n/g, '\\n')
+            .replace(/\r/g, '\\r')
+            .replace(/\f/g, '\\f')
+            .replace(/\t/g, '\\t');
+}
+
+
+function varOccurences(str, dataVar) {
+  dataVar += '[^0-9]';
+  var matches = str.match(new RegExp(dataVar, 'g'));
+  return matches ? matches.length : 0;
+}
+
+
+function varReplace(str, dataVar, expr) {
+  dataVar += '([^0-9])';
+  expr = expr.replace(/\$/g, '$$$$');
+  return str.replace(new RegExp(dataVar, 'g'), expr + '$1');
+}
+
+
+var EMPTY_ELSE = /else\s*{\s*}/g
+  , EMPTY_IF_NO_ELSE = /if\s*\([^)]+\)\s*\{\s*\}(?!\s*else)/g
+  , EMPTY_IF_WITH_ELSE = /if\s*\(([^)]+)\)\s*\{\s*\}\s*else(?!\s*if)/g;
+function cleanUpCode(out) {
+  return out.replace(EMPTY_ELSE, '')
+            .replace(EMPTY_IF_NO_ELSE, '')
+            .replace(EMPTY_IF_WITH_ELSE, 'if (!($1))');
+}
+
+
+var ERRORS_REGEXP = /[^v.]errors/g
+  , REMOVE_ERRORS = /var errors = 0;|var vErrors = null;|validate.errors = vErrors;/g
+  , REMOVE_ERRORS_ASYNC = /var errors = 0;|var vErrors = null;/g
+  , RETURN_VALID = 'return errors === 0;'
+  , RETURN_TRUE = 'validate.errors = null; return true;'
+  , RETURN_ASYNC = /if \(errors === 0\) return data;\s*else throw new ValidationError\(vErrors\);/
+  , RETURN_DATA_ASYNC = 'return data;'
+  , ROOTDATA_REGEXP = /[^A-Za-z_$]rootData[^A-Za-z0-9_$]/g
+  , REMOVE_ROOTDATA = /if \(rootData === undefined\) rootData = data;/;
+
+function finalCleanUpCode(out, async) {
+  var matches = out.match(ERRORS_REGEXP);
+  if (matches && matches.length == 2) {
+    out = async
+          ? out.replace(REMOVE_ERRORS_ASYNC, '')
+               .replace(RETURN_ASYNC, RETURN_DATA_ASYNC)
+          : out.replace(REMOVE_ERRORS, '')
+               .replace(RETURN_VALID, RETURN_TRUE);
+  }
+
+  matches = out.match(ROOTDATA_REGEXP);
+  if (!matches || matches.length !== 3) return out;
+  return out.replace(REMOVE_ROOTDATA, '');
+}
+
+
+function schemaHasRules(schema, rules) {
+  if (typeof schema == 'boolean') return !schema;
+  for (var key in schema) if (rules[key]) return true;
+}
+
+
+function schemaHasRulesExcept(schema, rules, exceptKeyword) {
+  if (typeof schema == 'boolean') return !schema && exceptKeyword != 'not';
+  for (var key in schema) if (key != exceptKeyword && rules[key]) return true;
+}
+
+
+function toQuotedString(str) {
+  return '\'' + escapeQuotes(str) + '\'';
+}
+
+
+function getPathExpr(currentPath, expr, jsonPointers, isNumber) {
+  var path = jsonPointers // false by default
+              ? '\'/\' + ' + expr + (isNumber ? '' : '.replace(/~/g, \'~0\').replace(/\\//g, \'~1\')')
+              : (isNumber ? '\'[\' + ' + expr + ' + \']\'' : '\'[\\\'\' + ' + expr + ' + \'\\\']\'');
+  return joinPaths(currentPath, path);
+}
+
+
+function getPath(currentPath, prop, jsonPointers) {
+  var path = jsonPointers // false by default
+              ? toQuotedString('/' + escapeJsonPointer(prop))
+              : toQuotedString(getProperty(prop));
+  return joinPaths(currentPath, path);
+}
+
+
+var JSON_POINTER = /^\/(?:[^~]|~0|~1)*$/;
+var RELATIVE_JSON_POINTER = /^([0-9]+)(#|\/(?:[^~]|~0|~1)*)?$/;
+function getData($data, lvl, paths) {
+  var up, jsonPointer, data, matches;
+  if ($data === '') return 'rootData';
+  if ($data[0] == '/') {
+    if (!JSON_POINTER.test($data)) throw new Error('Invalid JSON-pointer: ' + $data);
+    jsonPointer = $data;
+    data = 'rootData';
+  } else {
+    matches = $data.match(RELATIVE_JSON_POINTER);
+    if (!matches) throw new Error('Invalid JSON-pointer: ' + $data);
+    up = +matches[1];
+    jsonPointer = matches[2];
+    if (jsonPointer == '#') {
+      if (up >= lvl) throw new Error('Cannot access property/index ' + up + ' levels up, current level is ' + lvl);
+      return paths[lvl - up];
+    }
+
+    if (up > lvl) throw new Error('Cannot access data ' + up + ' levels up, current level is ' + lvl);
+    data = 'data' + ((lvl - up) || '');
+    if (!jsonPointer) return data;
+  }
+
+  var expr = data;
+  var segments = jsonPointer.split('/');
+  for (var i=0; i<segments.length; i++) {
+    var segment = segments[i];
+    if (segment) {
+      data += getProperty(unescapeJsonPointer(segment));
+      expr += ' && ' + data;
+    }
+  }
+  return expr;
+}
+
+
+function joinPaths (a, b) {
+  if (a == '""') return b;
+  return (a + ' + ' + b).replace(/' \+ '/g, '');
+}
+
+
+function unescapeFragment(str) {
+  return unescapeJsonPointer(decodeURIComponent(str));
+}
+
+
+function escapeFragment(str) {
+  return encodeURIComponent(escapeJsonPointer(str));
+}
+
+
+function escapeJsonPointer(str) {
+  return str.replace(/~/g, '~0').replace(/\//g, '~1');
+}
+
+
+function unescapeJsonPointer(str) {
+  return str.replace(/~1/g, '/').replace(/~0/g, '~');
+}

+ 96 - 0
resources/app/node_modules/ajv/lib/dot/_limit.jst

@@ -0,0 +1,96 @@
+{{# def.definitions }}
+{{# def.errors }}
+{{# def.setupKeyword }}
+{{# def.$data }}
+
+{{## def.setExclusiveLimit:
+  $exclusive = true;
+  $errorKeyword = $exclusiveKeyword;
+  $errSchemaPath = it.errSchemaPath + '/' + $exclusiveKeyword;
+#}}
+
+{{
+  var $isMax = $keyword == 'maximum'
+    , $exclusiveKeyword = $isMax ? 'exclusiveMaximum' : 'exclusiveMinimum'
+    , $schemaExcl = it.schema[$exclusiveKeyword]
+    , $isDataExcl = it.opts.$data && $schemaExcl && $schemaExcl.$data
+    , $op = $isMax ? '<' : '>'
+    , $notOp = $isMax ? '>' : '<'
+    , $errorKeyword = undefined;
+}}
+
+{{? $isDataExcl }}
+  {{
+    var $schemaValueExcl = it.util.getData($schemaExcl.$data, $dataLvl, it.dataPathArr)
+      , $exclusive = 'exclusive' + $lvl
+      , $exclType = 'exclType' + $lvl
+      , $exclIsNumber = 'exclIsNumber' + $lvl
+      , $opExpr = 'op' + $lvl
+      , $opStr = '\' + ' + $opExpr + ' + \'';
+  }}
+  var schemaExcl{{=$lvl}} = {{=$schemaValueExcl}};
+  {{ $schemaValueExcl = 'schemaExcl' + $lvl; }}
+
+  var {{=$exclusive}};
+  var {{=$exclType}} = typeof {{=$schemaValueExcl}};
+  if ({{=$exclType}} != 'boolean' && {{=$exclType}} != 'undefined' && {{=$exclType}} != 'number') {
+    {{ var $errorKeyword = $exclusiveKeyword; }}
+    {{# def.error:'_exclusiveLimit' }}
+  } else if ({{# def.$dataNotType:'number' }}
+            {{=$exclType}} == 'number'
+              ? (
+                  ({{=$exclusive}} = {{=$schemaValue}} === undefined || {{=$schemaValueExcl}} {{=$op}}= {{=$schemaValue}})
+                    ? {{=$data}} {{=$notOp}}= {{=$schemaValueExcl}}
+                    : {{=$data}} {{=$notOp}} {{=$schemaValue}}
+                )
+              : (
+                  ({{=$exclusive}} = {{=$schemaValueExcl}} === true)
+                    ? {{=$data}} {{=$notOp}}= {{=$schemaValue}}
+                    : {{=$data}} {{=$notOp}} {{=$schemaValue}}
+                )
+            || {{=$data}} !== {{=$data}}) {
+    var op{{=$lvl}} = {{=$exclusive}} ? '{{=$op}}' : '{{=$op}}=';
+{{??}}
+  {{
+    var $exclIsNumber = typeof $schemaExcl == 'number'
+      , $opStr = $op;  /*used in error*/
+  }}
+
+  {{? $exclIsNumber && $isData }}
+    {{ var $opExpr = '\'' + $opStr + '\''; /*used in error*/ }}
+    if ({{# def.$dataNotType:'number' }}
+        ( {{=$schemaValue}} === undefined
+          || {{=$schemaExcl}} {{=$op}}= {{=$schemaValue}}
+            ? {{=$data}} {{=$notOp}}= {{=$schemaExcl}}
+            : {{=$data}} {{=$notOp}} {{=$schemaValue}} )
+        || {{=$data}} !== {{=$data}}) {
+  {{??}}
+    {{
+      if ($exclIsNumber && $schema === undefined) {
+          {{# def.setExclusiveLimit }}
+          $schemaValue = $schemaExcl;
+          $notOp += '=';
+      } else {
+        if ($exclIsNumber)
+          $schemaValue = Math[$isMax ? 'min' : 'max']($schemaExcl, $schema);
+
+        if ($schemaExcl === ($exclIsNumber ? $schemaValue : true)) {
+          {{# def.setExclusiveLimit }}
+          $notOp += '=';
+        } else {
+          $exclusive = false;
+          $opStr += '=';
+        }
+      }
+
+      var $opExpr = '\'' + $opStr + '\''; /*used in error*/
+    }}
+
+    if ({{# def.$dataNotType:'number' }}
+        {{=$data}} {{=$notOp}} {{=$schemaValue}}
+        || {{=$data}} !== {{=$data}}) {
+  {{?}}
+{{?}}
+    {{ $errorKeyword = $errorKeyword || $keyword; }}
+    {{# def.error:'_limit' }}
+  } {{? $breakOnError }} else { {{?}}

+ 10 - 0
resources/app/node_modules/ajv/lib/dot/_limitItems.jst

@@ -0,0 +1,10 @@
+{{# def.definitions }}
+{{# def.errors }}
+{{# def.setupKeyword }}
+{{# def.$data }}
+
+{{ var $op = $keyword == 'maxItems' ? '>' : '<'; }}
+if ({{# def.$dataNotType:'number' }} {{=$data}}.length {{=$op}} {{=$schemaValue}}) {
+  {{ var $errorKeyword = $keyword; }}
+  {{# def.error:'_limitItems' }}
+} {{? $breakOnError }} else { {{?}}

+ 10 - 0
resources/app/node_modules/ajv/lib/dot/_limitLength.jst

@@ -0,0 +1,10 @@
+{{# def.definitions }}
+{{# def.errors }}
+{{# def.setupKeyword }}
+{{# def.$data }}
+
+{{ var $op = $keyword == 'maxLength' ? '>' : '<'; }}
+if ({{# def.$dataNotType:'number' }} {{# def.strLength }} {{=$op}} {{=$schemaValue}}) {
+  {{ var $errorKeyword = $keyword; }}
+  {{# def.error:'_limitLength' }}
+} {{? $breakOnError }} else { {{?}}

+ 10 - 0
resources/app/node_modules/ajv/lib/dot/_limitProperties.jst

@@ -0,0 +1,10 @@
+{{# def.definitions }}
+{{# def.errors }}
+{{# def.setupKeyword }}
+{{# def.$data }}
+
+{{ var $op = $keyword == 'maxProperties' ? '>' : '<'; }}
+if ({{# def.$dataNotType:'number' }} Object.keys({{=$data}}).length {{=$op}} {{=$schemaValue}}) {
+  {{ var $errorKeyword = $keyword; }}
+  {{# def.error:'_limitProperties' }}
+} {{? $breakOnError }} else { {{?}}

+ 34 - 0
resources/app/node_modules/ajv/lib/dot/allOf.jst

@@ -0,0 +1,34 @@
+{{# def.definitions }}
+{{# def.errors }}
+{{# def.setupKeyword }}
+{{# def.setupNextLevel }}
+
+{{
+  var $currentBaseId = $it.baseId
+    , $allSchemasEmpty = true;
+}}
+
+{{~ $schema:$sch:$i }}
+  {{? {{# def.nonEmptySchema:$sch }} }}
+    {{
+      $allSchemasEmpty = false;
+      $it.schema = $sch;
+      $it.schemaPath = $schemaPath + '[' + $i + ']';
+      $it.errSchemaPath = $errSchemaPath + '/' + $i;
+    }}
+
+    {{# def.insertSubschemaCode }}
+
+    {{# def.ifResultValid }}
+  {{?}}
+{{~}}
+
+{{? $breakOnError }}
+  {{? $allSchemasEmpty }}
+    if (true) {
+  {{??}}
+    {{= $closingBraces.slice(0,-1) }}
+  {{?}}
+{{?}}
+
+{{# def.cleanUp }}

+ 48 - 0
resources/app/node_modules/ajv/lib/dot/anyOf.jst

@@ -0,0 +1,48 @@
+{{# def.definitions }}
+{{# def.errors }}
+{{# def.setupKeyword }}
+{{# def.setupNextLevel }}
+
+{{
+  var $noEmptySchema = $schema.every(function($sch) {
+    return {{# def.nonEmptySchema:$sch }};
+  });
+}}
+{{? $noEmptySchema }}
+  {{ var $currentBaseId = $it.baseId; }}
+  var {{=$errs}} = errors;
+  var {{=$valid}} = false;
+
+  {{# def.setCompositeRule }}
+
+  {{~ $schema:$sch:$i }}
+    {{
+      $it.schema = $sch;
+      $it.schemaPath = $schemaPath + '[' + $i + ']';
+      $it.errSchemaPath = $errSchemaPath + '/' + $i;
+    }}
+
+    {{# def.insertSubschemaCode }}
+
+    {{=$valid}} = {{=$valid}} || {{=$nextValid}};
+
+    if (!{{=$valid}}) {
+    {{ $closingBraces += '}'; }}
+  {{~}}
+
+  {{# def.resetCompositeRule }}
+
+  {{= $closingBraces }}
+
+  if (!{{=$valid}}) {
+    {{# def.extraError:'anyOf' }}
+  } else {
+    {{# def.resetErrors }}
+  {{? it.opts.allErrors }} } {{?}}
+
+  {{# def.cleanUp }}
+{{??}}
+  {{? $breakOnError }}
+    if (true) {
+  {{?}}
+{{?}}

+ 61 - 0
resources/app/node_modules/ajv/lib/dot/coerce.def

@@ -0,0 +1,61 @@
+{{## def.coerceType:
+  {{
+    var $dataType = 'dataType' + $lvl
+      , $coerced = 'coerced' + $lvl;
+  }}
+  var {{=$dataType}} = typeof {{=$data}};
+  {{? it.opts.coerceTypes == 'array'}}
+    if ({{=$dataType}} == 'object' && Array.isArray({{=$data}})) {{=$dataType}} = 'array';
+  {{?}}
+
+  var {{=$coerced}} = undefined;
+
+  {{ var $bracesCoercion = ''; }}
+  {{~ $coerceToTypes:$type:$i }}
+    {{? $i }}
+      if ({{=$coerced}} === undefined) {
+      {{ $bracesCoercion += '}'; }}
+    {{?}}
+
+    {{? it.opts.coerceTypes == 'array' && $type != 'array' }}
+      if ({{=$dataType}} == 'array' && {{=$data}}.length == 1) {
+        {{=$coerced}} = {{=$data}} = {{=$data}}[0];
+        {{=$dataType}} = typeof {{=$data}};
+        /*if ({{=$dataType}} == 'object' && Array.isArray({{=$data}})) {{=$dataType}} = 'array';*/
+      }
+    {{?}}
+
+    {{? $type == 'string' }}
+      if ({{=$dataType}} == 'number' || {{=$dataType}} == 'boolean')
+        {{=$coerced}} = '' + {{=$data}};
+      else if ({{=$data}} === null) {{=$coerced}} = '';
+    {{?? $type == 'number' || $type == 'integer' }}
+      if ({{=$dataType}} == 'boolean' || {{=$data}} === null
+          || ({{=$dataType}} == 'string' && {{=$data}} && {{=$data}} == +{{=$data}}
+          {{? $type == 'integer' }} && !({{=$data}} % 1){{?}}))
+        {{=$coerced}} = +{{=$data}};
+    {{?? $type == 'boolean' }}
+      if ({{=$data}} === 'false' || {{=$data}} === 0 || {{=$data}} === null)
+        {{=$coerced}} = false;
+      else if ({{=$data}} === 'true' || {{=$data}} === 1)
+        {{=$coerced}} = true;
+    {{?? $type == 'null' }}
+      if ({{=$data}} === '' || {{=$data}} === 0 || {{=$data}} === false)
+        {{=$coerced}} = null;
+    {{?? it.opts.coerceTypes == 'array' && $type == 'array' }}
+      if ({{=$dataType}} == 'string' || {{=$dataType}} == 'number' || {{=$dataType}} == 'boolean' || {{=$data}} == null)
+        {{=$coerced}} = [{{=$data}}];
+    {{?}}
+  {{~}}
+
+  {{= $bracesCoercion }}
+
+  if ({{=$coerced}} === undefined) {
+    {{# def.error:'type' }}
+  } else {
+    {{# def.setParentData }}
+    {{=$data}} = {{=$coerced}};
+    {{? !$dataLvl }}if ({{=$parentData}} !== undefined){{?}}
+      {{=$parentData}}[{{=$parentDataProperty}}] = {{=$coerced}};
+  }
+#}}

+ 0 - 0
resources/app/node_modules/ajv/lib/dot/const.jst


Vissa filer visades inte eftersom för många filer har ändrats