gina 0.1.1-alpha.247 → 0.1.1-alpha.248

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (294) hide show
  1. package/framework/v0.1.1-alpha.248/VERSION +1 -0
  2. package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/plugin/dist/vendor/gina/css/gina.min.css.map +1 -1
  3. package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/plugin/dist/vendor/gina/js/gina.js +6 -1
  4. package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/plugin/dist/vendor/gina/js/gina.min.js +75 -75
  5. package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/plugin/dist/vendor/gina/js/gina.min.js.map +4 -4
  6. package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/plugin/dist/vendor/gina/js/gina.onload.min.js.map +2 -2
  7. package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/validator/src/form-validator.js +2 -1
  8. package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/validator/src/main.js +4 -0
  9. package/package.json +2 -2
  10. package/framework/v0.1.1-alpha.247/VERSION +0 -1
  11. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/AUTHORS +0 -0
  12. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/LICENSE +0 -0
  13. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/html/nolayout.html +0 -0
  14. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/html/static.html +0 -0
  15. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/img/android-chrome-192x192.png +0 -0
  16. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/img/android-chrome-512x512.png +0 -0
  17. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/img/apple-touch-icon.png +0 -0
  18. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/img/favicon-16x16.png +0 -0
  19. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/img/favicon-32x32.png +0 -0
  20. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/img/favicon.ico +0 -0
  21. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/plugin/README.md +0 -0
  22. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/plugin/dist/vendor/gina/css/gina.min.css +0 -0
  23. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/plugin/dist/vendor/gina/html/toolbar.html +0 -0
  24. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/plugin/dist/vendor/gina/js/gina.onload.min.js +0 -0
  25. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/asset/plugin/uuid.json +0 -0
  26. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/config.js +0 -0
  27. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/connectors/couchbase/index.js +0 -0
  28. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/connectors/couchbase/lib/connector.js +0 -0
  29. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/connectors/couchbase/lib/connector.v2.js +0 -0
  30. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/connectors/couchbase/lib/connector.v3.js +0 -0
  31. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/connectors/couchbase/lib/connector.v4.js +0 -0
  32. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/connectors/couchbase/lib/n1ql.js +0 -0
  33. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/connectors/couchbase/lib/session-store.js +0 -0
  34. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/connectors/couchbase/lib/session-store.v2.js +0 -0
  35. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/connectors/couchbase/lib/session-store.v3.js +0 -0
  36. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/connectors/couchbase/lib/session-store.v4.js +0 -0
  37. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/controller/controller.framework.js +0 -0
  38. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/controller/controller.js +0 -0
  39. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/controller/index.js +0 -0
  40. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/deps/busboy/.travis.yml +0 -0
  41. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/deps/busboy/LICENSE +0 -0
  42. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/deps/busboy/README.md +0 -0
  43. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/deps/busboy/deps/encoding/encoding-indexes.js +0 -0
  44. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/deps/busboy/deps/encoding/encoding.js +0 -0
  45. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/deps/busboy/lib/main.js +0 -0
  46. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/deps/busboy/lib/types/multipart.js +0 -0
  47. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/deps/busboy/lib/types/urlencoded.js +0 -0
  48. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/deps/busboy/lib/utils.js +0 -0
  49. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/deps/busboy/package.json +0 -0
  50. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/deps/swig-client/swig-2.0.0.min.js +0 -0
  51. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/dev/index.js +0 -0
  52. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/dev/lib/class.js +0 -0
  53. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/dev/lib/factory.js +0 -0
  54. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/dev/lib/tools.js +0 -0
  55. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/gna.js +0 -0
  56. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/locales/README.md +0 -0
  57. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/locales/currency.json +0 -0
  58. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/locales/dist/language/en.json +0 -0
  59. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/locales/dist/language/fr.json +0 -0
  60. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/locales/dist/region/en.json +0 -0
  61. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/locales/dist/region/fr.json +0 -0
  62. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/locales/index.js +0 -0
  63. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/locales/src/make.js +0 -0
  64. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/locales/src/resources/currency.csv +0 -0
  65. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/locales/src/resources/region.csv +0 -0
  66. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/locales/src/resources/region.mapping.json +0 -0
  67. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/mime.types +0 -0
  68. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/model/entity.js +0 -0
  69. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/model/index.js +0 -0
  70. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/model/template/entityFactory.js +0 -0
  71. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/model/template/index.js +0 -0
  72. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/README.md +0 -0
  73. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/index.js +0 -0
  74. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/file/README.md +0 -0
  75. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/file/build.json +0 -0
  76. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/file/package.json +0 -0
  77. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/intl/README.md +0 -0
  78. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/intl/build.json +0 -0
  79. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/intl/package.json +0 -0
  80. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/intl/src/main.js +0 -0
  81. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/storage/README.md +0 -0
  82. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/storage/build.json +0 -0
  83. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/storage/package.json +0 -0
  84. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/storage/src/main.js +0 -0
  85. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/validator/README.md +0 -0
  86. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/validator/build.json +0 -0
  87. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/plugins/lib/validator/package.json +0 -0
  88. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/router.js +0 -0
  89. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/server.express.js +0 -0
  90. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/server.isaac.js +0 -0
  91. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/server.js +0 -0
  92. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/status.codes +0 -0
  93. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle/config/app.json +0 -0
  94. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle/config/routing.json +0 -0
  95. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle/config/settings.json +0 -0
  96. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle/config/settings.server.json +0 -0
  97. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle/config/templates.json +0 -0
  98. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle/controllers/controller.content.js +0 -0
  99. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle/controllers/controller.js +0 -0
  100. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle/controllers/setup.js +0 -0
  101. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle/index.js +0 -0
  102. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle_namespace/controllers/controller.js +0 -0
  103. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle_public/css/default.css +0 -0
  104. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle_public/css/vendor/readme.md +0 -0
  105. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle_public/favicon.ico +0 -0
  106. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle_public/js/vendor/readme.md +0 -0
  107. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle_public/readme.md +0 -0
  108. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle_templates/handlers/main.js +0 -0
  109. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle_templates/html/content/homepage.html +0 -0
  110. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle_templates/html/includes/error-msg-noscript.html +0 -0
  111. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle_templates/html/includes/error-msg-outdated-browser.html +0 -0
  112. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/boilerplate/bundle_templates/html/layouts/main.html +0 -0
  113. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/command/gina.bat.tpl +0 -0
  114. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/command/gina.tpl +0 -0
  115. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/conf/env.json +0 -0
  116. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/conf/manifest.json +0 -0
  117. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/conf/package.json +0 -0
  118. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/conf/settings.json +0 -0
  119. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/conf/statics.json +0 -0
  120. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/conf/templates.json +0 -0
  121. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/error/client/json/401.json +0 -0
  122. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/error/client/json/403.json +0 -0
  123. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/error/client/json/404.json +0 -0
  124. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/error/server/html/50x.html +0 -0
  125. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/error/server/json/500.json +0 -0
  126. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/error/server/json/503.json +0 -0
  127. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/core/template/extensions/logger/config.json +0 -0
  128. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/console.js +0 -0
  129. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/context.js +0 -0
  130. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/data/LICENSE +0 -0
  131. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/data/README.md +0 -0
  132. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/data/package.json +0 -0
  133. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/data/src/main.js +0 -0
  134. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/dateFormat.js +0 -0
  135. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/index.js +0 -0
  136. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/json/LICENSE +0 -0
  137. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/json/README.md +0 -0
  138. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/json/package.json +0 -0
  139. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/json/src/main.js +0 -0
  140. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/path.js +0 -0
  141. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/plugins/README.md +0 -0
  142. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/plugins/package.json +0 -0
  143. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/plugins/src/api-error.js +0 -0
  144. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/plugins/src/main.js +0 -0
  145. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/prototypes.js +0 -0
  146. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/task.js +0 -0
  147. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/helpers/text.js +0 -0
  148. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/archiver/README.md +0 -0
  149. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/archiver/build.json +0 -0
  150. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/archiver/package.json +0 -0
  151. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/archiver/src/dep/jszip.min.js +0 -0
  152. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/archiver/src/main.js +0 -0
  153. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/aliases.json +0 -0
  154. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/add.js +0 -0
  155. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/arguments.json +0 -0
  156. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/copy.js +0 -0
  157. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/cp.js +0 -0
  158. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/help.js +0 -0
  159. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/help.txt +0 -0
  160. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/list.js +0 -0
  161. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/remove.js +0 -0
  162. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/rename.js +0 -0
  163. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/restart.js +0 -0
  164. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/rm.js +0 -0
  165. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/start.js +0 -0
  166. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/status.js +0 -0
  167. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/bundle/stop.js +0 -0
  168. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/env/add.js +0 -0
  169. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/env/get.js +0 -0
  170. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/env/help.js +0 -0
  171. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/env/help.txt +0 -0
  172. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/env/link-dev.js +0 -0
  173. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/env/list.js +0 -0
  174. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/env/remove.js +0 -0
  175. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/env/rm.js +0 -0
  176. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/env/set.js +0 -0
  177. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/env/unset.js +0 -0
  178. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/env/use.js +0 -0
  179. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/build.js +0 -0
  180. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/dot.js +0 -0
  181. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/get.js +0 -0
  182. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/help.js +0 -0
  183. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/help.txt +0 -0
  184. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/init.js +0 -0
  185. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/link-node-modules.js +0 -0
  186. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/link.js +0 -0
  187. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/msg.json +0 -0
  188. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/open.js +0 -0
  189. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/restart.js +0 -0
  190. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/set.js +0 -0
  191. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/start.js +0 -0
  192. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/status.js +0 -0
  193. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/stop.js +0 -0
  194. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/tail.js +0 -0
  195. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/update.js +0 -0
  196. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/framework/version.js +0 -0
  197. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/gina-dev.1.md +0 -0
  198. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/gina-framework.1.md +0 -0
  199. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/gina.1.md +0 -0
  200. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/helper.js +0 -0
  201. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/index.js +0 -0
  202. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/msg.json +0 -0
  203. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/port/help.js +0 -0
  204. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/port/help.txt +0 -0
  205. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/port/inc/scan.js +0 -0
  206. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/port/list.js +0 -0
  207. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/port/reset.js +0 -0
  208. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/port/set.js +0 -0
  209. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/add.js +0 -0
  210. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/arguments.json +0 -0
  211. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/build.js +0 -0
  212. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/help.js +0 -0
  213. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/help.txt +0 -0
  214. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/import.js +0 -0
  215. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/list.js +0 -0
  216. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/move.js +0 -0
  217. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/remove.js +0 -0
  218. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/rename.js +0 -0
  219. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/restart.js +0 -0
  220. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/rm.js +0 -0
  221. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/start.js +0 -0
  222. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/status.js +0 -0
  223. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/project/stop.js +0 -0
  224. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/protocol/help.js +0 -0
  225. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/protocol/help.txt +0 -0
  226. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/protocol/list.js +0 -0
  227. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/protocol/set.js +0 -0
  228. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/scope/help.js +0 -0
  229. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/scope/help.txt +0 -0
  230. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/scope/link-local.js +0 -0
  231. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/scope/list.js +0 -0
  232. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/scope/use.js +0 -0
  233. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cmd/view/add.js +0 -0
  234. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/collection/README.md +0 -0
  235. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/collection/build.json +0 -0
  236. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/collection/package.json +0 -0
  237. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/collection/src/main.js +0 -0
  238. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/config.js +0 -0
  239. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cron/README.md +0 -0
  240. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cron/package.json +0 -0
  241. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/cron/src/main.js +0 -0
  242. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/domain/LICENSE +0 -0
  243. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/domain/README.md +0 -0
  244. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/domain/dist/public_suffix_list.dat +0 -0
  245. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/domain/exemples/backend.js +0 -0
  246. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/domain/exemples/frontend.html +0 -0
  247. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/domain/package.json +0 -0
  248. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/domain/src/main.js +0 -0
  249. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/generator/index.js +0 -0
  250. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/index.js +0 -0
  251. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/inherits/LICENSE +0 -0
  252. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/inherits/README.md +0 -0
  253. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/inherits/example/inheriting_eventemitter.js +0 -0
  254. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/inherits/example/protected_inheritance.js +0 -0
  255. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/inherits/example/simple_inheritance.js +0 -0
  256. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/inherits/example/super_attribute_overridden_by_child_on_init.js +0 -0
  257. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/inherits/package.json +0 -0
  258. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/inherits/src/main.js +0 -0
  259. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/logger/README.md +0 -0
  260. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/logger/package.json +0 -0
  261. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/logger/src/containers/default/index.js +0 -0
  262. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/logger/src/containers/file/index.js +0 -0
  263. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/logger/src/containers/file/lib/logrotator/README.md +0 -0
  264. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/logger/src/containers/file/lib/logrotator/index.js +0 -0
  265. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/logger/src/containers/mq/index.js +0 -0
  266. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/logger/src/containers/mq/listener.js +0 -0
  267. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/logger/src/containers/mq/speaker.js +0 -0
  268. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/logger/src/helper.js +0 -0
  269. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/logger/src/main.js +0 -0
  270. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/math/index.js +0 -0
  271. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/merge/README.md +0 -0
  272. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/merge/example/merge.js +0 -0
  273. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/merge/example/merge_2_literal objects.js +0 -0
  274. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/merge/example/merge_and_preserve_first.js +0 -0
  275. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/merge/package.json +0 -0
  276. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/merge/src/main.js +0 -0
  277. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/model.js +0 -0
  278. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/proc.js +0 -0
  279. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/routing/README.md +0 -0
  280. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/routing/build.json +0 -0
  281. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/routing/package.json +0 -0
  282. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/routing/src/main.js +0 -0
  283. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/session-store.js +0 -0
  284. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/shell.js +0 -0
  285. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/swig-filters/README.md +0 -0
  286. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/swig-filters/package.json +0 -0
  287. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/swig-filters/src/main.js +0 -0
  288. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/url/README.md +0 -0
  289. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/url/index.js +0 -0
  290. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/url/mocks.json +0 -0
  291. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/url/routing.json +0 -0
  292. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/url/test.js +0 -0
  293. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/lib/validator.js +0 -0
  294. /package/framework/{v0.1.1-alpha.247 → v0.1.1-alpha.248}/package.json +0 -0
@@ -0,0 +1 @@
1
+ 0.1.1-alpha.248
@@ -1 +1 @@
1
- {"version":3,"sources":[],"names":[],"mappings":"","file":"/usr/local/lib/node_modules/gina/framework/v0.1.1-alpha.247/core/asset/plugin/dist/vendor/gina/css/gina.min.css","sourcesContent":[]}
1
+ {"version":3,"sources":[],"names":[],"mappings":"","file":"/usr/local/lib/node_modules/gina/framework/v0.1.1-alpha.248/core/asset/plugin/dist/vendor/gina/css/gina.min.css","sourcesContent":[]}
@@ -6225,7 +6225,8 @@ function FormValidatorUtil(data, $fields, xhrOptions, fieldsSet) {
6225
6225
  }
6226
6226
  // Fixed on 2023-01-10
6227
6227
  // We want `local.errorLabels['query']` before the generic|user defined `rule` error
6228
- errors['query'] = replace(systemError || _this['error'] || local.errorLabels['query'] || options['error'], _this);
6228
+ var optionError = ( typeof(options['error']) != 'undefined' ) ? options['error'] : null;
6229
+ errors['query'] = replace(systemError || _this['error'] || optionError || local.errorLabels['query'], _this);
6229
6230
  console.debug('[1] query error detected !! ', result);
6230
6231
  }
6231
6232
 
@@ -10551,6 +10552,10 @@ if ( ( typeof(module) !== 'undefined' ) && module.exports ) {
10551
10552
  && typeof(instance.$forms[formId]) != 'undefined'
10552
10553
  && typeof(instance.$forms[formId].errors) != 'undefined'
10553
10554
  && instance.$forms[formId].errors.count() == 0
10555
+ ||
10556
+ typeof(instance.$forms) != 'undefined'
10557
+ && typeof(instance.$forms[formId]) != 'undefined'
10558
+ && !instance.$forms[formId].errors
10554
10559
  ) {
10555
10560
  // update submit trigger state
10556
10561
  updateSubmitTriggerState( $form, true );
@@ -347,40 +347,40 @@ J=!0);y.query=C(this.error||z||S.errorLabels.query,this);console.debug('[2] pote
347
347
  v=m.data||null;y=null;H=/^true$/i.test(this.target.form.dataset.ginaFormLiveCheckEnabled)?!0:!1;y=JSON.stringify(v);if(/\$/.test(y)){v=y.match(/\$[-_\[\]a-z 0-9]+/g)||[];w=F=null;for(let xa=0,ma=v.length;xa<ma;xa++)w=v[xa].replace(/\$/g,''),re=new RegExp('\\'+v[xa].replace(/\[|\]/g,'\\$&'),'g'),F=S.data[w]||null,!F&&H&&(F=G(this.target.form,w).value),y=y.replace(re,F)}v=y.replace(/\\"/g,'');var Fa='undefined'==typeof m.validIf?!0:m.validIf;z=M(z,m,V);delete z.data;delete z.validIf;y=z.headers['Content-Type'];
348
348
  var W=null;H=this.target.getAttribute('id');if(!/^http/.test(z.url)&&/@/.test(z.url))try{J=ba.getRoute(z.url),z.url=J.toUrl()}catch(xa){throw xa;}if(z.withCredentials){if('withCredentials'in T)z.isSynchrone?T.open(z.method,z.url,z.isSynchrone):T.open(z.method,z.url);else if('undefined'!=typeof XDomainRequest)T=new XDomainRequest,T.open(z.method,z.url);else throw T=null,W='CORS not supported: the server is missing the header `"Access-Control-Allow-Credentials": true` ',Error(W);T.responseType='undefined'!=
349
349
  typeof z.responseType?z.responseType:'';T.withCredentials=!0}else z.isSynchrone?T.open(z.method,z.url,z.isSynchrone):T.open(z.method,z.url);for(var la in z.headers)'Content-Type'==la&&'undefined'!=typeof y&&null!=y&&''!=y||T.setRequestHeader(la,z.headers[la]);'undefined'!=typeof y&&null!=y&&''!=y&&T.setRequestHeader('Content-Type',y);var ia=function(xa){ta.value=S.data[ta.name]=ta.value?ta.value.toLowerCase():ta.value;var ma=xa.isValid||!1;ma=Fa!=ma?!1:!0;u[ta.name].valid=ma;var ua=u[ta.name].errors||
350
- {},Ca='undefined'!=typeof xa.error&&'undefined'!=typeof xa.fields?xa.fields:{};if(0<Ca.count()&&!ma||!ma){if(!ma){var Qa=null;'undefined'!=typeof Ca[ta.name]?S.errorLabels.query=ea(Ca[ta.name],m.data):'undefined'!=typeof xa.error&&/^5/.test(xa.status)&&(Qa=xa.error);ua.query=C(Qa||ta.error||S.errorLabels.query||m.error,ta);console.debug('[1] query error detected !! ',xa)}ua.query||''!=ta.value||(ma=!0)}ma&&'undefined'!=typeof ua.query&&delete ua.query;ta.valid=ma;xa=gina.validator.$forms[ta.target.form.getAttribute('id')].cachedErrors||
351
- {};0<ua.count()?(ta.errors=ua,'undefined'==typeof u[ta.name].errors&&(u[ta.name].errors={}),u[ta.name].errors=M(u[ta.name].errors,ua),'undefined'!=typeof ua.query&&ua.query&&('undefined'==typeof xa[ta.name]&&(xa[ta.name]={}),'undefined'==typeof xa[ta.name].query&&(xa[ta.name].query={}),xa[ta.name].query[ta.value]=ua.query.slice(0)),ua=ta.target.getAttribute('data-gina-form-errors'),/query/.test(ua)||ta.target.setAttribute('data-gina-form-errors',ua&&''!=ua?ua+' query':'query')):'undefined'!=typeof xa[ta.name]&&
352
- 'undefined'!=typeof xa[ta.name].query&&'undefined'!=typeof xa[ta.name].query[ta.value]&&delete xa[ta.name].query[ta.value];ua=ta.target.id||ta.target.getAttribute('id');console.debug('prematurely completed event `asyncCompleted.'+ua+'`');return triggerEvent(gina,ta.target,'asyncCompleted.'+ua,u[ta.name])};T&&(T.onerror=function(xa,ma){console.debug('query error [2] detected !! ',ma,'Transaction error: might be due to the server CORS settings.\nPlease, check the console for more details.');isOnException=
353
- !0;xa=this.getResponseHeader('Content-Type');if(/\/json/.test(xa))xa=JSON.parse(this.responseText),'undefined'==typeof xa.status&&(xa.status=this.status);else if(xa={status:T.status,message:''},/^(\{|\[)/.test(T.responseText))try{xa=M(xa,JSON.parse(T.responseText))}catch(ua){xa=M(xa,ua)}return ia(xa)},T.onload=function(){try{W=this.responseText;var xa=this.getResponseHeader('Content-Type');if(/\/json/.test(xa))W=JSON.parse(this.responseText),'undefined'==typeof W.status&&(W.status=this.status);else if(W=
354
- {status:T.status,message:''},/^(\{|\[)/.test(T.responseText))try{W=M(W,JSON.parse(T.responseText))}catch(ma){W=M(W,ma)}return ia(W)}catch(ma){throw ma;}},A?T.send(v):T.send())}else console.debug('stopping on errors ...'),triggerEvent(gina,this.target,'asyncCompleted.'+H,u[this.name])},N=async function(m,z,y,H){var v=(new (require(_(GINA_FRAMEWORK_DIR+'/core/config.js',!0)))).getInstance(),w=null,F=null,J=null,T=getContext('bundle');if(/@/.test(m.url)){var ta=m.url.split(/@/);F=ta[0];J=ta[1];getConfig(T,
355
- 'app');try{v.bundle!==J&&(w=getConfig(T,'app').proxy[J])}catch(ia){throw Error('Could not retrieve `proxy` configuration for bundle `'+J+'`. Please check your `/config/app.json`.\n'+ia.stack);}ta=null}else throw Error('external url/domain not handled at this moment, please contact us if you need support for it.');ta=JSON.clone(ba.getRoute(m.url,m.data));var Fa=v[J][v.env];w||(v.bundle==J&&(w=getConfig(T,'settings').server.credentials,m.ca=w.ca||null,m.hostname=Fa.server.scheme+'://'+Fa.host,m.port=
356
- Fa.port[Fa.server.protocol][Fa.server.scheme],m.protocol=Fa.server.protocol,m.rejectUnauthorized=!1),w={ca:m.ca,hostname:m.hostname,port:m.port,path:m.path},'undefined'!=typeof m.protocol&&(w.protocol=m.protocol),'undefined'!=typeof m.rejectUnauthorized&&(w.rejectUnauthorized=m.rejectUnauthorized));F={method:ta.method,requirements:ta.requirements,namespace:ta.namespace||void 0,url:decodeURI(ta.url),rule:F+'@'+J,param:JSON.clone(ta.param),middleware:JSON.clone(ta.middleware),bundle:ta.bundle,isXMLRequest:z.isXMLRequest,
357
- isWithCredentials:z.isWithCredentials};J=F.rule.replace('@'+J,'')||'_common';J={template:'undefined'!=typeof Fa.content.templates?Fa.content.templates[J]||Fa.content.templates._common:void 0,cacheless:Fa.cacheless};J=M(J,F);Fa=JSON.clone(Fa);J.conf=Fa;J.conf.content.routing[J.rule].param=F.param;J.template&&'undefined'==typeof J.template.ginaLoader&&(J.template.ginaLoader=J.conf.content.templates._common.ginaLoader);J.conf.content.routing[J.rule].param=F.param;delete J.middleware;delete J.param;delete J.requirements;
358
- Fa=new (require(_(GINA_FRAMEWORK_DIR+'/core/controller/controller.js'),!0))(J);Fa.name=ta.param.control;Fa.setOptions(z,y,H,J);z='object'==typeof m.data&&0<m.data.count()?m.data:{};if(/^get|delete|put$/i.test(m.method)){y=0;for(let ia in z)'object'==typeof z[ia]&&encodeRFC5987ValueChars(JSON.stringify(z[ia])),y++}w.method=m.method;w.path=ta.url;m=require('util').promisify;var W={isValid:!1},la=!1;await m(Fa.query)(w,z).then(function(ia){W=ia}).catch(function(ia){la=ia});la&&(console.error(la),W.error=
359
- la);return W},O=null;O=U?Ea:N;var D=function(m,z){var y=null,H=null;'undefined'==typeof u[m]&&'undefined'!=typeof z&&(u[m]=y=z);if('object'==typeof u[m])try{y=JSON.parse(JSON.stringify(u[m]))}catch(v){y=u[m]}else y=u[m];H='';U&&'undefined'!=typeof P&&(H=P[m].getAttribute('data-gina-form-field-label')||'');u[m]={target:U&&'undefined'!=typeof P?P[m]:null,name:m,value:y,valid:!1,label:H,exclude:!1};u[m].is=function(v,w,F){var J=!1,T='undefined'!=typeof window&&'undefined'!=typeof window._currentValidatorAlias?
360
- window._currentValidatorAlias:'is';'undefined'!=typeof window&&window._currentValidatorAlias&&delete window._currentValidatorAlias;var ta=u[this.name].errors||{};S.data[this.name]=u[this.name].value;'undefined'==typeof ta.isRequired&&''==this.value&&!/^false$/i.test(this.value)&&0!=this.value||!ta.isRequired&&''==this.value&&!/^false$/i.test(this.value)&&0!=this.value?J=!0:ta.isRequired||'string'!=typeof this.value||''!=this.value||(J=!0);if(!J&&/^(true|false)$/i.test(v))J=v;else if(!J){var Fa=null,
361
- W=null;if(/[!=>><a-z 0-9]+/i.test(v)){if((W=v.match(/\${0}[-_,.\[\]a-z0-9]+/ig))&&0<W.length){for(var la=0,ia=W.length;la<ia;++la)'undefined'!=typeof u[W[la]]&&W[la]&&(Fa=new RegExp('\\$'+W[la]+'(?!\\S+)','g'),v=''==u[W[la]].value?v.replace(Fa,'""'):'string'==typeof u[W[la]].value?v.replace(Fa,'"'+u[W[la]].value+'"'):v.replace(Fa,u[W[la]].value));try{v=v.replace(/(\(|\)|return)/g,''),J=/^\//.test(v)?eval(v+'.test("'+this.value+'")'):eval(v)}catch(xa){throw Error(xa.stack||xa.message);}}}else if(v instanceof
362
- RegExp)J=v.test(this.value)?!0:!1;else if('boolean'==typeof v)J=v?!0:!1;else try{/\/(.*)\//.test(v)?(Fa=v.match(/\/(.*)\//).pop(),W=v.replace('/'+Fa+'/',''),J=(new RegExp(Fa,W)).test(this.value)):J=eval(v)}catch(xa){throw Error(xa.stack||xa.message);}}J?J&&'undefined'!=typeof ta[T]&&delete ta[T]:(ta[T]=C(this.error||w||S.errorLabels[T],this),'undefined'!=typeof F&&(ta.stack=F));this.valid=J;0<ta.count()&&(this.errors=ta);return u[this.name]};u[m].set=function(v){this.value=S.data[this.name]=v;this.target.setAttribute('value',
363
- v);return u[this.name]};u[m].isEmail=function(){this.value=S.data[this.name]=this.value?this.value.toLowerCase():this.value;U&&this.target&&''!=this.target.value&&/[A-Z]+/.test(this.target.value)&&(this.target.value=this.value);var v=/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(this.value)?!0:!1,w=u[this.name].errors||{};w.isRequired||''!=this.value||(v=!0);v?v&&'undefined'!=typeof w.isEmail&&
364
- delete w.isEmail:w.isEmail=C(this.error||S.errorLabels.isEmail,this);this.valid=v;0<w.count()&&(this.errors=w);return u[this.name]};u[m].isJsonWebToken=function(){this.value=S.data[this.name]=this.value?this.value.toLowerCase():this.value;U&&this.target&&''!=this.target.value&&/[A-Z]+/.test(this.target.value)&&(this.target.value=this.value);var v=/^[A-Za-z0-9-_=]+\.[A-Za-z0-9-_=]+\.?[A-Za-z0-9-_.+/=]*$/.test(this.value)?!0:!1,w=u[this.name].errors||{};w.isRequired||''!=this.value||(v=!0);v?v&&'undefined'!=
365
- typeof w.isJsonWebToken&&delete w.isJsonWebToken:w.isJsonWebToken=C(this.error||S.errorLabels.isJsonWebToken,this);this.valid=v;0<w.count()&&(this.errors=w);return u[this.name]};u[m].isBoolean=function(){var v=null,w=u[this.name].errors||{};w.isRequired&&0==this.value&&(delete w.isRequired,this.errors=w);switch(this.value){case 'true':case !0:case 1:v=this.value=S.data[this.name]=!0;break;case 'false':case !1:case 0:v=this.value=S.data[this.name]=!1}(v=null!==v?!0:!1)?v&&'undefined'!=typeof w.isBoolean&&
366
- delete w.isBoolean:w.isBoolean=C(this.error||S.errorLabels.isBoolean,this);this.valid=v;0<w.count()&&(this.errors=w);return u[this.name]};u[m].isNumber=function(v,w){var F=this.value,J=!1,T=!0,ta=!0,Fa=u[this.name].errors||{};try{'string'==typeof F&&/,|\./g.test(F)?F=S.data[this.name]=this.value=parseFloat(F.replace(/,/g,'.').replace(/\s+/g,'')):'string'==typeof F&&''!=F&&(F=S.data[this.name]=this.value=parseInt(F.replace(/\s+/g,'')))}catch(la){Fa.isNumber=C(this.error||S.errorLabels.isNumber,this),
367
- this.valid=!1,0<Fa.count()&&(this.errors=Fa)}if(+F===+F&&(J=!0,!Fa.isRequired&&''!=F)){var W=F.toString().length;v&&'number'==typeof v&&W<v&&(T=!1,this.size=v);w&&'number'==typeof w&&W>w&&(ta=!1,this.size=w)}J&&T&&ta||(J||(Fa.isNumber=C(this.error||S.errorLabels.isNumber,this)),T&&ta||(T||(Fa.isNumberLength=C(this.error||S.errorLabels.isNumberMinLength,this)),ta||(Fa.isNumberLength=C(this.error||S.errorLabels.isNumberMaxLength,this)),v===w&&(Fa.isNumberLength=C(this.error||S.errorLabels.isNumberLength,
368
- this))),J=!1);J&&'undefined'!=typeof Fa.isNumberLength&&delete Fa.isNumberLength;this.valid=J;this.value=S.data[this.name]=''!=F?Number(F):F;0<Fa.count()&&(this.errors=Fa);return u[this.name]};u[m].toInteger=function(){var v=this.value,w=u[this.name].errors||{};if(v)try{this.value=S.data[this.name]=Math.round(v)}catch(F){w.toInteger=C(this.error||S.errorLabels.toInteger,this),this.valid=!1,0<w.count()&&(this.errors=w)}return u[this.name]};u[m].isInteger=function(v,w){var F=this.value,J=!1,T=!0,ta=
369
- !0,Fa=u[this.name].errors||{};+F===+F&&0===F%1&&(J=!0,Fa.isRequired||''==F||(v&&'number'==typeof v&&F.length<v&&(T=!1,this.size=v),w&&'number'==typeof w&&F.length>w&&(ta=!1,this.size=w)));J&&T&&ta||(J||(Fa.isInteger=C(this.error||S.errorLabels.isInteger,this)),T&&ta||(T||(Fa.isIntegerLength=C(this.error||S.errorLabels.isIntegerMinLength,this),J=!1),ta||(Fa.isIntegerLength=C(this.error||S.errorLabels.isIntegerMaxLength,this),J=!1),v===w&&(Fa.isIntegerLength=C(this.error||S.errorLabels.isIntegerLength,
370
- this),J=!1)));this.valid=J;this.value=S.data[this.name]=Number(F);0<Fa.count()&&(this.errors=Fa);return u[this.name]};u[m].toFloat=function(v){'string'==typeof this.value&&(this.value=this.value.replace(/\s+/g,''),/,/.test(this.value)&&!/\./.test(this.value)?this.value=this.value.replace(/,/g,'.'):this.value=this.value.replace(/,/g,''));var w=S.data[this.name]=this.value,F=u[this.name].errors||{},J=!0;v?this.decimals=parseInt(v):'undefined'==typeof this.decimals&&(this.decimals=2);if(w)if(this.isNumber().valid)try{Number.isFinite(w)||
371
- (w=this.value=S.data[this.name]=new Number(parseFloat(w.match(/[0-9.,]+/g).join('').replace(/,/,'.')))),U&&this.target.setAttribute('value',w)}catch(T){J=!1,F.toFloat=C(this.error||S.errorLabels.toFloat,this),this.valid=!1,0<F.count()&&(this.errors=F)}else J=!1,F.toFloat=C(this.error||S.errorLabels.toFloatNAN,this);else return u[this.name];this.decimals&&w&&!F.toFloat&&(this.value=S.data[this.name]=parseFloat(this.value.toFixed(this.decimals)));this.valid=J;0<F.count()&&(this.errors=F);return u[this.name]};
372
- u[m].isFloat=function(v){'string'==typeof this.value&&(this.value=this.value.replace(/\s+/g,''));var w=S.data[this.name]=this.value;v=u[this.name].errors||{};'string'==typeof w&&/\./.test(w)&&Number.isFinite(Number(w));'string'==typeof w&&/,/g.test(w)&&(w=this.value=S.data[this.name]=Number(w.replace(/,/g,'.')));Number(w)===w&&0!==w%1?(this.value=S.data[this.name]=Number(w),w=!0):w=!1;v.isRequired||''!=this.value||(w=!0);w||(v.isFloat=C(this.error||S.errorLabels.isFloat,this));this.valid=w;0<v.count()&&
373
- (this.errors=v);return u[this.name]};u[m].isRequired=function(v){if('boolean'==typeof v&&!v)return this.valid=!0,v=S.excluded.indexOf(this.name),-1<v&&S.excluded.splice(v,1),u[this.name];if(U&&this.target&&'INPUT'==this.target.tagName&&'undefined'!=typeof this.target.type&&'radio'==this.target.type){v=document.getElementsByName(this.name);for(var w=0,F=v.length;w<F;++w)if(v[w].checked){/true|false/.test(v[w].value)?this.value=S.data[this.name]=/true/.test(v[w].value)?!0:!1:this.value=S.data[this.name]=
374
- v[w].value;this.valid=!0;break}}v='undefined'==typeof this.value||null==this.value||''==this.value||/^\s+/.test(this.value)?!1:!0;w=u[this.name].errors||{};v?v&&'undefined'!=typeof w.isRequired&&delete w.isRequired:w.isRequired=C(this.error||S.errorLabels.isRequired,this);this.valid=v;0<w.count()&&(this.errors=w);return u[this.name]};u[m].isString=function(v,w){var F=S.data[this.name]=this.value,J=!1,T=!0,ta=!0,Fa=u[this.name].errors||{};'string'!=typeof F||Fa.isRequired||''==F||(J=!0,v&&'number'==
375
- typeof v&&F.length<v&&(T=!1,this.size=v),w&&'number'==typeof w&&F.length>w&&(ta=!1,this.size=w));J&&T&&ta||(!J&&Fa.isRequired&&''==F?(J=!1,Fa.isString=C(this.error||S.errorLabels.isString,this)):J||Fa.isRequired||(J=!0),T&&ta||(J=!1,T||(Fa.isStringLength=C(this.error||S.errorLabels.isStringMinLength,this)),ta||(Fa.isStringLength=C(this.error||S.errorLabels.isStringMaxLength,this)),v===w&&(Fa.isStringLength=C(this.error||S.errorLabels.isStringLength,this))));this.valid=J;0<Fa.count()&&(this.errors=
376
- Fa);return u[this.name]};u[m].isDate=function(v){var w=this.value,F=!1,J=u[this.name].errors||{},T=null;if(!w||''==w||/NaN|Invalid Date/i.test(w))return/NaN|Invalid Date/i.test(w)&&(console.warn('[FormValidator::isDate] Provided value for field `'+this.name+'` is not allowed: `'+w+'`'),J.isDate=C(this.error||S.errorLabels.isDate,this)),this.valid=F,0<J.count()&&(this.errors=J),u[this.name];if('undefined'==typeof v||'undefined'!=typeof v&&/true/i.test(v))v='yyyy-mm-dd';if(w instanceof Date)w=w.format(v);
377
- else{try{T=v.match(/[^\/\- ]+/g)}catch(ia){throw Error('[FormValidator::isDate] Provided mask not allowed: `'+v+'`');}try{w=w.match(/[^\/\- ]+/g);var ta={},Fa;var W=0;for(Fa=T.length;W<Fa;++W)ta[T[W]]=w[W];for(var la in ta)v=v.replace(new RegExp(la,'g'),ta[la])}catch(ia){throw Error('[FormValidator::isDate] Provided value not allowed: `'+w+'`'+ia);}w=this.value=S.data[this.name]=new Date(v);if(/Invalid Date/i.test(w)||!1===w instanceof Date)return J.isRequired||''!=this.value?J.isDate=C(this.error||
378
- S.errorLabels.isDate,this):F=!0,this.valid=F,0<J.count()&&(this.errors=J),u[this.name];F=!0}this.valid=F;return w};u[m].format=function(v,w){var F=this.value;return F?F.format(v,w):u[this.name]};u[m].setFlash=function(v,w){'undefined'!=typeof w&&''!=w&&(this.error=w);return u[this.name]};u[m].setLabel=function(v){'undefined'!=typeof v&&''!=v&&(this.label=v);return u[this.name]};u[m].trim=function(v){if('boolean'==typeof v&&v)return this.value=this.value.replace(/^\s+|\s+$/,''),S.data[this.name]=S.data[this.name]=
379
- this.value,u[this.name]};u[m].exclude=function(v){if('boolean'==typeof v&&!v)return/^true|false$/i.test(this.value)&&(this.value=/^true$/i.test(this.value)?!0:!1,S.data[this.name]=this.value),u[this.name];this.isExcluded=!1;0>S.excluded.indexOf(this.name)&&(S.excluded.push(this.name),this.isExcluded=!0);return u[this.name]};u[m].query=O;u[m].getValidationContext=function(){return{isGFFCtx:U,self:u,local:S,replace:C}};if(Q()){y=z=null;try{for(let v in gina.forms.validators)y='/validators/'+v+'/main.js',
380
- S.errorLabels[v]='Condition not satisfied',U?(z=r(gina.forms.validators[v].data),z=z.replace(/(\)\s+\{|\)\{){1}/,'$&\n\tvar validationContext = this.getValidationContext(),isGFFCtx = validationContext.isGFFCtx,self = validationContext.self,local = validationContext.local,replace = validationContext.replace;')):z=gina.forms.validators[v].toString(),u[m][v]=eval('('+z+')\n//# sourceURL='+v+'.js')}catch(v){throw Error('[UserFormValidator] Could not evaluate: `'+y+'`\n'+v.stack);}}};for(let m in u)D(m,
381
- u[m]);u.addField=function(m,z){'undefined'==typeof u[m]&&D(m,z)};u.isValid=function(){return 0<u.getErrors().count()?!1:!0};u.setErrors=function(m){if(!m)return{};for(var z in u)if('object'==typeof u[z]){for(var y in u[z])'object'==typeof m[z]&&'undefined'!=typeof m[z][y]&&('undefined'!=typeof u[z].valid&&/^true$/i.test(u[z].valid)?delete m[z][y]:('undefined'==typeof u[z].errors&&(u[z].errors={}),u[z].errors[y]=m[z][y]));('undefined'==typeof u[z].errors&&'undefined'!=typeof m[z]||'undefined'!=typeof u[z].errors&&
382
- 0==u[z].errors.count()&&'undefined'!=typeof m[z])&&delete m[z]}return m};u.getErrors=function(m){var z={};if('undefined'!=typeof m)return'undefined'!=typeof u[m]&&u[m]&&'undefined'!=typeof u[m].errors&&0<u[m].errors.count()&&(z[m]=u[m].errors),z;for(var y in u)'object'==typeof u[y]&&'undefined'!=typeof u[y].errors&&0<u[y].errors.count()&&(z[y]=u[y].errors);return z};u.toData=function(){if(0<S.excluded.length)for(var m=0,z=S.excluded.length;m<z;++m)'undefined'!=typeof S.data[S.excluded[m]]&&delete S.data[S.excluded[m]];
383
- return S.data};var C=function(m,z){var y=m.match(/%[a-z]+/gi);if(y)for(var H=0,v=y.length;H<v;++H)m=m.replace(new RegExp(y[H],'g'),z[S.keys[y[H]]]);return m};u.setErrorLabels=function(m){'undefined'!=typeof m&&(S.errorLabels=M(m,S.errorLabels))};return u}'undefined'!==typeof module&&module.exports?module.exports=FormValidatorUtil:'function'===typeof define&&define.amd&&define('lib/form-validator',[],function(){return FormValidatorUtil});
350
+ {},Ca='undefined'!=typeof xa.error&&'undefined'!=typeof xa.fields?xa.fields:{};if(0<Ca.count()&&!ma||!ma){if(!ma){var Qa=null;'undefined'!=typeof Ca[ta.name]?S.errorLabels.query=ea(Ca[ta.name],m.data):'undefined'!=typeof xa.error&&/^5/.test(xa.status)&&(Qa=xa.error);Ca='undefined'!=typeof m.error?m.error:null;ua.query=C(Qa||ta.error||Ca||S.errorLabels.query,ta);console.debug('[1] query error detected !! ',xa)}ua.query||''!=ta.value||(ma=!0)}ma&&'undefined'!=typeof ua.query&&delete ua.query;ta.valid=
351
+ ma;xa=gina.validator.$forms[ta.target.form.getAttribute('id')].cachedErrors||{};0<ua.count()?(ta.errors=ua,'undefined'==typeof u[ta.name].errors&&(u[ta.name].errors={}),u[ta.name].errors=M(u[ta.name].errors,ua),'undefined'!=typeof ua.query&&ua.query&&('undefined'==typeof xa[ta.name]&&(xa[ta.name]={}),'undefined'==typeof xa[ta.name].query&&(xa[ta.name].query={}),xa[ta.name].query[ta.value]=ua.query.slice(0)),ua=ta.target.getAttribute('data-gina-form-errors'),/query/.test(ua)||ta.target.setAttribute('data-gina-form-errors',
352
+ ua&&''!=ua?ua+' query':'query')):'undefined'!=typeof xa[ta.name]&&'undefined'!=typeof xa[ta.name].query&&'undefined'!=typeof xa[ta.name].query[ta.value]&&delete xa[ta.name].query[ta.value];ua=ta.target.id||ta.target.getAttribute('id');console.debug('prematurely completed event `asyncCompleted.'+ua+'`');return triggerEvent(gina,ta.target,'asyncCompleted.'+ua,u[ta.name])};T&&(T.onerror=function(xa,ma){console.debug('query error [2] detected !! ',ma,'Transaction error: might be due to the server CORS settings.\nPlease, check the console for more details.');
353
+ isOnException=!0;xa=this.getResponseHeader('Content-Type');if(/\/json/.test(xa))xa=JSON.parse(this.responseText),'undefined'==typeof xa.status&&(xa.status=this.status);else if(xa={status:T.status,message:''},/^(\{|\[)/.test(T.responseText))try{xa=M(xa,JSON.parse(T.responseText))}catch(ua){xa=M(xa,ua)}return ia(xa)},T.onload=function(){try{W=this.responseText;var xa=this.getResponseHeader('Content-Type');if(/\/json/.test(xa))W=JSON.parse(this.responseText),'undefined'==typeof W.status&&(W.status=this.status);
354
+ else if(W={status:T.status,message:''},/^(\{|\[)/.test(T.responseText))try{W=M(W,JSON.parse(T.responseText))}catch(ma){W=M(W,ma)}return ia(W)}catch(ma){throw ma;}},A?T.send(v):T.send())}else console.debug('stopping on errors ...'),triggerEvent(gina,this.target,'asyncCompleted.'+H,u[this.name])},N=async function(m,z,y,H){var v=(new (require(_(GINA_FRAMEWORK_DIR+'/core/config.js',!0)))).getInstance(),w=null,F=null,J=null,T=getContext('bundle');if(/@/.test(m.url)){var ta=m.url.split(/@/);F=ta[0];J=ta[1];
355
+ getConfig(T,'app');try{v.bundle!==J&&(w=getConfig(T,'app').proxy[J])}catch(ia){throw Error('Could not retrieve `proxy` configuration for bundle `'+J+'`. Please check your `/config/app.json`.\n'+ia.stack);}ta=null}else throw Error('external url/domain not handled at this moment, please contact us if you need support for it.');ta=JSON.clone(ba.getRoute(m.url,m.data));var Fa=v[J][v.env];w||(v.bundle==J&&(w=getConfig(T,'settings').server.credentials,m.ca=w.ca||null,m.hostname=Fa.server.scheme+'://'+
356
+ Fa.host,m.port=Fa.port[Fa.server.protocol][Fa.server.scheme],m.protocol=Fa.server.protocol,m.rejectUnauthorized=!1),w={ca:m.ca,hostname:m.hostname,port:m.port,path:m.path},'undefined'!=typeof m.protocol&&(w.protocol=m.protocol),'undefined'!=typeof m.rejectUnauthorized&&(w.rejectUnauthorized=m.rejectUnauthorized));F={method:ta.method,requirements:ta.requirements,namespace:ta.namespace||void 0,url:decodeURI(ta.url),rule:F+'@'+J,param:JSON.clone(ta.param),middleware:JSON.clone(ta.middleware),bundle:ta.bundle,
357
+ isXMLRequest:z.isXMLRequest,isWithCredentials:z.isWithCredentials};J=F.rule.replace('@'+J,'')||'_common';J={template:'undefined'!=typeof Fa.content.templates?Fa.content.templates[J]||Fa.content.templates._common:void 0,cacheless:Fa.cacheless};J=M(J,F);Fa=JSON.clone(Fa);J.conf=Fa;J.conf.content.routing[J.rule].param=F.param;J.template&&'undefined'==typeof J.template.ginaLoader&&(J.template.ginaLoader=J.conf.content.templates._common.ginaLoader);J.conf.content.routing[J.rule].param=F.param;delete J.middleware;
358
+ delete J.param;delete J.requirements;Fa=new (require(_(GINA_FRAMEWORK_DIR+'/core/controller/controller.js'),!0))(J);Fa.name=ta.param.control;Fa.setOptions(z,y,H,J);z='object'==typeof m.data&&0<m.data.count()?m.data:{};if(/^get|delete|put$/i.test(m.method)){y=0;for(let ia in z)'object'==typeof z[ia]&&encodeRFC5987ValueChars(JSON.stringify(z[ia])),y++}w.method=m.method;w.path=ta.url;m=require('util').promisify;var W={isValid:!1},la=!1;await m(Fa.query)(w,z).then(function(ia){W=ia}).catch(function(ia){la=
359
+ ia});la&&(console.error(la),W.error=la);return W},O=null;O=U?Ea:N;var D=function(m,z){var y=null,H=null;'undefined'==typeof u[m]&&'undefined'!=typeof z&&(u[m]=y=z);if('object'==typeof u[m])try{y=JSON.parse(JSON.stringify(u[m]))}catch(v){y=u[m]}else y=u[m];H='';U&&'undefined'!=typeof P&&(H=P[m].getAttribute('data-gina-form-field-label')||'');u[m]={target:U&&'undefined'!=typeof P?P[m]:null,name:m,value:y,valid:!1,label:H,exclude:!1};u[m].is=function(v,w,F){var J=!1,T='undefined'!=typeof window&&'undefined'!=
360
+ typeof window._currentValidatorAlias?window._currentValidatorAlias:'is';'undefined'!=typeof window&&window._currentValidatorAlias&&delete window._currentValidatorAlias;var ta=u[this.name].errors||{};S.data[this.name]=u[this.name].value;'undefined'==typeof ta.isRequired&&''==this.value&&!/^false$/i.test(this.value)&&0!=this.value||!ta.isRequired&&''==this.value&&!/^false$/i.test(this.value)&&0!=this.value?J=!0:ta.isRequired||'string'!=typeof this.value||''!=this.value||(J=!0);if(!J&&/^(true|false)$/i.test(v))J=
361
+ v;else if(!J){var Fa=null,W=null;if(/[!=>><a-z 0-9]+/i.test(v)){if((W=v.match(/\${0}[-_,.\[\]a-z0-9]+/ig))&&0<W.length){for(var la=0,ia=W.length;la<ia;++la)'undefined'!=typeof u[W[la]]&&W[la]&&(Fa=new RegExp('\\$'+W[la]+'(?!\\S+)','g'),v=''==u[W[la]].value?v.replace(Fa,'""'):'string'==typeof u[W[la]].value?v.replace(Fa,'"'+u[W[la]].value+'"'):v.replace(Fa,u[W[la]].value));try{v=v.replace(/(\(|\)|return)/g,''),J=/^\//.test(v)?eval(v+'.test("'+this.value+'")'):eval(v)}catch(xa){throw Error(xa.stack||
362
+ xa.message);}}}else if(v instanceof RegExp)J=v.test(this.value)?!0:!1;else if('boolean'==typeof v)J=v?!0:!1;else try{/\/(.*)\//.test(v)?(Fa=v.match(/\/(.*)\//).pop(),W=v.replace('/'+Fa+'/',''),J=(new RegExp(Fa,W)).test(this.value)):J=eval(v)}catch(xa){throw Error(xa.stack||xa.message);}}J?J&&'undefined'!=typeof ta[T]&&delete ta[T]:(ta[T]=C(this.error||w||S.errorLabels[T],this),'undefined'!=typeof F&&(ta.stack=F));this.valid=J;0<ta.count()&&(this.errors=ta);return u[this.name]};u[m].set=function(v){this.value=
363
+ S.data[this.name]=v;this.target.setAttribute('value',v);return u[this.name]};u[m].isEmail=function(){this.value=S.data[this.name]=this.value?this.value.toLowerCase():this.value;U&&this.target&&''!=this.target.value&&/[A-Z]+/.test(this.target.value)&&(this.target.value=this.value);var v=/^(([^<>()[\]\\.,;:\s@"]+(\.[^<>()[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(this.value)?!0:!1,w=u[this.name].errors||{};w.isRequired||
364
+ ''!=this.value||(v=!0);v?v&&'undefined'!=typeof w.isEmail&&delete w.isEmail:w.isEmail=C(this.error||S.errorLabels.isEmail,this);this.valid=v;0<w.count()&&(this.errors=w);return u[this.name]};u[m].isJsonWebToken=function(){this.value=S.data[this.name]=this.value?this.value.toLowerCase():this.value;U&&this.target&&''!=this.target.value&&/[A-Z]+/.test(this.target.value)&&(this.target.value=this.value);var v=/^[A-Za-z0-9-_=]+\.[A-Za-z0-9-_=]+\.?[A-Za-z0-9-_.+/=]*$/.test(this.value)?!0:!1,w=u[this.name].errors||
365
+ {};w.isRequired||''!=this.value||(v=!0);v?v&&'undefined'!=typeof w.isJsonWebToken&&delete w.isJsonWebToken:w.isJsonWebToken=C(this.error||S.errorLabels.isJsonWebToken,this);this.valid=v;0<w.count()&&(this.errors=w);return u[this.name]};u[m].isBoolean=function(){var v=null,w=u[this.name].errors||{};w.isRequired&&0==this.value&&(delete w.isRequired,this.errors=w);switch(this.value){case 'true':case !0:case 1:v=this.value=S.data[this.name]=!0;break;case 'false':case !1:case 0:v=this.value=S.data[this.name]=
366
+ !1}(v=null!==v?!0:!1)?v&&'undefined'!=typeof w.isBoolean&&delete w.isBoolean:w.isBoolean=C(this.error||S.errorLabels.isBoolean,this);this.valid=v;0<w.count()&&(this.errors=w);return u[this.name]};u[m].isNumber=function(v,w){var F=this.value,J=!1,T=!0,ta=!0,Fa=u[this.name].errors||{};try{'string'==typeof F&&/,|\./g.test(F)?F=S.data[this.name]=this.value=parseFloat(F.replace(/,/g,'.').replace(/\s+/g,'')):'string'==typeof F&&''!=F&&(F=S.data[this.name]=this.value=parseInt(F.replace(/\s+/g,'')))}catch(la){Fa.isNumber=
367
+ C(this.error||S.errorLabels.isNumber,this),this.valid=!1,0<Fa.count()&&(this.errors=Fa)}if(+F===+F&&(J=!0,!Fa.isRequired&&''!=F)){var W=F.toString().length;v&&'number'==typeof v&&W<v&&(T=!1,this.size=v);w&&'number'==typeof w&&W>w&&(ta=!1,this.size=w)}J&&T&&ta||(J||(Fa.isNumber=C(this.error||S.errorLabels.isNumber,this)),T&&ta||(T||(Fa.isNumberLength=C(this.error||S.errorLabels.isNumberMinLength,this)),ta||(Fa.isNumberLength=C(this.error||S.errorLabels.isNumberMaxLength,this)),v===w&&(Fa.isNumberLength=
368
+ C(this.error||S.errorLabels.isNumberLength,this))),J=!1);J&&'undefined'!=typeof Fa.isNumberLength&&delete Fa.isNumberLength;this.valid=J;this.value=S.data[this.name]=''!=F?Number(F):F;0<Fa.count()&&(this.errors=Fa);return u[this.name]};u[m].toInteger=function(){var v=this.value,w=u[this.name].errors||{};if(v)try{this.value=S.data[this.name]=Math.round(v)}catch(F){w.toInteger=C(this.error||S.errorLabels.toInteger,this),this.valid=!1,0<w.count()&&(this.errors=w)}return u[this.name]};u[m].isInteger=
369
+ function(v,w){var F=this.value,J=!1,T=!0,ta=!0,Fa=u[this.name].errors||{};+F===+F&&0===F%1&&(J=!0,Fa.isRequired||''==F||(v&&'number'==typeof v&&F.length<v&&(T=!1,this.size=v),w&&'number'==typeof w&&F.length>w&&(ta=!1,this.size=w)));J&&T&&ta||(J||(Fa.isInteger=C(this.error||S.errorLabels.isInteger,this)),T&&ta||(T||(Fa.isIntegerLength=C(this.error||S.errorLabels.isIntegerMinLength,this),J=!1),ta||(Fa.isIntegerLength=C(this.error||S.errorLabels.isIntegerMaxLength,this),J=!1),v===w&&(Fa.isIntegerLength=
370
+ C(this.error||S.errorLabels.isIntegerLength,this),J=!1)));this.valid=J;this.value=S.data[this.name]=Number(F);0<Fa.count()&&(this.errors=Fa);return u[this.name]};u[m].toFloat=function(v){'string'==typeof this.value&&(this.value=this.value.replace(/\s+/g,''),/,/.test(this.value)&&!/\./.test(this.value)?this.value=this.value.replace(/,/g,'.'):this.value=this.value.replace(/,/g,''));var w=S.data[this.name]=this.value,F=u[this.name].errors||{},J=!0;v?this.decimals=parseInt(v):'undefined'==typeof this.decimals&&
371
+ (this.decimals=2);if(w)if(this.isNumber().valid)try{Number.isFinite(w)||(w=this.value=S.data[this.name]=new Number(parseFloat(w.match(/[0-9.,]+/g).join('').replace(/,/,'.')))),U&&this.target.setAttribute('value',w)}catch(T){J=!1,F.toFloat=C(this.error||S.errorLabels.toFloat,this),this.valid=!1,0<F.count()&&(this.errors=F)}else J=!1,F.toFloat=C(this.error||S.errorLabels.toFloatNAN,this);else return u[this.name];this.decimals&&w&&!F.toFloat&&(this.value=S.data[this.name]=parseFloat(this.value.toFixed(this.decimals)));
372
+ this.valid=J;0<F.count()&&(this.errors=F);return u[this.name]};u[m].isFloat=function(v){'string'==typeof this.value&&(this.value=this.value.replace(/\s+/g,''));var w=S.data[this.name]=this.value;v=u[this.name].errors||{};'string'==typeof w&&/\./.test(w)&&Number.isFinite(Number(w));'string'==typeof w&&/,/g.test(w)&&(w=this.value=S.data[this.name]=Number(w.replace(/,/g,'.')));Number(w)===w&&0!==w%1?(this.value=S.data[this.name]=Number(w),w=!0):w=!1;v.isRequired||''!=this.value||(w=!0);w||(v.isFloat=
373
+ C(this.error||S.errorLabels.isFloat,this));this.valid=w;0<v.count()&&(this.errors=v);return u[this.name]};u[m].isRequired=function(v){if('boolean'==typeof v&&!v)return this.valid=!0,v=S.excluded.indexOf(this.name),-1<v&&S.excluded.splice(v,1),u[this.name];if(U&&this.target&&'INPUT'==this.target.tagName&&'undefined'!=typeof this.target.type&&'radio'==this.target.type){v=document.getElementsByName(this.name);for(var w=0,F=v.length;w<F;++w)if(v[w].checked){/true|false/.test(v[w].value)?this.value=S.data[this.name]=
374
+ /true/.test(v[w].value)?!0:!1:this.value=S.data[this.name]=v[w].value;this.valid=!0;break}}v='undefined'==typeof this.value||null==this.value||''==this.value||/^\s+/.test(this.value)?!1:!0;w=u[this.name].errors||{};v?v&&'undefined'!=typeof w.isRequired&&delete w.isRequired:w.isRequired=C(this.error||S.errorLabels.isRequired,this);this.valid=v;0<w.count()&&(this.errors=w);return u[this.name]};u[m].isString=function(v,w){var F=S.data[this.name]=this.value,J=!1,T=!0,ta=!0,Fa=u[this.name].errors||{};
375
+ 'string'!=typeof F||Fa.isRequired||''==F||(J=!0,v&&'number'==typeof v&&F.length<v&&(T=!1,this.size=v),w&&'number'==typeof w&&F.length>w&&(ta=!1,this.size=w));J&&T&&ta||(!J&&Fa.isRequired&&''==F?(J=!1,Fa.isString=C(this.error||S.errorLabels.isString,this)):J||Fa.isRequired||(J=!0),T&&ta||(J=!1,T||(Fa.isStringLength=C(this.error||S.errorLabels.isStringMinLength,this)),ta||(Fa.isStringLength=C(this.error||S.errorLabels.isStringMaxLength,this)),v===w&&(Fa.isStringLength=C(this.error||S.errorLabels.isStringLength,
376
+ this))));this.valid=J;0<Fa.count()&&(this.errors=Fa);return u[this.name]};u[m].isDate=function(v){var w=this.value,F=!1,J=u[this.name].errors||{},T=null;if(!w||''==w||/NaN|Invalid Date/i.test(w))return/NaN|Invalid Date/i.test(w)&&(console.warn('[FormValidator::isDate] Provided value for field `'+this.name+'` is not allowed: `'+w+'`'),J.isDate=C(this.error||S.errorLabels.isDate,this)),this.valid=F,0<J.count()&&(this.errors=J),u[this.name];if('undefined'==typeof v||'undefined'!=typeof v&&/true/i.test(v))v=
377
+ 'yyyy-mm-dd';if(w instanceof Date)w=w.format(v);else{try{T=v.match(/[^\/\- ]+/g)}catch(ia){throw Error('[FormValidator::isDate] Provided mask not allowed: `'+v+'`');}try{w=w.match(/[^\/\- ]+/g);var ta={},Fa;var W=0;for(Fa=T.length;W<Fa;++W)ta[T[W]]=w[W];for(var la in ta)v=v.replace(new RegExp(la,'g'),ta[la])}catch(ia){throw Error('[FormValidator::isDate] Provided value not allowed: `'+w+'`'+ia);}w=this.value=S.data[this.name]=new Date(v);if(/Invalid Date/i.test(w)||!1===w instanceof Date)return J.isRequired||
378
+ ''!=this.value?J.isDate=C(this.error||S.errorLabels.isDate,this):F=!0,this.valid=F,0<J.count()&&(this.errors=J),u[this.name];F=!0}this.valid=F;return w};u[m].format=function(v,w){var F=this.value;return F?F.format(v,w):u[this.name]};u[m].setFlash=function(v,w){'undefined'!=typeof w&&''!=w&&(this.error=w);return u[this.name]};u[m].setLabel=function(v){'undefined'!=typeof v&&''!=v&&(this.label=v);return u[this.name]};u[m].trim=function(v){if('boolean'==typeof v&&v)return this.value=this.value.replace(/^\s+|\s+$/,
379
+ ''),S.data[this.name]=S.data[this.name]=this.value,u[this.name]};u[m].exclude=function(v){if('boolean'==typeof v&&!v)return/^true|false$/i.test(this.value)&&(this.value=/^true$/i.test(this.value)?!0:!1,S.data[this.name]=this.value),u[this.name];this.isExcluded=!1;0>S.excluded.indexOf(this.name)&&(S.excluded.push(this.name),this.isExcluded=!0);return u[this.name]};u[m].query=O;u[m].getValidationContext=function(){return{isGFFCtx:U,self:u,local:S,replace:C}};if(Q()){y=z=null;try{for(let v in gina.forms.validators)y=
380
+ '/validators/'+v+'/main.js',S.errorLabels[v]='Condition not satisfied',U?(z=r(gina.forms.validators[v].data),z=z.replace(/(\)\s+\{|\)\{){1}/,'$&\n\tvar validationContext = this.getValidationContext(),isGFFCtx = validationContext.isGFFCtx,self = validationContext.self,local = validationContext.local,replace = validationContext.replace;')):z=gina.forms.validators[v].toString(),u[m][v]=eval('('+z+')\n//# sourceURL='+v+'.js')}catch(v){throw Error('[UserFormValidator] Could not evaluate: `'+y+'`\n'+v.stack);
381
+ }}};for(let m in u)D(m,u[m]);u.addField=function(m,z){'undefined'==typeof u[m]&&D(m,z)};u.isValid=function(){return 0<u.getErrors().count()?!1:!0};u.setErrors=function(m){if(!m)return{};for(var z in u)if('object'==typeof u[z]){for(var y in u[z])'object'==typeof m[z]&&'undefined'!=typeof m[z][y]&&('undefined'!=typeof u[z].valid&&/^true$/i.test(u[z].valid)?delete m[z][y]:('undefined'==typeof u[z].errors&&(u[z].errors={}),u[z].errors[y]=m[z][y]));('undefined'==typeof u[z].errors&&'undefined'!=typeof m[z]||
382
+ 'undefined'!=typeof u[z].errors&&0==u[z].errors.count()&&'undefined'!=typeof m[z])&&delete m[z]}return m};u.getErrors=function(m){var z={};if('undefined'!=typeof m)return'undefined'!=typeof u[m]&&u[m]&&'undefined'!=typeof u[m].errors&&0<u[m].errors.count()&&(z[m]=u[m].errors),z;for(var y in u)'object'==typeof u[y]&&'undefined'!=typeof u[y].errors&&0<u[y].errors.count()&&(z[y]=u[y].errors);return z};u.toData=function(){if(0<S.excluded.length)for(var m=0,z=S.excluded.length;m<z;++m)'undefined'!=typeof S.data[S.excluded[m]]&&
383
+ delete S.data[S.excluded[m]];return S.data};var C=function(m,z){var y=m.match(/%[a-z]+/gi);if(y)for(var H=0,v=y.length;H<v;++H)m=m.replace(new RegExp(y[H],'g'),z[S.keys[y[H]]]);return m};u.setErrorLabels=function(m){'undefined'!=typeof m&&(S.errorLabels=M(m,S.errorLabels))};return u}'undefined'!==typeof module&&module.exports?module.exports=FormValidatorUtil:'function'===typeof define&&define.amd&&define('lib/form-validator',[],function(){return FormValidatorUtil});
384
384
  function Routing(){var A='undefined'!==typeof module&&module.exports?!1:!0,P={allowedMethods:['get','post','put','delete'],reservedParams:['controle','file','title','namespace','path'],notFound:{}};P.allowedMethodsString=P.allowedMethods.join(',');var V=null,na=null,U=null;A?(na&&'function'==typeof na||(na=require('lib/merge')),U&&'function'==typeof U||(U=require('lib/form-validator'))):(require('fs'),require('util'),require('../../inherits'),na=require('../../merge'),V=require(__dirname+'/../../../core/plugins')||
385
385
  getContext('gina').plugins,U=V.Validator);P.getUrlProps=function(u,G){var r={};if(A){var ea=window.gina.config;r.hostname=ea.hostname;'undefined'!=typeof u&&(u=routing.getRoute('webroot@'+u),r.hostname=u.hostname,r.host=u.host,r.webroot=u.webroot)}else ea=getContext('gina').config,'undefined'!=typeof getContext('argvFilename')&&(ea.getRouting=getContext('gina').Config.instance.getRouting),'undefined'==typeof u&&(u=ea.bundle),'undefined'==typeof G&&(G=ea.env),r.hostname=ea.envConf[u][G].hostname,r.host=
386
386
  ea.envConf[u][G].host,r.webroot=ea.envConf[u][G].server.webroot;return r};P.compareUrls=async function(u,G,r,ea,Ea){'undefined'==typeof r&&(r={routing:{}});if(/,/.test(G)){var N=0;G=G.split(/,/g);for(var O=G.length,D={past:!1,request:r};N<O&&!D.past;)D=await M(u,G[N],r,ea,Ea),++N;return D}return await M(u,G,r,ea,Ea)};var M=async function(u,G,r,ea,Ea){var N=u.url.split(/\//);G=G.split(/\//);var O=0,D=0,C=G.length,m=0,z={},y=0,H=r.method.toLowerCase(),v=u.method.toLowerCase(),w=!1;if('undefined'!=typeof u.requirements&&
@@ -442,47 +442,47 @@ typeof g)if(q=l.replace(/\-/g,'.'),'undefined'!=typeof h)x.rule=Da(q);else{if('u
442
442
  g+'` is not a valid rule');b&&'undefined'!=typeof this.isPopinContext&&/true/i.test(this.isPopinContext)&&(b.isPopinContext=this.isPopinContext);b&&!x.binded&&xb(b,q)}if(!x)throw Error('[ FormValidator::validateFormById(formId, customRule) ] `'+l+'` not found');return x||null},v=function(l){var g=l.form.getAttribute('id');if(!/^true$/i.test(r.$forms[g].isValidating)){var h=l.parentNode;l=!1;g=h.getElementsByTagName('div');/form\-item\-warning/.test(h.className)?h.className=h.className.replace(/form\-item\-warning/,
443
443
  'form-item-error'):/form\-item\-error/.test(h.className)&&(h.className=h.className.replace(/form\-item\-error/,'form-item-warning'),l=!0);h=0;for(var b=g.length;h<b;++h)if(/form\-item\-error\-message/.test(g[h].className)){g[h].className=l?g[h].className+' hidden':g[h].className.replace(/(\s+hidden|hidden)/,'');break}}},w={},F=function(l,g,h,b){if(M)var x=null;var q=!1;if('undefined'!=typeof l.dataset.ginaFormIsResetting&&/^(true)$/i.test(l.dataset.ginaFormIsResetting))g={},w={},l.dataset.ginaFormIsResetting=
444
444
  !1;else if(/^(true)$/i.test(l.dataset.ginaFormLiveCheckEnabled)&&'undefined'!=typeof b){var p='string'!=typeof l.id?l.getAttribute('id'):l.id;'undefined'==typeof w[p]&&(w[p]={});if(0<g.count()){if(w[p][b]={},w[p][b]=Q(g[b],w[p][b]),0==w[p][b].count()&&delete w[p][b],g=w[p],!r.$forms[p].sent||r.$forms[p].isValidating)q=!0}else'undefined'!=typeof w[p][b]&&(delete w[p][b],'undefined'!=typeof window.gina.validator.$forms[p].errors&&'undefined'!=typeof window.gina.validator.$forms[p].errors[b]&&delete window.gina.validator.$forms[p].errors[b]),
445
- 'undefined'!=typeof r.$forms&&'undefined'!=typeof r.$forms[p]&&'undefined'!=typeof r.$forms[p].errors&&0==r.$forms[p].errors.count()&&Ka(l,!0),'undefined'!=typeof w[p]&&0==w[p].count()?delete w[p]:g=w[p]}var R=null;p=l.getAttribute('id');h='undefined'!=typeof h?h:{};for(var K=0,ha=l.length;K<ha;++K){var Aa=l[K];if('undefined'==typeof b||b==Aa.name){if(/form\-item\-wrapper$/.test(Aa.parentNode.className)){var da=Aa.parentNode.parentNode;var fa=Aa.parentNode}else da=Aa.parentNode,fa=Aa;var E=Aa.getAttribute('name');
446
- var oa=Aa.getAttribute('data-gina-form-errors');if(E){if('undefined'!=typeof g[E]&&!/(form\-item\-error|form\-item\-warning)/.test(da.className)){da.className=q?da.className+(''==da.className?'form-item-warning':' form-item-warning'):da.className+(''==da.className?'form-item-error':' form-item-error');R=document.createElement('div');R.className=q?'form-item-error-message hidden':'form-item-error-message';for(var ra in g[E])'stack'!=ra&&(da=document.createElement('p'),da.appendChild(document.createTextNode(g[E][ra])),
447
- R.appendChild(da)),M&&(x||={},x[E]||(x[E]={}),x[E][ra]=g[E][ra]);'hidden'!=fa.type&&insertAfter(fa,R)}else if('undefined'==typeof g[E]&&/(form\-item\-error|form\-item\-warning)/.test(da.className)||'undefined'!=typeof g[E]&&0==g[E].count()&&/(form\-item\-error|form\-item\-warning)/.test(da.className)){E=da.getElementsByTagName('div');fa=0;for(oa=E.length;fa<oa;++fa)if(/form\-item\-error\-message/.test(E[fa].className)){E[fa].parentElement.removeChild(E[fa]);break}da.className=da.className.replace(/(\s+form\-item\-error|form\-item\-error|\s+form\-item\-warning|form\-item\-warning)/,
448
- '')}else if('undefined'!=typeof g[E]&&oa){da=da.getElementsByTagName('div');oa=0;for(var ja=da.length;oa<ja;++oa)if('form-item-error-message'==da[oa].className){da[oa].parentElement.removeChild(da[oa]);R=document.createElement('div');R.setAttribute('class','form-item-error-message');for(ra in g[E])da=document.createElement('p'),da.appendChild(document.createTextNode(g[E][ra])),R.appendChild(da),M&&(x||={},x[E]||(x[E]={}),x[E][ra]=g[E][ra]);break}R&&'hidden'!=fa.type&&insertAfter(fa,R)}if('undefined'!=
449
- typeof b&&b===Aa.name)break}}}x?(triggerEvent(gina,l,'error.'+p,g),M&&U&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&(gina.forms.errors||(gina.forms.errors={}),l={id:p,errors:x},window.ginaToolbar.update('forms',l))):M&&U&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&(gina.forms.errors||(gina.forms.errors={}),l={id:p,errors:{}},U&&window.ginaToolbar.update('forms',l));if(gina&&U&&M&&r.$forms[p].isSubmitting&&/^true$/i.test(r.$forms[p].isSubmitting)&&'undefined'!=typeof window.ginaToolbar&&
450
- window.ginaToolbar&&h)try{window.ginaToolbar.update('data-xhr',h)}catch(Z){throw Z;}},J=function(l){var g=null;'undefined'==typeof l&&'undefined'!=typeof this.id&&(l=this.id);/^string$/i.test(typeof l)?(g=l.replace(/#/,''),g=document.getElementById(g)):l instanceof HTMLFormElement?g=l:/^object$/i.test(typeof l)&&(g=l.target);if(!g)throw Error('[ FormValidator::resetErrorsDisplay([ formId | <form> ]) ] `'+l+'` not found');g.dataset.ginaFormIsResetting=!0;F(g,{});return g},T=function(l){if('undefined'==
451
- typeof l){var g='undefined'!=typeof this.target?this.target.getAttribute('id'):this.getAttribute('id');l=r.$forms[g]}else if('string'==typeof l){g=l.replace(/#/,'');if('undefined'==typeof r.$forms[g])throw Error('[ FormValidator::resetErrorsDisplay([formId]) ] `'+l+'` not found');l=r.$forms[g]}if(l.fieldsSet){var h;for(h in l.fieldsSet){g=document.getElementById(h);var b=g.tagName.toLowerCase();var x=g.tagName;/textarea/i.test(x)?(x=l.fieldsSet[h].defaultValue,g.value=x,triggerEvent(gina,g,'change')):
452
- 'input'==b?(x=l.fieldsSet[h].defaultValue,/$(on|true|false)$/i.test(x)&&(x=/$(on|true)$/i.test(x)?!0:!1),/^(checkbox|radio)$/i.test(g.type)?g.checked=l.fieldsSet[h].defaultChecked:/^(checkbox|radio)$/i.test(g.type)||(g.value=x),triggerEvent(gina,g,'change')):'select'==b&&(x=l.fieldsSet[h].selectedIndex||0,g.selectedIndex=x,g.dataset.value=g.options[g.selectedIndex].value,triggerEvent(gina,g,'change'))}}return l},ta=function(){var l=null,g=null;'undefined'!=typeof this.getAttribute?(l=this.getAttribute('id'),
453
- g=this):'undefined'!=typeof this.target&&null!=this.target&&'undefined'!=typeof this.target.getAttribute&&(l=this.target.getAttribute('id'),g=this.target);if('undefined'==typeof r.$forms[l])throw Error('[ FormValidator::submit() ] not `$form` binded. Use `FormValidator::getFormById(id)` or `FormValidator::validateFormById(id)` first ');triggerEvent(gina,g,'submit');return this},Fa=function(l,g){var h=this.target,b=h.getAttribute('id'),x=r.$forms[b]||this,q=null,p=null,R=null,K=null;if(!('undefined'!=
454
- typeof x.isSending&&/^true$/i.test(x.isSending)||'undefined'!=typeof x.sent&&/^true$/i.test(x.sent))){r.$forms[b].isSending=!0;g='undefined'!=typeof g?Q(g,D):D;'undefined'!=typeof x.id&&(g.headers['X-Gina-Form-Id']=x.id,'undefined'!=typeof gina.forms.rules&&0<x.rules.count()&&'undefined'!=typeof x.rules[x.id]&&(g.headers['X-Gina-Form-Rule']=x.id+'@'+gina.config.bundle));'undefined'!=typeof x.target.dataset.ginaFormRule&&(g.headers['X-Gina-Form-Rule']=x.target.dataset.ginaFormRule+'@'+gina.config.bundle);
455
- y()&&($activePopin=gina.popin.getActivePopin(),$activePopin.isOpen&&('undefined'!=typeof $activePopin.id&&(g.headers['X-Gina-Popin-Id']=$activePopin.id),'undefined'!=typeof $activePopin.name&&(g.headers['X-Gina-Popin-Name']=$activePopin.name)));(K=h.getAttribute('data-gina-form-event-on-submit-success')||h.getAttribute('data-gina-form-event-on-submit-error')?!0:!1)&&xa(x);var ha=h.getAttribute('action')||g.url,Aa=h.getAttribute('method')||g.method;Aa=Aa.toUpperCase();g.method=Aa;g.url=ha;O||=setupXhr(g);
456
- ha=h.getAttribute('enctype')||g.headers['Content-Type'];if(g.withCredentials){if('withCredentials'in O)g.isSynchrone?O.open(g.method,g.url,g.isSynchrone):O.open(g.method,g.url);else if('undefined'!=typeof XDomainRequest)O=new XDomainRequest,O.open(g.method,g.url);else{O=null;q='CORS not supported: the server is missing the header `"Access-Control-Allow-Credentials": true` ';triggerEvent(gina,h,'error.'+b,q);return}O.responseType='undefined'!=typeof g.responseType?g.responseType:'';O.withCredentials=
457
- !0}else g.isSynchrone?O.open(g.method,g.url,g.isSynchrone):O.open(g.method,g.url);for(var da in g.headers)'Content-Type'==da&&'undefined'!=typeof ha&&null!=ha&&''!=ha||O.setRequestHeader(da,g.headers[da]);if(O){O.onreadystatechange=function(Z){x.isSubmitting=!1;x.isSending=!1;setTimeout(function(){x.sent=!1},1E3);Z=/Google Inc/i.test(navigator.vendor)?50:0;2==O.readyState&&(R=/^attachment;/.test(O.getResponseHeader('Content-Disposition'))?!0:!1,!O.responseType&&R&&(O.responseType='blob'));if(4==O.readyState){var Ga=
458
- null,Pa=null,$a=O.getResponseHeader('Content-Type');if(/^2/.test(O.status)){try{if(/blob/.test(O.responseType)||R){if('undefined'==typeof $a||null==$a)$a='application/octet-stream';Pa=new Blob([this.response],{type:$a});var ib=document.createElement('a');ib.style='display: none';document.body.appendChild(ib);var Cb=window.URL.createObjectURL(Pa);ib.href=Cb;var zb=O.getResponseHeader('Content-Disposition');ib.download=zb.match('=(.*)')[0].substr(1);ib.click();window.URL.revokeObjectURL(Cb);q={status:O.status,
459
- statusText:O.statusText,responseType:Pa.type,type:Pa.type,size:Pa.size}}else q=O.responseText;/\/json/.test($a)&&(q=JSON.parse(O.responseText),'undefined'==typeof q.status&&(q.status=O.status));if(/\/html/.test($a)&&(q={contentType:$a,content:O.responseText},'undefined'==typeof q.status&&(q.status=O.status),'undefined'!=typeof gina.popin&&gina.hasPopinHandler&&(Ga=gina.popin.getActivePopin()))){p={};try{p=(new DOMParser).parseFromString(q.content,'text/html').getElementById('gina-without-layout-xhr-data'),
460
- p=JSON.parse(decodeURIComponent(p.value)),XHRView=(new DOMParser).parseFromString(q.content,'text/html').getElementById('gina-without-layout-xhr-view'),XHRView=JSON.parse(decodeURIComponent(XHRView.value)),gina&&M&&typeof window.ginaToolbar&&'undefined'!=typeof p&&window.ginaToolbar.update('data-xhr',p),gina&&M&&typeof window.ginaToolbar&&'undefined'!=typeof XHRView&&window.ginaToolbar.update('view-xhr',XHRView)}catch(X){throw X;}Ga.loadContent(q.content);q=p;triggerEvent(gina,h,'success.'+b,q);return}p=
461
- x.eventData.success=q;if(gina&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&p)try{M&&'undefined'!=typeof p&&!/\/html|\/json/.test($a)&&window.ginaToolbar.update('data-xhr',p)}catch(X){throw X;}/^gina\-upload/i.test(b)&&W(gina,h,'success',b,q);var qb=!1;'undefined'!=typeof q.isXhrRedirect&&/^true$/i.test(q.isXhrRedirect)&&(qb=!0);if('undefined'!=typeof gina.popin&&gina.hasPopinHandler&&'undefined'!=typeof q.popin||'undefined'!=typeof gina.popin&&gina.hasPopinHandler&&'undefined'!=typeof q.location&&
462
- qb){Ga=gina.popin.getActivePopin();if(!Ga&&'undefined'!=typeof q.popin){if('undefined'!=typeof q.popin&&'undefined'==typeof q.popin.name)throw Error('To get a `$popin` instance, you need at list a `popin.name`.');Ga=gina.popin.getPopinByName(q.popin.name);if(!Ga)throw Error('Popin with name: `'+q.popin.name+'` not found.');}if('undefined'!=typeof q.popin&&'undefined'!=typeof q.popin.close){Ga.isRedirecting=!1;Ga.close();var Mb=q.popin.reload?q.popin.reload:!1;q.popin.location||q.popin.url||(delete q.popin,
463
- Mb&&(q.popin={reload:Mb}))}if('undefined'!=typeof q.popin&&'undefined'!=typeof q.popin.location||'undefined'!=typeof q.popin&&'undefined'!=typeof q.popin.url||'undefined'!=typeof q.location&&qb){qb=null;Ga&&(qb=Ga.name,Ga.isRedirecting=!0);'undefined'!=typeof q.popin&&'undefined'!=typeof q.popin.target&&(q.popin.target='_'+q.popin.target);var Ya=q.location||q.popin.location||q.popin.url;if('undefined'!=typeof q.popin&&'undefined'!=typeof q.popin.name&&qb!=q.popin.name){Ga&&Ga.isOpen&&Ga.close();qb=
464
- q.popin.name;Ga=gina.popin.getPopinByName(qb);if(!Ga)throw Error('Popin with name `'+qb+'` not found !');console.debug('Validator::Popin now redirecting [1-c]');Ga.load(Ga.name,Ya,Ga.options)}else Ga&&(console.debug('Validator::Popin now redirecting [1-d]'),Ga&&Ga.isOpen&&Ga.close(),Ga.load(Ga.name,Ya,Ga.options));if(Ga&&!Ga.isOpen)return setTimeout(function(X){X.isOpen||X.open()},50,Ga)}}triggerEvent(gina,h,'success.'+b,q);K&&triggerEvent(gina,h,'success.'+b+'.hform',q)}catch(X){q={status:422,error:X.message,
465
- stack:X.stack};p=x.eventData.error=q;if(gina&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&p)try{M&&'undefined'!=typeof p&&window.ginaToolbar.update('data-xhr',p)}catch(ka){throw ka;}/^gina\-upload/i.test(b)&&W(gina,h,'error',b,q);triggerEvent(gina,h,'error.'+b,q);K&&triggerEvent(gina,h,'error.'+b+'.hform',q)}if('undefined'!=typeof q&&'undefined'!=typeof q.location)return window.location.hash='',q.location=/^http/.test(q.location)||/^\//.test(q.location)?q.location:location.protocol+
466
- '//'+q.location,setTimeout(()=>{window.location.href=q.location},Z)}else if(0!=O.status)if(q={status:O.status},/blob/.test(O.responseType)){Pa=new Blob([this.response],{type:'text/plain'});var cb=new FileReader,ca='';cb.addEventListener('loadend',X=>{/string/i.test(typeof X.srcElement.result)?ca+=X.srcElement.result:'object'==typeof X.srcElement.result?q=Q(q,X.srcElement.result):q.message+=X.srcElement.result;if(/2/.test(cb.readyState)){if(/^(\{|\[)/.test(ca))try{q=Q(q,JSON.parse(ca))}catch(ka){q=
467
- Q(q,ka)}q.message||delete q.message;p=x.eventData.error=q;if(gina&&M&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&p)try{window.ginaToolbar.update('data-xhr',p)}catch(ka){throw ka;}/^gina\-upload/i.test(b)&&W(gina,h,'error',b,q);triggerEvent(gina,h,'error.'+b,q);K&&triggerEvent(gina,h,'error.'+b+'.hform',q)}});cb.readAsText(Pa)}else{if(/^(\{|\[)/.test(O.responseText))try{q=Q(JSON.parse(O.responseText),q)}catch(X){q=Q(X,q)}else'object'==typeof O.responseText?q=Q(O.responseText,q):q.message=
468
- O.responseText;if('undefined'!=typeof q&&'undefined'!=typeof q.error&&q.fields&&'object'==typeof q.fields){Ya='undefined'!=typeof q.message?q.message:null;Z={};for(qb in q.fields)Ga={},Ga[qb]={},Ga[qb].isApiError=q.fields[qb],Ya&&!Ga[qb].isApiError&&(Ga[qb].isApiError=q.error),Z[qb]=Ga[qb],F(x.target,Ga,l,qb);q.fields=Z}p=x.eventData.error=q;if(gina&&M&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&p)try{window.ginaToolbar.update('data-xhr',p)}catch(X){throw X;}/^gina\-upload/i.test(b)&&
469
- W(gina,h,'error',b,q);triggerEvent(gina,h,'error.'+b,q);K&&triggerEvent(gina,h,'error.'+b+'.hform',q)}}};O.onprogress=function(Z){var Ga='0';Z.lengthComputable&&(Ga=Z.loaded/Z.total,Ga=parseInt(100*Ga));Z={status:100,progress:Ga};x.eventData.onprogress=Z;triggerEvent(gina,h,'progress.'+b,Z)};O.ontimeout=function(Z){q={status:408,error:'Request Timeout'};x.eventData.ontimeout=q;/^gina\-upload/i.test(b)&&W(gina,h,'error',b,q);triggerEvent(gina,h,'error.'+b,q);K&&triggerEvent(gina,h,'error.'+b+'.hform',
470
- q)};l||(l=event.detail.data);if(l){g=!1;if('object'==typeof l){da=[];Aa=0;var fa={};try{if(l instanceof FormData){var E=event.currentTarget.getAttribute('data-gina-form-upload-group')||'untagged',oa,ra;for([oa,ra]of l.entries())ra instanceof File?(g||=!0,da[Aa]={key:oa,group:E,file:ra,bin:''},++Aa):fa[oa]=ra}else l=JSON.stringify(l);if(g&&0<da.length){var ja='--ginaWKBoundary'+ba.v4().replace(/\-/g,'');return ia(da,ja,'',0,function(Z,Ga,Pa){if(Z)/^gina\-upload/i.test(b)&&W(gina,h,'error',b,Z),triggerEvent(gina,
471
- h,'error.'+b,Z),K&&triggerEvent(gina,h,'error.'+b+'.hform',Z);else return Pa&&(O.setRequestHeader('Content-Type','multipart/form-data; boundary='+ja),O.send(Ga),x.sent=!0,M&&U&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&(gina.forms.sent||(gina.forms.sent={}),window.ginaToolbar.update('forms',{id:b,sent:Ga}))),!1})}'undefined'!=typeof fa&&0<fa.count()&&(l=JSON.stringify(fa))}catch(Z){/^gina\-upload/i.test(b)&&W(gina,h,'error',b,Z),triggerEvent(gina,h,'error.'+b,Z),K&&triggerEvent(gina,
472
- h,'error.'+b+'.hform',Z)}}g||('undefined'!=typeof ha&&null!=ha&&''!=ha&&O.setRequestHeader('Content-Type',ha),O.send(l))}else'undefined'!=typeof ha&&null!=ha&&''!=ha&&O.setRequestHeader('Content-Type',ha),O.send();x.sent=!0;M&&U&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&(gina.forms.sent||(gina.forms.sent={}),E={id:b,sent:'string'==typeof l?JSON.parse(l):l},window.ginaToolbar.update('forms',E))}}},W=function(l,g,h,b,x){l=g.uploadProperties||null;if(!l)throw Error('No uploadProperties found !!');
473
- g=document.getElementById(l.uploadTriggerId);b=null;var q=x.files||[],p=null;l.hasPreviewContainer&&(b=document.getElementById(l.previewContainer.id))&&(b.innerHTML='');l.errorField&&(p=document.getElementById(l.errorField));p&&(p.style.display='none');if(p&&'success'!=h){var R=x.message||x.error;p.innerHTML='<p>'+R+'</p>';fadeIn(p)}else if(p||'success'==h)for(h=0,x=q.length;h<x;++h){var K=b.id.replace(/\-preview/,'-'+h+'-reset-trigger');R=!1;p=document.getElementById(K);var ha=['reset','js-upload-reset'];
474
- p?(/a/i.test(p.tagName)&&(p.href='#'),p.innerHTML&&''!=p.innerHTML||(p.innerHTML=g.getAttribute('data-gina-form-upload-reset-label')||'Reset'),'undefined'==typeof p.className&&(p.className=''),K=Q(p.className.split(/\s+/g),ha),p.className=K.join(' ')):(R=!0,p=document.createElement('A'),p.href='#',p.innerHTML=g.getAttribute('data-gina-form-upload-reset-label')||'Reset',p.className=ha.join(' '),p.id=K);p.style.display='none';if('undefined'==typeof q[h].preview&&l.hasPreviewContainer&&/^image/.test(q[h].mime)&&
475
- ''!=q[h].location){K=document.createElement('IMG');K.src=q[h].tmpUri;K.style.display='none';K.setAttribute('data-upload-original-filename',q[h].originalFilename);K.setAttribute('data-upload-reset-link-id',p.id);ha=b.getAttribute('data-preview-max-width')||null;if(K.width&&ha&&K.width>ha){var Aa=K.width/ha;K.width=ha;K.height/=Aa}else!K.width&&ha&&(K.width=ha);/ul/i.test(l.previewContainer.tagName)?(ha=document.createElement('LI'),ha.className='item',ha.appendChild(K),b.appendChild(ha)):b.appendChild(K);
476
- fadeIn(K)}K=l.uploadFields[h];for(var da in K)if('name'==da&&''!=K[da].value||!q[h][da]||'preview'==da&&'undefined'==typeof q[h][da]||/(height|width)/i.test(da)&&!/^image/.test(q[h].mime))/(preview|height|width)/i.test(da)&&(ha=document.getElementById(K[da].id))&&ha.parentNode.removeChild(ha);else if(K[da].value=q[h][da],'preview'==da)for(var fa in q[h][da])if('undefined'!=typeof q[h][da][fa]&&'undefined'!=typeof K[da][fa]&&(K[da][fa].value=q[h][da][fa]),'tmpUri'==fa&&l.hasPreviewContainer){Aa=document.createElement('IMG');
477
- Aa.src=q[h][da].tmpUri;Aa.style.display='none';Aa.setAttribute('data-upload-original-filename',q[h].originalFilename);Aa.setAttribute('data-upload-preview-original-filename',q[h][da].originalFilename);Aa.setAttribute('data-upload-reset-link-id',p.id);if(ha=b.getAttribute('data-preview-max-width')||null)Aa.width=ha;/ul/i.test(l.previewContainer.tagName)?(ha=document.createElement('LI'),ha.className='item',ha.appendChild(Aa),b.appendChild(ha)):b.appendChild(Aa);fadeIn(Aa)}l.hasPreviewContainer&&(/ul/i.test(l.previewContainer.tagName)?
478
- (ha=document.createElement('LI'),ha.className='item',R&&ha.appendChild(p),b.appendChild(ha)):R&&b.appendChild(p));Ub('reset',g,h);fadeIn(p)}else throw Error(R);},la=function(l,g){console.debug(g+' input files');var h=/reset/i.test(g)?!0:!1,b=null,x=null,q=document.getElementById(l.id+'-preview').childNodes,p=null,R=l.customFiles,K=[];for(let ha=0,Aa=q.length;ha<Aa;ha++)if(/img/i.test(q[ha].tagName)){h?(b=q[ha].getAttribute('data-upload-original-filename'),K.push(b),(x=q[ha].getAttribute('data-upload-preview-original-filename'))&&
479
- K.push(x)):(b=q[ha].src.substr(q[ha].src.lastIndexOf('/')+1),K.push(b));for(let da=0,fa=R.length;da<fa;da++)if(R[da].name==b){p=h?document.getElementById(q[ha].getAttribute('data-upload-'+g+'-link-id')):document.getElementById(R[da].deleteLinkId);p.style.display='none';q[ha].style.display='none';R.splice(da,1);l.customFiles=R;h&&(l.value=R.join(', C:\\fakepath\\'));b=new RegExp('^'+(l.name+'['+da+']').replace(/\-|\[|\]|\./g,'\\$&'));for(let oa=0,ra=l.form.length;oa<ra;oa++)if(x=l.form[oa].dataset.ginaFormUploadIsLocked||
480
- !1,b.test(l.form[oa].name)&&!/true/i.test(x)&&(l.form[oa].remove(),ra--,oa--,gina&&M&&U&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar))try{window.ginaToolbar.update('data-xhr',{files:R})}catch(ja){throw ja;}x=l.getAttribute('data-gina-form-upload-'+g+'-action');if(!x||'undefined'==typeof x||''==x||/404/.test(x))throw Error('input file `'+l.id+'` error: `data-gina-form-upload-'+g+'-action` is required. You need to provide a valide url.');(b=l.getAttribute('data-gina-form-upload-'+g+'-method'))&&
481
- 'undefined'!=typeof b&&''!=b?b=b.toUpperCase():h?b='POST':(b=1<K.length?'POST':'DELETE',console.warn('`data-gina-form-upload-'+g+'-method` was not defined. Switching to `'+b+'` by default.'));let E=l.getAttribute('data-gina-form-upload-'+g+'-is-synchrone');if(/null/i.test(E)||'undefined'==typeof b||''==b)E=!0;x=setupXhr({url:x,method:b,isSynchrone:E,headers:{'Content-Type':'application/x-www-form-urlencoded; charset=UTF-8','X-Requested-With':'XMLHttpRequest'}});/GET|DELETE/i.test(b)?x.send():x.send(JSON.stringify({files:K}));
482
- if(/none/i.test(window.getComputedStyle(l).display)){if(/none/i.test(l.parentElement.style.display)){l.parentElement.style.display='block';return}l.style.display='block'}removeListener(gina,$uploadResetTrigger,'click',function(){p.remove();q[ha].remove()});Aa--;ha--;break}}},ia=function(l,g,h,b,x){var q=new FileReader;q.addEventListener('load',function(p){p.preventDefault();try{var R=this.result,K=void 0;p='';var ha=null;'undefined'==typeof K&&(K=8);var Aa=K/8;switch(K){case 8:ha=new Uint8Array(R);
483
- break;case 16:ha=new Uint16Array(R);break;case 32:ha=new Uint32Array(R);break;default:ha=new Uint8Array(R)}var da=ha.length,fa=Math.pow(2,8)+Aa;R=0;for(Aa=K=null;R<da;R+=fa)K=Math.min(fa,da-R),Aa=ha.subarray(R,R+K),p+=String.fromCharCode.apply(null,Aa);l[this.index].bin+=p;l[this.index].file.type||(l[this.index].file.type='application/octet-stream')}catch(E){return x(E,null,!0)}h+='--'+g+'\r\n';h+='Content-Disposition: form-data; name="'+l[this.index].key+'"; group="'+l[this.index].group+'"; filename="'+
484
- l[this.index].file.name+'"\r\nContent-Type: '+l[this.index].file.type+'\r\nContent-Length: '+l[this.index].bin.length+'\r\n\r\n';h+=l[this.index].bin+'\r\n';++this.index;this.index==l.length?(h+='--'+g+'--',x(!1,h,!0)):ia(l,g,h,this.index,x)},!1);q.index=b;l[b].bin='';q.readAsArrayBuffer(l[b].file)},xa=function(l){var g=l.target.getAttribute('data-gina-form-event-on-submit-success')||null;if(null!=g)if(/\((.*)\)/.test(g))eval(g);else l.on('success.hform',window[g]);g=l.target.getAttribute('data-gina-form-event-on-submit-error')||
485
- null;if(null!=g)if(/\((.*)\)/.test(g))eval(g);else l.on('error.hform',window[g])},ma=function(l){var g=null,h=l;if(!r.$forms)throw Error('`$forms` collection not found');if('undefined'==typeof h)if('undefined'!=typeof this.id&&''!=this.id&&null!=this.id)h=this.id;else throw Error('[ FormValidator::destroy(formId) ] `formId` is missing');if('string'==typeof h)h=h.replace(/#/,'');else{if('object'!=typeof h||Array.isArray(h))throw Error('[ FormValidator::destroy(formId) ] `formId` should be a `string`');
445
+ ('undefined'!=typeof r.$forms&&'undefined'!=typeof r.$forms[p]&&'undefined'!=typeof r.$forms[p].errors&&0==r.$forms[p].errors.count()||'undefined'!=typeof r.$forms&&'undefined'!=typeof r.$forms[p]&&!r.$forms[p].errors)&&Ka(l,!0),'undefined'!=typeof w[p]&&0==w[p].count()?delete w[p]:g=w[p]}var R=null;p=l.getAttribute('id');h='undefined'!=typeof h?h:{};for(var K=0,ha=l.length;K<ha;++K){var Aa=l[K];if('undefined'==typeof b||b==Aa.name){if(/form\-item\-wrapper$/.test(Aa.parentNode.className)){var da=
446
+ Aa.parentNode.parentNode;var fa=Aa.parentNode}else da=Aa.parentNode,fa=Aa;var E=Aa.getAttribute('name');var oa=Aa.getAttribute('data-gina-form-errors');if(E){if('undefined'!=typeof g[E]&&!/(form\-item\-error|form\-item\-warning)/.test(da.className)){da.className=q?da.className+(''==da.className?'form-item-warning':' form-item-warning'):da.className+(''==da.className?'form-item-error':' form-item-error');R=document.createElement('div');R.className=q?'form-item-error-message hidden':'form-item-error-message';
447
+ for(var ra in g[E])'stack'!=ra&&(da=document.createElement('p'),da.appendChild(document.createTextNode(g[E][ra])),R.appendChild(da)),M&&(x||={},x[E]||(x[E]={}),x[E][ra]=g[E][ra]);'hidden'!=fa.type&&insertAfter(fa,R)}else if('undefined'==typeof g[E]&&/(form\-item\-error|form\-item\-warning)/.test(da.className)||'undefined'!=typeof g[E]&&0==g[E].count()&&/(form\-item\-error|form\-item\-warning)/.test(da.className)){E=da.getElementsByTagName('div');fa=0;for(oa=E.length;fa<oa;++fa)if(/form\-item\-error\-message/.test(E[fa].className)){E[fa].parentElement.removeChild(E[fa]);
448
+ break}da.className=da.className.replace(/(\s+form\-item\-error|form\-item\-error|\s+form\-item\-warning|form\-item\-warning)/,'')}else if('undefined'!=typeof g[E]&&oa){da=da.getElementsByTagName('div');oa=0;for(var ja=da.length;oa<ja;++oa)if('form-item-error-message'==da[oa].className){da[oa].parentElement.removeChild(da[oa]);R=document.createElement('div');R.setAttribute('class','form-item-error-message');for(ra in g[E])da=document.createElement('p'),da.appendChild(document.createTextNode(g[E][ra])),
449
+ R.appendChild(da),M&&(x||={},x[E]||(x[E]={}),x[E][ra]=g[E][ra]);break}R&&'hidden'!=fa.type&&insertAfter(fa,R)}if('undefined'!=typeof b&&b===Aa.name)break}}}x?(triggerEvent(gina,l,'error.'+p,g),M&&U&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&(gina.forms.errors||(gina.forms.errors={}),l={id:p,errors:x},window.ginaToolbar.update('forms',l))):M&&U&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&(gina.forms.errors||(gina.forms.errors={}),l={id:p,errors:{}},U&&window.ginaToolbar.update('forms',
450
+ l));if(gina&&U&&M&&r.$forms[p].isSubmitting&&/^true$/i.test(r.$forms[p].isSubmitting)&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&h)try{window.ginaToolbar.update('data-xhr',h)}catch(Z){throw Z;}},J=function(l){var g=null;'undefined'==typeof l&&'undefined'!=typeof this.id&&(l=this.id);/^string$/i.test(typeof l)?(g=l.replace(/#/,''),g=document.getElementById(g)):l instanceof HTMLFormElement?g=l:/^object$/i.test(typeof l)&&(g=l.target);if(!g)throw Error('[ FormValidator::resetErrorsDisplay([ formId | <form> ]) ] `'+
451
+ l+'` not found');g.dataset.ginaFormIsResetting=!0;F(g,{});return g},T=function(l){if('undefined'==typeof l){var g='undefined'!=typeof this.target?this.target.getAttribute('id'):this.getAttribute('id');l=r.$forms[g]}else if('string'==typeof l){g=l.replace(/#/,'');if('undefined'==typeof r.$forms[g])throw Error('[ FormValidator::resetErrorsDisplay([formId]) ] `'+l+'` not found');l=r.$forms[g]}if(l.fieldsSet){var h;for(h in l.fieldsSet){g=document.getElementById(h);var b=g.tagName.toLowerCase();var x=
452
+ g.tagName;/textarea/i.test(x)?(x=l.fieldsSet[h].defaultValue,g.value=x,triggerEvent(gina,g,'change')):'input'==b?(x=l.fieldsSet[h].defaultValue,/$(on|true|false)$/i.test(x)&&(x=/$(on|true)$/i.test(x)?!0:!1),/^(checkbox|radio)$/i.test(g.type)?g.checked=l.fieldsSet[h].defaultChecked:/^(checkbox|radio)$/i.test(g.type)||(g.value=x),triggerEvent(gina,g,'change')):'select'==b&&(x=l.fieldsSet[h].selectedIndex||0,g.selectedIndex=x,g.dataset.value=g.options[g.selectedIndex].value,triggerEvent(gina,g,'change'))}}return l},
453
+ ta=function(){var l=null,g=null;'undefined'!=typeof this.getAttribute?(l=this.getAttribute('id'),g=this):'undefined'!=typeof this.target&&null!=this.target&&'undefined'!=typeof this.target.getAttribute&&(l=this.target.getAttribute('id'),g=this.target);if('undefined'==typeof r.$forms[l])throw Error('[ FormValidator::submit() ] not `$form` binded. Use `FormValidator::getFormById(id)` or `FormValidator::validateFormById(id)` first ');triggerEvent(gina,g,'submit');return this},Fa=function(l,g){var h=
454
+ this.target,b=h.getAttribute('id'),x=r.$forms[b]||this,q=null,p=null,R=null,K=null;if(!('undefined'!=typeof x.isSending&&/^true$/i.test(x.isSending)||'undefined'!=typeof x.sent&&/^true$/i.test(x.sent))){r.$forms[b].isSending=!0;g='undefined'!=typeof g?Q(g,D):D;'undefined'!=typeof x.id&&(g.headers['X-Gina-Form-Id']=x.id,'undefined'!=typeof gina.forms.rules&&0<x.rules.count()&&'undefined'!=typeof x.rules[x.id]&&(g.headers['X-Gina-Form-Rule']=x.id+'@'+gina.config.bundle));'undefined'!=typeof x.target.dataset.ginaFormRule&&
455
+ (g.headers['X-Gina-Form-Rule']=x.target.dataset.ginaFormRule+'@'+gina.config.bundle);y()&&($activePopin=gina.popin.getActivePopin(),$activePopin.isOpen&&('undefined'!=typeof $activePopin.id&&(g.headers['X-Gina-Popin-Id']=$activePopin.id),'undefined'!=typeof $activePopin.name&&(g.headers['X-Gina-Popin-Name']=$activePopin.name)));(K=h.getAttribute('data-gina-form-event-on-submit-success')||h.getAttribute('data-gina-form-event-on-submit-error')?!0:!1)&&xa(x);var ha=h.getAttribute('action')||g.url,Aa=
456
+ h.getAttribute('method')||g.method;Aa=Aa.toUpperCase();g.method=Aa;g.url=ha;O||=setupXhr(g);ha=h.getAttribute('enctype')||g.headers['Content-Type'];if(g.withCredentials){if('withCredentials'in O)g.isSynchrone?O.open(g.method,g.url,g.isSynchrone):O.open(g.method,g.url);else if('undefined'!=typeof XDomainRequest)O=new XDomainRequest,O.open(g.method,g.url);else{O=null;q='CORS not supported: the server is missing the header `"Access-Control-Allow-Credentials": true` ';triggerEvent(gina,h,'error.'+b,q);
457
+ return}O.responseType='undefined'!=typeof g.responseType?g.responseType:'';O.withCredentials=!0}else g.isSynchrone?O.open(g.method,g.url,g.isSynchrone):O.open(g.method,g.url);for(var da in g.headers)'Content-Type'==da&&'undefined'!=typeof ha&&null!=ha&&''!=ha||O.setRequestHeader(da,g.headers[da]);if(O){O.onreadystatechange=function(Z){x.isSubmitting=!1;x.isSending=!1;setTimeout(function(){x.sent=!1},1E3);Z=/Google Inc/i.test(navigator.vendor)?50:0;2==O.readyState&&(R=/^attachment;/.test(O.getResponseHeader('Content-Disposition'))?
458
+ !0:!1,!O.responseType&&R&&(O.responseType='blob'));if(4==O.readyState){var Ga=null,Pa=null,$a=O.getResponseHeader('Content-Type');if(/^2/.test(O.status)){try{if(/blob/.test(O.responseType)||R){if('undefined'==typeof $a||null==$a)$a='application/octet-stream';Pa=new Blob([this.response],{type:$a});var ib=document.createElement('a');ib.style='display: none';document.body.appendChild(ib);var Cb=window.URL.createObjectURL(Pa);ib.href=Cb;var zb=O.getResponseHeader('Content-Disposition');ib.download=zb.match('=(.*)')[0].substr(1);
459
+ ib.click();window.URL.revokeObjectURL(Cb);q={status:O.status,statusText:O.statusText,responseType:Pa.type,type:Pa.type,size:Pa.size}}else q=O.responseText;/\/json/.test($a)&&(q=JSON.parse(O.responseText),'undefined'==typeof q.status&&(q.status=O.status));if(/\/html/.test($a)&&(q={contentType:$a,content:O.responseText},'undefined'==typeof q.status&&(q.status=O.status),'undefined'!=typeof gina.popin&&gina.hasPopinHandler&&(Ga=gina.popin.getActivePopin()))){p={};try{p=(new DOMParser).parseFromString(q.content,
460
+ 'text/html').getElementById('gina-without-layout-xhr-data'),p=JSON.parse(decodeURIComponent(p.value)),XHRView=(new DOMParser).parseFromString(q.content,'text/html').getElementById('gina-without-layout-xhr-view'),XHRView=JSON.parse(decodeURIComponent(XHRView.value)),gina&&M&&typeof window.ginaToolbar&&'undefined'!=typeof p&&window.ginaToolbar.update('data-xhr',p),gina&&M&&typeof window.ginaToolbar&&'undefined'!=typeof XHRView&&window.ginaToolbar.update('view-xhr',XHRView)}catch(X){throw X;}Ga.loadContent(q.content);
461
+ q=p;triggerEvent(gina,h,'success.'+b,q);return}p=x.eventData.success=q;if(gina&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&p)try{M&&'undefined'!=typeof p&&!/\/html|\/json/.test($a)&&window.ginaToolbar.update('data-xhr',p)}catch(X){throw X;}/^gina\-upload/i.test(b)&&W(gina,h,'success',b,q);var qb=!1;'undefined'!=typeof q.isXhrRedirect&&/^true$/i.test(q.isXhrRedirect)&&(qb=!0);if('undefined'!=typeof gina.popin&&gina.hasPopinHandler&&'undefined'!=typeof q.popin||'undefined'!=typeof gina.popin&&
462
+ gina.hasPopinHandler&&'undefined'!=typeof q.location&&qb){Ga=gina.popin.getActivePopin();if(!Ga&&'undefined'!=typeof q.popin){if('undefined'!=typeof q.popin&&'undefined'==typeof q.popin.name)throw Error('To get a `$popin` instance, you need at list a `popin.name`.');Ga=gina.popin.getPopinByName(q.popin.name);if(!Ga)throw Error('Popin with name: `'+q.popin.name+'` not found.');}if('undefined'!=typeof q.popin&&'undefined'!=typeof q.popin.close){Ga.isRedirecting=!1;Ga.close();var Mb=q.popin.reload?q.popin.reload:
463
+ !1;q.popin.location||q.popin.url||(delete q.popin,Mb&&(q.popin={reload:Mb}))}if('undefined'!=typeof q.popin&&'undefined'!=typeof q.popin.location||'undefined'!=typeof q.popin&&'undefined'!=typeof q.popin.url||'undefined'!=typeof q.location&&qb){qb=null;Ga&&(qb=Ga.name,Ga.isRedirecting=!0);'undefined'!=typeof q.popin&&'undefined'!=typeof q.popin.target&&(q.popin.target='_'+q.popin.target);var Ya=q.location||q.popin.location||q.popin.url;if('undefined'!=typeof q.popin&&'undefined'!=typeof q.popin.name&&
464
+ qb!=q.popin.name){Ga&&Ga.isOpen&&Ga.close();qb=q.popin.name;Ga=gina.popin.getPopinByName(qb);if(!Ga)throw Error('Popin with name `'+qb+'` not found !');console.debug('Validator::Popin now redirecting [1-c]');Ga.load(Ga.name,Ya,Ga.options)}else Ga&&(console.debug('Validator::Popin now redirecting [1-d]'),Ga&&Ga.isOpen&&Ga.close(),Ga.load(Ga.name,Ya,Ga.options));if(Ga&&!Ga.isOpen)return setTimeout(function(X){X.isOpen||X.open()},50,Ga)}}triggerEvent(gina,h,'success.'+b,q);K&&triggerEvent(gina,h,'success.'+
465
+ b+'.hform',q)}catch(X){q={status:422,error:X.message,stack:X.stack};p=x.eventData.error=q;if(gina&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&p)try{M&&'undefined'!=typeof p&&window.ginaToolbar.update('data-xhr',p)}catch(ka){throw ka;}/^gina\-upload/i.test(b)&&W(gina,h,'error',b,q);triggerEvent(gina,h,'error.'+b,q);K&&triggerEvent(gina,h,'error.'+b+'.hform',q)}if('undefined'!=typeof q&&'undefined'!=typeof q.location)return window.location.hash='',q.location=/^http/.test(q.location)||
466
+ /^\//.test(q.location)?q.location:location.protocol+'//'+q.location,setTimeout(()=>{window.location.href=q.location},Z)}else if(0!=O.status)if(q={status:O.status},/blob/.test(O.responseType)){Pa=new Blob([this.response],{type:'text/plain'});var cb=new FileReader,ca='';cb.addEventListener('loadend',X=>{/string/i.test(typeof X.srcElement.result)?ca+=X.srcElement.result:'object'==typeof X.srcElement.result?q=Q(q,X.srcElement.result):q.message+=X.srcElement.result;if(/2/.test(cb.readyState)){if(/^(\{|\[)/.test(ca))try{q=
467
+ Q(q,JSON.parse(ca))}catch(ka){q=Q(q,ka)}q.message||delete q.message;p=x.eventData.error=q;if(gina&&M&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&p)try{window.ginaToolbar.update('data-xhr',p)}catch(ka){throw ka;}/^gina\-upload/i.test(b)&&W(gina,h,'error',b,q);triggerEvent(gina,h,'error.'+b,q);K&&triggerEvent(gina,h,'error.'+b+'.hform',q)}});cb.readAsText(Pa)}else{if(/^(\{|\[)/.test(O.responseText))try{q=Q(JSON.parse(O.responseText),q)}catch(X){q=Q(X,q)}else'object'==typeof O.responseText?
468
+ q=Q(O.responseText,q):q.message=O.responseText;if('undefined'!=typeof q&&'undefined'!=typeof q.error&&q.fields&&'object'==typeof q.fields){Ya='undefined'!=typeof q.message?q.message:null;Z={};for(qb in q.fields)Ga={},Ga[qb]={},Ga[qb].isApiError=q.fields[qb],Ya&&!Ga[qb].isApiError&&(Ga[qb].isApiError=q.error),Z[qb]=Ga[qb],F(x.target,Ga,l,qb);q.fields=Z}p=x.eventData.error=q;if(gina&&M&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&p)try{window.ginaToolbar.update('data-xhr',p)}catch(X){throw X;
469
+ }/^gina\-upload/i.test(b)&&W(gina,h,'error',b,q);triggerEvent(gina,h,'error.'+b,q);K&&triggerEvent(gina,h,'error.'+b+'.hform',q)}}};O.onprogress=function(Z){var Ga='0';Z.lengthComputable&&(Ga=Z.loaded/Z.total,Ga=parseInt(100*Ga));Z={status:100,progress:Ga};x.eventData.onprogress=Z;triggerEvent(gina,h,'progress.'+b,Z)};O.ontimeout=function(Z){q={status:408,error:'Request Timeout'};x.eventData.ontimeout=q;/^gina\-upload/i.test(b)&&W(gina,h,'error',b,q);triggerEvent(gina,h,'error.'+b,q);K&&triggerEvent(gina,
470
+ h,'error.'+b+'.hform',q)};l||(l=event.detail.data);if(l){g=!1;if('object'==typeof l){da=[];Aa=0;var fa={};try{if(l instanceof FormData){var E=event.currentTarget.getAttribute('data-gina-form-upload-group')||'untagged',oa,ra;for([oa,ra]of l.entries())ra instanceof File?(g||=!0,da[Aa]={key:oa,group:E,file:ra,bin:''},++Aa):fa[oa]=ra}else l=JSON.stringify(l);if(g&&0<da.length){var ja='--ginaWKBoundary'+ba.v4().replace(/\-/g,'');return ia(da,ja,'',0,function(Z,Ga,Pa){if(Z)/^gina\-upload/i.test(b)&&W(gina,
471
+ h,'error',b,Z),triggerEvent(gina,h,'error.'+b,Z),K&&triggerEvent(gina,h,'error.'+b+'.hform',Z);else return Pa&&(O.setRequestHeader('Content-Type','multipart/form-data; boundary='+ja),O.send(Ga),x.sent=!0,M&&U&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&(gina.forms.sent||(gina.forms.sent={}),window.ginaToolbar.update('forms',{id:b,sent:Ga}))),!1})}'undefined'!=typeof fa&&0<fa.count()&&(l=JSON.stringify(fa))}catch(Z){/^gina\-upload/i.test(b)&&W(gina,h,'error',b,Z),triggerEvent(gina,
472
+ h,'error.'+b,Z),K&&triggerEvent(gina,h,'error.'+b+'.hform',Z)}}g||('undefined'!=typeof ha&&null!=ha&&''!=ha&&O.setRequestHeader('Content-Type',ha),O.send(l))}else'undefined'!=typeof ha&&null!=ha&&''!=ha&&O.setRequestHeader('Content-Type',ha),O.send();x.sent=!0;M&&U&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar&&(gina.forms.sent||(gina.forms.sent={}),E={id:b,sent:'string'==typeof l?JSON.parse(l):l},window.ginaToolbar.update('forms',E))}}},W=function(l,g,h,b,x){l=g.uploadProperties||null;
473
+ if(!l)throw Error('No uploadProperties found !!');g=document.getElementById(l.uploadTriggerId);b=null;var q=x.files||[],p=null;l.hasPreviewContainer&&(b=document.getElementById(l.previewContainer.id))&&(b.innerHTML='');l.errorField&&(p=document.getElementById(l.errorField));p&&(p.style.display='none');if(p&&'success'!=h){var R=x.message||x.error;p.innerHTML='<p>'+R+'</p>';fadeIn(p)}else if(p||'success'==h)for(h=0,x=q.length;h<x;++h){var K=b.id.replace(/\-preview/,'-'+h+'-reset-trigger');R=!1;p=document.getElementById(K);
474
+ var ha=['reset','js-upload-reset'];p?(/a/i.test(p.tagName)&&(p.href='#'),p.innerHTML&&''!=p.innerHTML||(p.innerHTML=g.getAttribute('data-gina-form-upload-reset-label')||'Reset'),'undefined'==typeof p.className&&(p.className=''),K=Q(p.className.split(/\s+/g),ha),p.className=K.join(' ')):(R=!0,p=document.createElement('A'),p.href='#',p.innerHTML=g.getAttribute('data-gina-form-upload-reset-label')||'Reset',p.className=ha.join(' '),p.id=K);p.style.display='none';if('undefined'==typeof q[h].preview&&l.hasPreviewContainer&&
475
+ /^image/.test(q[h].mime)&&''!=q[h].location){K=document.createElement('IMG');K.src=q[h].tmpUri;K.style.display='none';K.setAttribute('data-upload-original-filename',q[h].originalFilename);K.setAttribute('data-upload-reset-link-id',p.id);ha=b.getAttribute('data-preview-max-width')||null;if(K.width&&ha&&K.width>ha){var Aa=K.width/ha;K.width=ha;K.height/=Aa}else!K.width&&ha&&(K.width=ha);/ul/i.test(l.previewContainer.tagName)?(ha=document.createElement('LI'),ha.className='item',ha.appendChild(K),b.appendChild(ha)):
476
+ b.appendChild(K);fadeIn(K)}K=l.uploadFields[h];for(var da in K)if('name'==da&&''!=K[da].value||!q[h][da]||'preview'==da&&'undefined'==typeof q[h][da]||/(height|width)/i.test(da)&&!/^image/.test(q[h].mime))/(preview|height|width)/i.test(da)&&(ha=document.getElementById(K[da].id))&&ha.parentNode.removeChild(ha);else if(K[da].value=q[h][da],'preview'==da)for(var fa in q[h][da])if('undefined'!=typeof q[h][da][fa]&&'undefined'!=typeof K[da][fa]&&(K[da][fa].value=q[h][da][fa]),'tmpUri'==fa&&l.hasPreviewContainer){Aa=
477
+ document.createElement('IMG');Aa.src=q[h][da].tmpUri;Aa.style.display='none';Aa.setAttribute('data-upload-original-filename',q[h].originalFilename);Aa.setAttribute('data-upload-preview-original-filename',q[h][da].originalFilename);Aa.setAttribute('data-upload-reset-link-id',p.id);if(ha=b.getAttribute('data-preview-max-width')||null)Aa.width=ha;/ul/i.test(l.previewContainer.tagName)?(ha=document.createElement('LI'),ha.className='item',ha.appendChild(Aa),b.appendChild(ha)):b.appendChild(Aa);fadeIn(Aa)}l.hasPreviewContainer&&
478
+ (/ul/i.test(l.previewContainer.tagName)?(ha=document.createElement('LI'),ha.className='item',R&&ha.appendChild(p),b.appendChild(ha)):R&&b.appendChild(p));Ub('reset',g,h);fadeIn(p)}else throw Error(R);},la=function(l,g){console.debug(g+' input files');var h=/reset/i.test(g)?!0:!1,b=null,x=null,q=document.getElementById(l.id+'-preview').childNodes,p=null,R=l.customFiles,K=[];for(let ha=0,Aa=q.length;ha<Aa;ha++)if(/img/i.test(q[ha].tagName)){h?(b=q[ha].getAttribute('data-upload-original-filename'),K.push(b),
479
+ (x=q[ha].getAttribute('data-upload-preview-original-filename'))&&K.push(x)):(b=q[ha].src.substr(q[ha].src.lastIndexOf('/')+1),K.push(b));for(let da=0,fa=R.length;da<fa;da++)if(R[da].name==b){p=h?document.getElementById(q[ha].getAttribute('data-upload-'+g+'-link-id')):document.getElementById(R[da].deleteLinkId);p.style.display='none';q[ha].style.display='none';R.splice(da,1);l.customFiles=R;h&&(l.value=R.join(', C:\\fakepath\\'));b=new RegExp('^'+(l.name+'['+da+']').replace(/\-|\[|\]|\./g,'\\$&'));
480
+ for(let oa=0,ra=l.form.length;oa<ra;oa++)if(x=l.form[oa].dataset.ginaFormUploadIsLocked||!1,b.test(l.form[oa].name)&&!/true/i.test(x)&&(l.form[oa].remove(),ra--,oa--,gina&&M&&U&&'undefined'!=typeof window.ginaToolbar&&window.ginaToolbar))try{window.ginaToolbar.update('data-xhr',{files:R})}catch(ja){throw ja;}x=l.getAttribute('data-gina-form-upload-'+g+'-action');if(!x||'undefined'==typeof x||''==x||/404/.test(x))throw Error('input file `'+l.id+'` error: `data-gina-form-upload-'+g+'-action` is required. You need to provide a valide url.');
481
+ (b=l.getAttribute('data-gina-form-upload-'+g+'-method'))&&'undefined'!=typeof b&&''!=b?b=b.toUpperCase():h?b='POST':(b=1<K.length?'POST':'DELETE',console.warn('`data-gina-form-upload-'+g+'-method` was not defined. Switching to `'+b+'` by default.'));let E=l.getAttribute('data-gina-form-upload-'+g+'-is-synchrone');if(/null/i.test(E)||'undefined'==typeof b||''==b)E=!0;x=setupXhr({url:x,method:b,isSynchrone:E,headers:{'Content-Type':'application/x-www-form-urlencoded; charset=UTF-8','X-Requested-With':'XMLHttpRequest'}});
482
+ /GET|DELETE/i.test(b)?x.send():x.send(JSON.stringify({files:K}));if(/none/i.test(window.getComputedStyle(l).display)){if(/none/i.test(l.parentElement.style.display)){l.parentElement.style.display='block';return}l.style.display='block'}removeListener(gina,$uploadResetTrigger,'click',function(){p.remove();q[ha].remove()});Aa--;ha--;break}}},ia=function(l,g,h,b,x){var q=new FileReader;q.addEventListener('load',function(p){p.preventDefault();try{var R=this.result,K=void 0;p='';var ha=null;'undefined'==
483
+ typeof K&&(K=8);var Aa=K/8;switch(K){case 8:ha=new Uint8Array(R);break;case 16:ha=new Uint16Array(R);break;case 32:ha=new Uint32Array(R);break;default:ha=new Uint8Array(R)}var da=ha.length,fa=Math.pow(2,8)+Aa;R=0;for(Aa=K=null;R<da;R+=fa)K=Math.min(fa,da-R),Aa=ha.subarray(R,R+K),p+=String.fromCharCode.apply(null,Aa);l[this.index].bin+=p;l[this.index].file.type||(l[this.index].file.type='application/octet-stream')}catch(E){return x(E,null,!0)}h+='--'+g+'\r\n';h+='Content-Disposition: form-data; name="'+
484
+ l[this.index].key+'"; group="'+l[this.index].group+'"; filename="'+l[this.index].file.name+'"\r\nContent-Type: '+l[this.index].file.type+'\r\nContent-Length: '+l[this.index].bin.length+'\r\n\r\n';h+=l[this.index].bin+'\r\n';++this.index;this.index==l.length?(h+='--'+g+'--',x(!1,h,!0)):ia(l,g,h,this.index,x)},!1);q.index=b;l[b].bin='';q.readAsArrayBuffer(l[b].file)},xa=function(l){var g=l.target.getAttribute('data-gina-form-event-on-submit-success')||null;if(null!=g)if(/\((.*)\)/.test(g))eval(g);else l.on('success.hform',
485
+ window[g]);g=l.target.getAttribute('data-gina-form-event-on-submit-error')||null;if(null!=g)if(/\((.*)\)/.test(g))eval(g);else l.on('error.hform',window[g])},ma=function(l){var g=null,h=l;if(!r.$forms)throw Error('`$forms` collection not found');if('undefined'==typeof h)if('undefined'!=typeof this.id&&''!=this.id&&null!=this.id)h=this.id;else throw Error('[ FormValidator::destroy(formId) ] `formId` is missing');if('string'==typeof h)h=h.replace(/#/,'');else{if('object'!=typeof h||Array.isArray(h))throw Error('[ FormValidator::destroy(formId) ] `formId` should be a `string`');
486
486
  l=h.form;h=l.getAttribute('id')||'form.'+ba.v4();l.setAttribute('id',h)}'undefined'!=typeof r.$forms[h]?g=r.$forms[h]:'undefined'!=typeof this.binded&&(g=this);if(g)addListener(gina,g.target,'destroy.'+h,function(b){cancelEvent(b);delete r.$forms[h];removeListener(gina,b.currentTarget,b.type);removeListener(gina,b.currentTarget,'destroy')}),g=Db(g),triggerEvent(gina,g.target,'destroy.'+h);else throw Error('[ FormValidator::destroy(formId) ] `'+h+'` not found');},ua=function(l){l='undefined'!=typeof l?
487
487
  l:r.rules;for(let b in l){var g=Object.getOwnPropertyNames(l[b]),h=0;let x=g.length,q=!1,p=null;for(;h<x;){if(/^_case_/.test(g[h])){q=!0;p=g[h];break}h++}q||'object'!=typeof l[b]||ua(l[b]);if(p&&Array.isArray(l[b][p].conditions)&&0<l[b][p].conditions.length)for(g=0,h=l[b][p].conditions.length;g<h;)'undefined'!=typeof l[b][p].conditions[g].rules&&0==l[b][p].conditions[g].rules.count()&&(l[b][p].conditions.splice(g,1),h--,g--),g++}},Ca=function(l){var g=JSON.stringify(l),h=g.match(/("@import\s+[-_a-z A-Z 0-9/.]+")/g)||
488
488
  [],b=[];for(let R=0,K=h.length;R<K;R++)0>b.indexOf(h[R])&&b.push(h[R]);h=b;b=g.match(/("_merging(.*))(\s+:|:)(.*)(",|")/g);r.rules||(r.rules={});if(h&&0<h.length){l={};for(let R=0,K=h.length;R<K;++R){var x=h[R].replace(/(@import\s+|"|')/g,'');var q=x.replace(/(@import\s+|"|')/g,'').split(/\s/g);for(let ha=0,Aa=q.length;ha<Aa;++ha){var p=q[ha].replace(/\//g,'.').replace(/\-/g,'.');'undefined'!=typeof r.rules[p]?(p=JSON.stringify(r.rules[p]),p=JSON.parse(p),p._comment='undefined'!=typeof p._comment?