gina 0.6.12 → 0.6.13
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.
- package/CHANGELOG.md +1 -1
- package/README.md +24 -17
- package/ROADMAP.md +3 -2
- package/framework/v0.6.13/VERSION +1 -0
- package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/js/gina.js +8 -0
- package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/js/gina.min.js +165 -165
- package/framework/v0.6.13/core/asset/plugin/dist/vendor/gina/js/gina.min.js.br +0 -0
- package/framework/v0.6.13/core/asset/plugin/dist/vendor/gina/js/gina.min.js.gz +0 -0
- package/framework/{v0.6.12 → v0.6.13}/core/config.js +26 -0
- package/framework/v0.6.13/core/connectors/redis/index.js +62 -0
- package/framework/v0.6.13/core/connectors/redis/lib/kv-store.js +394 -0
- package/framework/v0.6.13/core/connectors/sqlite/lib/kv-store.js +316 -0
- package/framework/{v0.6.12 → v0.6.13}/core/controller/controller.js +202 -0
- package/framework/{v0.6.12 → v0.6.13}/core/gna.js +85 -0
- package/framework/{v0.6.12 → v0.6.13}/core/model/entity.js +13 -5
- package/framework/{v0.6.12 → v0.6.13}/core/router.js +147 -56
- package/framework/{v0.6.12 → v0.6.13}/core/server.js +61 -0
- package/framework/{v0.6.12 → v0.6.13}/lib/cmd/service/help.txt +8 -2
- package/framework/{v0.6.12 → v0.6.13}/lib/cmd/service/start.js +1 -1
- package/framework/{v0.6.12 → v0.6.13}/lib/index.js +18 -0
- package/framework/v0.6.13/lib/kv/package.json +7 -0
- package/framework/v0.6.13/lib/kv/src/main.js +862 -0
- package/framework/v0.6.13/lib/kv-store.js +112 -0
- package/framework/v0.6.13/lib/rate-limit/package.json +6 -0
- package/framework/v0.6.13/lib/rate-limit/src/main.js +399 -0
- package/framework/{v0.6.12 → v0.6.13}/lib/routing/src/main.js +8 -0
- package/framework/{v0.6.12 → v0.6.13}/package.json +1 -1
- package/gna.js +4 -4
- package/llms.txt +13 -3
- package/package.json +3 -3
- package/schema/routing.json +30 -0
- package/schema/settings.json +101 -0
- package/types/index.d.ts +9 -0
- package/framework/v0.6.12/VERSION +0 -1
- package/framework/v0.6.12/core/asset/plugin/dist/vendor/gina/js/gina.min.js.br +0 -0
- package/framework/v0.6.12/core/asset/plugin/dist/vendor/gina/js/gina.min.js.gz +0 -0
- package/framework/v0.6.12/core/connectors/redis/index.js +0 -36
- /package/framework/{v0.6.12 → v0.6.13}/AUTHORS +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/LICENSE +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/html/nolayout.html +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/html/static.html +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/img/android-chrome-192x192.png +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/img/android-chrome-512x512.png +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/img/apple-touch-icon.png +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/img/favicon-16x16.png +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/img/favicon-32x32.png +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/img/favicon.ico +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/beemaster/beemaster.css +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/beemaster/beemaster.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/beemaster/index.html +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/css/gina.min.css +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/css/gina.min.css.br +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/css/gina.min.css.gz +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/html/statusbar.html +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/html/statusbar.html.br +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/html/statusbar.html.gz +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/inspector/have_heart_one-webfont.woff2 +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/inspector/index.html +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/inspector/inspector.css +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/inspector/inspector.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/inspector/logo.svg +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/js/gina.onload.min.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/js/gina.onload.min.js.br +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/asset/plugin/dist/vendor/gina/js/gina.onload.min.js.gz +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/ai/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/ai/lib/connector.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/couchbase/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/couchbase/lib/connector.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/couchbase/lib/connector.v3.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/couchbase/lib/connector.v4.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/couchbase/lib/n1ql.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/couchbase/lib/session-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/couchbase/lib/session-store.v3.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/couchbase/lib/session-store.v4.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/couchbase/lib/storage-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/duckdb/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/duckdb/lib/connector.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/mongodb/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/mongodb/lib/connector.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/mongodb/lib/job-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/mongodb/lib/pipeline-loader.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/mongodb/lib/session-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/mysql/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/mysql/lib/connector.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/param-redact.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/postgresql/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/postgresql/lib/connector.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/redis/lib/connector.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/redis/lib/job-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/redis/lib/render-cache-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/redis/lib/session-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/scylladb/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/scylladb/lib/connector.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/scylladb/lib/session-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/sql-parser.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/sqlite/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/sqlite/lib/connector.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/sqlite/lib/job-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/connectors/sqlite/lib/session-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/content.encoding +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/controller/controller.framework.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/controller/controller.render-json.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/controller/controller.render-nunjucks-async.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/controller/controller.render-nunjucks.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/controller/controller.render-stream.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/controller/controller.render-swig-async.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/controller/controller.render-swig.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/controller/controller.render-v1.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/controller/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/controller/inspector-window-emit.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/controller/release-banner.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/dev/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/dev/lib/class.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/dev/lib/factory.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/dev/lib/tools.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/locales/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/locales/currency.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/locales/dist/language/en.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/locales/dist/language/fr.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/locales/dist/region/en.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/locales/dist/region/fr.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/locales/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/mime.types +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/model/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/model/template/entityFactory.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/model/template/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/csrf/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/csrf/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/csrf/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/coep/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/coep/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/coep/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/coop/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/coop/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/coop/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/corp/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/corp/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/corp/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/csp/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/csp/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/csp/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/hide-powered-by/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/hide-powered-by/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/hide-powered-by/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/hsts/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/hsts/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/hsts/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/origin-agent-cluster/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/origin-agent-cluster/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/origin-agent-cluster/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/referrer-policy/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/referrer-policy/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/referrer-policy/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-content-type-options/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-content-type-options/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-content-type-options/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-dns-prefetch-control/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-dns-prefetch-control/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-dns-prefetch-control/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-download-options/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-download-options/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-download-options/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-frame-options/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-frame-options/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-frame-options/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-permitted-cross-domain-policies/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-permitted-cross-domain-policies/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-permitted-cross-domain-policies/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-xss-protection/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-xss-protection/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/security-headers/x-xss-protection/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/session/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/session/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/session/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/storage/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/storage/build.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/storage/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/storage/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/validator/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/validator/build.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/validator/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/validator/src/form-validator.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/plugins/lib/validator/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/server.express.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/server.isaac.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/status.codes +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/_gitignore +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle/config/app.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle/config/connectors.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle/config/routing.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle/config/settings.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle/config/settings.server.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle/config/templates.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle/config/watchers.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle/controllers/controller.content.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle/controllers/controller.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle/controllers/setup.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle/locales/en.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_namespace/controllers/controller.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_public/css/default.css +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_public/css/home.css +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_public/css/vendor/readme.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_public/favicon.ico +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_public/js/components/x-checklist.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_public/js/vendor/readme.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_public/manifest.webmanifest +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_public/readme.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_public/sw.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_templates/handlers/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_templates/html/content/homepage.html +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_templates/html/includes/error-msg-noscript.html +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_templates/html/includes/error-msg-outdated-browser.html +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_templates/html/includes/x-checklist.html +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/boilerplate/bundle_templates/html/layouts/main.html +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/command/gina.bat.tpl +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/command/gina.tpl +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/conf/env.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/conf/manifest.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/conf/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/conf/settings.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/conf/statics.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/conf/templates.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/error/client/json/401.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/error/client/json/403.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/error/client/json/404.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/error/server/html/50x.html +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/error/server/json/500.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/error/server/json/503.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/core/template/extensions/logger/config.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/console.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/context.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/data/LICENSE +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/data/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/data/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/data/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/dateFormat.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/json/LICENSE +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/json/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/json/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/json/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/path.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/plugins/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/plugins/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/plugins/src/api-error.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/plugins/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/prototypes.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/task.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/helpers/text.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/admin/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/admin/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/archiver/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/archiver/build.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/archiver/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/archiver/src/dep/jszip.min.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/archiver/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/async/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/async/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/audit/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/audit/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/audit-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/authn/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/authn/src/lockout.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/authn/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/authn/src/totp.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/authz-gate/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/authz-gate/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cache/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cache/build.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cache/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cache/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/aliases.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/audit/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/audit/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/audit/verify.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/add.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/build.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/copy.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/cp.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/inc/name-rewrite.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/list.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/man.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/mcp-start.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/mcp.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/oas.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/openapi.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/remove.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/rename.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/restart.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/rm.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/start.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/status.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/stop.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/bundle/types.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/cache/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/cache/clear.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/cache/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/cache/stats.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/connector/add.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/connector/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/connector/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/connector/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/connector/infer.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/connector/list.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/connector/migrate.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/connector/models.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/connector/remove.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/connector/rm.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/connector/test.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/container/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/container/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/container/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/container/man.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/container/ps.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/container/stop.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/controller/add.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/controller/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/controller/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/controller/inc/args.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/controller/inc/namespace.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/controller/inc/reference-rewrite.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/controller/inc/reference-scan.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/controller/inc/scaffold.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/controller/remove.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/controller/rename.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/controller/rm.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/env/add.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/env/get.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/env/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/env/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/env/link-dev.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/env/list.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/env/remove.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/env/rm.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/env/set.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/env/unset.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/env/use.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/add.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/build.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/dot.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/get.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/init.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/link-node-modules.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/link.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/list.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/man.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/msg.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/open.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/remove.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/reset.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/restart.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/set.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/start.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/status.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/stop.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/tail.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/update.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/framework/version.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/gina-dev.1.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/gina-framework.1.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/gina.1.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/helper.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/i18n/add.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/i18n/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/i18n/export.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/i18n/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/i18n/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/i18n/import.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/i18n/scan.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/image/_host.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/image/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/image/build.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/image/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/image/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/image/list.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/image/man.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/image/rm.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/image/run.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/inspector/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/inspector/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/inspector/open.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/man-render.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/minion/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/minion/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/minion/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/minion/kill.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/minion/list.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/msg.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/port/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/port/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/port/inc/scan.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/port/list.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/port/reset.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/port/set.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/add.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/backup.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/build.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/import.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/list.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/man.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/move.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/remove.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/rename.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/restart.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/restore.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/rm.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/start.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/status.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/project/stop.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/protocol/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/protocol/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/protocol/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/protocol/list.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/protocol/remove.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/protocol/set.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/scope/add.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/scope/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/scope/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/scope/link-local.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/scope/link-production.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/scope/list.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/scope/remove.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/scope/rm.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/scope/use.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/secrets/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/secrets/check.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/secrets/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/secrets/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/secrets/scan.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/service/help.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/service/list.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/service/man.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/storage/arguments.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/storage/gc.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/storage/help.txt +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/storage/stats.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/storage/verify.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd/view/add.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd-status-format/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cmd-status-format/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/collection/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/collection/build.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/collection/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/collection/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/config.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/connector-config/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/connector-config/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/connector-error/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/connector-error/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/connector-registry/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/connector-registry/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cron/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cron/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/cron/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/domain/LICENSE +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/domain/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/domain/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/domain/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/dto/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/dto/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/dto-pipe/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/dto-pipe/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/dto-types/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/dto-types/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/generator/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/i18n/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/i18n/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/image-build/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/image-build/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/inherits/LICENSE +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/inherits/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/inherits/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/inherits/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/inspector-events/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/inspector-events/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/inspector-redact/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/inspector-redact/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/instrument/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/instrument/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/job/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/job/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/job-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/json-config-header/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/json-config-header/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/loading-state/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/loading-state/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/logger/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/logger/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/logger/src/containers/default/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/logger/src/containers/file/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/logger/src/containers/file/lib/logrotator/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/logger/src/containers/file/lib/logrotator/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/logger/src/containers/mq/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/logger/src/containers/mq/listener.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/logger/src/containers/mq/speaker.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/logger/src/helper.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/logger/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/maintenance/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/maintenance/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/math/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/mcp-dispatch/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/mcp-dispatch/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/mcp-http/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/mcp-http/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/mcp-server/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/mcp-server/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/merge/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/merge/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/merge/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/metrics/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/metrics/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/model.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/net-locality/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/net-locality/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/nunjucks-filters/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/nunjucks-filters/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/nunjucks-filters/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/nunjucks-resolver/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/nunjucks-resolver/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/proc.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/push/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/push/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/release-watch/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/release-watch/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/render-cache/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/render-cache/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/render-cache-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/routing/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/routing/build.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/routing/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/routing/src/radix.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/routing-introspect/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/routing-introspect/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/secrets/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/secrets/src/backends/env.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/secrets/src/backends/file.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/secrets/src/env-file.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/secrets/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/session-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/shell.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/sqlite-driver.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/state.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/storage/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/storage/src/local-cas.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/storage/src/local-stream.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/storage/src/local.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/storage/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/storage/src/meta-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/storage/src/s3.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/storage/src/util.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/storage-store.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/swig-filters/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/swig-filters/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/swig-filters/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/swig-resolver/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/swig-resolver/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/template-loaders/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/template-loaders/src/loaders/http.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/template-loaders/src/loaders/memory.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/template-loaders/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/url/README.md +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/url/index.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/url/routing.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/uuid/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/uuid/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/validator.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/watcher/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/watcher/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/ws-framing/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/ws-framing/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/ws-query/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/ws-query/src/main.js +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/ws-session/package.json +0 -0
- /package/framework/{v0.6.12 → v0.6.13}/lib/ws-session/src/main.js +0 -0
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
Released under the MIT License.
|
|
7
7
|
@source https://gist.github.com/eligrey/1129031 */
|
|
8
8
|
var requirejs,require,define;
|
|
9
|
-
(function(
|
|
10
|
-
Oa))break}function
|
|
9
|
+
(function(k,G){function F(ua,za){return za||''}function L(ua){return I.call(ua)==='[object Function]'}function U(ua){return I.call(ua)==='[object Array]'}function q(ua,za){if(ua){var Oa;for(Oa=0;Oa<ua.length&&(!ua[Oa]||!za(ua[Oa],Oa,ua));Oa+=1);}}function O(ua,za){if(ua){var Oa;for(Oa=ua.length-1;Oa>-1&&(!ua[Oa]||!za(ua[Oa],Oa,ua));--Oa);}}function A(ua,za){return la.call(ua,za)}function P(ua,za){return A(ua,za)&&ua[za]}function ba(ua,za){for(var Oa in ua)if(A(ua,Oa)&&Fa.indexOf(Oa)==-1&&za(ua[Oa],
|
|
10
|
+
Oa))break}function h(ua,za,Oa,qb){za&&ba(za,function(Wa,gb){if(Oa||!A(ua,gb))!qb||typeof Wa!=='object'||!Wa||U(Wa)||L(Wa)||Wa instanceof RegExp?ua[gb]=Wa:(ua[gb]||(ua[gb]={}),h(ua[gb],Wa,Oa,qb))});return ua}function J(ua,za){return function(){return za.apply(ua,arguments)}}function w(ua){throw ua;}function m(ua){if(!ua)return ua;var za=k;q(ua.split('.'),function(Oa){za=za[Oa]});return za}function oa(ua,za,Oa,qb){za=Error(za+'\nhttps://requirejs.org/docs/errors.html#'+ua);za.requireType=ua;za.requireModules=
|
|
11
11
|
qb;Oa&&(za.originalError=Oa);return za}function S(){if(y&&y.readyState==='interactive')return y;O(document.getElementsByTagName('script'),function(ua){if(ua.readyState==='interactive')return y=ua});return y}var r,V,v,y,z,l,ja,M=/\/\*[\s\S]*?\*\/|([^:"'=]|^)\/\/.*$/mg,T=/[^.]\s*require\s*\(\s*["']([^'"\s]+)["']\s*\)/g,N=/\.js$/,Y=/^\.\//;var C=Object.prototype;var I=C.toString,la=C.hasOwnProperty,va=!(typeof window==='undefined'||typeof navigator==='undefined'||!window.document),H=!va&&typeof importScripts!==
|
|
12
12
|
'undefined',da=va&&navigator.platform==='PLAYSTATION 3'?/^complete$/:/^(complete|loaded)$/,ma=typeof opera!=='undefined'&&opera.toString()==='[object Opera]',ia={},sa={},xa=[],ta=!1,Fa=['__proto__','constructor'];if(typeof define==='undefined'){if(typeof requirejs!=='undefined'){if(L(requirejs))return;sa=requirejs;requirejs=void 0}typeof require==='undefined'||L(require)||(sa=require,require=void 0);var ha=requirejs=function(ua,za,Oa,qb){var Wa='_';if(!U(ua)&&typeof ua!=='string'){var gb=ua;U(za)?
|
|
13
13
|
(ua=za,za=Oa,Oa=qb):ua=[]}gb&&gb.context&&(Wa=gb.context);(qb=P(ia,Wa))||(qb=ia[Wa]=ha.s.newContext(Wa));gb&&qb.configure(gb);return qb.require(ua,za,Oa)};ha.config=function(ua){return ha(ua)};ha.nextTick=typeof G!=='undefined'?function(ua){G(ua,4)}:function(ua){ua()};require||=ha;ha.version='2.3.7';ha.jsExtRegExp=/^\/|:|\?|\.js$/;ha.isBrowser=va;C=ha.s={contexts:ia,newContext:function(ua){function za(B,Aa,na){var qa;Aa=Aa&&Aa.split('/');var ra=ea.map,Pa=ra&&ra['*'];if(B){B=B.split('/');var $a=B.length-
|
|
@@ -28,9 +28,9 @@ ib;this.init([],function(){return eb},null,{enabled:!0,ignore:!0})}));if(qa=P(u,
|
|
|
28
28
|
bb(eb)});ob.fromText=J(this,function(eb,Ab){var tb=B.name,xb=gb(tb),Cb=ta;Ab&&(eb=Ab);Cb&&(ta=!1);yb(xb);A(ea.config,Aa)&&(ea.config[tb]=ea.config[Aa]);try{ha.exec(eb)}catch(Sb){return bb(oa('fromtexteval','fromText eval for '+Aa+' failed: '+Sb,Sb,[Aa]))}Cb&&(ta=!0);this.depMaps.push(xb);ya.completeLoad(tb);hb([tb],ob)});qa.load(B.name,hb,ob,ea)}}));ya.enable(na,this);this.pluginMaps[na.id]=na},enable:function(){Z[this.map.id]=this;this.enabling=this.enabled=!0;q(this.depMaps,J(this,function(B,Aa){var na;
|
|
29
29
|
if(typeof B==='string'){B=gb(B,this.map.isDefine?this.map:this.map.parentMap,!1,!this.skipMap);this.depMaps[Aa]=B;if(na=P(Qa,B.id)){this.depExports[Aa]=na(this);return}this.depCount+=1;mb(B,'defined',J(this,function(ra){this.undefed||(this.defineDep(Aa,ra),this.check())}));this.errback?mb(B,'error',J(this,this.errback)):this.events.error&&mb(B,'error',J(this,function(ra){this.emit('error',ra)}))}na=B.id;var qa=u[na];A(Qa,na)||!qa||qa.enabled||ya.enable(B,this)}));ba(this.pluginMaps,J(this,function(B){var Aa=
|
|
30
30
|
P(u,B.id);Aa&&!Aa.enabled&&ya.enable(B,this)}));this.enabling=!1;this.check()},on:function(B,Aa){var na=this.events[B];na||=this.events[B]=[];na.push(Aa)},emit:function(B,Aa){q(this.events[B],function(na){na(Aa)});B==='error'&&delete this.events[B]}};var ya={config:ea,contextName:ua,registry:u,defined:x,urlFetched:aa,defQueue:g,defQueueMap:{},Module:Ma,makeModuleMap:gb,nextTick:ha.nextTick,onError:bb,configure:function(B){B.baseUrl&&B.baseUrl.charAt(B.baseUrl.length-1)!=='/'&&(B.baseUrl+='/');if(typeof B.urlArgs===
|
|
31
|
-
'string'){var Aa=B.urlArgs;B.urlArgs=function(ra,Pa){return(Pa.indexOf('?')===-1?'?':'&')+Aa}}var na=ea.shim,qa={paths:!0,bundles:!0,config:!0,map:!0};ba(B,function(ra,Pa){qa[Pa]?(ea[Pa]||(ea[Pa]={}),
|
|
32
|
-
typeof ra==='string'?{name:ra}:ra;var Pa=ra.name;ra.location&&(ea.paths[Pa]=ra.location);ea.pkgs[Pa]=ra.name+'/'+(ra.main||'main').replace(Y,'').replace(N,'')});ba(u,function(ra,Pa){ra.inited||ra.map.unnormalized||(ra.map=gb(Pa,null,!0))});(B.deps||B.callback)&&ya.require(B.deps||[],B.callback)},makeShimExports:function(B){return function(){var Aa;B.init&&(Aa=B.init.apply(
|
|
33
|
-
ra&&L(ra)&&(ra.__requireJsBuild=!0);if(typeof qa==='string'){if(L(ra))return bb(oa('requireargs','Invalid require call'),Pa);if(B&&A(Qa,qa))return Qa[qa](u[B.id]);if(ha.get)return ha.get(ya,qa,B,na);var hb=gb(qa,B,!1,!0);hb=hb.id;return A(x,hb)?x[hb]:bb(oa('notloaded','Module name "'+hb+'" has not been loaded yet for context: '+ua+(B?'':'. Use require([])')))}Qb();ya.nextTick(function(){Qb();$a=yb(gb(null,B));$a.skipMap=Aa.skipMap;$a.init(qa,ra,Pa,{enabled:!0});Mb()});return na}Aa=Aa||{};
|
|
31
|
+
'string'){var Aa=B.urlArgs;B.urlArgs=function(ra,Pa){return(Pa.indexOf('?')===-1?'?':'&')+Aa}}var na=ea.shim,qa={paths:!0,bundles:!0,config:!0,map:!0};ba(B,function(ra,Pa){qa[Pa]?(ea[Pa]||(ea[Pa]={}),h(ea[Pa],ra,!0,!0)):ea[Pa]=ra});B.bundles&&ba(B.bundles,function(ra,Pa){q(ra,function($a){$a!==Pa&&(Q[$a]=Pa)})});B.shim&&(ba(B.shim,function(ra,Pa){U(ra)&&(ra={deps:ra});!ra.exports&&!ra.init||ra.exportsFn||(ra.exportsFn=ya.makeShimExports(ra));na[Pa]=ra}),ea.shim=na);B.packages&&q(B.packages,function(ra){ra=
|
|
32
|
+
typeof ra==='string'?{name:ra}:ra;var Pa=ra.name;ra.location&&(ea.paths[Pa]=ra.location);ea.pkgs[Pa]=ra.name+'/'+(ra.main||'main').replace(Y,'').replace(N,'')});ba(u,function(ra,Pa){ra.inited||ra.map.unnormalized||(ra.map=gb(Pa,null,!0))});(B.deps||B.callback)&&ya.require(B.deps||[],B.callback)},makeShimExports:function(B){return function(){var Aa;B.init&&(Aa=B.init.apply(k,arguments));return Aa||B.exports&&m(B.exports)}},makeRequire:function(B,Aa){function na(qa,ra,Pa){var $a;Aa.enableBuildCallback&&
|
|
33
|
+
ra&&L(ra)&&(ra.__requireJsBuild=!0);if(typeof qa==='string'){if(L(ra))return bb(oa('requireargs','Invalid require call'),Pa);if(B&&A(Qa,qa))return Qa[qa](u[B.id]);if(ha.get)return ha.get(ya,qa,B,na);var hb=gb(qa,B,!1,!0);hb=hb.id;return A(x,hb)?x[hb]:bb(oa('notloaded','Module name "'+hb+'" has not been loaded yet for context: '+ua+(B?'':'. Use require([])')))}Qb();ya.nextTick(function(){Qb();$a=yb(gb(null,B));$a.skipMap=Aa.skipMap;$a.init(qa,ra,Pa,{enabled:!0});Mb()});return na}Aa=Aa||{};h(na,{isBrowser:va,
|
|
34
34
|
toUrl:function(qa){var ra=qa.lastIndexOf('.'),Pa=qa.split('/')[0];if(ra!==-1&&(Pa!=='.'&&Pa!=='..'||ra>1)){var $a=qa.substring(ra,qa.length);qa=qa.substring(0,ra)}return ya.nameToUrl(za(qa,B&&B.id,!0),$a,!0)},defined:function(qa){return A(x,gb(qa,B,!1,!0).id)},specified:function(qa){qa=gb(qa,B,!1,!0).id;return A(x,qa)||A(u,qa)}});B||(na.undef=function(qa){Ha();var ra=gb(qa,B,!0),Pa=P(u,qa);Pa.undefed=!0;Oa(qa);delete x[qa];delete aa[ra.url];delete e[qa];O(g,function($a,hb){$a[0]===qa&&g.splice(hb,
|
|
35
35
|
1)});delete ya.defQueueMap[qa];Pa&&(Pa.events.defined&&(e[qa]=Pa.events),Ib(qa))});return na},enable:function(B){P(u,B.id)&&yb(B).enable()},completeLoad:function(B){var Aa=P(ea.shim,B)||{},na=Aa.exports;for(Ha();g.length;){var qa=g.shift();if(qa[0]===null){qa[0]=B;if(ra)break;var ra=!0}else qa[0]===B&&(ra=!0);Hb(qa)}ya.defQueueMap={};qa=P(u,B);if(!ra&&!A(x,B)&&qa&&!qa.inited)if(!ea.enforceDefine||na&&m(na))Hb([B,Aa.deps||[],Aa.exportsFn]);else return qb(B)?void 0:bb(oa('nodefine','No define call for '+
|
|
36
36
|
B,null,[B]));Mb()},nameToUrl:function(B,Aa,na){var qa,ra;(qa=P(ea.pkgs,B))&&(B=qa);if(qa=P(Q,B))return ya.nameToUrl(qa,Aa,na);if(ha.jsExtRegExp.test(B))qa=B+(Aa||'');else{qa=ea.paths;var Pa=B.split('/');for(ra=Pa.length;ra>0;--ra){var $a=Pa.slice(0,ra).join('/');if($a=P(qa,$a)){U($a)&&($a=$a[0]);Pa.splice(0,ra,$a);break}}qa=Pa.join('/');qa+=Aa||(/^data:|^blob:|\?/.test(qa)||na?'':'.js');qa=(qa.charAt(0)==='/'||qa.match(/^[\w\+\.\-]+:/)?'':ea.baseUrl)+qa}return ea.urlArgs&&!/^blob:/.test(qa)?qa+ea.urlArgs(B,
|
|
@@ -40,26 +40,26 @@ qa):qa},load:function(B,Aa){ha.load(ya,B,Aa)},execCb:function(B,Aa,na,qa){return
|
|
|
40
40
|
Wa.src=Oa;if(qb.onNodeCreated)qb.onNodeCreated(Wa,qb,za,Oa);z=Wa;r?jb.insertBefore(Wa,r):jb.appendChild(Wa);z=null;return Wa}if(H)try{G(function(){},0),importScripts(Oa),ua.completeLoad(za)}catch(gb){ua.onError(oa('importscripts','importScripts failed for '+za+' at '+Oa,gb,[za]))}};va&&!sa.skipDataMain&&O(document.getElementsByTagName('script'),function(ua){jb||(jb=ua.parentNode);if(V=ua.getAttribute('data-main'))return l=V,sa.baseUrl||l.indexOf('!')!==-1||(v=l.split('/'),l=v.pop(),ja=v.length?v.join('/')+
|
|
41
41
|
'/':'./',sa.baseUrl=ja),l=l.replace(N,''),ha.jsExtRegExp.test(l)&&(l=V),sa.deps=sa.deps?sa.deps.concat(l):[l],!0});define=function(ua,za,Oa){var qb;typeof ua!=='string'&&(Oa=za,za=ua,ua=null);U(za)||(Oa=za,za=null);!za&&L(Oa)&&(za=[],Oa.length&&(Oa.toString().replace(M,F).replace(T,function(gb,yb){za.push(yb)}),za=(Oa.length===1?['require']:['require','exports','module']).concat(za)));if(ta&&(qb=z||S())){ua||=qb.getAttribute('data-requiremodule');var Wa=ia[qb.getAttribute('data-requirecontext')]}Wa?
|
|
42
42
|
(Wa.defQueue.push([ua,za,Oa]),Wa.defQueueMap[ua]=!0):xa.push([ua,za,Oa])};define.amd={jQuery:!0};ha.exec=function(ua){return eval(ua)};ha(sa)}})(this,typeof setTimeout==='undefined'?void 0:setTimeout);define('requireLib',function(){});
|
|
43
|
-
function Merge(){var
|
|
44
|
-
'boolean'&&(J=arguments[ba])!=null){if(typeof J!='object'){A=J;break}if(Array.isArray(J)&&Array.isArray(A))A=L(J,A,P);else for(var m in J){A||={name:null};var oa=A[m];var S=J[m];if(A!==S)if(S&&(U(S)||(w=Array.isArray(S)))){var r=!1;if(w){w=!1;if(oa&&Array.isArray(oa))var V=oa||[];else if(U(oa)){V=oa||{};A[m]=V;continue}else V=[];
|
|
45
|
-
V[v]=L(S[v],V[v],P):V[v]=S[v]:Array.isArray(S[v])&&Array.isArray(V[v])&&(V[v]=L(S[v],V[v],P));A[m]=V}else{for(v in S)typeof V[v]=='undefined'?Array.isArray(S[v])&&Array.isArray(V[v])?V[v]=L(S[v],V[v],P):V[v]=S[v]:Array.isArray(S[v])&&Array.isArray(V[v])&&(V[v]=L(S[v],V[v],P));typeof oa=='boolean'||r?r&&(A[m]=V):A[m]=F(V,S,P)}}}else S!==void 0&&(A[m]=typeof oa=='undefined'||oa==null||oa===S||P?S:oa)}}
|
|
46
|
-
'object'&&q[0]!=null&&typeof q[0][ba]!='undefined'&&typeof O[0]=='object'&&typeof O[0][ba]!='undefined'){
|
|
47
|
-
q.length==0||typeof q=='undefined'?/^true$/i.test(A)?q:O:q}if(q.length==0&&O.length>0)return
|
|
48
|
-
var oa=null;
|
|
49
|
-
typeof P!='undefined'&&P!=null&&(P=P[0]||null),O.indexOf(q[
|
|
50
|
-
-1||typeof q[
|
|
43
|
+
function Merge(){var k=[],G=!1,F=function(q,O){var A=q;G||(typeof q=='object'&&Array.isArray(q),G=!0);typeof A=='undefined'&&(A=typeof O!='undefined'&&Array.isArray(O)?[]:{});var P=!1;typeof arguments[arguments.length-1]=='boolean'&&(P=arguments[arguments.length-1]);var ba=1,h=arguments.length,J,w;if(typeof A!=='object'&&typeof A!=='function')A=P?typeof arguments[2]=='undefined'?arguments[1]:arguments[2]:typeof arguments[0]=='undefined'?arguments[1]:arguments[0];else for(;ba<h;++ba)if(typeof arguments[ba]!=
|
|
44
|
+
'boolean'&&(J=arguments[ba])!=null){if(typeof J!='object'){A=J;break}if(Array.isArray(J)&&Array.isArray(A))A=L(J,A,P);else for(var m in J){A||={name:null};var oa=A[m];var S=J[m];if(A!==S)if(S&&(U(S)||(w=Array.isArray(S)))){var r=!1;if(w){w=!1;if(oa&&Array.isArray(oa))var V=oa||[];else if(U(oa)){V=oa||{};A[m]=V;continue}else V=[];k=V;V=L(S,V,P);A[m]=V}else{V=oa&&U(oa)?oa:null;if(!V){r=!0;V={};for(var v in S)V[v]=S[v]}if(P){for(v in S)typeof S[v]!='undefined'?Array.isArray(S[v])&&Array.isArray(V[v])?
|
|
45
|
+
V[v]=L(S[v],V[v],P):V[v]=S[v]:Array.isArray(S[v])&&Array.isArray(V[v])&&(V[v]=L(S[v],V[v],P));A[m]=V}else{for(v in S)typeof V[v]=='undefined'?Array.isArray(S[v])&&Array.isArray(V[v])?V[v]=L(S[v],V[v],P):V[v]=S[v]:Array.isArray(S[v])&&Array.isArray(V[v])&&(V[v]=L(S[v],V[v],P));typeof oa=='boolean'||r?r&&(A[m]=V):A[m]=F(V,S,P)}}}else S!==void 0&&(A[m]=typeof oa=='undefined'||oa==null||oa===S||P?S:oa)}}k=[];G=!1;return A},L=function(q,O,A){k=[];var P=[],ba=F.getKeyComparison();if(/^true$/i.test(A)){if(typeof q[0]==
|
|
46
|
+
'object'&&q[0]!=null&&typeof q[0][ba]!='undefined'&&typeof O[0]=='object'&&typeof O[0][ba]!='undefined'){k=Array.isArray(O)?Array.from(O):JSON.clone(O);var h=0;for(A=k.length;h<A;++h)P.push(k[h][ba]);A=JSON.clone(q);var J=0;h=0;q=A.length;for(var w=oa||0,m=O.length;w<m;++w)a:for(h=h||0;h<q;++h)if(A[h][ba]===O[w][ba]){P.indexOf(A[h][ba])>-1?(k[J]=A[h],++J):P.indexOf(A[h][ba])==-1&&(P.push(A[h][ba]),k[J]=A[h],++J);break a}else P.indexOf(A[h][ba])==-1&&(P.push(A[h][ba]),k.push(A[h]));return k}return Array.isArray(q)&&
|
|
47
|
+
q.length==0||typeof q=='undefined'?/^true$/i.test(A)?q:O:q}if(q.length==0&&O.length>0)return k=O;if(O.length==0&&q.length>0)for(h=0;h<q.length;++h)O.push(q[h]);if(k.length==0&&O.length>0)for(h=0;h<O.length;++h)typeof O[h]=='object'&&O[h]!==null||k.indexOf(O[h])!=-1||k.push(O[h]);if(O.length>0){if(typeof q[0]!='undefined'&&typeof q[0]=='object'&&q[0]!=null&&typeof q[0][ba]!='undefined'&&typeof O[0]=='object'&&typeof O[0][ba]!='undefined'){k=Array.isArray(O)?Array.from(O):JSON.clone(O);A=JSON.clone(q);
|
|
48
|
+
var oa=null;h=0;for(q=k.length;h<q;++h)P.push(k[h][ba]);for(h=0;h<q;++h)a:for(w=oa||0,m=A.length;w<m;++w)if(A[w]!=null&&typeof A[w][ba]!='undefined'&&A[w][ba]!==k[h][ba]){if(P.indexOf(A[w][ba])==-1){k.push(A[w]);P.push(A[w][ba]);oa=w+1;q<m&&++q;break a}}else if(A[w]!=null&&typeof A[w][ba]!='undefined'&&A[w][ba]===k[h][ba])oa=w+1;else break a;return k}for(h=0;h<q.length;++h)if(P=null,typeof q=='undefined'||typeof q[h]!='object'||Array.isArray(q[h])||q[h]==null||(P=Object.getOwnPropertyNames(q[h])),
|
|
49
|
+
typeof P!='undefined'&&P!=null&&(P=P[0]||null),O.indexOf(q[h])>-1&&A)O.splice(O.indexOf(q[h]),1,q[h]);else if(typeof k[h]=='undefined'&&typeof q[h]=='object'&&q[h]!=null)for(J in k=O,typeof k[h]=='undefined'&&(k[h]={}),q[h])k[h].hasOwnProperty(J)||(k[h][J]=q[h][J]);else!A&&k.indexOf(q[h])>-1&&/number/i.test(typeof q[h])&&q[h]!==k[h]?k.push(q[h]):typeof O[h]=='undefined'||/null/i.test(O[h])||typeof O[h][ba]=='undefined'||typeof q[h]=='undefined'||typeof q[h][ba]=='undefined'||O[h][ba]!=q[h][ba]?k.indexOf(q[h])!=
|
|
50
|
+
-1||typeof q[h]=='object'&&q[h]!==null?typeof O[h]=='undefined'||/null/i.test(O[h])||typeof O[h][P]=='undefined'||typeof q[h]=='undefined'||typeof q[h][P]=='undefined'||O[h][P]!=q[h][P]||(k[h]=A?q[h]:O[h]):k.push(q[h]):k[h]=A?q[h]:O[h]}if(k.length>0&&O.length>0||k.length==0&&O.length==0)return k};L.prototype.setKeyComparison=function(q){this.keyComparison=q};var U=function(q){if(!q||{}.toString.call(q)!=='[object Object]'||q.nodeType||q.setInterval)return!1;var O={}.hasOwnProperty,A=O.call(q,'constructor');
|
|
51
51
|
O=typeof q.constructor!='undefined'?O.call(q.constructor.prototype,'isPrototypeOf'):!1;return!q.constructor||A||O?!0:!1};F.setKeyComparison=function(q){L.keyComparison=q;return F};F.getKeyComparison=function(){var q=L.keyComparison||'id';L.keyComparison='id';return q};return F}
|
|
52
52
|
typeof module!=='undefined'&&module.exports?(typeof JSON.clone=='undefined'&&(JSON.clone=require(__dirname+'/../../../../../utils/prototypes.json_clone')),module.exports=Merge()):typeof define==='function'&&define.amd&&define('lib/merge',[],function(){return Merge()});var _alphabet='0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz',_mask=63,_step=7;
|
|
53
|
-
function uuid(
|
|
54
|
-
uuid.customAlphabet=function(
|
|
53
|
+
function uuid(k){k=k||4;for(var G=k<=4?_step:Math.ceil(1.6*(_mask+1)*k/_alphabet.length),F='';;)for(var L=crypto.getRandomValues(new Uint8Array(G)),U=0;U<G;U++){var q=L[U]&_mask;if(q<62&&(F+=_alphabet[q],F.length===k))return F}}
|
|
54
|
+
uuid.customAlphabet=function(k,G){G=G||4;for(var F=1;F<k.length-1;)F=F<<1|1;var L=Math.ceil(1.6*(F+1)*G/k.length);L<5&&(L=5);return function(U){U=U||G;for(var q='';;)for(var O=crypto.getRandomValues(new Uint8Array(L)),A=0;A<L;A++){var P=O[A]&F;if(P<k.length&&(q+=k[P],q.length===U))return q}}};
|
|
55
55
|
if(typeof module!=='undefined'&&module.exports){if(typeof crypto==='undefined'||typeof crypto.getRandomValues!=='function'){var _webcrypto=require('crypto').webcrypto||require('crypto');typeof globalThis!=='undefined'?globalThis.crypto=_webcrypto:crypto=_webcrypto}module.exports=uuid}else typeof define==='function'&&define.amd&&define('lib/uuid',[],function(){return uuid});
|
|
56
|
-
function FormValidatorUtil(
|
|
57
|
-
for(var I=0,la=C.length;I<la;++I){for(var va=C[I];va.charAt(0)===' '||va.charAt(0)==='\t';)va=va.slice(1);var H=va.indexOf('=');if(!(H<0)&&va.slice(0,H)==='gina-csrf-token'){C=va.slice(H+1);try{return decodeURIComponent(C)}catch(da){return C}}}return null},
|
|
56
|
+
function FormValidatorUtil(k,G,F,L,U){var q=typeof module!=='undefined'&&module.exports?!1:!0,O=q?require('lib/merge'):require('../../../../../lib/merge');q||require('../../../../../helpers');q&&require('helpers/dateFormat');var A=q?require('lib/routing'):require('../../../../../lib/routing'),P=q?null:require('../../../../../lib/i18n'),ba=function(){if(typeof document==='undefined'||!document||typeof document.cookie!=='string')return null;var C=document.cookie||'';if(!C)return null;C=C.split(';');
|
|
57
|
+
for(var I=0,la=C.length;I<la;++I){for(var va=C[I];va.charAt(0)===' '||va.charAt(0)==='\t';)va=va.slice(1);var H=va.indexOf('=');if(!(H<0)&&va.slice(0,H)==='gina-csrf-token'){C=va.slice(H+1);try{return decodeURIComponent(C)}catch(da){return C}}}return null},h=function(C){if(typeof C!=='string'||!C)return!1;C=C.toUpperCase();return C!=='GET'&&C!=='HEAD'&&C!=='OPTIONS'},J=function(){var C=!1,I=null;q?q&&typeof gina.forms!='undefined'&&(I=gina.forms):I=getContext('gina').forms||null;I&&typeof I.validators!=
|
|
58
58
|
'undefined'&&(C=!0);return C},w={errors:{},keys:{'%l':'label','%n':'name','%s':'size'},errorLabels:{},data:{},excluded:[]},m={is:'Condition not satisfied',isEmail:'A valid email is required',isRequired:'Cannot be left empty',isBoolean:'Must be a valid boolean',isNumber:'Must be a number: allowed values are integers or floats',isNumberLength:'Must contain %s characters',isNumberMinLength:'Should be at least %s characters',isNumberMaxLength:'Should not be more than %s characters',isInteger:'Must be an integer',
|
|
59
59
|
isIntegerLength:'Must have %s characters',isIntegerMinLength:'Should be at least %s characters',isIntegerMaxLength:'Should not be more than %s characters',toInteger:'Could not be converted to integer',isFloat:'Must be a proper float',isFloatException:'Float exception found: %n',toFloat:'Could not be converted to float',toFloatNAN:'Value must be a valid number',isDate:'Must be a valid Date',isString:'Must be a string',isStringLength:'Must have %s characters',isStringMinLength:'Should be at least %s characters',
|
|
60
60
|
isStringMaxLength:'Should not be more than %s characters',isJsonWebToken:'Must be a valid JSON Web Token',query:'Must be a valid response',isInList:'Must be one of: %s'},oa={},S=function(C){var I={toFloatNAN:'toFloat',isNumberMinLength:'isNumberLength',isNumberMaxLength:'isNumberLength',isIntegerMinLength:'isIntegerLength',isIntegerMaxLength:'isIntegerLength',isStringMinLength:'isStringLength',isStringMaxLength:'isStringLength'},la;for(la in I)typeof C[la]=='undefined'&&typeof C[I[la]]!='undefined'&&
|
|
61
61
|
(C[la]=C[I[la]]);return C};w.errorLabels=m;if(!q&&P&&typeof U==='string'&&U){var r=getContext('bundle');if(r){U=P.walkFallback(U);for(var V=null,v=0;v<U.length;v++){var y=P.getCatalog(r,U[v]);if(y&&(y=P.resolveKey(y,'_validator'))&&typeof y==='object'){V=y;break}}V&&(V=S(JSON.clone(V)),w.errorLabels=O(JSON.clone(V),m))}}if(q&&typeof gina!='undefined'&&typeof gina.config!='undefined'){r=(P=gina.config.culture)&&P.indexOf('_')>0?P.substr(0,P.indexOf('_')):P;P=typeof gina.validator!='undefined'&&gina.validator._errorLabelsByCulture&&
|
|
62
|
-
P?gina.validator._errorLabelsByCulture[P]||(r?gina.validator._errorLabelsByCulture[r]:null)||null:null;r=null;if(gina.config.validatorLabels&&typeof gina.config.validatorLabels=='object')for(var z in gina.config.validatorLabels)if(gina.config.validatorLabels.hasOwnProperty(z)){r=gina.config.validatorLabels;break}r&&(r=S(JSON.clone(r)),w.errorLabels=O(JSON.clone(r),w.errorLabels));P&&(P=S(JSON.clone(P)),w.errorLabels=O(JSON.clone(P),w.errorLabels))}var l=null;if(
|
|
62
|
+
P?gina.validator._errorLabelsByCulture[P]||(r?gina.validator._errorLabelsByCulture[r]:null)||null:null;r=null;if(gina.config.validatorLabels&&typeof gina.config.validatorLabels=='object')for(var z in gina.config.validatorLabels)if(gina.config.validatorLabels.hasOwnProperty(z)){r=gina.config.validatorLabels;break}r&&(r=S(JSON.clone(r)),w.errorLabels=O(JSON.clone(r),w.errorLabels));P&&(P=S(JSON.clone(P)),w.errorLabels=O(JSON.clone(P),w.errorLabels))}var l=null;if(k)l=O(JSON.clone(k),l),w.data=O(JSON.clone(k),
|
|
63
63
|
w.data);else throw Error('missing data param');var ja=function(C,I){var la=null;for(let va in L)if(L[va].name===I){la=(new DOMParser).parseFromString(C.innerHTML,'text/html').getElementById(L[va].id);break}if(la)return la;throw Error('Field `'+I+'` not found in fieldsSet');},M=function(C){var I;var la='';var va=C.length;for(I=0;I<va;){var H=C[I++];switch(H>>4){case 0:case 1:case 2:case 3:case 4:case 5:case 6:case 7:la+=String.fromCharCode(H);break;case 12:case 13:var da=C[I++];la+=String.fromCharCode((H&
|
|
64
64
|
31)<<6|da&63);break;case 14:da=C[I++];var ma=C[I++];la+=String.fromCharCode((H&15)<<12|(da&63)<<6|(ma&63)<<0)}}return la};z=function(C,I){var la=l[this.name].errors||{},va=this.target.id||this.target.getAttribute('id');if(l.isValid()){var H=this.target.dataset.ginaFormValidatorTestedValue;console.debug('[ '+this.name+' ]','TESTED VALUE -> '+this.value+' vs '+H);var da='asyncCompleted.'+va,ma=this.target.form.getAttribute('id'),ia=typeof gina.validator!='undefined'&&typeof gina.validator.$forms[ma]!=
|
|
65
65
|
'undefined'&&typeof gina.validator.$forms[ma].cachedErrors!='undefined'?gina.validator.$forms[ma].cachedErrors:null;if(!H||typeof H=='undefined'||H!==this.value)this.target.dataset.ginaFormValidatorTestedValue=this.value,ia&&typeof ia[this.name]!='undefined'&&typeof ia[this.name].query!='undefined'&&(delete ia[this.name].query,typeof gina.validator.$forms[ma]!='undefined'&&typeof gina.validator.$forms[ma].errors!='undefined'&&delete gina.validator.$forms[ma].errors.query);else if(H===this.value){if(this.target&&
|
|
@@ -67,7 +67,7 @@ this.target.dataset&&this.target.dataset.ginaFormValidatorQueryPending===this.va
|
|
|
67
67
|
'undefined'){var xa=this.target,ta=this.name;queueMicrotask(function(){triggerEvent(gina,xa,da,l[ta])})}return l[this.name]}var Fa=null,ha=this;if(window.XMLHttpRequest)Fa=new XMLHttpRequest;else if(window.ActiveXObject)try{Fa=new ActiveXObject('Msxml2.XMLHTTP')}catch(mb){try{Fa=new ActiveXObject('Microsoft.XMLHTTP')}catch(bb){}}I={isSynchrone:!1,headers:{}};H=C.data||null;la=null;ia=/^true$/i.test(this.target.form.dataset.ginaFormLiveCheckEnabled)?!0:!1;la=JSON.stringify(H);if(/\$/.test(la)){H=la.match(/\$[-_\[\]a-z 0-9]+/g)||
|
|
68
68
|
[];var jb=ma=null;for(let mb=0,bb=H.length;mb<bb;mb++)jb=H[mb].replace(/\$/g,''),re=new RegExp('\\'+H[mb].replace(/\[|\]/g,'\\$&'),'g'),ma=w.data[jb]||null,!ma&&ia&&(ma=ja(this.target.form,jb).value),la=la.replace(re,ma)}H=la.replace(/\\"/g,'');var ua=typeof C.validIf=='undefined'?!0:C.validIf;I=O(I,C,F);delete I.data;delete I.validIf;la=I.headers['Content-Type'];var za=null;va=this.target.getAttribute('id');if(!/^http/.test(I.url)&&/@/.test(I.url))try{sa=A.getRoute(I.url),I.url=sa.toUrl()}catch(mb){throw mb;
|
|
69
69
|
}if(I.withCredentials){if('withCredentials'in Fa)I.isSynchrone?Fa.open(I.method,I.url,I.isSynchrone):Fa.open(I.method,I.url);else if(typeof XDomainRequest!='undefined')Fa=new XDomainRequest,Fa.open(I.method,I.url);else throw Fa=null,za='CORS not supported: the server is missing the header `"Access-Control-Allow-Credentials": true` ',Error(za);Fa.responseType=typeof I.responseType!='undefined'?I.responseType:'';Fa.withCredentials=!0}else I.isSynchrone?Fa.open(I.method,I.url,I.isSynchrone):Fa.open(I.method,
|
|
70
|
-
I.url);for(var Oa in I.headers)Oa=='Content-Type'&&typeof la!='undefined'&&la!=null&&la!=''||Fa.setRequestHeader(Oa,I.headers[Oa]);typeof la!='undefined'&&la!=null&&la!=''&&Fa.setRequestHeader('Content-Type',la);
|
|
70
|
+
I.url);for(var Oa in I.headers)Oa=='Content-Type'&&typeof la!='undefined'&&la!=null&&la!=''||Fa.setRequestHeader(Oa,I.headers[Oa]);typeof la!='undefined'&&la!=null&&la!=''&&Fa.setRequestHeader('Content-Type',la);h(I.method)&&(sa=ba())&&Fa.setRequestHeader('X-Gina-CSRF-Token',sa);var qb=function(mb){console.warn('[ FormValidator ] `query` result handling failed for field `'+(ha&&ha.name)+'`: '+(mb&&mb.message||mb));try{ha.target&&ha.target.dataset&&ha.target.dataset.ginaFormValidatorQueryPending===
|
|
71
71
|
String(ha.value)&&delete ha.target.dataset.ginaFormValidatorQueryPending}catch(Ha){}try{var bb=ha.target&&(ha.target.id||ha.target.getAttribute('id'));bb&&triggerEvent(gina,ha.target,'asyncCompleted.'+bb,l[ha.name])}catch(Ha){}},Wa=function(mb){try{ha.target&&ha.target.dataset&&ha.target.dataset.ginaFormValidatorQueryPending===String(ha.value)&&delete ha.target.dataset.ginaFormValidatorQueryPending;ha.value=w.data[ha.name]=ha.value&&typeof ha.value=='string'?ha.value.toLowerCase():ha.value;var bb=
|
|
72
72
|
mb.isValid||!1;bb=ua!=bb?!1:!0;l[ha.name].valid=bb;var Ha=l[ha.name].errors||{},Ib=typeof mb.error!='undefined'&&typeof mb.fields!='undefined'?mb.fields:{};if(Ib.count()>0&&!bb||!bb){if(!bb){var vb=null;if(typeof Ib[ha.name]!='undefined'){if(typeof Ib[ha.name]==='string'){var Mb=w.errorLabels;var Hb=Ib[ha.name],Pb=C.data;if(typeof Hb=='string'){var Qb=Hb.match(/\{\{([^{{}}]+)\}\}/g);if(Qb)for(let g=0,x=Qb.length;g<x;g++){let aa=Qb[g].replace(/\[/g,'["').replace(/\]/g,'"]').replace(/\{|\}/g,'').trim();
|
|
73
73
|
try{var W=aa;let Q=[],wa=W.match(/^([A-Za-z_$][\w$]*)/);if(!wa)throw Error('Invalid property path: `'+aa+'`');Q.push(wa[1]);for(W=W.slice(wa[0].length);W.length>0;)if(wa=W.match(/^\.([A-Za-z_$][\w$]*)/))Q.push(wa[1]),W=W.slice(wa[0].length);else if(wa=W.match(/^\["([^"\]]*)"\]/))Q.push(wa[1]),W=W.slice(wa[0].length);else throw Error('Invalid property path: `'+aa+'`');W=Pb;for(let Ka=0;W!=null&&Ka<Q.length;Ka++)W=W[Q[Ka]];aa=W.replace(/^"|"$/g,'');Hb=Hb.replace(new RegExp(Qb[g].replace(/\{|\[|\]|\}/g,
|
|
@@ -75,7 +75,7 @@ try{var W=aa;let Q=[],wa=W.match(/^([A-Za-z_$][\w$]*)/);if(!wa)throw Error('Inva
|
|
|
75
75
|
'undefined'&&(l[ha.name].errors={});l[ha.name].errors=O(l[ha.name].errors,Ha);typeof Ha.query!='undefined'&&Ha.query&&(typeof u[ha.name]=='undefined'&&(u[ha.name]={}),typeof u[ha.name].query=='undefined'&&(u[ha.name].query={}),u[ha.name].query[ha.value]=Ha.query.slice(0));var Z=ha.target.getAttribute('data-gina-form-errors');/query/.test(Z)||ha.target.setAttribute('data-gina-form-errors',Z&&Z!=''?Z+' query':'query')}else typeof u[ha.name]!='undefined'&&typeof u[ha.name].query!='undefined'&&typeof u[ha.name].query[ha.value]!=
|
|
76
76
|
'undefined'&&delete u[ha.name].query[ha.value];var e=ha.target.id||ha.target.getAttribute('id');console.debug('prematurely completed event `asyncCompleted.'+e+'`');return triggerEvent(gina,ha.target,'asyncCompleted.'+e,l[ha.name])}catch(g){return qb(g)}};Fa&&(Fa.onerror=function(mb,bb){try{var Ha={status:Fa.status,error:'Transaction error: might be due to the server CORS settings.\nPlease, check the console for more details.'};console.debug('query error [2] detected !! ',bb,'Transaction error: might be due to the server CORS settings.\nPlease, check the console for more details.');
|
|
77
77
|
isOnException=!0;Ha=this.responseText;var Ib=this.getResponseHeader('Content-Type');if(/\/json/.test(Ib))Ha=JSON.parse(this.responseText),typeof Ha.status=='undefined'&&(Ha.status=this.status);else if(Ha={status:Fa.status,message:''},/^(\{|\[)/.test(Fa.responseText))try{Ha=O(Ha,JSON.parse(Fa.responseText))}catch(vb){Ha=O(Ha,vb)}return Wa(Ha)}catch(vb){return qb(vb)}},Fa.onload=function(){try{za=this.responseText;var mb=this.getResponseHeader('Content-Type');if(/\/json/.test(mb))za=JSON.parse(this.responseText),
|
|
78
|
-
typeof za.status=='undefined'&&(za.status=this.status);else if(za={status:Fa.status,message:''},/^(\{|\[)/.test(Fa.responseText))try{za=O(za,JSON.parse(Fa.responseText))}catch(bb){za=O(za,bb)}return Wa(za)}catch(bb){return qb(bb)}},ha.target&&ha.target.dataset&&(ha.target.dataset.ginaFormValidatorQueryPending=ha.value),
|
|
78
|
+
typeof za.status=='undefined'&&(za.status=this.status);else if(za={status:Fa.status,message:''},/^(\{|\[)/.test(Fa.responseText))try{za=O(za,JSON.parse(Fa.responseText))}catch(bb){za=O(za,bb)}return Wa(za)}catch(bb){return qb(bb)}},ha.target&&ha.target.dataset&&(ha.target.dataset.ginaFormValidatorQueryPending=ha.value),k?Fa.send(H):Fa.send())}else{console.debug('stopping on errors ...');var gb=this.target,yb=this.name;queueMicrotask(function(){triggerEvent(gina,gb,'asyncCompleted.'+va,l[yb])})}};
|
|
79
79
|
P=async function(C,I,la,va){var H=(new (require(_(GINA_FRAMEWORK_DIR+'/core/config.js',!0)))).getInstance(),da=null,ma=null,ia=null,sa=getContext('bundle');if(/@/.test(C.url)){var xa=C.url.split(/@/);ma=xa[0];ia=xa[1];getConfig(sa,'app');try{H.bundle!==ia&&(da=getConfig(sa,'app').proxy[ia])}catch(ua){throw Error('Could not retrieve `proxy` configuration for bundle `'+ia+'`. Please check your `/config/app.json`.\n'+ua.stack);}xa=null}else throw Error('external url/domain not handled at this moment, please contact us if you need support for it.');
|
|
80
80
|
xa=JSON.clone(A.getRoute(C.url,C.data));var ta=H[ia][H.env],Fa=ta.content.server;typeof Fa._cached=='undefined'&&(Fa._cached=new Map);typeof Fa._cachedPath=='undefined'&&(Fa._cachePath=Fa.cache.path);typeof Fa._cacheIsEnabled=='undefined'&&(Fa._cacheIsEnabled=Fa.cache.enable);da||(H.bundle==ia&&(da=getConfig(sa,'settings').server.credentials,C.ca=da.ca||null,C.hostname=ta.server.scheme+'://'+ta.host,C.port=ta.port[ta.server.protocol][ta.server.scheme],C.protocol=ta.server.protocol,C.rejectUnauthorized=
|
|
81
81
|
!1),da={ca:C.ca,hostname:C.hostname,port:C.port,path:C.path},typeof C.protocol!='undefined'&&(da.protocol=C.protocol),typeof C.rejectUnauthorized!='undefined'&&(da.rejectUnauthorized=C.rejectUnauthorized));ma={method:xa.method,requirements:xa.requirements,namespace:xa.namespace||void 0,url:decodeURI(xa.url),rule:ma+'@'+ia,param:JSON.clone(xa.param),middleware:JSON.clone(xa.middleware),bundle:xa.bundle,isXMLRequest:I.isXMLRequest,isWithCredentials:I.isWithCredentials};ia=ma.rule.replace('@'+ia,'')||
|
|
@@ -113,99 +113,99 @@ I=gina.forms.validators[H].toString(),l[C][H]=eval('('+I+')\n//# sourceURL='+H+'
|
|
|
113
113
|
typeof l[la].errors!='undefined'&&l[la].errors.count()>0&&(I[la]=l[la].errors);return I};l.toData=function(){if(w.excluded.length>0)for(var C=0,I=w.excluded.length;C<I;++C)typeof w.data[w.excluded[C]]!='undefined'&&delete w.data[w.excluded[C]];return w.data};var Y=function(C,I,la){if(typeof C!=='string'){var va=la&&typeof w.errorLabels[la]==='string'?w.errorLabels[la]:la&&typeof m[la]==='string'?m[la]:'';la=la||'(unknown rule)';oa[la]||(oa[la]=!0,console.warn('[FormValidator] error label for rule `'+
|
|
114
114
|
la+'` must be a string \u2014 got '+(C===null?'null':typeof C)+'. Falling back to '+(va?'`'+va+'`':'an empty message')+". Check the bundle catalog's `_validator` node, `setErrorLabels()`, the rule's `errorMessage` argument, and the field's `error`."));C=va}if(va=C.match(/%[a-z]+/gi)){la=0;for(var H=va.length;la<H;++la)C=C.replace(new RegExp(va[la],'g'),I[w.keys[va[la]]])}return C};l.setErrorLabels=function(C){typeof C!='undefined'&&(S(C),w.errorLabels=O(C,w.errorLabels))};return l}
|
|
115
115
|
typeof module!=='undefined'&&module.exports?module.exports=FormValidatorUtil:typeof define==='function'&&define.amd&&define('lib/form-validator',[],function(){return FormValidatorUtil});
|
|
116
|
-
function Routing(){var
|
|
117
|
-
(L&&typeof L=='function'||(L=require('lib/merge')),U&&typeof U=='function'||(U=require('lib/form-validator'))):(require('fs'),require('util'),require('../../inherits'),L=require('../../merge'),F=require(__dirname+'/../../../core/plugins')||getContext('gina').plugins,U=F.Validator);G.getUrlProps=function(
|
|
118
|
-
typeof getContext('argvFilename')!='undefined'&&(m.getRouting=getContext('gina').Config.instance.getRouting),typeof
|
|
119
|
-
G.getCached=function(
|
|
120
|
-
typeof
|
|
121
|
-
w,m,oa){typeof w=='undefined'&&(w={routing:{}});if(/,/.test(J)){var S=0;J=J.split(/,/g);for(var r=J.length,V={past:!1,request:w};S<r&&!V.past;)V=await q(
|
|
122
|
-
typeof w[ja]!='undefined'||typeof
|
|
123
|
-
await O(J[C],S[C],
|
|
124
|
-
r=0,J.join(',').match(/:[-_a-z0-9]+/g);r<N.length;){V=N[r];if(typeof
|
|
125
|
-
for(let I=0,la=J.length;I<la;I++){if(!/^:/.test(J[I]))continue;Y=J[I].replace(/^:/,'');Y!=''&&typeof S[I]!='undefined'&&(l[Y]=S[I],typeof w.params[Y]=='undefined'&&(w.params[Y]=S[I]))}}l=L(l,JSON.clone(w[ja])||{});typeof l[V]=='undefined'&&(l[V]=null);T[V]=M;_validator=
|
|
126
|
-
M[I]):await _validator[V][I](M[I],w,m,oa),!T.isValid&&(--y,typeof T.error!='undefined'))throw T.error;}r++}z.past=y===v?!0:!1;z.past&&(w.routing=P(
|
|
127
|
-
w.param.namespace.replace(r,J));typeof w.param.file!='undefined'&&/:/.test(w.param.file)&&(v=new RegExp('(:'+
|
|
128
|
-
'undefined'||typeof w.requirements[z]=='undefined')return typeof w.param[z]!='undefined'&&typeof m.params!='undefined'&&J?(m.params[z]=J,typeof m[M][z]=='undefined'&&(m[M][z]=J),!0):!1;r=w.requirements[z];if(/^\//.test(r))v=r.match(/\/(.*)\//).pop(),y=r.replace('/'+v+'/',''),v=(new RegExp(v,y)).test(J);else if(/^validator::/.test(r)&&J){y={};v={};l={};ja='';
|
|
129
|
-
'"$1":').replace(/([^:"\s+](\w+))\s+:/g,'"$1":'))}catch(I){throw I;}typeof v.query!='undefined'&&typeof v.query.data!='undefined'&&
|
|
130
|
-
if(typeof w.param[z]!='undefined'&&typeof w.requirements!='undefined'&&typeof w.requirements[z]!='undefined'&&typeof m.params!='undefined'&&v){m.params[z]=J;if(typeof m[M][z]=='undefined'){switch(J){case 'null':J=null;break;case 'false':J=!1;break;case 'true':J=!0}m[M][z]=J}return!0}}else{if(typeof w.requirements=='undefined')return!1;oa=w.url;S=m.url;M={};l='';var N=!1,Y=0;T=0;for(var C=S.length;T<C;++T)if(S.charAt(T)!=
|
|
131
|
-
w.requirements[V[0]];J=l.substring(0,l.length);if(/^\//.test(r))v=r.match(/\/(.*)\//).pop(),y=r.replace('/'+v+'/',''),v=(new RegExp(v,y)).test(J);else if(/^validator::/.test(r)){y={};v={};l={};ja='';
|
|
132
|
-
else y[z[0]][I](v[I]);v=y.isValid()}else v=(new RegExp(w.requirements[z[0]])).test(J);if(v)M[V[0].substring(1)]=J;else return!1;l='';N=!1;Y=oa.indexOf(V[0])+V[0].length;--T;V.splice(0,1)}else l+=S.charAt(T),++Y;if(T==C-1)if(r=w.requirements[V[0]],J=l.substring(0,l.length),/^\//.test(r)?(v=r.match(/\/(.*)\//).pop(),y=r.replace('/'+v+'/',''),v=(new RegExp(v,y)).test(J)):v=(new RegExp(w.requirements[z])).test(J),v)M[V[0].substring(1)]=
|
|
133
|
-
null;break;case 'false':M[z]=!1;break;case 'true':M[z]=!0}m.params[z]=M[z]}return!0}}return!1},A=function(
|
|
134
|
-
J[r]));typeof
|
|
135
|
-
|
|
136
|
-
'').replace(/:\d+$/,'')),m=window.gina.config):(m=getContext('gina').config,typeof getContext('argvFilename')!='undefined'&&(m.getRouting=getContext('gina').Config.instance.getRouting),oa=getContext('isProxyHost'));var S=m.env||GINA_ENV,r=null,V=m.bundle;/@/.test(
|
|
137
|
-
'@'+V}r=m.getRouting(V,S);if(typeof r[
|
|
138
|
-
(ba=!0,console.warn('[ RoutingHelper::getRoute() ] Proxied context is active but no proxy hostname is resolvable (worker global and envConf fallback both unset) - falling back to the route direct hostname. Warned once per process.')))):!
|
|
139
|
-
') VS config.envConf._proxyHostname ('+m.envConf._proxyHostname+')'));/,/.test(V.url)&&(typeof V.urlIndex!='undefined'&&(w=V.urlIndex,delete V.urlIndex),w=typeof w!='undefined'?w:0,V.url=V.url.split(/,/g)[w]);/\/$/.test(V.url)&&V.url!='/'&&(V.url=V.url.substring(0,V.url.length-1));if(/GET/i.test(V.method)&&typeof J!='undefined'){w='?';m=r[
|
|
140
|
-
'&',oa[r]=J[y],++r);for(let y in J)G.reservedParams.indexOf(y)>-1||V.requirements&&typeof V.requirements[y]!='undefined'||oa.indexOf(y)>-1||(w=typeof J[y]=='object'?w+(y+'='+encodeRFC5987ValueChars(JSON.stringify(J[y]))+'&'):w+(y+'='+J[y]+'&'));r=oa=m=null;w.length>1&&(w=w.substring(0,w.length-1),V.url+=w);w=null}V.toUrl=function(y){var z=null;
|
|
141
|
-
''+z.hostname;var ja=''+this.url;this.isProxyHost&&(z=''+this.proxy_hostname);this.url=typeof y!='undefined'&&/^true$/i.test(y)?ja.replace(new RegExp('^'+l),'/'):ja.replace(new RegExp('^('+l+'|/$)'),l);return z+this.url};V.request=function(y,z){var l=null,ja=null;typeof arguments[arguments.length-1]=='function'&&(l=arguments[arguments.length-
|
|
142
|
-
'/'):this.url||ja.url;/^\//.test(ja)&&(ja=T+ja);T=/^https/.test(T)?'https':'http';
|
|
143
|
-
(C=JSON.clone(Y),Y=null)}catch(I){C=I}C?l(C):l(!1,Y)})},l?T.get(ja,z,M):T.get(ja,z))};!/:/.test(V.url)||/:d+\//.test(V.url)||/:\/\//.test(V.url)||(J=V.url.match(/(:(.*)\/|:(.*)$)/g).map(function(y){return y.replace(/\//g,'')}).join(', '),v='[ RoutingHelper::getRoute(rule[, bundle, method]) ] : route [ %r ] param placeholder not defined: `'+
|
|
144
|
-
return V};G.getRouteByUrl=async function(
|
|
145
|
-
typeof v[S]!='undefined'&&(l=V[v[S]],J=l.bundle,S=l.webroot,z=l.hostname,l=null));oa=typeof arguments[arguments.length-1]!='boolean'?!1:arguments[arguments.length-1];var ja=!1,M=null,T=v=M=v=null;l=typeof w!='undefined'?!0:!1;
|
|
146
|
-
J=typeof J!='undefined'?J:M.bundle,v=M.env,V=M.getRouting(J),z=M.envConf[J][v].hostname,S=M.envConf[J][v].server.webroot,m||={routing:{},isXMLRequest:!1,method:typeof w!='undefined'?w.toLowerCase():'get',params:{},url:
|
|
147
|
-
safeDecodeURI(M));m.method||(m.method=w);v={};S=new RegExp(w,'i');z=null;for(N in V){if(typeof V[N].param=='undefined')break;if(V[N].bundle==J&&(z=V[N].method,/,/.test(z)&&S.test(z)&&(z=m.method),typeof V[N].method=='undefined'||S.test(z))){v={method:z,requirements:V[N].requirements,namespace:V[N].namespace||void 0,
|
|
148
|
-
m),M==V[N].url||T.past){r=JSON.clone(V[N]);r.name=N;r.param=v.param;ja=!0;T={};break}}catch(Y){throw Error('Route [ '+N+' ] needs your attention.\n'+Y.stack);}}}if(ja)return/\/$/.test(
|
|
149
|
-
(G.notFound={});y=null;r='[ RoutingHelper::getRouteByUrl(rule[, bundle, method]) ] : route [ %r ] is called but not found inside your view: `'+
|
|
150
|
-
'undefined'?G.notFound[y]={count:1,message:r}:l&&typeof G.notFound[y]!='undefined'&&++G.notFound[y].count,!1;if((N=gina.config.reverseRouting[
|
|
151
|
-
r=r.replace(/%r/,y):++G.notFound[y].count);return!1}console.warn(Error('[ RoutingHelper::getRouteByUrl(rule[, bundle, method, request]) ] : route not found for url: `'+
|
|
152
|
-
J){return Routing._tries&&Routing._tries[J]?require('./radix').lookup(Routing._tries[J],
|
|
153
|
-
function registerEvents(
|
|
154
|
-
function addListener(
|
|
155
|
-
O;q++)U(
|
|
156
|
-
function triggerEvent(
|
|
157
|
-
G.id,
|
|
158
|
-
function setupXhr(
|
|
159
|
-
|
|
160
|
-
null&&enctype!=''||G.setRequestHeader(F,
|
|
161
|
-
function handleXhr(
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
!0:!1,!
|
|
165
|
-
r.click();window.URL.revokeObjectURL(V);A={status:
|
|
116
|
+
function Routing(){var k=typeof module!=='undefined'&&module.exports?!1:!0,G={allowedMethods:['get','post','put','delete'],reservedParams:['controle','file','title','namespace','path'],notFound:{},getInstance:function(h){return Routing.instance}};if(typeof Routing.initialized=='undefined')Routing.initialized=!0,Routing.instance=G,Routing._cached=[],Routing._cachedRoutes={},Routing._tries={};else return G=G.getInstance();G.allowedMethodsString=G.allowedMethods.join(',');var F=null,L=null,U=null;k?
|
|
117
|
+
(L&&typeof L=='function'||(L=require('lib/merge')),U&&typeof U=='function'||(U=require('lib/form-validator'))):(require('fs'),require('util'),require('../../inherits'),L=require('../../merge'),F=require(__dirname+'/../../../core/plugins')||getContext('gina').plugins,U=F.Validator);G.getUrlProps=function(h,J){var w={};if(k){var m=window.gina.config;w.hostname=m.hostname;typeof h!='undefined'&&(h=this.getRoute('webroot@'+h),w.hostname=h.hostname,w.host=h.host,w.webroot=h.webroot)}else m=getContext('gina').config,
|
|
118
|
+
typeof getContext('argvFilename')!='undefined'&&(m.getRouting=getContext('gina').Config.instance.getRouting),typeof h=='undefined'&&(h=m.bundle),typeof J=='undefined'&&(J=m.env),w.hostname=m.envConf[h][J].hostname,w.host=m.envConf[h][J].host,w.webroot=m.envConf[h][J].server.webroot;return w};G.cache=function(h,J,w,m,oa){Routing._cached.indexOf(h)==-1&&(Routing._cached.length>=5E3&&G.invalidateCached(Routing._cached[0]),Routing._cached.push(h),Routing._cachedRoutes[h]={name:J,routing:w,params:m,methodParams:oa})};
|
|
119
|
+
G.getCached=function(h,J){if(Routing._cached.indexOf(h)>-1){var w=Routing._cachedRoutes[h],m=J.method.toLowerCase();h=JSON.clone(w.routing);w={method:m,requirements:h.requirements,namespace:h.namespace||void 0,url:safeDecodeURI(J.url),rule:h.originalRule||w.name,param:h.param,middleware:h.middleware,bundle:h.bundle,isXMLRequest:J.isXMLRequest,isWithCredentials:J.isWithCredentials};typeof h.rule=='undefined'&&typeof w.rule!='undefined'&&(h.rule=w.rule);typeof h.cache!='undefined'&&(w.cache=h.cache);
|
|
120
|
+
typeof h.csrfExempt!='undefined'&&(w.csrfExempt=h.csrfExempt);typeof h.culturePrefix!='undefined'&&(w.culturePrefix=h.culturePrefix);typeof h.queryTimeout!='undefined'&&(w.queryTimeout=parseTimeout(h.queryTimeout));typeof h.negotiate!='undefined'&&(w.negotiate=h.negotiate);typeof h.rateLimit!='undefined'&&(w.rateLimit=h.rateLimit);return G.compareUrls(w,h.url,J)}return null};G.invalidateCached=function(h){Routing._cached.indexOf(h)>-1&&(Routing._cached.splice(Routing._cached.indexOf(h),1),delete Routing._cachedRoutes[h])};
|
|
121
|
+
G.compareUrls=async function(h,J,w,m,oa){typeof w=='undefined'&&(w={routing:{}});if(/,/.test(J)){var S=0;J=J.split(/,/g);for(var r=J.length,V={past:!1,request:w};S<r&&!V.past;)V=await q(h,J[S],w,m,oa),++S;return V}return await q(h,J,w,m,oa)};var q=async function(h,J,w,m,oa){var S=null;try{S=h.url.split(/\//)}catch(C){console.warn(C),S=['']}J=J.split(/\//);var r=0,V=0,v=J.length,y=0,z={},l=0,ja=w.method.toLowerCase(),M='get';try{M=h.method.toLowerCase()}catch(C){}var T=!1;if(typeof h.requirements!=
|
|
122
|
+
'undefined'&&/get|delete/i.test(ja)&&typeof w[ja]!='undefined'||typeof h.requirements!='undefined'&&/get/i.test(ja)&&/delete/i.test(M)){/get/i.test(ja)&&/delete/i.test(M)&&(ja=M);if(/^(delete)$/i.test(ja)&&S.length===J.length){typeof w[ja]=='undefined'&&(w[ja]={});for(let C=0,I=J.length;C<I;C++){if(S[C]===J[C]){++y;continue}M=J[C].substring(1);if(typeof h.requirements[M]=='undefined')continue;M=h.requirements[M];T='';if(/^\//.test(M))T=M.substring(M.lastIndexOf('/')+1),M=M.substring(1,M.lastIndexOf('/'));
|
|
123
|
+
else if(/^validator::/.test(M)&&await O(J[C],S[C],h,w,m,oa)){++y;continue}/^:/.test(J[C])&&typeof M!='undefined'&&(new RegExp(M,T)).test(S[C])&&(++y,w[ja][J[C].substring(1)]=S[C])}T=!0}for(var N in w[ja])typeof h.requirements[N]!='undefined'&&J.indexOf(':'+N)<0&&(J[V]=':'+N,++V,S[r]=w[ja][N],++r,T||S.length!==J.length||++v)}if(!T&&S.length===J.length)for(;l<v;++l)S[l]===J[l]?++y:y==l&&/:/.test(J[l])&&await O(J[l],S[l],h,w,m,oa)&&++y;if(typeof h.requirements!='undefined'&&ja==h.method.toLowerCase()&&
|
|
124
|
+
!T&&y>=v)for(N=Object.getOwnPropertyNames(h.requirements),r=0,J.join(',').match(/:[-_a-z0-9]+/g);r<N.length;){V=N[r];if(typeof h.param[V]=='undefined'&&/^validator::/i.test(h.requirements[V])){if(J.length!=S.length)break;var Y=J.join(',').match(/:[-_a-z0-9]+/g);let C=h.requirements[V];l={};M={};T={};try{M=JSON.parse(C.split(/::/).splice(1)[0].replace(/([^:"\s+](\w+)):/g,'"$1":').replace(/([^:"\s+](\w+))\s+:/g,'"$1":'))}catch(I){throw I;}if(typeof M.query!='undefined'&&typeof M.query.data!='undefined'){l=
|
|
125
|
+
M.query.data;for(let I in l)Y.indexOf(l[I])<0&&delete l[I];for(let I=0,la=J.length;I<la;I++){if(!/^:/.test(J[I]))continue;Y=J[I].replace(/^:/,'');Y!=''&&typeof S[I]!='undefined'&&(l[Y]=S[I],typeof w.params[Y]=='undefined'&&(w.params[Y]=S[I]))}}l=L(l,JSON.clone(w[ja])||{});typeof l[V]=='undefined'&&(l[V]=null);T[V]=M;_validator=k?new U(l):new U('routing',l,null,T);if(M.count()==0){console.error('Route validation failed '+h.rule);--y;r++;continue}for(let I in M)if(typeof M[I].data!='undefined'&&(M[I].data=
|
|
126
|
+
l),T=Array.isArray(M[I])?await _validator[V][I].apply(_validator[V],M[I]):await _validator[V][I](M[I],w,m,oa),!T.isValid&&(--y,typeof T.error!='undefined'))throw T.error;}r++}z.past=y===v?!0:!1;z.past&&(w.routing=P(h,w[ja]),z.request=w);return z},O=async function(h,J,w,m,oa,S){var r=-1,V=h.match(/:\w+/g);r=new RegExp(h,'g');var v=null,y=null,z=null;v=!1;var l=v=y=y=null,ja=null,M=m.method.toLowerCase();if(!V.length)return!1;w.param.path&&r.test(w.param.path)&&(w.param.path=w.param.path.replace(r,
|
|
127
|
+
J));w.param.namespace&&r.test(w.param.namespace)&&(w.param.namespace=w.param.namespace.replace(r,J));typeof w.param.file!='undefined'&&/:/.test(w.param.file)&&(v=new RegExp('(:'+h+'/|:'+h+'$)','g'),A.variable=J,w.param.file=w.param.file.replace(v,A),v=null);w.param.title&&r.test(w.param.title)&&(w.param.title=w.param.title.replace(r,J));if(V.length==1){v=new RegExp(V[0]);r=V.indexOf(h)>-1?V.indexOf(h):!1;r===!1&&h.match(v)&&(r=0);if(r===!1)return r;if(w.method.toLowerCase()!==M)return!1;typeof m[M]==
|
|
128
|
+
'undefined'&&(m[M]={});z=V[r].substring(1);if(typeof w.requirements=='undefined'||typeof w.requirements[z]=='undefined')return typeof w.param[z]!='undefined'&&typeof m.params!='undefined'&&J?(m.params[z]=J,typeof m[M][z]=='undefined'&&(m[M][z]=J),!0):!1;r=w.requirements[z];if(/^\//.test(r))v=r.match(/\/(.*)\//).pop(),y=r.replace('/'+v+'/',''),v=(new RegExp(v,y)).test(J);else if(/^validator::/.test(r)&&J){y={};v={};l={};ja='';h.replace(new RegExp('[^'+z+']','g'),function(){ja+=arguments[0]});y[z]=
|
|
129
|
+
J.replace(new RegExp(ja,'g'),'');try{v=JSON.parse(r.split(/::/).splice(1)[0].replace(/([^:"\s+](\w+)):/g,'"$1":').replace(/([^:"\s+](\w+))\s+:/g,'"$1":'))}catch(I){throw I;}typeof v.query!='undefined'&&typeof v.query.data!='undefined'&&h==v.query.data[Object.keys(v.query.data)[0]]&&(v.query.data[Object.keys(v.query.data)[0]]=y[z],m.params[z]=y[z]);l[z]=v;y=new U('routing',y,null,l);if(v.count()==0)return console.error('Route validation failed '+w.rule),!1;for(var T in v)Array.isArray(v[T])?await y[z][T].apply(y[z],
|
|
130
|
+
v[T]):await y[z][T](v[T],m,oa,S);v=y.isValid()}else v=(new RegExp(w.requirements[z])).test(J);if(typeof w.param[z]!='undefined'&&typeof w.requirements!='undefined'&&typeof w.requirements[z]!='undefined'&&typeof m.params!='undefined'&&v){m.params[z]=J;if(typeof m[M][z]=='undefined'){switch(J){case 'null':J=null;break;case 'false':J=!1;break;case 'true':J=!0}m[M][z]=J}return!0}}else{if(typeof w.requirements=='undefined')return!1;oa=w.url;S=m.url;M={};l='';var N=!1,Y=0;T=0;for(var C=S.length;T<C;++T)if(S.charAt(T)!=
|
|
131
|
+
oa.charAt(Y)||N){if(l=='')N=!0,l+=S.charAt(T);else if(T>oa.indexOf(V[0])+V[0].length){r=w.requirements[V[0]];J=l.substring(0,l.length);if(/^\//.test(r))v=r.match(/\/(.*)\//).pop(),y=r.replace('/'+v+'/',''),v=(new RegExp(v,y)).test(J);else if(/^validator::/.test(r)){y={};v={};l={};ja='';h.replace(new RegExp('[^'+z[0]+']','g'),function(){ja+=arguments[0]});y[z[0]]=J.replace(new RegExp(ja,'g'),'');v=JSON.parse(r.split(/::/).splice(1)[0].replace(/([^\W+ true false])+(\w+)/g,'"$&"'));l[z[0]]=v;y=new U('routing',
|
|
132
|
+
y,null,l);for(let I in v)if(Array.isArray(v[I]))y[z[0]][I].apply(y[z[0]],v[I]);else y[z[0]][I](v[I]);v=y.isValid()}else v=(new RegExp(w.requirements[z[0]])).test(J);if(v)M[V[0].substring(1)]=J;else return!1;l='';N=!1;Y=oa.indexOf(V[0])+V[0].length;--T;V.splice(0,1)}else l+=S.charAt(T),++Y;if(T==C-1)if(r=w.requirements[V[0]],J=l.substring(0,l.length),/^\//.test(r)?(v=r.match(/\/(.*)\//).pop(),y=r.replace('/'+v+'/',''),v=(new RegExp(v,y)).test(J)):v=(new RegExp(w.requirements[z])).test(J),v)M[V[0].substring(1)]=
|
|
133
|
+
J;else return!1}else++Y;if(M.count()==V.length){z=null;for(z in M){switch(M[z]){case 'null':M[z]=null;break;case 'false':M[z]=!1;break;case 'true':M[z]=!0}m.params[z]=M[z]}return!0}}return!1},A=function(h){return/\/$/.test(h)?A.variable+'/':A.variable},P=function(h,J){var w=null,m,oa=h.url,S=null;for(S in h.param)if((typeof J=='undefined'||typeof J[S]!='undefined')&&/^:/.test(h.param[S])){var r=h.param[S].substring(1);if(typeof J!='undefined'&&typeof J[r]!='undefined'){var V=new RegExp('(:'+r+'/|:'+
|
|
134
|
+
r+'$)','g');typeof h.param.path!='undefined'&&/:/.test(h.param.path)&&(h.param.path=h.param.path.replace(V,J[r]));typeof h.param.title!='undefined'&&/:/.test(h.param.title)&&(h.param.title=h.param.title.replace(V,J[r]));typeof h.param.namespace!='undefined'&&/:/.test(h.param.namespace)&&(h.param.namespace=h.param.namespace.replace(V,J[r]));typeof h.param.file!='undefined'&&/:/.test(h.param.file)&&(A.variable=J[r],h.param.file=h.param.file.replace(V,A));if(/,/.test(h.url)){w=h.url.split(/,/g);var v=
|
|
135
|
+
0;for(m=w.length;v<m;++v)A.variable=J[r],w[v]=w[v].replace(V,A);h.url=w.join(',')}else A.variable=J[r],h.url=h.url.replace(V,A)}}if(w){v=0;m=w.length;oa=oa.split(/,/g);var y=0;for(h.urlIndex=0;v<m;++v)if(w=0,V=oa[0].match(/:[-_a-z0-9]+/ig)){S=0;for(r=V.length;S<r;S++){var z=V[S].substring(1);typeof J[z]!='undefined'&&J[z]&&w++}w>y&&(y=w,h.urlIndex=v)}}return h},ba=!1;G.getRoute=function(h,J,w){var m=null,oa=!1;k?(window.location.port||window.location.hostname!=window.gina.config.hostname.replace(/^(https|http|wss|ws):\/\//,
|
|
136
|
+
'').replace(/:\d+$/,'')||(oa=!0,window.gina.config.hostname=window.gina.config.hostname.replace(/^(https|http|wss|ws):\/\//,'').replace(/:\d+$/,'')),m=window.gina.config):(m=getContext('gina').config,typeof getContext('argvFilename')!='undefined'&&(m.getRouting=getContext('gina').Config.instance.getRouting),oa=getContext('isProxyHost'));var S=m.env||GINA_ENV,r=null,V=m.bundle;/@/.test(h)||typeof V=='undefined'||V==null||(h=h.toLowerCase(),h+='@'+V);if(/@/.test(h)){var v=h.replace(/(.*):\/\//,'').split(/@/);
|
|
137
|
+
V=v[1];/\/(.*)$/.test(h)&&(r=h.replace(/(.*):\/\//,'').split(/\/(.*)$/)[1],V=V.replace(/\/(.*)$/,''),S=r||S);h=v[0].toLowerCase()+'@'+V}r=m.getRouting(V,S);if(typeof r[h]=='undefined')throw Error('[ RoutingHelper::getRouting(rule, params) ] : `'+h+'` not found ! (bundle `'+V+'` holds '+Object.keys(r).length+' rules)');V=JSON.clone(r[h]);v=null;V=P(V,J);(V.isProxyHost=oa)?(V.proxy_hostname=k?window.location.protocol+'//'+document.location.hostname:process.gina.PROXY_HOSTNAME||m.envConf._proxyHostname,
|
|
138
|
+
V.proxy_hostname?V.proxy_host=V.proxy_hostname.replace(/^(https|http):\/\//,''):(delete V.proxy_hostname,V.isProxyHost=!1,ba||(ba=!0,console.warn('[ RoutingHelper::getRoute() ] Proxied context is active but no proxy hostname is resolvable (worker global and envConf fallback both unset) - falling back to the route direct hostname. Warned once per process.')))):!k&&typeof process.gina.PROXY_HOSTNAME!='undefined'&&process.gina.PROXY_HOSTNAME&&(V.proxy_hostname=process.gina.PROXY_HOSTNAME,V.proxy_host=
|
|
139
|
+
V.proxy_hostname.replace(/^(https|http):\/\//,''),console.debug('[getRoute#2]['+oa+'] process.gina.PROXY_HOSTNAME ('+process.gina.PROXY_HOSTNAME+') VS config.envConf._proxyHostname ('+m.envConf._proxyHostname+')'));/,/.test(V.url)&&(typeof V.urlIndex!='undefined'&&(w=V.urlIndex,delete V.urlIndex),w=typeof w!='undefined'?w:0,V.url=V.url.split(/,/g)[w]);/\/$/.test(V.url)&&V.url!='/'&&(V.url=V.url.substring(0,V.url.length-1));if(/GET/i.test(V.method)&&typeof J!='undefined'){w='?';m=r[h].url;oa=[];r=
|
|
140
|
+
0;for(let y in V.param)G.reservedParams.indexOf(y)>-1||(new RegExp(V.param[y])).test(m)||typeof J[y]=='undefined'||(w+=y+'='+encodeRFC5987ValueChars(J[y])+'&',oa[r]=J[y],++r);for(let y in J)G.reservedParams.indexOf(y)>-1||V.requirements&&typeof V.requirements[y]!='undefined'||oa.indexOf(y)>-1||(w=typeof J[y]=='object'?w+(y+'='+encodeRFC5987ValueChars(JSON.stringify(J[y]))+'&'):w+(y+'='+J[y]+'&'));r=oa=m=null;w.length>1&&(w=w.substring(0,w.length-1),V.url+=w);w=null}V.toUrl=function(y){var z=null;
|
|
141
|
+
if(this.isRedirect===!0||/^redirect$/i.test(this.param&&this.param.control))z=G.getUrlProps(this.bundle,S||GINA_ENV);var l=this.webroot||z.webroot;z=''+this.hostname||''+z.hostname;var ja=''+this.url;this.isProxyHost&&(z=''+this.proxy_hostname);this.url=typeof y!='undefined'&&/^true$/i.test(y)?ja.replace(new RegExp('^'+l),'/'):ja.replace(new RegExp('^('+l+'|/$)'),l);return z+this.url};V.request=function(y,z){var l=null,ja=null;typeof arguments[arguments.length-1]=='function'&&(l=arguments[arguments.length-
|
|
142
|
+
1]);typeof arguments[2]=='object'&&(ja=arguments[2]);var M=this.webroot||ja.webroot,T=this.hostname||ja.hostname;ja=typeof y!='undefined'&&y==1?path.replace(M,'/'):this.url||ja.url;/^\//.test(ja)&&(ja=T+ja);T=/^https/.test(T)?'https':'http';k?window.open(ja,typeof z!='undefined'&&typeof z.target!='undefined'?z.target:'_self'):(typeof z.agent=='undefined'&&(z.agent=!1),T=require(''+T),M=function(N){var Y='',C=!1;N.on('data',function(I){Y+=I});N.on('error',function(I){C='Failed to get mail content';
|
|
143
|
+
I&&typeof I.stack!='undefined'?C+=I.stack:typeof I=='string'&&(C+='\n'+I)});N.on('end',function(){if(/^\{/.test(Y))try{Y=JSON.parse(Y),typeof Y.error!='undefined'&&(C=JSON.clone(Y),Y=null)}catch(I){C=I}C?l(C):l(!1,Y)})},l?T.get(ja,z,M):T.get(ja,z))};!/:/.test(V.url)||/:d+\//.test(V.url)||/:\/\//.test(V.url)||(J=V.url.match(/(:(.*)\/|:(.*)$)/g).map(function(y){return y.replace(/\//g,'')}).join(', '),v='[ RoutingHelper::getRoute(rule[, bundle, method]) ] : route [ %r ] param placeholder not defined: `'+
|
|
144
|
+
V.url+'` !\n Check your route description to compare requirements against param variables [ '+J+']',v=v.replace(/%r/,h),h=Error(v),console.warn(h),v=h=J=null);return V};G.getRouteByUrl=async function(h,J,w,m,oa){arguments.length==2&&typeof arguments[1]!='undefined'&&arguments[1]&&G.allowedMethods.indexOf(arguments[1].toLowerCase())>-1&&(w=arguments[1],J=void 0);var S=null,r=null,V=null,v=null,y=null,z=null;if(/#/.test(h)&&h.length>1){var l=h.split(/#/);h=l[0];y='#'+l[1];l=null}arguments.length==1&&
|
|
145
|
+
typeof arguments[0]!='undefined'&&(/^(https|http)/i.test(h)||/^\//.test(h)||(h='/'+h),S='/'+h.split(/\//g)[1],k&&(v=gina.config.reverseRouting,V=gina.config.routing),typeof v[S]!='undefined'&&(l=V[v[S]],J=l.bundle,S=l.webroot,z=l.hostname,l=null));oa=typeof arguments[arguments.length-1]!='boolean'?!1:arguments[arguments.length-1];var ja=!1,M=null,T=v=M=v=null;l=typeof w!='undefined'?!0:!1;k?(M=window.gina.config,J=typeof J!='undefined'?J:M.bundle,v=M.env,V=M.routing||M.getRouting(J),v=M.reverseRouting,
|
|
146
|
+
isXMLRequest=typeof isXMLRequest!='undefined'?isXMLRequest:!1,z=z||M.hostname,S=S||M.webroot,m={routing:{},method:w,params:{},url:h},J&&(m.bundle=J)):(M=getContext('gina').config,J=typeof J!='undefined'?J:M.bundle,v=M.env,V=M.getRouting(J),z=M.envConf[J][v].hostname,S=M.envConf[J][v].server.webroot,m||={routing:{},isXMLRequest:!1,method:typeof w!='undefined'?w.toLowerCase():'get',params:{},url:h},oa&&(m.method=w),isXMLRequest=m.isXMLRequest||!1);M=h.replace(new RegExp('^('+z+'|'+z.replace(/:\d+/,
|
|
147
|
+
'')+')'),'');typeof m.routing.path=='undefined'&&(m.routing.path=safeDecodeURI(M));w=typeof w!='undefined'?w.toLowerCase():'get';l&&(m.originalMethod=m.method,m.method=w,m.routing.path=safeDecodeURI(M));m.method||(m.method=w);v={};S=new RegExp(w,'i');z=null;for(N in V){if(typeof V[N].param=='undefined')break;if(V[N].bundle==J&&(z=V[N].method,/,/.test(z)&&S.test(z)&&(z=m.method),typeof V[N].method=='undefined'||S.test(z))){v={method:z,requirements:V[N].requirements,namespace:V[N].namespace||void 0,
|
|
148
|
+
url:safeDecodeURI(M),rule:V[N].originalRule||N,param:JSON.clone(V[N].param),middleware:JSON.clone(V[N].middleware),bundle:V[N].bundle,isXMLRequest};try{if(T=await G.compareUrls(v,V[N].url,m),M==V[N].url||T.past){r=JSON.clone(V[N]);r.name=N;r.param=v.param;ja=!0;T={};break}}catch(Y){throw Error('Route [ '+N+' ] needs your attention.\n'+Y.stack);}}}if(ja)return/\/$/.test(h)&&h!='/'&&(h=h.substring(0,h.length-1)),y&&(h+=y),r.url=h,r.toUrl=function(Y){var C=this.webroot,I=this.hostname,la=this.url;this.url=
|
|
149
|
+
typeof Y!='undefined'&&Y==1?la.replace(C,'/'):la;return I+this.url},r;if(k){var N=!1;if(h=='#'&&/GET/i.test(w)&&l||/^404:/.test(h))h=location.pathname,N=!0;typeof G.notFound=='undefined'&&(G.notFound={});y=null;r='[ RoutingHelper::getRouteByUrl(rule[, bundle, method]) ] : route [ %r ] is called but not found inside your view: `'+h+'` !';if((y=(y=gina.hasPopinHandler&&gina.popinIsBinded?gina.popin.getActivePopin().target.innerHTML.match(/404:\[\w+\][a-z 0-9-_@]+/):document.body.innerHTML.match(/404:\[\w+\][a-z 0-9-_@]+/))&&
|
|
150
|
+
y.length>0?y[0]:null)&&l&&N)return N=y.match(/\[\w+\]/)[0],y=y.replace('404:'+N,N.replace(/\[|\]/g,'')+'::'),r=r.replace(/%r/,y.replace(/404:\s+/,'')),typeof G.notFound[y]=='undefined'?G.notFound[y]={count:1,message:r}:l&&typeof G.notFound[y]!='undefined'&&++G.notFound[y].count,!1;if((N=gina.config.reverseRouting[h]||null)&&typeof N!='undefined'&&N.split(/@(.+)$/)[1]==J)return y=N,typeof G.notFound[y]=='undefined'?(r=r.replace(/%r/,w.toUpperCase()+'::'+N),G.notFound[y]={count:1,message:r}):l&&typeof G.notFound[y]!=
|
|
151
|
+
'undefined'&&++G.notFound[y].count,!1;y=await G.compareUrls(v,h,m)||null;y.past&&l&&(y=w.toUpperCase()+'::'+y.request.routing.rule,typeof G.notFound[y]=='undefined'?r=r.replace(/%r/,y):++G.notFound[y].count);return!1}console.warn(Error('[ RoutingHelper::getRouteByUrl(rule[, bundle, method, request]) ] : route not found for url: `'+h+'` !').stack);return!1};G.buildTrie=function(h,J){if(!k){var w=require('./radix'),m=w.createNode(),oa;for(oa in h){var S=h[oa];if(S&&typeof S==='object'&&S.bundle===J){S=
|
|
152
|
+
Array.isArray(S.url)?S.url:String(S.url).split(',');for(var r=0;r<S.length;r++){var V=S[r].trim();V&&w.insert(m,V,oa)}}}Routing._tries[J]=m}};G.lookupTrie=function(h,J){return Routing._tries&&Routing._tries[J]?require('./radix').lookup(Routing._tries[J],h):null};return G}
|
|
153
|
+
typeof module!=='undefined'&&module.exports?(typeof console.err=='undefined'&&(console=require('../../logger')),module.exports=Routing()):typeof define==='function'&&define.amd&&define('lib/routing',['require','lib/form-validator','lib/merge'],function(){return Routing()});function registerEvents(k,G){typeof gina=='undefined'&&typeof window.gina!='undefined'&&(gina=window.gina);gina.registeredEvents[k]=G}function mergeEventProps(k,G){for(let F in G)typeof k[F]=='undefined'&&(k[F]=G[F]);return k}
|
|
154
|
+
function addListener(k,G,F,L){var U=function(A,P,ba,h){typeof A.event!='undefined'&&A.event.isTouchSupported&&/^(click|mouseout|mouseover)/.test(ba)&&A.event[ba].indexOf(P)==-1&&(A.event[ba][A.event[ba].length]=P);typeof P!='undefined'&&P!=null?P.addEventListener?P.addEventListener(ba,h,!1):P.attachEvent&&P.attachEvent('on'+ba,h):A.customEvent.addListener(ba,h);gina.events[ba]=typeof P.id!='undefined'&&typeof P.id!='object'?P.id:P.getAttribute('id')},q=0,O=null;if(Array.isArray(F))for(O=F.length;q<
|
|
155
|
+
O;q++)U(k,G,F[q],L);else if(Array.isArray(G))for(q=0,O=G.length;q<O;q++){let A=/\.$/.test(F)?F+G[q].id:F;U(k,G[q],A,L)}else F=/\.$/.test(F)?F+G.id:F,U(k,G,F,L)}
|
|
156
|
+
function triggerEvent(k,G,F,L,U){if(typeof G!='undefined'&&G!=null){var q=!1;window.CustomEvent||document.createEvent?(window.CustomEvent?k=new CustomEvent(F,{detail:L,bubbles:!0,cancelable:!0,target:G}):(k=document.createEvent('HTMLEvents'),k.detail=L,k.target=G,k.initEvent(F,!0,!0),k.eventName=F),U&&(k=mergeEventProps(k,U)),typeof k.defaultPrevented!='undefined'&&k.defaultPrevented&&(q=k.defaultPrevented),q||G.dispatchEvent(k)):document.createEventObject&&(k=document.createEventObject(),k.srcElement.id=
|
|
157
|
+
G.id,k.detail=L,k.target=G,U&&(k=mergeEventProps(k,U)),G.fireEvent('on'+F,k))}else k.customEvent.fire(F,L)}function cancelEvent(k){typeof k!='undefined'&&k!=null&&(k.cancelBubble=!0,k.preventDefault&&k.preventDefault(),k.stopPropagation&&k.stopPropagation(),k.returnValue=!1)}
|
|
158
|
+
function setupXhr(k){var G=null;if(window.XMLHttpRequest)G=new XMLHttpRequest;else if(window.ActiveXObject)try{G=new ActiveXObject('Msxml2.XMLHTTP')}catch(L){try{G=new ActiveXObject('Microsoft.XMLHTTP')}catch(U){}}if(typeof k!='undefined'){if(!k.url||typeof k.url=='undefined')throw Error('Missing `options.url`');typeof k.method=='undefined'&&(k.method='GET');k.method=k.method.toUpperCase();if(k.withCredentials){if('withCredentials'in G)k.isSynchrone?G.open(k.method,k.url,k.isSynchrone):G.open(k.method,
|
|
159
|
+
k.url);else if(typeof XDomainRequest!='undefined')G=new XDomainRequest,G.open(k.method,k.url);else{result='CORS not supported: the server is missing the header `"Access-Control-Allow-Credentials": true` ';triggerEvent(gina,$target,'error.'+id,result);return}G.responseType=typeof k.responseType!='undefined'?k.responseType:'';G.withCredentials=!0}else k.isSynchrone?G.open(k.method,k.url,k.isSynchrone):G.open(k.method,k.url);for(var F in k.headers)F=='Content-Type'&&typeof enctype!='undefined'&&enctype!=
|
|
160
|
+
null&&enctype!=''||G.setRequestHeader(F,k.headers[F])}return G}function getFilenameFromContentDisposition(k){return k?(k=k.match(/filename\s*=\s*(?:"((?:[^"\\]|\\.)*)"|([^;]+))/i))?typeof k[1]!='undefined'?k[1].replace(/\\(.)/g,'$1'):k[2].replace(/^\s+|\s+$/g,''):'':''}
|
|
161
|
+
function handleXhr(k,G,F,L){if(!k)throw Error('No `xhr` object initiated');var U=null,q=null,O=null,A=null,P=null,ba=F.$link||null,h=F.$form||null,J=null;delete F.$link;delete F.$form;h||ba?ba?(ba.target=document.getElementById(ba.id),J=gina.link.target,P=gina.link.id):(J=h.target,P=J.getAttribute('id')):(J=G,P=J.getAttribute('id'));var w=ba&&G.getAttribute('data-gina-link-event-on-success')||ba&&G.getAttribute('data-gina-link-event-on-error')?!0:!1,m=h&&J.getAttribute('data-gina-form-event-on-submit-success')||
|
|
162
|
+
h&&J.getAttribute('data-gina-form-event-on-submit-error')?!0:!1;m&&h&&listenToXhrEvents(h,'form');G=G.getAttribute('enctype')||F.headers['Content-Type'];for(var oa in F.headers)oa=='Content-Type'&&typeof G!='undefined'&&G!=null&&G!=''||k.setRequestHeader(oa,F.headers[oa]);k.withCredentials=typeof F.withCredentials!='undefined'?F.withCredentials:!1;k.onerror=function(S,r){S={status:k.status||500,error:'Transaction error: might be due to the server CORS settings.\nPlease, check the console for more details.'};
|
|
163
|
+
h&&(h.eventData.error=S);ba&&(ba.eventData.error=S);typeof window.ginaToolbar!='undefined'&&window.ginaToolbar&&window.ginaToolbar.update('data-xhr',S,!0);triggerEvent(gina,J,'error.'+P,S);m&&triggerEvent(gina,J,'error.'+P+'.hform',S);w&&triggerEvent(gina,ba.target,'error.'+ba.id+'.hlink',S)};k.onreadystatechange=function(S){typeof merge=='undefined'&&(merge=L('lib/merge'));S=/Google Inc/i.test(navigator.vendor)?50:0;k.readyState==2&&(q=/^attachment;/.test(k.getResponseHeader('Content-Disposition'))?
|
|
164
|
+
!0:!1,!k.responseType&&q&&(k.responseType='blob'));if(k.readyState==4)if(U=null,O=k.getResponseHeader('Content-Type'),/^2/.test(k.status)){try{if(/blob/.test(k.responseType)||q){if(typeof O=='undefined'||O==null)O='application/octet-stream';U=new Blob([this.response],{type:O});var r=document.createElement('a');r.style='display: none';document.body.appendChild(r);var V=window.URL.createObjectURL(U);r.href=V;var v=k.getResponseHeader('Content-Disposition');r.download=getFilenameFromContentDisposition(v);
|
|
165
|
+
r.click();window.URL.revokeObjectURL(V);A={status:k.status,statusText:k.statusText,responseType:U.type,type:U.type,size:U.size}}!A&&/\/json/.test(O)&&(A=JSON.parse(k.responseText),typeof A.status=='undefined'&&(A.status=k.status||200));if(!A&&/\/html/.test(O)&&(A={contentType:O,content:k.responseText},typeof A.status=='undefined'&&(A.status=k.status),typeof gina.popin!='undefined'&&gina.hasPopinHandler)){var y=gina.popin.getActivePopin();if(y){XHRData={};try{XHRData=(new DOMParser).parseFromString(A.content,
|
|
166
166
|
'text/html').getElementById('gina-without-layout-xhr-data'),XHRData=JSON.parse(decodeURIComponent(XHRData.value)),XHRView=(new DOMParser).parseFromString(A.content,'text/html').getElementById('gina-without-layout-xhr-view'),XHRView=JSON.parse(decodeURIComponent(XHRView.value)),gina&&typeof window.ginaToolbar!='undefined'&&window.ginaToolbar&&typeof XHRData!='undefined'&&window.ginaToolbar.update('data-xhr',XHRData),gina&&typeof window.ginaToolbar!='undefined'&&window.ginaToolbar&&typeof XHRView!=
|
|
167
|
-
'undefined'&&window.ginaToolbar.update('view-xhr',XHRView)}catch(M){throw M;}y.loadContent(A.content);A=XHRData;triggerEvent(gina,J,'success.'+P,A);return}}A||(A=
|
|
168
|
-
ba.target,'success.'+ba.id+'.hlink',A)}catch(M){A={status:422,error:M.message,stack:M.stack};
|
|
169
|
-
'',A.location=/^http/.test(A.location)||/^\//.test(A.location)?A.location:location.protocol+'//'+A.location,setTimeout(()=>{window.location.href=A.location},S)}else if(
|
|
170
|
-
A=merge(A,M.srcElement.result):A.message+=M.srcElement.result;if(/^2/.test(z.readyState)){if(/^(\{|\[)/.test(l))try{A=merge(A,JSON.parse(l))}catch(Y){A=merge(A,Y)}A.message||delete A.message;
|
|
171
|
-
window.ginaToolbar&&XHRData)try{window.ginaToolbar.update('data-xhr',XHRData)}catch(Y){throw Y;}triggerEvent(gina,J,'error.'+P,A);m&&triggerEvent(gina,J,'error.'+P+'.hform',A);w&&triggerEvent(gina,ba.target,'error.'+ba.id+'.hlink',A)}});z.readAsText(U)}else{if(/^(\{|\[)/.test(
|
|
172
|
-
'undefined'&&A.error.fields&&typeof A.error.fields=='object'){r={};V=0;for(var ja in A.error.fields)++V,r[ja]={isApplicationValidationError:A.error.fields[ja]};V>0&&handleErrorsDisplay(
|
|
173
|
-
function(S){var r='0';S.lengthComputable&&(r=S.loaded/S.total,r=parseInt(r*100));S={status:100,progress:r};
|
|
174
|
-
function removeListener(
|
|
175
|
-
0,len=G.length;i<len;i++)
|
|
167
|
+
'undefined'&&window.ginaToolbar.update('view-xhr',XHRView)}catch(M){throw M;}y.loadContent(A.content);A=XHRData;triggerEvent(gina,J,'success.'+P,A);return}}A||(A=k.responseText);h&&(h.eventData.success=A);XHRData=A;if(gina&&typeof window.ginaToolbar!='undefined'&&window.ginaToolbar&&XHRData)try{typeof XHRData!='undefined'&&/\/html/.test(O)&&window.ginaToolbar.update('data-xhr',XHRData)}catch(M){throw M;}triggerEvent(gina,J,'success.'+P,A);m&&triggerEvent(gina,J,'success.'+P+'.hform',A);w&&triggerEvent(gina,
|
|
168
|
+
ba.target,'success.'+ba.id+'.hlink',A)}catch(M){A={status:422,error:M.message,stack:M.stack};h&&(h.eventData.error=A);XHRData=A;if(gina&&typeof window.ginaToolbar!='undefined'&&window.ginaToolbar&&XHRData)try{typeof XHRData!='undefined'&&window.ginaToolbar.update('data-xhr',XHRData)}catch(T){throw T;}triggerEvent(gina,J,'error.'+P,A);m&&triggerEvent(gina,J,'error.'+P+'.hform',A);w&&triggerEvent(gina,ba.target,'error.'+ba.id+'.hlink',A)}if(typeof A!='undefined'&&typeof A.location!='undefined')return window.location.hash=
|
|
169
|
+
'',A.location=/^http/.test(A.location)||/^\//.test(A.location)?A.location:location.protocol+'//'+A.location,setTimeout(()=>{window.location.href=A.location},S)}else if(k.status!=0)if(A={status:k.status,message:''},/blob/.test(k.responseType)){U=new Blob([this.response],{type:'text/plain'});var z=new FileReader,l='';z.addEventListener('loadend',M=>{typeof merge=='undefined'&&(merge=L('lib/merge'));/string/i.test(typeof M.srcElement.result)?l+=M.srcElement.result:typeof M.srcElement.result=='object'?
|
|
170
|
+
A=merge(A,M.srcElement.result):A.message+=M.srcElement.result;if(/^2/.test(z.readyState)){if(/^(\{|\[)/.test(l))try{A=merge(A,JSON.parse(l))}catch(Y){A=merge(A,Y)}A.message||delete A.message;h&&(h.eventData.error=A);if(typeof A!='undefined'&&typeof A.error!='undefined'&&A.error.fields&&typeof A.error.fields=='object'){M={};var T=0,N;for(N in A.error.fields)++T,M[N]={isApplicationValidationError:A.error.fields[N]};T>0&&handleErrorsDisplay(h.target,M)}XHRData=A;if(gina&&typeof window.ginaToolbar!='undefined'&&
|
|
171
|
+
window.ginaToolbar&&XHRData)try{window.ginaToolbar.update('data-xhr',XHRData)}catch(Y){throw Y;}triggerEvent(gina,J,'error.'+P,A);m&&triggerEvent(gina,J,'error.'+P+'.hform',A);w&&triggerEvent(gina,ba.target,'error.'+ba.id+'.hlink',A)}});z.readAsText(U)}else{if(/^(\{|\[)/.test(k.responseText))try{A=merge(A,JSON.parse(k.responseText))}catch(M){A=merge(A,M)}else typeof k.responseText=='object'?A=merge(A,k.responseText):A.message=k.responseText;h&&(h.eventData.error=A);if(typeof A!='undefined'&&typeof A.error!=
|
|
172
|
+
'undefined'&&A.error.fields&&typeof A.error.fields=='object'){r={};V=0;for(var ja in A.error.fields)++V,r[ja]={isApplicationValidationError:A.error.fields[ja]};V>0&&handleErrorsDisplay(h.target,r)}XHRData=A;if(gina&&typeof window.ginaToolbar!='undefined'&&window.ginaToolbar&&XHRData)try{window.ginaToolbar.update('data-xhr',XHRData)}catch(M){throw M;}triggerEvent(gina,J,'error.'+P,A);m&&triggerEvent(gina,J,'error.'+P+'.hform',A);w&&triggerEvent(gina,ba.target,'error.'+ba.id+'.hlink',A)}};k.onprogress=
|
|
173
|
+
function(S){var r='0';S.lengthComputable&&(r=S.loaded/S.total,r=parseInt(r*100));S={status:100,progress:r};h&&(h.eventData.onprogress=S);triggerEvent(gina,J,'progress.'+P,S)};k.ontimeout=function(S){A={status:408,error:'Request Timeout'};h&&(h.eventData.ontimeout=A);triggerEvent(gina,J,'error.'+P,A);m&&triggerEvent(gina,J,'error.'+P+'.hform',A);w&&triggerEvent(gina,ba.target,'error.'+ba.id+'.hlink',A)}}
|
|
174
|
+
function removeListener(k,G,F,L){typeof k.event!='undefined'&&k.event.isTouchSupported&&/^(click|mouseout|mouseover)/.test(F)&&k.event[F].indexOf(G)!=-1&&k.event[F].splice(k.event[F].indexOf(G),1);if(typeof G!='undefined'&&G!=null)if(G.removeEventListener)if(Array.isArray(G))for(i=0,len=G.length;i<len;i++)k=/\.$/.test(F)?F+G[i].id:F,G.removeEventListener(k,L,!1),typeof gina.events[k]!='undefined'&&delete gina.events[k];else F=/\.$/.test(F)?F+G.id:F,G.removeEventListener(F,L,!1);else{if(G.attachEvent)if(Array.isArray(G))for(i=
|
|
175
|
+
0,len=G.length;i<len;i++)k=/\.$/.test(F)?F+G[i].id:F,G.detachEvent('on'+k,L),typeof gina.events[k]!='undefined'&&delete gina.events[k];else F=/\.$/.test(F)?F+G.id:F,G.detachEvent('on'+F,L)}else if(Array.isArray(G))for(i=0,len=G.length;i<len;i++){let U=/\.$/.test(F)?F+G[i].id:F;k.customEvent.removeListener(U,L);typeof gina.events[U]!='undefined'&&delete gina.events[U]}else F=/\.$/.test(F)?F+G.id:F,k.customEvent.removeListener(F,L);typeof gina.events[F]!='undefined'&&delete gina.events[F];typeof L!=
|
|
176
176
|
'undefined'&&L()}
|
|
177
|
-
function on(
|
|
178
|
-
(F=this.target,L=instance.id);this.eventData&&!F.eventData&&(F.eventData=this.eventData);
|
|
177
|
+
function on(k,G){if(!this.plugin)throw Error('No `plugin` reference found for this event: `'+k);if(gina.registeredEvents[this.plugin].indexOf(k)<0&&!/^init$/.test(k)&&!/\.hform$/.test(k)&&!/\.hlink$/.test(k))G(Error('Event `'+k+'` not handled by ginaEventHandler'));else{var F=null,L=null;typeof this.id!='undefined'&&typeof this.id!='object'?(F=this.target||this,L=this.id):typeof this.target!='undefined'?((F=this.target)||(F=this),L=typeof F.getAttribute!='undefined'?F.getAttribute('id'):this.id):
|
|
178
|
+
(F=this.target,L=instance.id);this.eventData&&!F.eventData&&(F.eventData=this.eventData);k=/\.(hform|hlink)$/.test(k)?/\.hform$/.test(k)?k.replace(/\.hform$/,'.'+L+'.hform'):k.replace(/\.hlink$/,'.'+L+'.hlink'):k+('.'+L);gina.events[k]||(addListener(gina,F,k,function(U){cancelEvent(U);var q=null;U.detail?q=U.detail:typeof this.eventData.submit!='undefined'?q=this.eventData.submit:typeof this.eventData.error!='undefined'?q=this.eventData.error:typeof this.eventData.success!='undefined'&&(q=this.eventData.success);
|
|
179
179
|
G&&G(U,q)}),this.initialized&&!this.isReady&&triggerEvent(gina,F,'init.'+L));return this}}
|
|
180
|
-
function listenToXhrEvents(
|
|
181
|
-
G+'-event-on-error \u2014 use a bare identifier and register the handler on window: '+F)}catch(L){}else
|
|
182
|
-
function PrototypesHelper(
|
|
183
|
-
'undefined'&&Object.defineProperty(Date.prototype,U,{writable:!1,enumerable:!1,configurable:!0,value:function(){var q={0:this},O=1,A;for(A in arguments)q[O]=arguments[A],++O;q.length=O;return F.dateFormat[U].apply(this,q)}});typeof Array.clone=='undefined'&&Object.defineProperty(Array.prototype,'clone',{writable:!1,enumerable:!1,configurable:!0,value:function(){return this.slice(0)}});typeof JSON.clone!='undefined'||G||(typeof
|
|
184
|
-
(
|
|
185
|
-
{writable:!1,enumerable:!1,configurable:!0,value:function(U){return this.indexOf(U)!=-1}});typeof Array.from=='undefined'&&Object.defineProperty(Array.prototype,'from',{writable:!1,enumerable:!1,configurable:!0,value:function(U){for(var q={},O=[],A=U.length,P=0,ba=0;ba<A;ba++){var
|
|
180
|
+
function listenToXhrEvents(k,G){var F=k.target.getAttribute('data-gina-'+G+'-event-on-success')||null;if(F!=null)if(/\((.*)\)/.test(F))try{console.warn('[gina-event] function-call shape no longer supported on data-gina-'+G+'-event-on-success \u2014 use a bare identifier and register the handler on window: '+F)}catch(L){}else k.on('success.h'+G,window[F]);F=k.target.getAttribute('data-gina-'+G+'-event-on-error')||null;if(F!=null)if(/\((.*)\)/.test(F))try{console.warn('[gina-event] function-call shape no longer supported on data-gina-'+
|
|
181
|
+
G+'-event-on-error \u2014 use a bare identifier and register the handler on window: '+F)}catch(L){}else k.on('error.h'+G,window[F])}define('utils/events',function(){});
|
|
182
|
+
function PrototypesHelper(k){var G=typeof module!=='undefined'&&module.exports?!1:!0,F=k||null;k=null;if(typeof GINA_DIR=='undefined'&&!G&&typeof process!='undefined'&&process.argv.length>3)if(/^\{/.test(process.argv[2]))k=JSON.parse(process.argv[2]).envVars;else if(/\.ctx$/.test(process.argv[2])){k=require('fs');var L=process.argv[2].split(/\-\-argv\-filename=/)[1];k=JSON.parse(k.readFileSync(L).toString()).envVars}if(F&&typeof F!='undefined'&&typeof F.dateFormat!='undefined')for(let U in F.dateFormat)typeof Date[U]==
|
|
183
|
+
'undefined'&&Object.defineProperty(Date.prototype,U,{writable:!1,enumerable:!1,configurable:!0,value:function(){var q={0:this},O=1,A;for(A in arguments)q[O]=arguments[A],++O;q.length=O;return F.dateFormat[U].apply(this,q)}});typeof Array.clone=='undefined'&&Object.defineProperty(Array.prototype,'clone',{writable:!1,enumerable:!1,configurable:!0,value:function(){return this.slice(0)}});typeof JSON.clone!='undefined'||G||(typeof k!='undefined'&&k!=null?JSON.clone=require(k.GINA_DIR+'/utils/prototypes.json_clone'):
|
|
184
|
+
(k||(G=__dirname+'/../../../',require(G+'/utils/helper'),setEnvVar('GINA_DIR',G,!0),k=getEnvVars()),JSON.clone=require(getEnvVar('GINA_DIR')+'/utils/prototypes.json_clone')));typeof JSON.escape=='undefined'&&(JSON.escape=function(U){try{return U.replace(/\n/g,'\\n').replace(/\r/g,'\\r').replace(/\t/g,'\\t')}catch(q){throw q;}});typeof Array.toString=='undefined'&&(Array.prototype.toString=function(){return this.join()});typeof Array.inArray=='undefined'&&Object.defineProperty(Array.prototype,'inArray',
|
|
185
|
+
{writable:!1,enumerable:!1,configurable:!0,value:function(U){return this.indexOf(U)!=-1}});typeof Array.from=='undefined'&&Object.defineProperty(Array.prototype,'from',{writable:!1,enumerable:!1,configurable:!0,value:function(U){for(var q={},O=[],A=U.length,P=0,ba=0;ba<A;ba++){var h=U[ba];q[h]!==1&&(q[h]=1,O[P++]=h)}return O}});typeof Object.count=='undefined'&&Object.defineProperty(Object.prototype,'count',{writable:!0,enumerable:!1,configurable:!0,value:function(){var U=0;try{this instanceof String&&
|
|
186
186
|
JSON.parse(this);for(var q in this)this.hasOwnProperty(q)&&++U;return U}catch(O){return U}}});typeof global!='undefined'&&typeof global.__stack=='undefined'&&Object.defineProperty(global,'__stack',{configurable:!0,get:function(){var U=Error.prepareStackTrace;Error.prepareStackTrace=function(O,A){return A};var q=Error();Error.captureStackTrace(q,arguments.callee);q=q.stack;Error.prepareStackTrace=U;return q}})}
|
|
187
187
|
typeof module!=='undefined'&&module.exports?module.exports=PrototypesHelper:typeof define==='function'&&define.amd&&define('helpers/prototypes',[],function(){return PrototypesHelper});
|
|
188
|
-
function DateFormatHelper(){var
|
|
188
|
+
function DateFormatHelper(){var k=typeof module!=='undefined'&&module.exports?!1:!0,G=k?require('lib/merge'):require('./../lib/merge');var F='en-US';var L='en';var U={'default':'ddd mmm dd yyyy HH:MM:ss',shortDate:'m/d/yy',shortDate2:'mm/dd/yyyy',mediumDate:'mmm d, yyyy',longDate:'mmmm d, yyyy',fullDate:'dddd, mmmm d, yyyy',cookieDate:'GMT:ddd, dd mmm yyyy HH:MM:ss',logger:'yyyy mmm dd HH:MM:ss',shortTime:'h:MM TT',shortTime2:'h:MM',mediumTime:'h:MM:ss TT',mediumTime2:'h:MM:ss',longTime:'h:MM:ss TT Z',
|
|
189
189
|
longTime2:'h:MM:ss TT',concatenatedDate:'yyyymmdd',isoDate:'yyyy-mm-dd',isoTime:'HH:MM:ss',shortIsoTime:'HH:MM',longIsoTime:'HH:MM:ss TT',isoDateTime:"yyyy-mm-dd'T'HH:MM:ss",longIsoDateTime:"yyyy-mm-dd'T'HH:MM:ss.L",isoUtcDateTime:"UTC:yyyy-mm-dd'T'HH:MM:ss'Z'"};var q={en:{dayNames:'Sun Mon Tue Wed Thu Fri Sat Sunday Monday Tuesday Wednesday Thursday Friday Saturday'.split(' '),monthNames:'Jan Feb Mar Apr May Jun Jul Aug Sep Oct Nov Dec January February March April May June July August September October November December'.split(' '),
|
|
190
190
|
masks:{'default':'ddd mmm dd yyyy HH:MM:ss',shortDate:'m/d/yy',shortDate2:'mm/dd/yyyy',mediumDate:'mmm d, yyyy',longDate:'mmmm d, yyyy',fullDate:'dddd, mmmm d, yyyy'}},fr:{dayNames:'dim lun mar mer jeu ven sam dimanche lundi mardi mercredi jeudi vendredi samedi'.split(' '),monthNames:'Jan F\u00e9v Mar Avr Mai Jui Juil Ao\u00fb Sep Oct Nov D\u00e9c Janvier F\u00e9vrier Mars Avril Mai Juin Juillet Ao\u00fbt Septembre Octobre Novembre D\u00e9cembre'.split(' '),masks:{'default':'ddd mmm dd yyyy HH:MM:ss',
|
|
191
|
-
shortDate:'d/m/yy',shortDate2:'dd/mm/yyyy',mediumDate:'d mmm, yyyy',longDate:'d mmmm, yyyy',fullDate:'dddd, d mmmm, yyyy'}}};var O=function(ba,
|
|
192
|
-
864E5+1)/7)};return{setCulture:function(ba,
|
|
193
|
-
S=/[^-+\dA-Z]/g,r=function(Y,C){Y=String(Y);for(C=C||2;Y.length<C;)Y='0'+Y;return Y};arguments.length!=1||Object.prototype.toString.call(ba)!='[object String]'||/\d/.test(ba)||(
|
|
191
|
+
shortDate:'d/m/yy',shortDate2:'dd/mm/yyyy',mediumDate:'d mmm, yyyy',longDate:'d mmmm, yyyy',fullDate:'dddd, d mmmm, yyyy'}}};var O=function(ba,h){if(h instanceof Date)return ba=ba.getTime(),h=h.getTime(),Math.round(Math.abs(ba-h)/864E5);throw Error('dateTo is not instance of Date() !');},A=['us','eu','corporate'],P=function(ba){d=new Date(ba.getFullYear(),ba.getMonth(),ba.getDate());ba=d.getDay()||7;d.setDate(d.getDate()+4-ba);ba=new Date(Date.parse(d.getFullYear(),0,1));return Math.ceil(((d-ba)/
|
|
192
|
+
864E5+1)/7)};return{setCulture:function(ba,h){/\-/.test(h)?(F=h,L=h.split(/\-/)[0]):L=h;return this},format:function(ba,h,J){var w=q[L]||q.en,m=null;try{m=G(w.masks,U)}catch(Y){G=(k=typeof module!=='undefined'&&module.exports?!1:!0)?require('lib/merge'):require('./../lib/merge'),m=G(w.masks,U)}typeof q[F]!='undefined'&&(w=q[F],typeof q[F].mask!='undefined'&&(m=G(w.masks,U)));var oa=/\b(?:[PMCEA][SDP]T|(?:Pacific|Mountain|Central|Eastern|Atlantic) (?:Standard|Daylight|Prevailing) Time|(?:GMT|UTC)(?:[-+]\d{4})?)\b/g,
|
|
193
|
+
S=/[^-+\dA-Z]/g,r=function(Y,C){Y=String(Y);for(C=C||2;Y.length<C;)Y='0'+Y;return Y};arguments.length!=1||Object.prototype.toString.call(ba)!='[object String]'||/\d/.test(ba)||(h=ba,ba=void 0);ba=ba?new Date(ba):new Date;if(isNaN(ba))throw SyntaxError('invalid date');h=String(m[h]||h||m['default']);h.slice(0,4)=='UTC:'&&(h=h.slice(4),J=!0);var V=J?'getUTC':'get';m=ba[V+'Date']();var v=ba[V+'Day'](),y=ba[V+'Month'](),z=ba[V+'FullYear'](),l=ba[V+'Hours'](),ja=ba[V+'Minutes'](),M=ba[V+'Seconds']();V=
|
|
194
194
|
ba[V+'Milliseconds']();var T=J?0:ba.getTimezoneOffset(),N={d:m,dd:r(m),ddd:w.dayNames[v],dddd:w.dayNames[v+7],m:y+1,mm:r(y+1),mmm:w.monthNames[y],mmmm:w.monthNames[y+12],yy:String(z).slice(2),yyyy:z,h:l%12||12,hh:r(l%12||12),H:l,HH:r(l),M:ja,MM:r(ja),s:M,ss:r(M),l:r(V,3),L:r(V),t:l<12?'a':'p',tt:l<12?'am':'pm',T:l<12?'A':'P',TT:l<12?'AM':'PM',Z:J?'UTC':(String(ba).match(oa)||['']).pop().replace(S,''),o:(T>0?'-':'+')+r(Math.floor(Math.abs(T)/60)*100+Math.abs(T)%60,4),S:['th','st','nd','rd'][m%10>3?
|
|
195
|
-
0:(m%100-m%10!=10)*m%10]};return
|
|
196
|
-
},getDaysInMonth:function(ba){var
|
|
197
|
-
[4,1,2,3];break;case 'corportate':case 'eu':J=[1,2,3,4];break;default:J=[1,2,3,4]}return J[Math.floor(ba.getMonth()/3)]},getHalfYear:function(ba,
|
|
198
|
-
(ba=new Date);typeof
|
|
195
|
+
0:(m%100-m%10!=10)*m%10]};return h.replace(/d{1,4}|m{1,4}|yy(?:yy)?|([HhMsTt])\1?|[LloSZ]|"[^"]*"|'[^']*'/g,function(Y){return Y in N?N[Y]:Y.slice(1,Y.length-1)})},countDaysTo:O,getDaysTo:function(ba,h,J){if(h instanceof Date){h=O(ba,h);var w=ba.getMonth(),m=ba.getFullYear();ba=ba.getDate()+1;ba=new Date(m,w,ba);w=[];for(m=0;m<h;++m)typeof J!='undefined'?w.push((new Date(ba)).format(J)):w.push(new Date(ba)),ba.setDate(ba.getDate()+1);return w||[]}throw Error('dateTo is not instance of Date() !');
|
|
196
|
+
},getDaysInMonth:function(ba){var h=ba.getMonth();ba=ba.getFullYear();ba=new Date(ba,h,1);for(var J=[];ba.getMonth()===h;)J.push(new Date(ba)),ba.setDate(ba.getDate()+1);return J},getQuarter:function(ba,h){if(arguments.length==1&&typeof arguments[0]=='string'){if(A.indexOf(arguments[0].toLowerCase())<0)throw Error('Quarter '+arguments[0]+' code not supported !');ba=new Date;h=arguments[0]}typeof ba=='undefined'&&(ba=new Date);typeof h=='undefined'&&(h='corporate');h=h.toLowerCase();switch(h){case 'us':var J=
|
|
197
|
+
[4,1,2,3];break;case 'corportate':case 'eu':J=[1,2,3,4];break;default:J=[1,2,3,4]}return J[Math.floor(ba.getMonth()/3)]},getHalfYear:function(ba,h){if(arguments.length==1&&typeof arguments[0]=='string'){if(A.indexOf(arguments[0].toLowerCase())<0)throw Error('Quarter '+arguments[0]+' code not supported !');ba=new Date;h=arguments[0]}typeof ba=='undefined'&&(ba=new Date);typeof h=='undefined'&&(h='corporate');h=h.toLowerCase();return ba.getQuarter(h)<=2?1:2},getWeek:function(ba,h){typeof ba=='undefined'&&
|
|
198
|
+
(ba=new Date);typeof h=='undefined'&&(h='ISO 8601');h=h.replace(/\s+/g,'').toLowerCase();switch(h){case 'corporate':case 'eu':case 'iso8601':return P(ba);default:return P(ba)}},addHours:function(ba,h){ba=new Date(ba.getTime());ba.setHours(ba.getHours()+h);return ba},addDays:function(ba,h){ba=new Date(ba.getTime());ba.setHours(ba.getHours()+h*24);return ba},addYears:function(ba,h){ba=new Date(ba.getTime());ba.setFullYear(ba.getFullYear()+h);return ba}}}
|
|
199
199
|
typeof module!=='undefined'&&module.exports?module.exports=DateFormatHelper:typeof define==='function'&&define.amd&&define('helpers/dateFormat',[],function(){return DateFormatHelper});
|
|
200
|
-
define('gina','require lib/merge lib/uuid lib/routing utils/events helpers/prototypes helpers/dateFormat'.split(' '),function(
|
|
200
|
+
define('gina','require lib/merge lib/uuid lib/routing utils/events helpers/prototypes helpers/dateFormat'.split(' '),function(k){k('utils/events');var G=k('lib/merge'),F=k('lib/uuid');k('lib/routing');var L=k('helpers/dateFormat')();k('helpers/prototypes')({dateFormat:L});window.process||function(U,q,O,A,P,ba,h){for(ba=U[O]||(U[O]={});!h&&P<A.length;)h=U[A[P++]+'requestAnimationFrame'];ba[q]=ba[q]||h&&h.bind(U)||U.setImmediate||U.setTimeout}(window,'nextTick','process',['r','webkitR','mozR','msR',
|
|
201
201
|
'oR'],0);window.getComputedStyle||(window.getComputedStyle=function(U,q){this.el=U;this.getPropertyValue=function(O){var A=/(\-([a-z]){1})/g;O=='float'&&(O='styleFloat');A.test(O)&&(O=O.replace(A,function(){return arguments[2].toUpperCase()}));return U.currentStyle[O]?U.currentStyle[O]:null};return this});return async function(U){this.plugin='gina';var q='gina-'+F(),O=document;document.id=q;var A={id:q,isFrameworkLoaded:!1,hasValidator:!1,hasPopinHandler:!1,config:{},session:null,registeredEvents:{},
|
|
202
202
|
events:{},setOptions:function(P){P&&typeof P=='object'&&P!==A.config&&(A.config=G(A.config,P,!0))}};typeof parent.window.gina!='undefined'&&(window.gina=G(window.gina||{},parent.window.gina));A=G(window.gina||{},A);registerEvents(this.plugin,['ginaloaded','ready']);triggerEvent(U,O,'ginaloaded',A)}});
|
|
203
|
-
!function(
|
|
204
|
-
if('object'!=typeof g)break a;throw new TypeError('@@toPrimitive must return a primitive value.');}g=String(g)}e.call(Z,W,'symbol'==typeof g?g:g+'',u)}}function G(W,pa,ea){return pa&&
|
|
203
|
+
!function(k,G){'object'==typeof exports&&'undefined'!=typeof module?module.exports=G():'function'==typeof define&&define.amd?define('vendor/engine.io',G):(k='undefined'!=typeof globalThis?globalThis:k||self).eio=G()}(this,function(){function k(W,pa){for(var ea=0;ea<pa.length;ea++){var u=pa[ea];u.enumerable=u.enumerable||!1;u.configurable=!0;'value'in u&&(u.writable=!0);var Z=Object,e=Z.defineProperty;var g=u.key;a:if('object'==typeof g&&g){var x=g[Symbol.toPrimitive];if(void 0!==x){g=x.call(g,'string');
|
|
204
|
+
if('object'!=typeof g)break a;throw new TypeError('@@toPrimitive must return a primitive value.');}g=String(g)}e.call(Z,W,'symbol'==typeof g?g:g+'',u)}}function G(W,pa,ea){return pa&&k(W.prototype,pa),ea&&k(W,ea),Object.defineProperty(W,'prototype',{writable:!1}),W}function F(){return F=Object.assign?Object.assign.bind():function(W){for(var pa=1;pa<arguments.length;pa++){var ea=arguments[pa],u;for(u in ea)({}).hasOwnProperty.call(ea,u)&&(W[u]=ea[u])}return W},F.apply(null,arguments)}function L(W){return L=
|
|
205
205
|
Object.setPrototypeOf?Object.getPrototypeOf.bind():function(pa){return pa.__proto__||Object.getPrototypeOf(pa)},L(W)}function U(W,pa){W.prototype=Object.create(pa.prototype);W.prototype.constructor=W;O(W,pa)}function q(){try{var W=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch(pa){}return(q=function(){return!!W})()}function O(W,pa){return O=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(ea,u){return ea.__proto__=u,ea},O(W,pa)}function A(W){return A=
|
|
206
206
|
'function'==typeof Symbol&&'symbol'==typeof Symbol.iterator?function(pa){return typeof pa}:function(pa){return pa&&'function'==typeof Symbol&&pa.constructor===Symbol&&pa!==Symbol.prototype?'symbol':typeof pa},A(W)}function P(W){var pa='function'==typeof Map?new Map:void 0;return P=function(ea){function u(){return function(Z,e,g){if(q())return Reflect.construct.apply(null,arguments);var x=[null];x.push.apply(x,e);x=new (Z.bind.apply(Z,x));return g&&O(x,g.prototype),x}(ea,arguments,L(this).constructor)}
|
|
207
207
|
if(null===ea||!function(Z){try{return-1!==Function.toString.call(Z).indexOf('[native code]')}catch(e){return'function'==typeof Z}}(ea))return ea;if('function'!=typeof ea)throw new TypeError('Super expression must either be null or a function');if(void 0!==pa){if(pa.has(ea))return pa.get(ea);pa.set(ea,u)}return u.prototype=Object.create(ea.prototype,{constructor:{value:u,enumerable:!1,writable:!0,configurable:!0}}),O(u,ea)},P(W)}function ba(W){return W instanceof Uint8Array?W:W instanceof ArrayBuffer?
|
|
208
|
-
new Uint8Array(W):new Uint8Array(W.buffer,W.byteOffset,W.byteLength)}function
|
|
208
|
+
new Uint8Array(W):new Uint8Array(W.buffer,W.byteOffset,W.byteLength)}function h(){return new TransformStream({transform:function(W,pa){!function(ea,u){N&&ea.data instanceof Blob?ea.data.arrayBuffer().then(ba).then(u):Y&&(ea.data instanceof ArrayBuffer||C(ea.data))?u(ba(ea.data)):I(ea,!1,function(Z){M||=new TextEncoder;u(M.encode(Z))})}(W,function(ea){var u=ea.length;if(u<126){var Z=new Uint8Array(1);(new DataView(Z.buffer)).setUint8(0,u)}else if(u<65536){Z=new Uint8Array(3);var e=new DataView(Z.buffer);
|
|
209
209
|
e.setUint8(0,126);e.setUint16(1,u)}else Z=new Uint8Array(9),e=new DataView(Z.buffer),e.setUint8(0,127),e.setBigUint64(1,BigInt(u));W.data&&'string'!=typeof W.data&&(Z[0]|=128);pa.enqueue(Z);pa.enqueue(ea)})}})}function J(W){return W.reduce(function(pa,ea){return pa+ea.length},0)}function w(W,pa){if(W[0].length===pa)return W.shift();for(var ea=new Uint8Array(pa),u=0,Z=0;Z<pa;Z++)ea[Z]=W[0][u++],u===W[0].length&&(W.shift(),u=0);return W.length&&u<W[0].length&&(W[0]=W[0].slice(u)),ea}function m(W){if(W){for(var pa in m.prototype)W[pa]=
|
|
210
210
|
m.prototype[pa];return W}}function oa(W){for(var pa=arguments.length,ea=Array(pa>1?pa-1:0),u=1;u<pa;u++)ea[u-1]=arguments[u];return ea.reduce(function(Z,e){return W.hasOwnProperty(e)&&(Z[e]=W[e]),Z},{})}function S(W,pa){pa.useNativeTimers?(W.setTimeoutFn=ha.bind(Fa),W.clearTimeoutFn=jb.bind(Fa)):(W.setTimeoutFn=Fa.setTimeout.bind(Fa),W.clearTimeoutFn=Fa.clearTimeout.bind(Fa))}function r(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function V(){}function v(){for(var W in Wa.requests)Wa.requests.hasOwnProperty(W)&&
|
|
211
211
|
Wa.requests[W].abort()}function y(W){W=W.xdomain;try{if('undefined'!=typeof XMLHttpRequest&&(!W||qb))return new XMLHttpRequest}catch(pa){}if(!W)try{return new (Fa[['Active'].concat('Object').join('X')])('Microsoft.XMLHTTP')}catch(pa){}}function z(W){if(W.length>8E3)throw'URI too long';var pa=W,ea=W.indexOf('['),u=W.indexOf(']');-1!=ea&&-1!=u&&(W=W.substring(0,ea)+W.substring(ea,u).replace(/:/g,';')+W.substring(u,W.length));var Z,e;W=Ib.exec(W||'');for(var g={},x=14;x--;)g[vb[x]]=W[x]||'';return-1!=
|
|
@@ -234,7 +234,7 @@ u.onOpen()};this.ws.onclose=function(Z){return u.onClose({description:'websocket
|
|
|
234
234
|
function(){void 0!==this.ws&&(this.ws.onerror=function(){},this.ws.close(),this.ws=null)},ea.uri=function(){var u=this.opts.secure?'wss':'ws',Z=this.query||{};return this.opts.timestampRequests&&(Z[this.opts.timestampParam]=r()),this.supportsBinary||(Z.b64=1),this.createUri(u,Z)},G(pa,[{key:'name',get:function(){return'websocket'}}])}(H);var bb=Fa.WebSocket||Fa.MozWebSocket;za=function(W){function pa(){return W.apply(this,arguments)||this}U(pa,W);var ea=pa.prototype;return ea.createSocket=function(u,
|
|
235
235
|
Z,e){return mb?new bb(u,Z,e):Z?new bb(u,Z):new bb(u)},ea.doWrite=function(u,Z){this.ws.send(Z)},pa}(za);H=function(W){function pa(){return W.apply(this,arguments)||this}U(pa,W);var ea=pa.prototype;return ea.doOpen=function(){var u=this;try{this.M=new WebTransport(this.createUri('https'),this.opts.transportOptions[this.name])}catch(Z){return this.emitReserved('error',Z)}this.M.closed.then(function(){u.onClose()}).catch(function(Z){u.onError('webtransport error',Z)});this.M.ready.then(function(){u.M.createBidirectionalStream().then(function(Z){var e=
|
|
236
236
|
function(x,aa){da||=new TextDecoder;var Q=[],wa=0,Ka=-1,Qa=!1;return new TransformStream({transform:function(Ma,ya){for(Q.push(Ma);;){if(0===wa){if(J(Q)<1)break;Ma=w(Q,1);Qa=!(128&~Ma[0]);Ka=127&Ma[0];wa=Ka<126?3:126===Ka?1:2}else if(1===wa){if(J(Q)<2)break;Ma=w(Q,2);Ka=(new DataView(Ma.buffer,Ma.byteOffset,Ma.length)).getUint16(0);wa=3}else if(2===wa){if(J(Q)<8)break;Ma=w(Q,8);Ma=new DataView(Ma.buffer,Ma.byteOffset,Ma.length);var B=Ma.getUint32(0);if(B>2097151){ya.enqueue(T);break}Ka=B*4294967296+
|
|
237
|
-
Ma.getUint32(4);wa=3}else{if(J(Q)<Ka)break;Ma=w(Q,Ka);ya.enqueue(ia(Qa?Ma:da.decode(Ma),aa));wa=0}if(0===Ka||Ka>x){ya.enqueue(T);break}}}})}(Number.MAX_SAFE_INTEGER,u.socket.binaryType),g=Z.readable.pipeThrough(e).getReader();e=
|
|
237
|
+
Ma.getUint32(4);wa=3}else{if(J(Q)<Ka)break;Ma=w(Q,Ka);ya.enqueue(ia(Qa?Ma:da.decode(Ma),aa));wa=0}if(0===Ka||Ka>x){ya.enqueue(T);break}}}})}(Number.MAX_SAFE_INTEGER,u.socket.binaryType),g=Z.readable.pipeThrough(e).getReader();e=h();e.readable.pipeTo(Z.writable);u.C=e.writable.getWriter();!function aa(){g.read().then(function(Q){var wa=Q.value;Q.done||(u.onPacket(wa),aa())}).catch(function(Q){})}();Z={type:'open'};u.query.sid&&(Z.data='{"sid":"'.concat(u.query.sid,'"}'));u.C.write(Z).then(function(){return u.onOpen()})})})},
|
|
238
238
|
ea.write=function(u){var Z=this;this.writable=!1;for(var e=function(){var x=g===u.length-1;Z.C.write(u[g]).then(function(){x&&ta(function(){Z.writable=!0;Z.emitReserved('drain')},Z.setTimeoutFn)})},g=0;g<u.length;g++)e()},ea.doClose=function(){var u;null===(u=this.M)||void 0===u||u.close()},G(pa,[{key:'name',get:function(){return'webtransport'}}])}(H);var Ha={websocket:za,webtransport:H,polling:gb},Ib=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,
|
|
239
239
|
vb='source protocol authority userInfo user password host port relative path directory file query anchor'.split(' '),Mb='function'==typeof addEventListener&&'function'==typeof removeEventListener,Hb=[];Mb&&addEventListener('offline',function(){Hb.forEach(function(W){return W()})},!1);var Pb=function(W){function pa(u,Z){var e;((e=W.call(this)||this).binaryType='arraybuffer',e.writeBuffer=[],e.L=0,e.R=-1,e.D=-1,e.P=-1,e.I=1/0,u&&'object'===A(u)&&(Z=u,u=null),u)?(u=z(u),Z.hostname=u.host,Z.secure='https'===
|
|
240
240
|
u.protocol||'wss'===u.protocol,Z.port=u.port,u.query&&(Z.query=u.query)):Z.host&&(Z.hostname=z(Z.host).host);return S(e,Z),e.secure=null!=Z.secure?Z.secure:'undefined'!=typeof location&&'https:'===location.protocol,Z.hostname&&!Z.port&&(Z.port=e.secure?'443':'80'),e.hostname=Z.hostname||('undefined'!=typeof location?location.hostname:'localhost'),e.port=Z.port||('undefined'!=typeof location&&location.port?location.port:e.secure?'443':'80'),e.transports=[],e.$={},Z.transports.forEach(function(g){var x=
|
|
@@ -253,9 +253,9 @@ W.call(this,ea,u)||this}return U(pa,W),pa}(function(W){function pa(){var u;retur
|
|
|
253
253
|
wa=!1;Pb.priorWebsocketSuccess=!1;var Ka=function(){wa||(Q.send([{type:'ping',data:'probe'}]),Q.once('packet',function(ya){if(!wa)if('pong'===ya.type&&'probe'===ya.data){if(aa.upgrading=!0,aa.emitReserved('upgrading',Q),Q)Pb.priorWebsocketSuccess='websocket'===Q.name,aa.transport.pause(function(){wa||'closed'!==aa.readyState&&(Ma(),aa.setTransport(Q),Q.send([{type:'upgrade'}]),aa.emitReserved('upgrade',Q),Q=null,aa.upgrading=!1,aa.flush())})}else ya=Error('probe error'),ya.transport=Q.name,aa.emitReserved('upgradeError',
|
|
254
254
|
ya)}))},Qa=function(ya){ya=Error('probe error: '+ya);ya.transport=Q.name;Z();aa.emitReserved('upgradeError',ya)},Ma=function(){Q.removeListener('open',Ka);Q.removeListener('error',Qa);Q.removeListener('close',e);aa.off('close',g);aa.off('upgrading',x)};Q.once('open',Ka);Q.once('error',Qa);Q.once('close',e);this.once('close',g);this.once('upgrading',x);-1!==this._.indexOf('webtransport')&&'webtransport'!==u?this.setTimeoutFn(function(){wa||Q.open()},200):Q.open()},ea.onHandshake=function(u){this._=
|
|
255
255
|
this.nt(u.upgrades);W.prototype.onHandshake.call(this,u)},ea.nt=function(u){for(var Z=[],e=0;e<u.length;e++)~this.transports.indexOf(u[e])&&Z.push(u[e]);return Z},pa}(Pb));return function(W,pa){return new Qb(W,pa)}});
|
|
256
|
-
function BindingHelper(
|
|
256
|
+
function BindingHelper(k){var G={};typeof k!='undefined'&&(G=k);G.process=function(F,L,U){if(typeof F=='undefined'||!Array.isArray(F))throw Error('`bindings` must be a defined array');typeof L=='undefined'&&(L=F.length,U=0);if(F[U]){var q=F[U];if(typeof q.call=='undefined')throw Error('`bindings.['+U+'].call` is required !');if(typeof G[q.call]!='function')throw Error('`bindingContext.'+q.call+'` is not a function');var O=q.call;delete q.call;try{if(typeof q.handler!='undefined'){if(!window[q.handler])throw Error('`'+
|
|
257
257
|
q.handler+'` could not be reached. You must expose it to the `window` do object before any call.');var A=q.handler;delete q.handler;window[A].apply(this,Object.values(q));q.handler=A}else G[O].apply(this,Object.values(q));q.call=O}catch(P){console.error('BindingHelper encountered error while trying to execute `'+O+'`'+(P.stack||P))}G.process(F,L,U+1)}};return G}define('helpers/binding',[],function(){return BindingHelper});
|
|
258
|
-
(function(
|
|
258
|
+
(function(k,G){typeof exports=='object'&&typeof module!='undefined'?G(exports):typeof define=='function'&&define.amd?define('vendor/gina/psl',['exports'],G):(k=typeof globalThis!='undefined'?globalThis:k||self,G(k.psl={}))})(this,function(k){var G,F;const L=function(J){return J&&J.__esModule&&Object.prototype.hasOwnProperty.call(J,'default')?J.default:J}(function(){function J(M){throw new RangeError(V[M]);}function w(M,T){var N=M.split('@');let Y='';N.length>1&&(Y=N[0]+'@',M=N[1]);M=M.replace(r,'.');
|
|
259
259
|
M=M.split('.');N=[];let C=M.length;for(;C--;)N[C]=T(M[C]);T=N.join('.');return Y+T}function m(M){const T=[];let N=0;const Y=M.length;for(;N<Y;){const C=M.charCodeAt(N++);if(C>=55296&&C<=56319&&N<Y){const I=M.charCodeAt(N++);(I&64512)==56320?T.push(((C&1023)<<10)+(I&1023)+65536):(T.push(C),N--)}else T.push(C)}return T}if(F)return G;F=1;const oa=/^xn--/,S=/[^\0-\x7F]/,r=/[\x2E\u3002\uFF0E\uFF61]/g,V={overflow:'Overflow: input needs wider integers to process','not-basic':'Illegal input >= 0x80 (not a basic code point)',
|
|
260
260
|
'invalid-input':'Invalid input'},v=Math.floor,y=String.fromCharCode,z=function(M,T,N){let Y=0;M=N?v(M/700):M>>1;for(M+=v(M/T);M>455;Y+=36)M=v(M/35);return v(Y+36*M/(M+38))},l=function(M){const T=[],N=M.length;let Y=0,C=128,I=72;var la=M.lastIndexOf('-');la<0&&(la=0);for(var va=0;va<la;++va)M.charCodeAt(va)>=128&&J('not-basic'),T.push(M.charCodeAt(va));for(la=la>0?la+1:0;la<N;){va=Y;for(let da=1,ma=36;;ma+=36){la>=N&&J('invalid-input');var H=M.charCodeAt(la++);H=H>=48&&H<58?26+(H-48):H>=65&&H<91?H-
|
|
261
261
|
65:H>=97&&H<123?H-97:36;H>=36&&J('invalid-input');H>v((2147483647-Y)/da)&&J('overflow');Y+=H*da;const ia=ma<=I?1:ma>=I+26?26:ma-I;if(H<ia)break;H=36-ia;da>v(2147483647/H)&&J('overflow');da*=H}H=T.length+1;I=z(Y-va,H,va==0);v(Y/H)>2147483647-C&&J('overflow');C+=v(Y/H);Y%=H;T.splice(Y++,0,C)}return String.fromCodePoint(...T)},ja=function(M){const T=[];M=m(M);const N=M.length;let Y=128,C=0,I=72;for(var la of M)la<128&&T.push(y(la));let va=la=T.length;for(la&&T.push('-');va<N;){var H=2147483647;for(const sa of M)sa>=
|
|
@@ -265,41 +265,41 @@ w)=>{const m=w.replace(/^(\*\.|!)/,''),oa=L.toASCII(m),S=w.charAt(0);if(J.has(oa
|
|
|
265
265
|
LABEL_ENDS_WITH_DASH:'Domain name label can not end with a dash.',LABEL_TOO_LONG:'Domain name label should be at most 63 chars long.',LABEL_TOO_SHORT:'Domain name label should be at least 1 character long.',LABEL_INVALID_CHARS:'Domain name label can only contain alphanumeric characters or dashes.'},A=J=>{J=L.toASCII(J);if(J.length<1)return'DOMAIN_TOO_SHORT';if(J.length>255)return'DOMAIN_TOO_LONG';J=J.split('.');let w;for(let m=0;m<J.length;++m){if(w=J[m],!w.length)return'LABEL_TOO_SHORT';if(w.length>
|
|
266
266
|
63)return'LABEL_TOO_LONG';if(w.charAt(0)==='-')return'LABEL_STARTS_WITH_DASH';if(w.charAt(w.length-1)==='-')return'LABEL_ENDS_WITH_DASH';if(!/^[a-z0-9\-_]+$/.test(w))return'LABEL_INVALID_CHARS'}},P=J=>{if(typeof J!='string')throw new TypeError('Domain name must be a string.');let w=J.slice(0).toLowerCase();w.charAt(w.length-1)==='.'&&(w=w.slice(0,w.length-1));var m=A(w);if(m)return{input:J,error:{message:O[m],code:m}};const oa={input:J,tld:null,sld:null,domain:null,subdomain:null,listed:!1};var S=
|
|
267
267
|
w.split('.');if(S[S.length-1]==='local')return oa;J=()=>(/xn--/.test(w)&&(oa.domain&&(oa.domain=L.toASCII(oa.domain)),oa.subdomain&&(oa.subdomain=L.toASCII(oa.subdomain))),oa);m=q(w);if(!m)return S.length<2?oa:(oa.tld=S.pop(),oa.sld=S.pop(),oa.domain=[oa.sld,oa.tld].join('.'),S.length&&(oa.subdomain=S.pop()),J());oa.listed=!0;const r=m.suffix.split('.');S=S.slice(0,S.length-r.length);return m.exception&&S.push(r.shift()),oa.tld=r.join('.'),!S.length||(m.wildcard&&(r.unshift(S.pop()),oa.tld=r.join('.')),
|
|
268
|
-
!S.length)||(oa.sld=S.pop(),oa.domain=[oa.sld,oa.tld].join('.'),S.length&&(oa.subdomain=S.join('.'))),J()},ba=J=>J&&P(J).domain||null,
|
|
269
|
-
function parseHostname(
|
|
270
|
-
function Domain(
|
|
268
|
+
!S.length)||(oa.sld=S.pop(),oa.domain=[oa.sld,oa.tld].join('.'),S.length&&(oa.subdomain=S.join('.'))),J()},ba=J=>J&&P(J).domain||null,h=J=>{J=P(J);return!(!J.domain||!J.listed)};k.default={parse:P,get:ba,isValid:h};k.errorCodes=O;k.get=ba;k.isValid=h;k.parse=P;Object.defineProperties(k,{__esModule:{value:!0},[Symbol.toStringTag]:{value:'Module'}})});var _isNode=typeof module!=='undefined'&&module.exports,_psl=null;_isNode&&(_psl=require('psl'));
|
|
269
|
+
function parseHostname(k){k=String(k==null?'':k).trim().replace(/^[a-z][a-z0-9+.-]*:\/\//i,'');k=k.split(/[\/?#]/)[0];if(k.charAt(0)==='['){var G=k.indexOf(']');G!==-1&&(k=k.slice(1,G))}else G=k.lastIndexOf(':'),G!==-1&&/^\d+$/.test(k.slice(G+1))&&(k=k.slice(0,G));return k}function lastTwoLabels(k){if(!k)return k;var G=k.split('.');return G.length<=2?k:G.slice(-2).join('.')}
|
|
270
|
+
function Domain(k,G){var F=this;this.name='Domain';typeof arguments[0]==='function'&&(G=arguments[0],k=void 0);this.getRootDomain=function(L,U){U=parseHostname(L);if(/^\d+\.\d+\.\d+\.\d+$/.test(U))return{value:U,isSLD:!1,isRegisteredTldOrSld:!1};var q=_psl||(typeof window!=='undefined'&&window.psl?window.psl:null);L=null;if(q&&U)try{L=q.parse(U)}catch(A){L=null}var O=q=!1;L&&L.domain?(U=L.domain,q=!!(L.listed&&L.tld&&L.tld.indexOf('.')>-1),O=!!L.listed):U=lastTwoLabels(U);return{value:U,isSLD:q,isRegisteredTldOrSld:O}};
|
|
271
271
|
this.updatePSL=function(L){L&&L(!1)};_isNode&&(this.getFQDN=async function(L){var U=require('os'),q=require('dns'),O=require('util');L=typeof L!=='undefined'&&L!==''?L:U.hostname();if(/\./.test(L))return L;L=await O.promisify(q.lookup)(L,{hints:q.ADDRCONFIG||q.V4MAPPED});q=await O.promisify(q.lookupService)(L.address,0);if(!/\./.test(q.hostname))throw Error('[DOMAIN][getFQDN] `'+q.hostname+'` is not a FQDN !');return q.hostname});G&&setTimeout(function(){G(!1,F)},0);return F}
|
|
272
|
-
_isNode?module.exports=Domain:typeof define==='function'&&define.amd&&define('lib/domain',['vendor/gina/psl'],function(
|
|
273
|
-
function LoadingState(){var
|
|
274
|
-
return{DEFAULT_ATTRIBUTE:'data-gina-loading',getAttributeName:F,arm:function(L){if(!
|
|
272
|
+
_isNode?module.exports=Domain:typeof define==='function'&&define.amd&&define('lib/domain',['vendor/gina/psl'],function(k){_psl=k;return Domain});
|
|
273
|
+
function LoadingState(){var k=function(L){return!(!L||typeof L.setAttribute!='function'||typeof L.getAttribute!='function')},G=function(L){return k(L)&&L.tagName?/^(button|input)$/i.test(L.tagName)&&/^submit$/i.test(L.type||'')||/^a$/i.test(L.tagName)&&L.getAttribute('data-gina-form-submit')!=null?!0:!1:!1},F=function(){return typeof gina!='undefined'&&gina&&gina.config&&typeof gina.config.loadingAttribute=='string'&&gina.config.loadingAttribute!==''?gina.config.loadingAttribute:'data-gina-loading'};
|
|
274
|
+
return{DEFAULT_ATTRIBUTE:'data-gina-loading',getAttributeName:F,arm:function(L){if(!k(L))return!1;L.setAttribute(F(),'true');return!0},disarm:function(L){if(!k(L))return!1;L.setAttribute(F(),'false');return!0},isArmed:function(L){return k(L)?L.getAttribute(F())==='true':!1},resolveTrigger:function(L,U,q){if(!k(L))return null;q=typeof q=='function'?q:G;for(var O=L,A=0;k(O)&&A<10;){if(q(O))return O;if(U&&O===U)break;if(O.tagName&&/^(form|body|html)$/i.test(O.tagName))break;O=O.parentNode;++A}return L}}}
|
|
275
275
|
typeof module!=='undefined'&&module.exports?module.exports=LoadingState():typeof define==='function'&&define.amd&&define('lib/loading-state',[],function(){return LoadingState()});
|
|
276
|
-
define('gina/link','require lib/domain lib/loading-state lib/merge lib/uuid utils/events'.split(' '),function(
|
|
276
|
+
define('gina/link','require lib/domain lib/loading-state lib/merge lib/uuid utils/events'.split(' '),function(k){var G=k('lib/domain'),F=null,L=k('lib/loading-state'),U=k('lib/merge'),q=k('lib/uuid');k('utils/events');return function(O){function A(T,N){var Y=oa;oa=null;var C=++m;if(w&&w.readyState!==4)try{w.abort()}catch(ia){}var I=S();w=I;Y=Y||ja(T);var la=Y.id,va=document.getElementById(la)||null,H=null;(H=va.getAttribute('data-gina-link-event-on-success')||va.getAttribute('data-gina-link-event-on-error')?
|
|
277
277
|
!0:!1)&&listenToXhrEvents(Y,'link');N=typeof N=='undefined'?r:U(N,r);if(/^(http|https):/.test(T)&&!(new RegExp('^'+window.location.protocol+'//'+window.location.host)).test(T)){H=F.getRootDomain(window.location.hostname).value;var da=F.getRootDomain(T).value;H=H===da?!0:!1;gina.config.envIsDev&&(console.debug('Checking CORS from Popin plugin...TODO - local CORS Proxy'),console.debug('Is request from same domain ? ',H));H||(N.withCredentials=!1)}N.url=T;Y&&typeof Y.options!='undefined'&&(N=U(Y.options,
|
|
278
|
-
N));N.withCredentials?'withCredentials'in I?N.isSynchrone?I.open(N.method,N.url,N.isSynchrone):I.open(N.method,N.url):typeof XDomainRequest!='undefined'?(I=new XDomainRequest,I.open(N.method,N.url)):(I=null,triggerEvent(gina,va,'error.'+la,'CORS not supported: the server is missing the header `"Access-Control-Allow-Credentials": true` ')):N.isSynchrone?I.open(N.method,N.url,N.isSynchrone):I.open(N.method,N.url);if(!I)throw Error('No `xhr` object initiated');N.$link=Y;w=I;handleXhr(I,va,N,
|
|
279
|
-
I.onreadystatechange;I.onreadystatechange=function(ia){C===m&&typeof ma=='function'&&ma.call(this,ia)};typeof I.addEventListener=='function'&&(L.arm(va),I.addEventListener('loadend',function(){L.disarm(va)}));try{I.send()}catch(ia){throw L.isArmed(va)&&L.disarm(va),ia;}}function P(T,N){if(typeof N!='object')throw Error('`options` must be an object');T.options=U(N,ba.options);N=document.getElementById(T.id)||null;if(typeof
|
|
280
|
-
'` already exists !');if(!gina.events[evt]){addListener(gina,N,evt,function(I){cancelEvent(I);I=l(I.target.id);var la=I.url;typeof I.options.isSynchrone=='undefined'&&(I.options.isSynchrone=!1);typeof I.options.withCredentials=='undefined'&&(I.options.withCredentials=!1);oa=I;A(la,I.options)});var Y=N.childNodes,C=0;lLen=Y.length;if(lLen>0)for(;C<lLen;++C)typeof Y[C].tagName!='undefined'&&z(Y[C],N,evt)}T.request=A;T.getLinkById=l;T.getLinkByUrl=ja;
|
|
281
|
-
'loaded ready open close destroy success error progress'.split(' '));var ba={options:{url:void 0,'class':'gina-link-default'},authorizedEvents:['ready','success','error'],events:{}},
|
|
282
|
-
r={url:'',method:'GET',isSynchrone:!1,withCredentials:!0,headers:{'X-Requested-With':'XMLHttpRequest'}},V=[],v=function(T){return!(!T||!(T.ctrlKey||T.metaKey||T.shiftKey||T.altKey))},y=function(T){return!(!T||('disabled'in T||T.getAttribute('disabled')==null||T.getAttribute('disabled')=='false')&&T.getAttribute('aria-disabled')!='true')},z=function(T,N,Y){addListener(gina,T,'click',function(C){v(C)||(cancelEvent(C),y(N)||triggerEvent(gina,N,Y))})},l=function(T){return typeof
|
|
283
|
-
|
|
284
|
-
'undefined'&&I!=null?I:Y.getAttribute('href'),Y.getAttribute('download')==null&&Y.getAttribute('target')==null&&!/^#/.test(C.url||''))){I=Y.getAttribute('id');if(typeof I=='undefined'||I==null||I==''||/popin\.link/.test(I))I='link.click.gina-link-'+
|
|
285
|
-
M;
|
|
286
|
-
function insertAfter(
|
|
287
|
-
(function(
|
|
288
|
-
function fadeIn(
|
|
278
|
+
N));N.withCredentials?'withCredentials'in I?N.isSynchrone?I.open(N.method,N.url,N.isSynchrone):I.open(N.method,N.url):typeof XDomainRequest!='undefined'?(I=new XDomainRequest,I.open(N.method,N.url)):(I=null,triggerEvent(gina,va,'error.'+la,'CORS not supported: the server is missing the header `"Access-Control-Allow-Credentials": true` ')):N.isSynchrone?I.open(N.method,N.url,N.isSynchrone):I.open(N.method,N.url);if(!I)throw Error('No `xhr` object initiated');N.$link=Y;w=I;handleXhr(I,va,N,k);var ma=
|
|
279
|
+
I.onreadystatechange;I.onreadystatechange=function(ia){C===m&&typeof ma=='function'&&ma.call(this,ia)};typeof I.addEventListener=='function'&&(L.arm(va),I.addEventListener('loadend',function(){L.disarm(va)}));try{I.send()}catch(ia){throw L.isArmed(va)&&L.disarm(va),ia;}}function P(T,N){if(typeof N!='object')throw Error('`options` must be an object');T.options=U(N,ba.options);N=document.getElementById(T.id)||null;if(typeof h.$links[T.id]=='undefined'){if(V.indexOf(T.id)>-1)throw Error('`link '+T.id+
|
|
280
|
+
'` already exists !');if(!gina.events[evt]){addListener(gina,N,evt,function(I){cancelEvent(I);I=l(I.target.id);var la=I.url;typeof I.options.isSynchrone=='undefined'&&(I.options.isSynchrone=!1);typeof I.options.withCredentials=='undefined'&&(I.options.withCredentials=!1);oa=I;A(la,I.options)});var Y=N.childNodes,C=0;lLen=Y.length;if(lLen>0)for(;C<lLen;++C)typeof Y[C].tagName!='undefined'&&z(Y[C],N,evt)}T.request=A;T.getLinkById=l;T.getLinkByUrl=ja;h.$links[T.id]=T}}this.plugin='link';registerEvents(this.plugin,
|
|
281
|
+
'loaded ready open close destroy success error progress'.split(' '));var ba={options:{url:void 0,'class':'gina-link-default'},authorizedEvents:['ready','success','error'],events:{}},h={plugin:this.plugin,id:'gina-links-'+q(),on,eventData:{},$links:{},target:document,isReady:!1,initialized:!1},J={plugin:this.plugin,on,eventData:{},target:document,url:null,request:null,$forms:[]},w=null,m=0,oa=null,S=function(){if(window.XMLHttpRequest)return new XMLHttpRequest;if(window.ActiveXObject)try{return new ActiveXObject('Msxml2.XMLHTTP')}catch(T){try{return new ActiveXObject('Microsoft.XMLHTTP')}catch(N){}}return null},
|
|
282
|
+
r={url:'',method:'GET',isSynchrone:!1,withCredentials:!0,headers:{'X-Requested-With':'XMLHttpRequest'}},V=[],v=function(T){return!(!T||!(T.ctrlKey||T.metaKey||T.shiftKey||T.altKey))},y=function(T){return!(!T||('disabled'in T||T.getAttribute('disabled')==null||T.getAttribute('disabled')=='false')&&T.getAttribute('aria-disabled')!='true')},z=function(T,N,Y){addListener(gina,T,'click',function(C){v(C)||(cancelEvent(C),y(N)||triggerEvent(gina,N,Y))})},l=function(T){return typeof h.$links[T]!='undefined'?
|
|
283
|
+
h.$links[T]:null},ja=function(T){var N=null,Y;for(Y in gina.link.$links)if(typeof gina.link.$links[Y].url!='undefined'&&gina.link.$links[Y].url==T){N=gina.link.$links[Y];break}return N},M=function(T,N){typeof T=='undefined'&&(T=h.target);var Y=null,C=Y=null,I=null;I=I=null;T=T.getElementsByTagName('a');for(var la=0,va=T.length;la<va;++la)if(((Y=T[la].getAttribute('data-gina-link'))||Y=='')&&!/^false$/i.test(Y)&&(Y=T[la],C={type:'a',method:'GET'},I=Y.getAttribute('data-gina-link-url'),C.url=typeof I!=
|
|
284
|
+
'undefined'&&I!=null?I:Y.getAttribute('href'),Y.getAttribute('download')==null&&Y.getAttribute('target')==null&&!/^#/.test(C.url||''))){I=Y.getAttribute('id');if(typeof I=='undefined'||I==null||I==''||/popin\.link/.test(I))I='link.click.gina-link-'+h.id+'-'+q();Y.id=I;evt=C.id=I;Y.setAttribute('id',evt);addListener(gina,Y,'click',function(H){v(H)||H.preventDefault()});I=null;typeof h.$links[C.id]=='undefined'&&(C.target=Y,I=U(C,J),P(I,N))}};F||new G(function(T,N){if(T)throw T;F=N});return function(T){h.bindLinks=
|
|
285
|
+
M;h.request=A;h.getLinkById=l;h.getLinkByUrl=ja;h.on('init',function(N){evt='click';addListener(gina,h.target,evt,function(Y){v(Y)||typeof h.$links[Y.target.id]=='undefined'||(cancelEvent(Y),y(Y.target)||triggerEvent(gina,Y.target,Y.target.id,Y.detail))});typeof T=='undefined'&&(T={});h.options=T;M(h.target,T);gina.linkIsBinded=!0;h.isReady=!0;gina.hasLinkHandler=!0;typeof gina.link!='undefined'&&gina.link||(gina.link=h);triggerEvent(gina,h.target,'ready.'+h.id,h)});h.initialized=!0;return h}(O)}});
|
|
286
|
+
function insertAfter(k,G){k.parentNode.insertBefore(G,k.nextSibling)}function getElementsByAttribute(k){for(var G=[],F=0,L=document.getElementsByTagName('*'),U=0,q=L.length;U<q;++U)L[U].getAttribute(k)!==null&&(G[F]=L[U],++F);return G}
|
|
287
|
+
(function(k){var G=k.prototype,F=G.parseFromString;try{if((new k).parseFromString('','text/html'))return}catch(L){}G.parseFromString=function(L,U){if(/^\s*text\/html\s*(?:;|$)/i.test(U)){var q=document.implementation.createHTMLDocument('');L.toLowerCase().indexOf('<!doctype')>-1?q.documentElement.innerHTML=L:q.body.innerHTML=L;return q}return F.apply(this,arguments)}})(DOMParser);define('utils/dom',function(){});
|
|
288
|
+
function fadeIn(k){var G=.1;k.style.display='block';var F=setInterval(function(){G>=1&&clearInterval(F);k.style.opacity=G;k.style.filter='alpha(opacity='+G*100+')';G+=G*.1},10)}function fadeOut(k){var G=1,F=setInterval(function(){G<=.1&&(clearInterval(F),k.style.display='none');k.style.opacity=G;k.style.filter='alpha(opacity='+G*100+')';G-=G*.1},50)}define('utils/effects',function(){});
|
|
289
289
|
function DataHelper(){encodeRFC5987ValueChars=function(F){return encodeURIComponent(F).replace(/['()]/g,escape).replace(/\*/g,'%2A').replace(/%(?:7C|60|5E)/g,unescape)};safeDecodeURIComponent=function(F){try{return decodeURIComponent(F)}catch(L){return F}};safeDecodeURI=function(F){try{return decodeURI(F)}catch(L){return F}};formatDataFromString=function(F){typeof F=='object'&&(F=JSON.stringify(F));try{F=decodeURIComponent(F)}catch(ba){}/("false"|"true"|"on")/.test(F)&&(F=F.replace(/"false"/g,!1).replace(/"true"/g,
|
|
290
|
-
!0).replace(/"on"/g,!0));/("null")/i.test(F)&&(F=F.replace(/"null"/ig,null));a:{var L=F,U=F=null,q=null;if(/^(\{|\[|%7B|%5B)/.test(L)){try{F=(q=/^(\{|%7B)/.test(L)?!1:!0)?[]:{};U=/^(%7B|%5B)/.test(L)?JSON.parse(decodeURIComponent(L)):JSON.parse(L);if(Array.isArray(U)){q=0;for(var O=U.length;q<O;++q)F[q]=
|
|
290
|
+
!0).replace(/"on"/g,!0));/("null")/i.test(F)&&(F=F.replace(/"null"/ig,null));a:{var L=F,U=F=null,q=null;if(/^(\{|\[|%7B|%5B)/.test(L)){try{F=(q=/^(\{|%7B)/.test(L)?!1:!0)?[]:{};U=/^(%7B|%5B)/.test(L)?JSON.parse(decodeURIComponent(L)):JSON.parse(L);if(Array.isArray(U)){q=0;for(var O=U.length;q<O;++q)F[q]=k(U[q],F);var A=F}else A=k(U,F);var P=A;break a}catch(ba){console.error('[365] could not parse body:\n'+L)}P=void 0}else{F={};P=L.split(/&/g);/("false"|"true"|"on")/.test(L)&&L.replace(/"false"/g,
|
|
291
291
|
!1).replace(/"true"/g,!0).replace(/"on"/g,!0);L={};O=0;for(U=P.length;O<U;++O)if(P[O])if(P[O]=safeDecodeURIComponent(P[O]),/^\{/.test(P[O])||/=\{/.test(P[O])||/=\[/.test(P[O]))try{if(/^\{/.test(P[O])){F=JSON.parse(P[O]);break}else L=P[O].match(/=(.*)/),L[0]=P[O].split(/=/)[0],F[L[0]]=JSON.parse(L[1])}catch(ba){console.error('[parseBody#1] could not parse body:\n'+P[O])}else{L=P[O].split(/=/);if(/\{\}":/.test(L[1]))try{L[1]=JSON.parse(L[1])}catch(ba){console.error('[parseBody#2] could not parse body:\n'+
|
|
292
|
-
L[1])}typeof L[1]!='string'||/\[object /.test(L[1])||(L[0]=safeDecodeURIComponent(L[0]),L[1]=safeDecodeURIComponent(L[1]),/^(.*)\[(.*)\]/.test(L[0])?(A=L[0].replace(/\]/g,'').split(/\[/g),F=G(F,A,0,L[1])):F[L[0]]=L[1])}P=F}}return P};var
|
|
292
|
+
L[1])}typeof L[1]!='string'||/\[object /.test(L[1])||(L[0]=safeDecodeURIComponent(L[0]),L[1]=safeDecodeURIComponent(L[1]),/^(.*)\[(.*)\]/.test(L[0])?(A=L[0].replace(/\]/g,'').split(/\[/g),F=G(F,A,0,L[1])):F[L[0]]=L[1])}P=F}}return P};var k=function(F,L){var U=[];L||={};for(let O in F)if(U[0]=O,U[1]=F[O],/^(.*)\[(.*)\]/.test(U[0])){var q=U[0].replace(/\]/g,'').split(/\[/g);L=G(L,q,0,U[1])}else L[U[0]]=U[1];return L},G=function(F,L,U,q){for(let O=0,A=L.length;O<A;O++){let P=L[U];if(O==U){if(typeof F[L[U]]==
|
|
293
293
|
'undefined'||typeof F[L[U]]=='string')Array.isArray(F)?(P=~~L[U],F[P]=/^\d+$/.test(L[U+1])?[]:{}):F[L[U]]=/^\d+$/.test(L[U+1])?[]:{};if(U==L.length-1){q=typeof q!='undefined'?q:'';Array.isArray(F[L[U]])?F[L[U]].push(q):F[L[U]]=q;break}else/^\d+$/.test(L[U])&&!Array.isArray(F)&&(F=[]),typeof F[P]=='undefined'&&(F[P]=null),G(F[P],L,U+1,q)}}return F};nestBracketNotationKey=G}
|
|
294
294
|
typeof module!=='undefined'&&module.exports?module.exports=DataHelper:typeof define==='function'&&define.amd&&define('utils/data',[],function(){return DataHelper()});
|
|
295
|
-
function ValidatorPlugin(
|
|
296
|
-
!0:!1)delete require.cache[require.resolve('./form-validator')],delete require.cache[require.resolve('../../../../../helpers/data')];require('../../../../../helpers/data')}var A=q?require('lib/uuid'):require('../../../../../lib/uuid'),P=q?require('lib/merge'):require('../../../../../lib/merge'),ba=q?require('lib/inherits'):require('../../../../../lib/inherits'),
|
|
295
|
+
function ValidatorPlugin(k,G,F,L){this.plugin='validator';var U='init ready registered success error progress uploadProgress submit reset change changed keydown keyup focusout focusin validate validated destroy asyncCompleted'.split(' '),q=typeof module!=='undefined'&&module.exports?!1:!0,O=null;if(q)require('utils/events'),registerEvents(this.plugin,U),require('utils/dom'),require('utils/effects'),require('utils/data'),O=gina.config.envIsDev;else{if(O=/^true$/i.test(process.env.NODE_ENV_IS_DEV)?
|
|
296
|
+
!0:!1)delete require.cache[require.resolve('./form-validator')],delete require.cache[require.resolve('../../../../../helpers/data')];require('../../../../../helpers/data')}var A=q?require('lib/uuid'):require('../../../../../lib/uuid'),P=q?require('lib/merge'):require('../../../../../lib/merge'),ba=q?require('lib/inherits'):require('../../../../../lib/inherits'),h=q?require('lib/form-validator'):require('./form-validator'),J=q?require('lib/routing'):require('../../../../../lib/routing'),w=q?require('lib/loading-state'):
|
|
297
297
|
require('../../../../../lib/loading-state'),m={id:'validator-'+A(),plugin:this.plugin,on:q?on:null,eventData:{},target:q?document:null,errors:{},initialized:!1,isReady:!1,rules:{},$forms:{},getFormById:null,validateFormById:null,setOptions:null,resetErrorsDisplay:null,resetFields:null,setErrorLabels:null,_errorLabelsByCulture:{}},oa={id:null,plugin:this.plugin,on:q?on:null,eventData:{},target:q?document:null,cachedErrors:{},lastFocused:q?[]:null,binded:!1,unbinded:!1,withUserBindings:!1,rules:{},
|
|
298
298
|
setOptions:null,send:null,isValidating:null,isSubmitting:null,submit:null,destroy:null,resetErrorsDisplay:null,resetFields:null},S={},r={},V={url:'',method:'GET',isSynchrone:!1,withCredentials:!1,withRateLimit:!0,headers:{'Content-Type':'application/x-www-form-urlencoded; charset=UTF-8','X-Requested-With':'XMLHttpRequest'}},v=function(){if(typeof document==='undefined'||!document||typeof document.cookie!=='string')return null;var a=document.cookie||'';if(!a)return null;a=a.split(';');for(var b=0,
|
|
299
299
|
c=a.length;b<c;++b){for(var n=a[b];n.charAt(0)===' '||n.charAt(0)==='\t';)n=n.slice(1);var D=n.indexOf('=');if(!(D<0)&&n.slice(0,D)==='gina-csrf-token'){a=n.slice(D+1);try{return decodeURIComponent(a)}catch(E){return a}}}return null},y=function(a){if(typeof a!=='string'||!a)return!1;a=a.toUpperCase();return a!=='GET'&&a!=='HEAD'&&a!=='OPTIONS'},z=function(a){return a!==null&&typeof a=='object'&&!Array.isArray(a)&&!(a instanceof Date)},l=function(a,b){var c={count:0,map:{}},n=function(f,ca,K,X){for(var Ba in K){var Ea=
|
|
300
300
|
X.concat(Ba),Da=ca+'.'+Ba;z(K[Ba])?n(f,Da,K[Ba],Ea):typeof a[Da]=='undefined'&&(a[Da]=K[Ba],c.map[Da]={kind:'nested',rootKey:f,path:Ea},++c.count)}},D=null,E=null;for(D in b)/\[/.test(D)?(E=D.replace(/\[/g,'.').replace(/\]/g,''),typeof a[E]=='undefined'&&(a[E]=b[D],c.map[E]={kind:'bracket',original:D},++c.count)):z(b[D])&&n(D,D,b[D],[D]);return c},ja=function(a,b,c,n){c=typeof c!='undefined'?{id:c}:null;var D={};for(E in b)D[E]=b[E];if(typeof a!='undefined'&&a.count()>0){b=l(D,b);try{e(a,''),u(a)}catch(Ba){throw Ba;
|
|
301
301
|
}a=Rb(c,D,null,m.rules,null,n);if(b.count>0&&a&&typeof a.isValid=='function'&&typeof a.error!='undefined'){n=null;c={};for(n in a.error||{})if(D=b.map[n])if(D.kind=='bracket')c[D.original]=a.error[n];else{var E=D.path;D=D.rootKey;for(var f=1,ca=E.length;f<ca;++f)D+='['+E[f]+']';c[D]=a.error[n]}else c[n]=a.error[n];a.error=c;if((c=a.data)&&typeof c=='object')for(n in b.map){D=b.map[n];f=(E=Object.prototype.hasOwnProperty.call(c,n))?c[n]:void 0;delete c[n];D=D.kind=='bracket'?D.original.replace(/\]/g,
|
|
302
|
-
'').split(/\[/g):D.path;ca=D.length-1;for(var K=c,X=0;X<ca&&K;++X)K=K[D[X]];if(K&&typeof K=='object')if(E)K[D[ca]]=f;else for(delete K[D[ca]],E=ca-1;E>=0;--E){f=c;for(ca=0;ca<E&&f;++ca)f=f[D[ca]];if(f&&z(f[D[E]])&&Object.keys(f[D[E]]).length===0)delete f[D[E]];else break}}}return a}return new
|
|
302
|
+
'').split(/\[/g):D.path;ca=D.length-1;for(var K=c,X=0;X<ca&&K;++X)K=K[D[X]];if(K&&typeof K=='object')if(E)K[D[ca]]=f;else for(delete K[D[ca]],E=ca-1;E>=0;--E){f=c;for(ca=0;ca<E&&f;++ca)f=f[D[ca]];if(f&&z(f[D[E]])&&Object.keys(f[D[E]]).length===0)delete f[D[E]];else break}}}return a}return new h(D,void 0,void 0,void 0,n)},M=function(a){V=a=P(a,V);return this},T=function(a){var b=null;if(!m.$forms)throw Error('`$forms` collection not found');if(typeof a=='undefined')throw Error('[ FormValidator::getFormById(formId) ] `formId` is missing');
|
|
303
303
|
a=a.replace(/#/,'');var c=document.getElementById(a);if(c!=null&&typeof m.$forms[a]=='undefined'){if(!(c instanceof HTMLFormElement))throw Error('[ FormValidator::getFormById(formId) ] `'+a+'` resolves to <'+c.tagName+'>, not a FORM. A non-FORM element shares the same id as the target form \u2014 rename one of them so the id is unique.');var n,D=typeof(S.count()>0)?S:m.rules;c.getAttribute?(id=c.getAttribute('id')||'form.'+A(),id!==c.getAttribute('id')&&c.setAttribute('id',id)):(id='form.'+A(),c.setAttribute('id',
|
|
304
304
|
id));c.id=oa.id=id;if(typeof c.id!='undefined'&&c.id!='null'&&c.id!=''){oa.target=c;m.$forms[c.id]=P({},oa);if(n=c.getAttribute('data-gina-form-rule')){n=n.replace(/\-|\//g,'.');if(typeof D[n]=='undefined')throw Error('['+c.id+'] no rule found with key: `null`');n=D[n]}typeof c.id=='string'&&typeof D[c.id.replace(/\-/g,'.')]!='undefined'?$target=m.$forms[c.id].target:typeof c.id=='object'?(delete m.$forms[c.id],D=c.attributes.getNamedItem('id').nodeValue||'form.'+A(),c.setAttribute('id',D),c.id=D,
|
|
305
305
|
oa.target=c,m.$forms[D]=P({},oa),$target=m.$forms[D].target):$target=m.$forms[c.id].target;n?ob($target,n):ob($target)}}typeof m.$forms[a]!='undefined'&&(m.$forms[a].withUserBindings=!0,b=typeof this.$forms!='undefined'&&typeof this.$forms[a]=='undefined'?this.$forms[a]=m.$forms[a]:m.$forms[a]);if(!b)throw Error('Validator::getFormById(...) exception: could not retrieve form `'+a+'`');b.binded||(ob(b.target),b=m.$forms[a]);O&&q&&typeof window.ginaToolbar!='undefined'&&window.ginaToolbar&&(gina.forms.errors||
|
|
@@ -493,7 +493,7 @@ ka.detail;var Ta=a;/^form$/i.test(a.tagName)||(Ta=a.form);var Ja=Ta.getAttribute
|
|
|
493
493
|
'')va(Fb[cb]),ha(Ta,D._errors,D._data,cb),eb(Ta,pb);O&&q&&typeof window.ginaToolbar!='undefined'&&window.ginaToolbar&&(gina.forms.errors||(gina.forms.errors={}),window.ginaToolbar.update('forms',{id:Ja,errors:m.$forms[Ja].errors||{}}));triggerEvent(gina,a,'validated.'+Ja,D);return}/^true$/i.test(m.$forms[Ja].isSubmitting)?triggerEvent(gina,a,'validated.'+Ja,D):(ka=!1,fb.length==1||fb[fb.length-1]==cb?((pb=D._errors.count()>0?!1:!0)&&(ka=!0),!pb&&/^true|false$/i.test(m.$forms[Ja].isValidating)&&(console.debug('[1] Should update error display now ',
|
|
494
494
|
D._errors),m.$forms[Ja].errors=P(D._errors,m.$forms[Ja].errors),va(Fb[cb]),ha(Ta,D._errors,D._data,cb),eb(Ta,pb)),triggerEvent(gina,a,'validated.'+Ja,D)):/^true$/i.test(m.$forms[Ja].isValidating)&&fb.length>1&&fb[fb.length-1]!=cb?ka=!0:Ea&&Xa<=0&&D&&D.isRevealCompletion&&triggerEvent(gina,a,'validated.'+Ja,D),ka&&Rb(Ta,Eb,Fb,Ua,function(lb){m.$forms[Ja].isValidating=!1;pb=lb.isValid();O&&q&&typeof window.ginaToolbar!='undefined'&&window.ginaToolbar&&(gina.forms.errors||(gina.forms.errors={}),window.ginaToolbar.update('forms',
|
|
495
495
|
{id:Ja,errors:lb.error||{}}));ha(Ta,lb.error,lb.data,cb);eb(Ta,pb)}))}});db[cb][rb](Ua[cb][rb]);continue}else db[cb][rb](Ua[cb][rb]);delete sb[cb]}catch(fa){if(rb=='conditions')throw Error('[ ginaFormValidator ] could not evaluate `'+cb+'->'+rb+'()` where `conditions` must be a `collection` (Array)\nStack:\n'+fa);throw Error('[ ginaFormValidator ] could not evaluate `'+cb+'->'+rb+'()`\nStack:\n'+fa);}},db=null,kb={},ab=!1;q?/^form$/i.test(a.tagName)?(ca=a.getAttribute('id'),f='validated.'+ca,m.$forms[ca].fields=
|
|
496
|
-
b,typeof a.eventData!='undefined'&&typeof a.eventData.error!='undefined'&&delete a.eventData.error,db=new
|
|
496
|
+
b,typeof a.eventData!='undefined'&&typeof a.eventData.error!='undefined'&&delete a.eventData.error,db=new h(b,c,V)):(ab=!0,ca=a.form.getAttribute('id')||a.form.target.getAttribute('id'),f='validated.'+ca,m.$forms[ca].fields=b,db=new h(b,c,V,m.$forms[ca].fieldsSet)):db=new h(b,null,V,void 0,E);var Eb=null,Fb=null;ab?(E=a.form.getAttribute('id'),ab=Cb(m.$forms[E].target,m.$forms[E].rules,!1),Eb=cc(JSON.stringify(m.$forms[E].rules),JSON.clone(ab.fields)),Fb=ab.$fields):(Eb=JSON.clone(b),Fb=c);E=typeof n!=
|
|
497
497
|
'undefined'?JSON.clone(n):{};var Kb=function(cb,Ua,sb,Za,fb,Va,rb,ub){var zb=null;if(typeof Va!='undefined')for(var Ya in Za){var p=fb&&typeof fb[Ya]!='undefined'?fb[Ya].getAttribute('type'):null;if(q&&typeof fb[Ya]=='undefined')console.warn('field `'+Ya+'` found for your form rule ('+cb.id+'), but not found in $field collection.\nPlease, check your HTML or remove `'+Ya+'` declaration from your rule if this is a mistake.');else{q&&fb[Ya].getAttribute('data-gina-form-element-group')&&typeof Va[Ya]!=
|
|
498
498
|
'undefined'&&typeof Va[Ya].exclude!='undefined'&&Va[Ya].exclude&&!fb[Ya].disabled&&(Va[Ya].exclude=!1);var R=typeof Va['_case_'+Ya]!='undefined'?!0:!1;if(q&&fb[Ya].tagName.toLowerCase()=='input'&&/^(checkbox)$/i.test(p))if(!fb[Ya].checked&&typeof Va[Ya]!='undefined'&&typeof Va[Ya].isRequired!='undefined'&&/^(false)$/i.test(Va[Ya].isRequired)||fb[Ya].disabled)Va[Ya]={exclude:!0};else{if(!fb[Ya].checked&&typeof Va[Ya]=='undefined')continue}else q&&fb[Ya].tagName.toLowerCase()=='input'&&/^(radio)$/i.test(p)&&
|
|
499
499
|
console.debug('Radio: ',fb[Ya].id,fb[Ya].checked,fb[Ya].value);for(var fa in Va)if(/^_case_/.test(fa)&&typeof Va[fa].conditions!='undefined'&&(!Array.isArray(Va[fa].conditions)||Va[fa].conditions.length)&&typeof Va[fa].conditions[0].rules!='undefined'&&typeof Va[fa].conditions!='undefined'&&Array.isArray(Va[fa].conditions))if(zb=fa.replace('_case_',''),typeof Fb[zb]=='undefined')console.warn('Found case `'+fa+'` but field `'+zb+'` is misssing in the dom.\n You should add `'+zb+'` element to your form in order to allow Validator to process this case.');
|
|
@@ -507,9 +507,9 @@ P(Ta[pb],sb[pb]))))}else/^\//.test(R[lb]['case'])?(Sa=R[lb]['case'].match(/\/(.*
|
|
|
507
507
|
(Ta[Ja]=P(Ta[Ja],sb[Ja])));++Ba;if(q)Kb(cb,Ua,sb,Za,fb,Ta,rb,ub);else return Kb(cb,Ua,sb,Za,fb,Ta,rb,ub)}--ub}}}--Ba;if(ub<=0&&Ba<0){Ua=db.getErrors();for(Ya in Ua){for(rule in Ua[Ya])kb[Ya]||(kb[Ya]=''),kb[Ya].indexOf(rule)<0&&(kb[Ya]+=rule+' ');q&&fb[Ya].setAttribute('data-gina-form-errors',kb[Ya].substring(0,kb[Ya].length-1))}try{K=x(db.toData()),O&&q&&typeof window.ginaToolbar!='undefined'&&window.ginaToolbar&&(gina.forms.validated||(gina.forms.validated={}),gina.forms.validated[ca]||(gina.forms.validated[ca]=
|
|
508
508
|
{}),window.ginaToolbar.update('forms',{id:ca,validated:K}))}catch(lb){throw lb;}Ea=!0;if(!X&&Xa<=0)if(typeof rb!='undefined'&&typeof rb==='function')rb._errors=db.getErrors(),rb._data=db.toData(),triggerEvent(gina,cb,'validated.'+ca,rb);else return X=!0,{isValid:db.isValid,error:Ua,data:K}}};q&&typeof D==='function'&&addListener(gina,a,f,function sb(Ua){Ua.preventDefault();if(Ua.detail===D&&(Ua.currentTarget.removeEventListener(Ua.type,sb,!1),!X)){X=!0;Ea=!1;Xa=0;var Za=Ua.detail,fb=Za._data||db.toData(),
|
|
509
509
|
Va=Za._errors||db.getErrors()||null;console.debug('instance errors: ',m.$forms[ca].errors,' VS cbErrors: ',Va,db.isValid(),' VS d.getErrors(): ',db.getErrors());Va.count()>0&&db.isValid()&&(db.isValid=function(){return!1});Za({isValid:db.isValid,error:Va,data:x(fb)});removeListener(gina,Ua.target,'validated.'+Ua.target.id)}});if(q)Kb(a,Eb,E,b,c,n,D,0);else return Kb(a,Eb,E,b,c,n,D,0)},dc=function(a,b){if(!a||typeof a!='object')return m;b||=typeof gina!='undefined'&&gina.config&&gina.config.culture?
|
|
510
|
-
gina.config.culture:'en';m._errorLabelsByCulture||(m._errorLabelsByCulture={});m._errorLabelsByCulture[b]=P(JSON.clone(a),m._errorLabelsByCulture[b]||{});return m};return q?Z(
|
|
511
|
-
define('gina/popin',['require','lib/domain','lib/loading-state','lib/merge','utils/events'],function(
|
|
512
|
-
|
|
510
|
+
gina.config.culture:'en';m._errorLabelsByCulture||(m._errorLabelsByCulture={});m._errorLabelsByCulture[b]=P(JSON.clone(a),m._errorLabelsByCulture[b]||{});return m};return q?Z(k):ja(k,G,F,L)}typeof module!=='undefined'&&module.exports?module.exports=ValidatorPlugin:typeof define==='function'&&define.amd&&define('gina/validator','utils/events utils/dom utils/effects utils/data lib/form-validator lib/routing lib/loading-state'.split(' '),function(){return ValidatorPlugin});
|
|
511
|
+
define('gina/popin',['require','lib/domain','lib/loading-state','lib/merge','utils/events'],function(k){function G(S){return(S||'gp')+'-'+ ++A}function F(S){J[S]||(J[S]=!0,typeof console!='undefined'&&typeof console.warn=='function'&&console.warn('[gina/popin] `'+S+'` is deprecated; use `'+(S==='data-gina-popin-name'?'data-gina-dialog':'data-gina-dialog-src')+'` instead. The legacy attribute still works (mapped onto the new dialog path).'))}var L=k('lib/domain'),U=null,q=k('lib/loading-state'),O=
|
|
512
|
+
k('lib/merge');k('utils/events');var A=0,P={},ba={},h={},J={},w=!1,m=!1,oa=!1;return function(S){function r(){var e=null,g;for(g in gina.popin.$popins)if(typeof gina.popin.$popins[g].isOpen!='undefined'&&gina.popin.$popins[g].isOpen){e=gina.popin.$popins[g];break}!e&&gina.popin.activePopinId&&(e=gina.popin.$popins[gina.popin.activePopinId]);return e}function V(e){var g=!1,x=e.getAttribute('data-gina-dialog'),aa=e.getAttribute('data-gina-dialog-src');x==null&&e.getAttribute('data-gina-popin-name')!=
|
|
513
513
|
null&&(g=!0,x=e.getAttribute('data-gina-popin-name'),F('data-gina-popin-name'));aa==null&&e.getAttribute('data-gina-popin-url')!=null&&(g=!0,aa=e.getAttribute('data-gina-popin-url'),F('data-gina-popin-url'));if(aa==null&&/^A$/i.test(e.tagName)){var Q=e.getAttribute('href');Q&&Q!=''&&Q!='#'&&!/^#/.test(Q)&&(aa=Q)}Q=g;g||e.getAttribute('data-gina-popin-name')!=null?g=!0:(g=e.getAttribute('data-gina-dialog-modal'),g=g!=null?g==='false'?!1:!0:bb.options.modal===!0||bb.options.modal===!1?bb.options.modal:
|
|
514
514
|
typeof gina!='undefined'&&gina.config&&gina.config.popin&&(gina.config.popin.modal===!0||gina.config.popin.modal===!1)?gina.config.popin.modal:!1);return{id:x,src:aa,isLegacy:Q,modal:g,partialTarget:e.getAttribute('data-gina-dialog-target'),isLink:/^true$/i.test(e.getAttribute('data-gina-popin-is-link')),formSubmit:/^true$/i.test(e.getAttribute('data-gina-form-submit'))}}function v(e,g){e&&g&&(e.setAttribute('aria-haspopup','dialog'),e.setAttribute('aria-controls',g))}function y(e){if(e&&typeof e.querySelector==
|
|
515
515
|
'function'){var g=e.querySelector('[id$="-title"]')||e.querySelector('h1, h2, h3, h4, h5, h6');g&&(g.id||(g.id=(e.id||'gina-popin')+'-title',g.setAttribute('id',g.id)),e.setAttribute('aria-labelledby',g.id))}}function z(e){if(e&&typeof e.querySelector=='function'){var g=e.querySelector('[autofocus]')||e.querySelector('a[href], button:not([disabled]), input:not([disabled]), select:not([disabled]), textarea:not([disabled]), [tabindex]:not([tabindex="-1"])');g&&typeof g.focus=='function'?g.focus():typeof e.focus==
|
|
@@ -562,7 +562,7 @@ g)}}}function gb(e){var g=typeof e!='undefined'?ea(e):r(),x;if(!g&&typeof e!='un
|
|
|
562
562
|
gina.popin.activePopinId:Ha.activePopinId)===aa&&W(null);triggerEvent(gina,Ha.target,'destroy.'+aa,{name:e,id:aa})}}function yb(e,g){if(typeof g!='object')throw Error('`options` must be an object');e.options=O(g,bb.options);e.id='gina-popin-'+Ha.id+'-'+e.options.name;if(typeof Ha.$popins[e.id]=='undefined'){if(typeof e.options.name!='string'||e.options.name=='')throw Error('`options.name` can not be left `empty` or `undefined`');if(Mb.indexOf(e.options.name)>-1)throw Error('`popin '+e.options.name+
|
|
563
563
|
'` already exists !');Mb.push(e.options.name);typeof e.options.validator!='undefined'&&(vb=e.options.validator,e.validateFormById=vb.validateFormById);e.options['class']='gina-popin-container '+e.options['class'];e.name=e.options.name;e.target=Ha.target;e.load=ha;e.loadContent=jb;e.open=Oa;e.close=Wa;GINA_ENV_IS_DEV&&(e.updateToolbar=sa);e.parentScripts=[];e.parentStyles=[];g=gina.config.hostname.replace(/(https|http|):\/\//,'').replace(/:\d+$/,'');g=new RegExp(g+':\\d+|'+g);var x=document.getElementsByTagName('script');
|
|
564
564
|
for(let Q=0,wa=x.length;Q<wa;Q++){if(!x[Q].src||x[Q].src=='')continue;var aa=x[Q].src.replace(/(https|http|):\/\//,'').replace(g,'');e.parentScripts[Q]=aa}x=document.getElementsByTagName('link');for(let Q=0,wa=x.length;Q<wa;Q++){if(typeof x[Q].rel=='undefined'||!/stylesheet/i.test(x[Q].rel))continue;aa=x[Q].href.replace(/(https|http|):\/\//,'').replace(g,'');e.parentStyles[Q]=aa}Ha.$popins[e.id]=e;u(e)}}this.plugin='popin';var mb='init loaded ready open close click destroy success error progress'.split(' ');
|
|
565
|
-
registerEvents(this.plugin,mb);var bb={options:{name:void 0,'class':'gina-popin-default',useDialogMode:!0,cancelOnOverlayClick:!1,preOpen:!1,loadingShell:null,modal:null},authorizedEvents:['ready','error'],events:{}};S&&typeof S.modal!='undefined'&&(bb.options.modal=S.modal);var Ha={plugin:this.plugin,id:'gina-popins-'+G(),on,eventData:{},$popins:
|
|
565
|
+
registerEvents(this.plugin,mb);var bb={options:{name:void 0,'class':'gina-popin-default',useDialogMode:!0,cancelOnOverlayClick:!1,preOpen:!1,loadingShell:null,modal:null},authorizedEvents:['ready','error'],events:{}};S&&typeof S.modal!='undefined'&&(bb.options.modal=S.modal);var Ha={plugin:this.plugin,id:'gina-popins-'+G(),on,eventData:{},$popins:h,activePopinId:null,getActivePopin:null,target:document,isReady:!1,initialized:!1},Ib={plugin:this.plugin,on,eventData:{},target:document,name:null,load:null,
|
|
566
566
|
loadContent:null,open:null,isOpen:!1,isRedirecting:!1,close:null,$forms:[],hasForm:!1,$headers:[]},vb=null,Mb=[],Hb=new RegExp('^popin\\.click\\.gina-popin-'+Ha.id),Pb=function(){var e=document.createElement('div');e.id=Ha.id;e.setAttribute('id',Ha.id);e.setAttribute('class','gina-popins');if(!bb.options.useDialogMode){var g=document.createElement('div');g.setAttribute('id','gina-popins-overlay');g.setAttribute('class','gina-popins-overlay');e.appendChild(g)}document.body.appendChild(e);Ha.target=
|
|
567
567
|
e;Ha.on=on;gina.popinContainer=Ha.id},Qb=function(e,g,x){addListener(gina,e,'click',function(aa){cancelEvent(aa);triggerEvent(gina,g,x)})},W=function(e){Ha.activePopinId=e;typeof gina.popin!='undefined'&&gina.popin&&(gina.popin.activePopinId=e)},pa=function(e){return typeof Ha.$popins[e]!='undefined'?Ha.$popins[e]:null},ea=function(e){var g=null,x;for(x in Ha.$popins)if(Ha.$popins[x].name===e){g=Ha.$popins[x];break}return g},u=function(e,g){g=document.querySelectorAll('[data-gina-popin-name]');var x=
|
|
568
568
|
null,aa=null,Q=null,wa=null,Ka=aa=null,Qa=null;Ka=0;for(Qa=g.length;Ka<Qa;++Ka){x=g[Ka];aa=x.getAttribute('data-gina-popin-name');x.tagName=='A'&&(wa=x.getAttribute('href'),wa==''||wa=='#'||/#/.test(wa))&&(wa=null);wa||typeof x.getAttribute('data-gina-popin-url')=='undefined'||(wa=x.getAttribute('data-gina-popin-url'));if(!wa)throw Error('Found `data-gina-popin-name` without `url` !');x.url||(x.url=wa);x.popinName||(x.popinName=aa);if(aa==e.name&&(Q=x.id||x.getAttribute('id')||null,aa='popin.click.gina-popin-'+
|
|
@@ -571,78 +571,78 @@ this.getAttribute('href');if(!na)throw Error('Popin `url` not defined, please ch
|
|
|
571
571
|
var Ma=0;lLen=Q.length;if(lLen>0)for(;Ma<lLen;++Ma)typeof Q[Ma].tagName!='undefined'&&Qb(Q[Ma],x,aa)}}addListener(gina,document,'click',function(ya){if(!('disabled'in ya.target)&&ya.target.getAttribute('disabled')!=null&&ya.target.getAttribute('disabled')!='false')return!1;if(/^popin\.close\./.test(ya.target.id)){cancelEvent(ya);var B=ya.target.id;triggerEvent(gina,ya.target,B,ya.detail)}/^popin\.click\./.test(ya.target.id)&&(cancelEvent(ya),B=ya.target.id,Hb.test(B)&&triggerEvent(gina,ya.target,
|
|
572
572
|
B,ya.detail))});gina.popinIsBinded=!1},Z={url:'',method:'GET',isSynchrone:!1,withCredentials:!0,headers:{'X-Requested-With':'XMLHttpRequest'}};gina.hasPopinHandler?(Ha.target=document.getElementById(gina.popinContainer),Ha.on=on):Pb();U||new L(function(e,g){if(e)throw e;U=g});return function(e){Ha.getPopinById=pa;Ha.getPopinByName=ea;Ha.load=ha;Ha.loadContent=jb;Ha.getActivePopin=r;Ha.open=Oa;Ha.close=Wa;Ha.destroy=gb;ma();I();va();addListener(gina,Ha.target,'init.'+Ha.id,function(g){g=null;typeof Ha.$popins['gina-popin-'+
|
|
573
573
|
Ha.id+'-'+e.name]=='undefined'&&(g=O({},Ib),yb(g,e));Ha.isReady=!0;gina.hasPopinHandler=!0;typeof gina.popin!='undefined'&&gina.popin||(gina.popin=Ha);triggerEvent(gina,Ha.target,'ready.'+Ha.id,g)});Ha.initialized=!0;return Ha}(S)}});
|
|
574
|
-
function StoragePlugin(
|
|
574
|
+
function StoragePlugin(k){function G(S){h=JSON.parse(P.getItem(this.bucket));typeof h[S]=='undefined'&&(h[S]=[],P.setItem(this.bucket,JSON.stringify(h)),h=JSON.parse(P.getItem(this.bucket)));ba[S]={_collection:S,_bucket:this.bucket};ba[S]=L(ba[S],m);return ba[S]}function F(S){if(typeof S!=='object')throw Error('filter must be an object');var r=h[this._collection],V=S.count(),v=0,y=null;if(V==0)return null;for(var z in r)for(var l in S){var ja=typeof S[l]!='boolean'?S[l].toLocaleLowerCase():S[l];S[l]&&
|
|
575
575
|
J.indexOf(ja)>-1&&ja=='not null'&&typeof r[z][l]!='undefined'&&typeof r[z][l]!=='object'&&r[z][l]===S[l]&&r[z][l]!='null'&&r[z][l]!='undefined'?y.indexOf(r[z][l])<0&&(++v,v===V&&(y=r[z],y._index=z,y._collection=this._collection,y._bucket=this._bucket)):typeof r[z][l]!='undefined'&&typeof r[z][l]!=='object'&&r[z][l]===S[l]&&(++v,v===V&&(y=r[z],y._index=z,y._collection=this._collection,y._bucket=this._bucket,y._filter=S))}y&&(y.save=oa);return y}var L=L||require('lib/merge');G=G||require('lib/collection');
|
|
576
|
-
var U=U||require('lib/uuid'),q=q||require('helpers/dateFormat'),O={bucket:'default'},A={},P=null,ba={},
|
|
577
|
-
r){if(!S)return
|
|
578
|
-
findOne:F,update:null,'delete':function(S){if(typeof S!=='object')throw Error('filter must be an object');var r=JSON.clone(
|
|
579
|
-
r[y],
|
|
576
|
+
var U=U||require('lib/uuid'),q=q||require('helpers/dateFormat'),O={bucket:'default'},A={},P=null,ba={},h={},J=['not null'],w={bucket:void 0,drop:function(){P.removeItem(O.bucket);A=null;for(var S in this)delete this[S];return A},Collection:G},m={insert:function(S){S._id=Date.now().toString(36)+'-'+U(16);S._createdAt=(new Date).format('isoDateTime');S._updatedAt=(new Date).format('isoDateTime');h[this._collection][h[this._collection].length]=S;P.setItem(this._bucket,JSON.stringify(h))},find:function(S,
|
|
577
|
+
r){if(!S)return h[this._collection];if(typeof S!=='object')throw Error('filter must be an object');r=h[this._collection];S.count();var V=0,v=[],y;for(y in r)for(var z in S){var l=typeof S[z]!='boolean'?S[z].toLocaleLowerCase():S[z];S[z]&&J.indexOf(l)>-1&&l=='not null'&&typeof r[y][z]!='undefined'&&typeof r[y][z]!=='object'&&r[y][z]!='null'&&r[y][z]!='undefined'?v.indexOf(r[y][z])<0&&(v[V]=r[y][z],++V):typeof r[y][z]!='undefined'&&typeof r[y][z]!=='object'&&r[y][z]===S[z]&&(v[V]=r[y],++V)}return v},
|
|
578
|
+
findOne:F,update:null,'delete':function(S){if(typeof S!=='object')throw Error('filter must be an object');var r=JSON.clone(h[this._collection]),V=0,v=[],y;for(y in r)for(var z in S)S[z]&&J.indexOf(S[z].toLocaleLowerCase())>-1&&S[z].toLowerCase()=='not null'&&typeof r[y][z]!='undefined'&&typeof r[y][z]!=='object'&&r[y][z]!='null'&&r[y][z]!='undefined'?v.indexOf(r[y][z])<0&&(v[V]=r[y][z],delete h[this._collection][y][z],++V):typeof r[y][z]!='undefined'&&typeof r[y][z]!=='object'&&r[y][z]===S[z]&&(v[V]=
|
|
579
|
+
r[y],h[this._collection].splice(y,1),++V);return v.length>0?(P.setItem(this._bucket,JSON.stringify(h)),!0):!1},drop:function(S){if(typeof h[this._collection]=='undefined')throw Error('Collection `'+S+'` not found');delete ba[this._collection];delete h[this._collection];P.setItem(this._bucket,JSON.stringify(h))}},oa=function(S){S=S||!1;try{var r=JSON.clone(h),V=this._index,v=this._collection,y=this._bucket,z=this._filter;this._updatedAt=(new Date).format('isoDateTime');r[v][V]=L(r[v][V],this,!0);delete r[v][V]._index;
|
|
580
580
|
delete r[v][V]._collection;delete r[v][V]._bucket;delete r[v][V].save;delete r[v][V]._filter;if(S&&typeof r[v][V]=='object'){var l=function(M,T){for(var N=0,Y=M.length;N<Y;++N)typeof T[N]!='object'||typeof M[N]=='undefined'||Array.isArray(M[N])?Array.isArray(M[N])?l(M[N],T[N]):typeof M[N]=='undefined'&&delete T[N]:ja(M[N],T[N]);return T},ja=function(M,T){for(var N in T)typeof T[N]!='object'||typeof M[N]=='undefined'||Array.isArray(M[N])?Array.isArray(M[N])?l(M[N],T[N]):typeof M[N]=='undefined'&&delete T[N]:
|
|
581
|
-
ja(M[N],T[N]);return T};Array.isArray(r[v][V])?r[v][V]=l(this,r[v][V]):typeof r[v][V]=='object'?r[v][V]=ja(this,r[v][V]):typeof this[prop]=='undefined'&&delete r[v][V]}
|
|
582
|
-
if(typeof S!='object'&&typeof S!='undefined')throw Error('`options` must be an object');typeof S=='undefined'&&(S={});O=L(S,O);P=window.localStorage;S=O.bucket;if(!P.getItem(S)&&S!=void 0)P.setItem(S,JSON.stringify(
|
|
581
|
+
ja(M[N],T[N]);return T};Array.isArray(r[v][V])?r[v][V]=l(this,r[v][V]):typeof r[v][V]=='object'?r[v][V]=ja(this,r[v][V]):typeof this[prop]=='undefined'&&delete r[v][V]}h[v][V]=r[v][V];P.setItem(y,JSON.stringify(h));return F(z)}catch(M){throw M;}};(function(S){if(!window.localStorage||window.localStorage&&!typeof window.localStorage.setItem=='undefined')throw Error('Make sure your browser supports `window.localStorage` to use Gina Storage. See: `https://developer.mozilla.org/en-US/docs/Web/API/Web_Storage_API#Browser_compatibility`');
|
|
582
|
+
if(typeof S!='object'&&typeof S!='undefined')throw Error('`options` must be an object');typeof S=='undefined'&&(S={});O=L(S,O);P=window.localStorage;S=O.bucket;if(!P.getItem(S)&&S!=void 0)P.setItem(S,JSON.stringify(h));else if(S==void 0)throw Error('`bucket` name cannot be undefined');A.bucket=S;A=L(A,w)})(k);return A}
|
|
583
583
|
if(typeof module!=='undefined'&&module.exports){var merge=require('lib/merge');Collection=require('lib/collection');uuid=require('lib/uuid');module.exports=StoragePlugin}else typeof define==='function'&&define.amd&&define('gina/storage',['helpers/dateFormat','helpers/prototypes'],function(){return StoragePlugin});
|
|
584
|
-
define('gina/nav',['require','lib/merge','lib/uuid','utils/events'],function(
|
|
584
|
+
define('gina/nav',['require','lib/merge','lib/uuid','utils/events'],function(k){var G=k('lib/merge'),F=k('lib/uuid');k('utils/events');return function(L){this.plugin='nav';registerEvents(this.plugin,['init','ready','navigate','success','error']);var U={timeout:1E4},q={plugin:this.plugin,id:'gina-nav-'+F(),on,eventData:{},target:document,isReady:!1,initialized:!1},O=0,A=null,P=null,ba=null,h=[],J=[],w=null,m=!1,oa=function(z,l){z=String(z).split(/\//);for(var ja=[],M=0,T=z.length;M<T;++M){var N=z[M];
|
|
585
585
|
if(N.indexOf(':')<0)ja.push({lit:N});else{if(!/^:[-_a-zA-Z0-9]+$/.test(N))return null;N=N.substring(1);if(l.requirements&&typeof l.requirements[N]!='undefined'){a:{var Y=String(l.requirements[N]);try{if(/^\//.test(Y)){var C=Y.match(/\/(.*)\//).pop(),I=Y.replace('/'+C+'/','');var la=new RegExp(C,I);break a}la=new RegExp(Y);break a}catch(va){la=null;break a}la=void 0}if(!la)return null;ja.push({key:N,re:la})}else if(l.param&&typeof l.param[N]!='undefined')ja.push({key:N,re:null});else return null}}return ja},
|
|
586
586
|
S=function(){var z=window.gina&&window.gina.config?window.gina.config:null,l=z&&z.routing&&typeof z.routing=='object'?z.routing:null;if(!l)return null;if(ba===l&&P)return P;z=z.bundle;var ja=[],M;for(M in l){var T=l[M];if(T&&typeof T=='object'&&typeof T.param!='undefined'&&T.bundle==z){var N=String(T.method||''),Y=/,/.test(N),C=N.replace(/\s+/g,'');if(Y||/^(get|delete)$/i.test(C)){N=Y?/(^|,)\s*get\s*(,|$)/i.test(N):/^get$/i.test(C);Y=String(T.url).split(/,/g);C=[];for(var I=0,la=Y.length;I<la;++I)C.push(oa(Y[I],
|
|
587
587
|
T));ja.push({rule:M,route:T,isGet:N,variants:C,rawUrl:String(T.url)})}}}P=ja;ba=l;return ja},r=function(z){var l=S();if(!l)return null;try{var ja=decodeURI(z)}catch(ma){ja=z}for(var M=ja.split(/\//),T=0,N=l.length;T<N;++T){var Y=l[T];if(z===Y.rawUrl||ja===Y.rawUrl)return{rule:Y.rule,route:Y.route,isGet:Y.isGet};for(var C=0,I=Y.variants.length;C<I;++C){var la=Y.variants[C];if(la&&la.length===M.length){for(var va=!0,H=0,da=la.length;H<da;++H)if(typeof la[H].lit!='undefined'){if(la[H].lit!==M[H]){va=
|
|
588
588
|
!1;break}}else{if(!M[H]){va=!1;break}if(la[H].re&&!la[H].re.test(M[H])){va=!1;break}}if(va)return{rule:Y.rule,route:Y.route,isGet:Y.isGet}}}}return null},V=function(z,l,ja){q.eventData.error=ja||{};triggerEvent(gina,q.target,'error.'+q.id,q.eventData.error);l?window.location.reload():window.location.href=z},v=function(z,l){if(z&&typeof z=='string')if(q.isReady&&q.target!==document){var ja=l&&l.isPopState?!0:!1,M=++O;if(A&&A.readyState!==4)try{A.abort()}catch(N){}q.eventData.navigate={url:z,isPopState:ja};
|
|
589
589
|
triggerEvent(gina,q.target,'navigate.'+q.id,q.eventData.navigate);var T=new XMLHttpRequest;A=T;T.open('GET',z);T.setRequestHeader('X-Gina-Navigate','fragment');T.setRequestHeader('X-Requested-With','XMLHttpRequest');T.timeout=U.timeout;T.onreadystatechange=function(){if(T.readyState===4&&M===O){var N=T.status;if(/^2/.test(String(N))){var Y=T.getResponseHeader('Content-Type')||'';if(/application\/json/.test(Y)){var C=null;try{C=JSON.parse(T.responseText)}catch(xa){}C&&typeof C.location!='undefined'&&
|
|
590
|
-
C.location?window.location.href=C.location:V(z,ja,{status:N,error:'unexpected JSON answer to a fragment request'})}else if(Y=T.getResponseHeader('Vary')||'',/x-gina-navigate/i.test(Y)){Y=T.responseText;N=q.target;N.innerHTML=typeof Y=='string'?Y.trim():'';Y=N.getElementsByTagName('script');for(var I=0,la=Y.length;I<la;++I){var va=Y[I].src;if(va&&!(
|
|
590
|
+
C.location?window.location.href=C.location:V(z,ja,{status:N,error:'unexpected JSON answer to a fragment request'})}else if(Y=T.getResponseHeader('Vary')||'',/x-gina-navigate/i.test(Y)){Y=T.responseText;N=q.target;N.innerHTML=typeof Y=='string'?Y.trim():'';Y=N.getElementsByTagName('script');for(var I=0,la=Y.length;I<la;++I){var va=Y[I].src;if(va&&!(h.indexOf(va)>-1||J.indexOf(va)>-1)){var H=document.createElement('script');H.src=va;document.head.appendChild(H);J.push(va)}}if(Y=typeof N.querySelector==
|
|
591
591
|
'function'?N.querySelector('[data-gina-nav-title]'):null)if(Y=Y.getAttribute('data-gina-nav-title'))document.title=Y;if(!ja){try{var da=window.history.state||{};da.ginaNav=!0;da.scroll=[window.pageXOffset||0,window.pageYOffset||0];window.history.replaceState(da,'',window.location.href)}catch(xa){}try{window.history.pushState({ginaNav:!0},'',z)}catch(xa){}}w=window.location.pathname+window.location.search;try{N.getAttribute('tabindex')||N.setAttribute('tabindex','-1'),N.focus({preventScroll:!0})}catch(xa){try{N.focus()}catch(ta){}}(da=
|
|
592
592
|
ja&&l&&l.scroll?l.scroll:null)?window.scrollTo(da[0]||0,da[1]||0):(da=(da=z.indexOf('#')>-1?z.substring(z.indexOf('#')+1):null)?document.getElementById(da):null)&&typeof da.scrollIntoView=='function'?da.scrollIntoView():window.scrollTo(0,0);try{if(gina.hasPopinHandler&&gina.popin&&typeof gina.popin.getActivePopin=='function'){var ma=gina.popin.getActivePopin();ma&&ma.isOpen&&typeof gina.popin.close=='function'&&gina.popin.close(ma.name)}}catch(xa){}try{if(gina.hasValidator&&gina.validator&&typeof gina.validator.validateFormById==
|
|
593
593
|
'function'){C=N.getElementsByTagName('form');ma=0;for(var ia=C.length;ma<ia;++ma){var sa=C[ma].getAttribute('id');if(sa)try{gina.validator.validateFormById(sa)}catch(xa){console.warn('[gina][nav] validator rebind skipped for `'+sa+'`: '+(xa.message||xa))}}}}catch(xa){}q.eventData.success={url:z,target:N,isPopState:ja};triggerEvent(gina,q.target,'success.'+q.id,q.eventData.success)}else V(z,ja,{status:N,error:'response is not negotiated (no `Vary: X-Gina-Navigate`)'})}else V(z,ja,{status:N||0,error:T.statusText||
|
|
594
594
|
'network error or timeout'})}};T.send()}else window.location.href=z},y=function(){m||(m=!0,addListener(gina,document,'click',function(z){try{if(!(z.defaultPrevented||typeof z.button=='number'&&z.button!==0||z.ctrlKey||z.metaKey||z.shiftKey||z.altKey)){var l=z.target&&typeof z.target.closest=='function'?z.target.closest('a[href]'):null;if(l&&l.getAttribute('data-gina-link')==null&&l.getAttribute('data-gina-link-url')==null&&l.getAttribute('data-gina-dialog')==null&&l.getAttribute('data-gina-dialog-src')==
|
|
595
595
|
null&&l.getAttribute('data-gina-popin-name')==null&&l.getAttribute('data-gina-popin-url')==null&&!/^false$/i.test(l.getAttribute('data-gina-nav'))){var ja=l.getAttribute('target');if((!ja||/^_self$/i.test(ja))&&l.getAttribute('download')==null){var M=l.getAttribute('href');if(M&&!/^#/.test(M)&&l.protocol===window.location.protocol&&l.host===window.location.host&&(l.pathname!==window.location.pathname||l.search!==window.location.search||!l.hash)){var T=r(l.pathname);T&&T.route.negotiate===!0&&T.isGet&&
|
|
596
596
|
(cancelEvent(z),v(l.pathname+l.search+l.hash))}}}}}catch(N){console.warn('[gina][nav] click interception skipped: '+(N.message||N))}}),window.addEventListener('popstate',function(z){try{var l=window.location.pathname+window.location.search;if(l!==w){var ja=z.state;ja&&ja.ginaNav?v(l+window.location.hash,{isPopState:!0,scroll:ja.scroll||null}):window.location.reload()}}catch(M){window.location.reload()}}))};return function(z){q.navigate=v;q.matchUrl=r;q.on('init',function(l){U=G(z||{},U);l=null;try{l=
|
|
597
|
-
document.querySelector('[data-gina-nav]:not([data-gina-nav="false"])')}catch(N){}if(l){q.target=l;w=window.location.pathname+window.location.search;l=document.getElementsByTagName('script');for(var ja=0,M=l.length;ja<M;++ja)l[ja].src&&
|
|
597
|
+
document.querySelector('[data-gina-nav]:not([data-gina-nav="false"])')}catch(N){}if(l){q.target=l;w=window.location.pathname+window.location.search;l=document.getElementsByTagName('script');for(var ja=0,M=l.length;ja<M;++ja)l[ja].src&&h.push(l[ja].src);try{window.history&&'scrollRestoration'in window.history&&(window.history.scrollRestoration='manual');var T=window.history.state||{};T.ginaNav=!0;window.history.replaceState(T,'',window.location.href)}catch(N){}y();q.isReady=!0;gina.hasNavHandler=!0;
|
|
598
598
|
typeof gina.nav!='undefined'&&gina.nav||(gina.nav=q)}else console.warn('[gina][nav] no [data-gina-nav] region found \u2014 navigation interception stays off'),q.isReady=!0;triggerEvent(gina,q.target,'ready.'+q.id,q)});q.initialized=!0;return q}(L)}});
|
|
599
|
-
typeof Object.assign!=='function'&&Object.defineProperty(Object,'assign',{value:function(
|
|
600
|
-
if(typeof JSON.clone=='undefined'){var clone=function(
|
|
601
|
-
clone}if(typeof JSON.escape=='undefined'){var escape=function(
|
|
602
|
-
function Inherits(
|
|
599
|
+
typeof Object.assign!=='function'&&Object.defineProperty(Object,'assign',{value:function(k,G){if(k===null||k===void 0)throw new TypeError('Cannot convert undefined or null to object');for(var F=Object(k),L=1;L<arguments.length;L++){var U=arguments[L];if(U!==null&&U!==void 0)for(var q in U)Object.prototype.hasOwnProperty.call(U,q)&&(F[q]=U[q])}return F},writable:!0,configurable:!0});
|
|
600
|
+
if(typeof JSON.clone=='undefined'){var clone=function(k,G){if(k==null||typeof k!='object'||k.constructor!=Object&&k.constructor!=Array)return k;if(k.constructor==Date||k.constructor==RegExp||k.constructor==Function||k.constructor==String||k.constructor==Number||k.constructor==Boolean)return new k.constructor(k);G=G||new k.constructor;for(var F=0,L=Object.getOwnPropertyNames(k).length||0,U=Object.keys(k);F<L;)G[U[F]]=typeof G[U[F]]=='undefined'?clone(k[U[F]],null):G[U[F]],F++;return G};JSON.clone=
|
|
601
|
+
clone}if(typeof JSON.escape=='undefined'){var escape=function(k){try{return k.replace(/\n/g,'\\n').replace(/\r/g,'\\r').replace(/\t/g,'\\t')}catch(G){throw G;}};JSON.escape=escape}define('utils/polyfill',function(){});
|
|
602
|
+
function Inherits(k,G){return function(F,L){var U=typeof F=='undefined'||typeof L=='undefined'?"inherits(a, b): neither [ a ] nor [ b ] can't be undefined or null":!1;if(U)throw Error(U);U=function(){return function(){if(this){this.prototype=F.prototype;this.name||(this.name=F.name);this.prototype.name=this.name;for(var q in L.prototype)this[q]||(this[q]=L.prototype[q]);L.apply(this,arguments);F.apply(this,arguments)}}}(F,L);F.prototype==void 0&&(F.prototype={});L.prototype==void 0&&(L.prototype=
|
|
603
603
|
{});F.prototype=Object.create(L.prototype,{});U.prototype=Object.create(F.prototype,{});return U}}typeof module!=='undefined'&&module.exports?module.exports=Inherits():typeof define==='function'&&define.amd&&define('lib/inherits',[],function(){return Inherits()});
|
|
604
|
-
function Collection(
|
|
605
|
-
J=function(v){var y=v.match(/^\s*new\s+Date\("([^"]*)"\)\s*$/);if(y)return new Date(y[1]);y=v.replace(/^\s+|\s+$/g,'');if(/^"[^"]*"$/.test(y))return y.slice(1,-1);var z=Number(y);if(!isNaN(z)&&y!=='')return z;throw Error('Invalid operand: `'+v+'`');},w=function(v){var y=typeof v=='string'?v.match(
|
|
606
|
-
l=y[2],ja=J(y[3]);if(l==='<'||l==='>'||l==='<='||l==='>=')z instanceof Date&&(z=z.getTime()),ja instanceof Date&&(ja=ja.getTime());switch(l){case '===':return z===ja;case '!==':return z!==ja;case '==':return z==ja;case '!=':return z!=ja;case '<':return z<ja;case '>':return z>ja;case '<=':return z<=ja;case '>=':return z>=ja}}catch(M){throw Error('Could not evaluate condition `'+v+'`.\n'+M.stack);}};if(typeof
|
|
607
|
-
|
|
604
|
+
function Collection(k,G){var F=typeof module!=='undefined'&&module.exports?!1:!0,L=F?require('lib/uuid'):require('../../../lib/uuid'),U=F?require('lib/merge'):require('../../../lib/merge'),q={isCaseSensitive:{false:{re:'^%s$',modifiers:'i'},true:{re:'^%s$'}},skipEval:!1},O=!1,A=!1,P=null;F={useLocalStorage:!1,locale:'en',searchOptionRules:q};G=typeof G=='object'?U(G,F):F;var ba=['not null'],h=/^\s*(new\s+Date\("[^"]*"\)|"[^"]*"|-?\d+(?:\.\d+)?)\s*(===|!==|<=|>=|==|!=|<|>)\s*(new\s+Date\("[^"]*"\)|"[^"]*"|-?\d+(?:\.\d+)?)\s*$/,
|
|
605
|
+
J=function(v){var y=v.match(/^\s*new\s+Date\("([^"]*)"\)\s*$/);if(y)return new Date(y[1]);y=v.replace(/^\s+|\s+$/g,'');if(/^"[^"]*"$/.test(y))return y.slice(1,-1);var z=Number(y);if(!isNaN(z)&&y!=='')return z;throw Error('Invalid operand: `'+v+'`');},w=function(v){var y=typeof v=='string'?v.match(h):null;if(!y)throw Error('Could not evaluate condition `'+v+'`.\n(grammar: <operand><op><operand>; operand \u2208 number | "string" | new Date("..."); op \u2208 === !== == != < > <= >=)');try{var z=J(y[1]),
|
|
606
|
+
l=y[2],ja=J(y[3]);if(l==='<'||l==='>'||l==='<='||l==='>=')z instanceof Date&&(z=z.getTime()),ja instanceof Date&&(ja=ja.getTime());switch(l){case '===':return z===ja;case '!==':return z!==ja;case '==':return z==ja;case '!=':return z!=ja;case '<':return z<ja;case '>':return z>ja;case '<=':return z<=ja;case '>=':return z>=ja}}catch(M){throw Error('Could not evaluate condition `'+v+'`.\n'+M.stack);}};if(typeof k=='undefined'||k==''||k==null)k=[];if(!Array.isArray(k))throw Error('`new Collection([content] [, options] )`: `content` argument must be an Array !');
|
|
607
|
+
k=k?JSON.clone(k):[];for(var m=[],oa=F=0,S=k.length;oa<S;++oa)k[oa]||(k[oa]={}),typeof k[oa]._uuid!='undefined'?k[oa]._hasItsOwnUuid=!0:k[oa]._uuid=L(16),m[F]=k[oa]._uuid,++F;var r=k;r.setSearchOption=function(){if(!arguments.length)throw Error('searchOption cannot be left blank');if(arguments.length>3||arguments.length<3&&arguments.length>1)throw Error('argument length mismatch');var v=0,y=arguments.length;if(y==1){if(typeof arguments[0]!='object')throw Error('searchOption must be an object');for(var z in arguments[0])if(typeof q[z]==
|
|
608
608
|
'undefined')throw Error(arguments[1]+' is not an allowed searchOption !');P=arguments[0]}else for(P||={};v<y;++v){if(typeof q[arguments[1]]=='undefined')throw Error(arguments[1]+' is not an allowed searchOption !');typeof P[arguments[0]]=='undefined'&&(P[arguments[0]]={});/true|false/i.test(arguments[2])?P[arguments[0]][arguments[1]]=/true/i.test(arguments[2])?!0:!1:P[arguments[0]][arguments[1]]=arguments[2]}return r};r.find=function(){O=!1;typeof arguments[arguments.length-1]=='boolean'&&(O=arguments[arguments.length-
|
|
609
|
-
1],delete arguments[arguments.length-1],--arguments.length);for(var v=0,y=arguments.length,z=null,l=null;v<y;++v)if((z=arguments[v])&&typeof z=='object'&&!Array.isArray(z))for(l in z)if(typeof z[l]=='undefined')throw Error('filter `'+l+'` cannot be left undefined');z=v=y=z=null;try{y=JSON.stringify(arguments),v=JSON.parse(y),z=v.count()}catch(sa){throw Error('filter must be an object\n'+sa.stack);}if(typeof v!='undefined'&&z>0){z>1&&(O=!0);z=y=null;l=0;var ja=Array.isArray(this)?this:JSON.clone(
|
|
609
|
+
1],delete arguments[arguments.length-1],--arguments.length);for(var v=0,y=arguments.length,z=null,l=null;v<y;++v)if((z=arguments[v])&&typeof z=='object'&&!Array.isArray(z))for(l in z)if(typeof z[l]=='undefined')throw Error('filter `'+l+'` cannot be left undefined');z=v=y=z=null;try{y=JSON.stringify(arguments),v=JSON.parse(y),z=v.count()}catch(sa){throw Error('filter must be an object\n'+sa.stack);}if(typeof v!='undefined'&&z>0){z>1&&(O=!0);z=y=null;l=0;var ja=Array.isArray(this)?this:JSON.clone(k),
|
|
610
610
|
M=[],T='',N=null,Y=P,C=G.searchOptionRules,I=null,la=[],va=function(sa,xa,ta,Fa,ha){P&&typeof P[xa]!='undefined'&&(ha=U(P,ha));if(sa===null&&ta===null)++Fa;else if(sa&&ba.indexOf(T)>-1&&T=='not null'&&typeof ta!='undefined'&&typeof ta!=='object'&&ta!='null'&&ta!='undefined')M.indexOf(ta)<0&&++Fa;else if(typeof ta!='undefined'&&typeof ta!=='object'&&/(<|>|=)/.test(sa)&&!/undefined|function/.test(typeof ta)&&!ha.skipEval)xa=sa,ha=ta+sa,typeof sa=='string'&&typeof ta=='string'&&(ha=sa.replace(/^(<=|>=|!==|!=|===|!==)/g,
|
|
611
611
|
''),typeof ta!='string'||/^"(.*)"$/.test(ha)||(sa=sa.replace(ha,'"'+ha+'"')),ha='"'+ta+'"'+sa,sa=xa),/(\d{4})\-(\d{2})\-(\d{2})(\s+|T)(\d{2}):(\d{2}):(\d{2})/.test(ta)&&/(\d{4})\-(\d{2})\-(\d{2})(\s+|T)(\d{2}):(\d{2}):(\d{2})/.test(sa)?w(ta.replace(/(\d{4})\-(\d{2})\-(\d{2})(\s+|T)(\d{2}):(\d{2}):(\d{2})/,'new Date("$&")')+sa.replace(/(\d{4})\-(\d{2})\-(\d{2})(\s+|T)(\d{2}):(\d{2}):(\d{2})/,'new Date("$&")'))&&++Fa:w(ha)&&++Fa;else if(typeof ta!='undefined'&&typeof ta!=='object'&&ta===sa&&!Y||typeof ta!=
|
|
612
612
|
'undefined'&&typeof ta!=='object'&&ta===sa&&typeof Y[xa]=='undefined'||typeof ta!='undefined'&&typeof ta!=='object'&&ta===sa&&typeof Y[xa]!='undefined'&&ha.skipEval)++Fa;else if(typeof ta!='undefined'&&typeof ta!=='object'&&Y&&typeof Y[xa]!='undefined'){var jb=0;var ua=Y[xa].count();for(let za in Y[xa])typeof ha[za][Y[xa][za]]!='undefined'&&(ha[za][Y[xa][za]].re=ha[za][Y[xa][za]].re.replace(/%s/,sa),N=ha[za][Y[xa][za]].modifiers?new RegExp(ha[za][Y[xa][za]].re,ha[za][Y[xa][za]].modifiers):new RegExp(ha[za][Y[xa][za]].re),
|
|
613
613
|
N.test(ta)&&++jb);jb==ua&&++Fa}return{matched:Fa}},H=function(sa,xa,ta,Fa){var ha=xa.split(/\./g);ha=ha[ha.length-1];N=new RegExp('("'+ha+'":\\w+)');ha=null;try{if(ta){if(!/^[A-Za-z_$][\w$]*(\.[A-Za-z_$][\w$]*)*$/.test(xa))throw Error('Invalid property path: `'+xa+'`');var jb=xa.split('.');xa=ta;for(ta=0;xa!=null&&ta<jb.length;ta++)xa=xa[jb[ta]];ha=xa}}catch(ua){}ha&&(Array.isArray(ha)?ha=ha[1].split(/:/)[1]:typeof ha=='string'&&/:/.test(ha)&&(ha=ha.split(/:/)[1]),/(<|>|=)/.test(sa)?/(\d{4})\-(\d{2})\-(\d{2})(\s+|T)(\d{2}):(\d{2}):(\d{2})/.test(ha)&&
|
|
614
614
|
/(\d{4})\-(\d{2})\-(\d{2})(\s+|T)(\d{2}):(\d{2}):(\d{2})/.test(sa)?w(ha.replace(/(\d{4})\-(\d{2})\-(\d{2})(\s+|T)(\d{2}):(\d{2}):(\d{2})/,'new Date("$&")')+sa.replace(/(\d{4})\-(\d{2})\-(\d{2})(\s+|T)(\d{2}):(\d{2}):(\d{2})/,'new Date("$&")'))&&++Fa:w(ha+sa)&&++Fa:ha==sa&&++Fa);return{matched:Fa}},da=function(sa,xa,ta,Fa,ha){xa=xa.split(/\[\*\]/g);ha=xa[0].replace(/\[\*\]/,'');ta=ta[ha];xa=xa[1];/^\./.test(xa)&&(xa=xa.substring(1));ha=0;if(ta)for(var jb=0,ua=ta.length;jb<ua&&!(la=/\./.test(xa)?H(sa,
|
|
615
615
|
xa,ta[jb],ha):va(sa,xa,ta[jb],ha,C),ha=la.matched,ha>0);++jb);return{matched:Fa+ha}},ma;for(ma in ja)if(ja[ma]||(ja[ma]={}),!/undefined|function/.test(typeof ja[ma]))for(let sa=0,xa=v.count();sa<xa;++sa){y=v[sa];z=y.count();I=0;for(var ia in y){if(typeof y[ia]=='undefined')throw Error('filter `'+ia+'` cannot be left undefined');T=y[ia]===null||/(boolean|number)/.test(typeof y[ia])?y[ia]:y[ia].toLocaleLowerCase();la=/\./.test(ia)?/\[\*\]/.test(ia)?da(y[ia],ia,ja[ma],I,0):H(y[ia],ia,ja[ma],I):va(y[ia],
|
|
616
|
-
ia,ja[ma][ia],I,C);I=la.matched}if(I==z)if(O&&A&&m.indexOf(ja[ma]._uuid)<0||A||!O){if(!O||O&&M.indexOf(ja[ma]._uuid)<0||A)M[l]=ja[ma],++l}else O&&!A&&M.indexOf(ja[ma]._uuid)<0&&(M[l]=ja[ma],++l)}}else M=
|
|
616
|
+
ia,ja[ma][ia],I,C);I=la.matched}if(I==z)if(O&&A&&m.indexOf(ja[ma]._uuid)<0||A||!O){if(!O||O&&M.indexOf(ja[ma]._uuid)<0||A)M[l]=ja[ma],++l}else O&&!A&&M.indexOf(ja[ma]._uuid)<0&&(M[l]=ja[ma],++l)}}else M=k;P=null;M.insert=r.insert;M.notIn=r.notIn;M.find=this.find;M.update=r.update;M.replace=r.replace;M.or=r.or;M.findOne=r.findOne;M.limit=r.limit;M.orderBy=r.orderBy;M.delete=r.delete;M.toRaw=r.toRaw;M.filter=r.filter;return M};r.findOne=function(){var v=null;typeof arguments[arguments.length-1]=='string'&&
|
|
617
617
|
(delete arguments[arguments.length-1],--arguments.length);arguments.length>0&&(v=arguments);if(typeof v=='undefined'||!v||typeof v!='object')throw Error('[ Collection ][ findOne ] `filters` argument must be defined: Array or Filter Object(s) expected');v=null;var y=Array.isArray(arguments[0])?arguments[0]:r.find.apply(this,arguments)||[];y.length>0&&(v=y.limit(1).toRaw()[0]);return v};r.or=function(){arguments[arguments.length]=!0;++arguments.length;return r.find.apply(this,arguments)};r.limit=function(v){if(typeof v==
|
|
618
|
-
'undefined'||typeof v!='number')throw Error('[Collection::result->limit(resultLimit)] : `resultLimit` parametter must by a `number`');var y=Array.isArray(this)?this:JSON.clone(
|
|
619
|
-
1],delete arguments[arguments.length-1],--arguments.length);typeof arguments[arguments.length-1]=='boolean'&&(z=arguments[arguments.length-1],delete arguments[arguments.length-1],--arguments.length);arguments.length>0&&(y=arguments);if(typeof y=='undefined'||!y||typeof y!='object')throw Error('[ Collection ][ notIn ] `filters` argument must be defined: Array or Filter Object(s) expected');var l=JSON.clone(Array.isArray(this)?this:
|
|
618
|
+
'undefined'||typeof v!='number')throw Error('[Collection::result->limit(resultLimit)] : `resultLimit` parametter must by a `number`');var y=Array.isArray(this)?this:JSON.clone(k);y=y.splice(0,v);y.insert=r.insert;y.update=r.update;y.replace=r.replace;y.notIn=r.notIn;y.findOne=r.findOne;y.orderBy=r.orderBy;y.max=r.max;y.delete=r.delete;y.toRaw=r.toRaw;y.filter=r.filter;return y};r.notIn=function(){var v=null,y=null,z=!0;typeof arguments[arguments.length-1]=='string'&&(v=arguments[arguments.length-
|
|
619
|
+
1],delete arguments[arguments.length-1],--arguments.length);typeof arguments[arguments.length-1]=='boolean'&&(z=arguments[arguments.length-1],delete arguments[arguments.length-1],--arguments.length);arguments.length>0&&(y=arguments);if(typeof y=='undefined'||!y||typeof y!='object')throw Error('[ Collection ][ notIn ] `filters` argument must be defined: Array or Filter Object(s) expected');var l=JSON.clone(Array.isArray(this)?this:k);if(Array.isArray(arguments[0]))var ja=arguments[0];else A=!0,ja=
|
|
620
620
|
r.find.apply(this,arguments)||[],A=!1;if(ja.length>0){if(z&&v&&typeof ja[0]=='undefined'&&typeof ja[0][v]=='undefined')throw Error('[ Collection ][ notIn ] `key` not valid');z&&!v&&typeof ja[0]._uuid!='undefined'?v='_uuid':typeof ja[0].id!='undefined'&&(v='id');if(!v||typeof ja[0][v]=='undefined')throw Error('No comparison key defined !');var M=0,T=ja.length,N=0,Y,C=y.count(),I;if(z&&typeof l[N]!='undefined'&&l[N].hasOwnProperty(v))for(;M<T&&l.length;++M)for(N=0,z=l.length;N<z;++N){if(typeof l[N]!=
|
|
621
621
|
'undefined'&&typeof ja[M]!='undefined'&&l[N][v]===ja[M][v]){l.splice(N,1);break}}else if(typeof l[N]=='undefined')l=JSON.clone(ja);else for(;M<T&&l.length;++M)for(N=0,z=l.length;N<z;++N)if(typeof l[N]!='undefined'){for(Y=I=0;Y<C;++Y){if(typeof y[Y]=='undefined')throw Error('filter `'+Y+'` cannot be left undefined');var la=y[Y].count();var va=0;for(v in y[Y])l[N].hasOwnProperty(v)&&l[N][v]===ja[M][v]&&++va;va==la&&++I}if(I){l.splice(N,1);break}}}v=l;v.notIn=r.notIn;v.limit=r.limit;v.find=r.find;v.findOne=
|
|
622
|
-
r.findOne;v.insert=r.insert;v.replace=r.replace;v.update=r.update;v.orderBy=r.orderBy;v.max=r.max;v.delete=r.delete;v.toRaw=r.toRaw;v.filter=r.filter;return v};r.insert=function(v){if(typeof v!=='object')throw Error('filter must be an object');var y=Array.isArray(this)?this:
|
|
622
|
+
r.findOne;v.insert=r.insert;v.replace=r.replace;v.update=r.update;v.orderBy=r.orderBy;v.max=r.max;v.delete=r.delete;v.toRaw=r.toRaw;v.filter=r.filter;return v};r.insert=function(v){if(typeof v!=='object')throw Error('filter must be an object');var y=Array.isArray(this)?this:k;v._uuid=L(16);y.push(v);y.limit=r.limit;y.find=r.find;y.findOne=r.findOne;y.update=r.update;y.replace=r.replace;y.orderBy=r.orderBy;y.max=r.max;y.notIn=r.notIn;y.delete=r.delete;y.toRaw=r.toRaw;y.filter=r.filter;return y};r.update=
|
|
623
623
|
function(){var v='_uuid',y,z=y=null;typeof arguments[arguments.length-1]=='string'&&(v=arguments[arguments.length-1],delete arguments[arguments.length-1],--arguments.length);typeof arguments[arguments.length-1]=='object'&&(z=arguments[arguments.length-1],delete arguments[arguments.length-1],--arguments.length);arguments.length>0&&(y=arguments);if(typeof y=='undefined'||!y||typeof y!='object')throw Error('[ Collection ][ update ] `filters` argument must be defined: Array or Filter Object(s) expected');
|
|
624
|
-
if(typeof z=='undefined'||!z||typeof z!='object')throw Error('[ Collection ][ update ] `set` argument must be defined: Object expected');var l=Array.isArray(arguments[0])?arguments[0]:r.find.apply(this,arguments)||[];y=Array.isArray(this)?this:JSON.clone(
|
|
624
|
+
if(typeof z=='undefined'||!z||typeof z!='object')throw Error('[ Collection ][ update ] `set` argument must be defined: Object expected');var l=Array.isArray(arguments[0])?arguments[0]:r.find.apply(this,arguments)||[];y=Array.isArray(this)?this:JSON.clone(k);if(l.length>0){l=l.toRaw();for(var ja=0,M=l.length;ja<M;++ja){l[ja]=U(JSON.clone(z),l[ja]);for(var T=0,N=y.length;T<N;++T)if(typeof y[T][v]=='undefined'&&v=='_uuid'&&typeof y[T].id!='undefined'&&(v='id'),y[T][v]==l[ja][v]){y[T]=l[ja];break}}}y.limit=
|
|
625
625
|
r.limit;y.find=r.find;y.findOne=r.findOne;y.insert=r.insert;y.update=r.update;y.replace=r.replace;y.orderBy=r.orderBy;y.max=r.max;y.notIn=r.notIn;y.delete=r.delete;y.toRaw=r.toRaw;y.filter=r.filter;return y};r.replace=function(){var v='_uuid',y=!1,z,l=z=null;typeof arguments[arguments.length-1]=='string'&&(v=arguments[arguments.length-1],y=!0,delete arguments[arguments.length-1],--arguments.length);typeof arguments[arguments.length-1]=='object'&&(l=arguments[arguments.length-1],delete arguments[arguments.length-
|
|
626
|
-
1],--arguments.length);arguments.length>0&&(z=arguments);if(typeof z=='undefined'||!z||typeof z!='object')throw Error('[ Collection ][ update ] `filters` argument must be defined: Array or Filter Object(s) expected');if(typeof l=='undefined'||!l||typeof l!='object')throw Error('[ Collection ][ update ] `set` argument must be defined: Object expected');var ja=Array.isArray(arguments[0])?arguments[0]:r.find.apply(this,arguments)||[];z=Array.isArray(this)?this:JSON.clone(
|
|
626
|
+
1],--arguments.length);arguments.length>0&&(z=arguments);if(typeof z=='undefined'||!z||typeof z!='object')throw Error('[ Collection ][ update ] `filters` argument must be defined: Array or Filter Object(s) expected');if(typeof l=='undefined'||!l||typeof l!='object')throw Error('[ Collection ][ update ] `set` argument must be defined: Object expected');var ja=Array.isArray(arguments[0])?arguments[0]:r.find.apply(this,arguments)||[];z=Array.isArray(this)?this:JSON.clone(k);if(ja.length>0){ja=ja.toRaw();
|
|
627
627
|
for(var M=0,T=ja.length;M<T;++M){ja[M]=JSON.clone(l);for(var N=0,Y=z.length;N<Y;++N){var C=v;if(!y&&(typeof z[N][C]!='undefined'&&typeof ja[M][C]!='undefined'||typeof z[N].id=='undefined'||typeof ja[M].id=='undefined'||(C='id'),typeof z[N][C]=='undefined'||typeof ja[M][C]=='undefined'))throw Error('No comparison key defined !');if(z[N][C]==ja[M][C]){z[N]=ja[M];break}}}}z.limit=r.limit;z.find=r.find;z.findOne=r.findOne;z.insert=r.insert;z.update=r.update;z.replace=r.replace;z.orderBy=r.orderBy;z.max=
|
|
628
628
|
r.max;z.notIn=r.notIn;z.delete=r.delete;z.toRaw=r.toRaw;z.filter=r.filter;return z};r['delete']=function(){var v=r.notIn.apply(this,arguments);v.limit=r.limit;v.find=r.find;v.findOne=r.findOne;v.insert=r.insert;v.update=r.update;v.replace=r.replace;v.orderBy=r.orderBy;v.max=r.max;v.notIn=r.notIn;v.toRaw=r.toRaw;v.filter=r.filter;v.delete=this.delete;return v};r.orderBy=function(){if(typeof arguments=='undefined'||arguments.length<1)throw Error('[ Collection->orderBy(filter) ] where `filter` must not be empty or null');
|
|
629
|
-
if(arguments.length==1)var v=arguments[0];else{v=Array(arguments.length);for(var y=0,z=v.length;y<z;++y)v[y]=arguments[y]}y=Array.isArray(this)?this:JSON.clone(
|
|
629
|
+
if(arguments.length==1)var v=arguments[0];else{v=Array(arguments.length);for(var y=0,z=v.length;y<z;++y)v[y]=arguments[y]}y=Array.isArray(this)?this:JSON.clone(k);return V(v,y.toRaw())};r.max=function(){if(typeof arguments=='undefined'||arguments.length<1)throw Error('[ Collection->max(filter) ] where `filter` must not be empty or null');if(arguments.length>1||Array.isArray(arguments[0])||typeof arguments[0]=='object'&&arguments[0].count()>1)throw Error('[ Collection->max(filter) ] only accept one filter length, and fileter count must be equal to 1');
|
|
630
630
|
var v=arguments[0];try{var y=Object.keys(v)[0],z={};z[y]='desc';return r.find(v).orderBy(z).limit(1)[0][y]}catch(l){throw l;}};var V=function(v,y){if(typeof v!='object')throw Error('`filter` parametter must be an object or an array');var z={},l=null,ja=null,M=l=null;l=[];if(v.count()==0)return null;z.asc=function(T,N){var Y=N.map(function(C,I){var la={};la.index=I;la[T]=C[T];return la});Y.sort(function(C,I){var la=function(va,H){/^(true|false)$/i.test(va)&&(va=/true/i.test(va)?1:0);/^(true|false)$/i.test(H)&&
|
|
631
631
|
(H=/true/i.test(H)?1:0);if(typeof va=='string'&&va!=''||typeof H=='string'){if(typeof va=='undefined'||va==null)va='';if(typeof H=='undefined'||H==null)H='';typeof va=='number'&&(va=''+va);typeof H=='number'&&(H=''+H);return va.localeCompare(H,void 0,{sensitivity:'case',caseFirst:'upper'})}return va>H?1:va<H?-1:0};return typeof C=='object'?la(C[T],I[T]):la(C,I)});return Y.map(function(C,I,la){return N[C.index]})};z.desc=function(T,N){return z.asc(T,N).reverse()};l=function(T,N){var Y=[],C=[];if(Array.isArray(N))for(var I=
|
|
632
632
|
0,la=N.length;I<la;++I)Y[I]=Object.keys(N[I])[0],C[I]=N[I][Y[I]];else for(la in I=0,N)Y[I]=la,C[I]=N[la],++I;ja=function(va,H,da,ma,ia){var sa=ma[ia]=='desc'?1:0,xa,ta=xa=null;return typeof va[da[ia]]=='string'&&va[da[ia]]!=''?(xa=va[da[ia]].localeCompare(H[da[ia]]),sa==0&&xa!=0?xa<0?-1:1:xa!=0?xa<0?1:-1:da.length-1>ia?ja(va,H,da,ma,ia+1):0):typeof va[da[ia]]=='number'||typeof H[da[ia]]=='number'?(xa=(''+va[da[ia]]).localeCompare(''+H[da[ia]],void 0,{numeric:!0}),sa==0&&xa!=0?xa<0?-1:1:xa!=0?xa<0?
|
|
633
633
|
1:-1:da.length-1>ia?ja(va,H,da,ma,ia+1):0):typeof va[da[ia]]=='boolean'||typeof H[da[ia]]=='boolean'?(typeof va[da[ia]]=='boolean'&&(xa=va[da[ia]]?1:0),typeof H[da[ia]]=='boolean'&&(ta=H[da[ia]]?1:0),xa>ta?sa==0?1:-1:xa<ta?sa==0?-1:1:da.length-1>ia?ja(va,H,da,ma,ia+1):0):va[da[ia]]>H[da[ia]]?sa==0?1:-1:va[da[ia]]<H[da[ia]]?sa==0?-1:1:da.length-1>ia?ja(va,H,da,ma,ia+1):0};return T.sort(function(va,H){return ja(va,H,Y,C,0)})};Array.isArray(v)||v.count()>1?l=l(y,v):(M=Object.keys(v)[0],l=v[M],l=z[l](M,
|
|
634
|
-
y));l.find=r.find;l.findOne=r.findOne;l.limit=r.limit;l.notIn=r.notIn;l.insert=r.insert;l.update=r.update;l.replace=r.replace;l.delete=r.delete;l.orderBy=r.orderBy;l.max=r.max;l.toRaw=r.toRaw;l.filter=r.filter;return l};r.toRaw=function(){for(var v=Array.isArray(this)?this.slice():
|
|
635
|
-
'undefined')throw Error('`filter` parametter must be a string or an array.');var y=Array.isArray(this)?this:
|
|
634
|
+
y));l.find=r.find;l.findOne=r.findOne;l.limit=r.limit;l.notIn=r.notIn;l.insert=r.insert;l.update=r.update;l.replace=r.replace;l.delete=r.delete;l.orderBy=r.orderBy;l.max=r.max;l.toRaw=r.toRaw;l.filter=r.filter;return l};r.toRaw=function(){for(var v=Array.isArray(this)?this.slice():k.slice(),y=0,z=v.length;y<z;++y){if(v[y]._hasItsOwnUuid){let l=/^true$/i.test(v[y]._hasItsOwnUuid)?!0:!1;delete v[y]._hasItsOwnUuid;if(l)continue}v[y]._uuid&&delete v[y]._uuid}return v};r.filter=function(v){if(typeof v==
|
|
635
|
+
'undefined')throw Error('`filter` parametter must be a string or an array.');var y=Array.isArray(this)?this:k;if(!y.length)return[];var z=0,l=y.length,ja=[],M=0;if(Array.isArray(v))for(var T,N=v.length,Y;z<l;++z){Y=!1;for(T=0;T<N;++T)typeof y[z][v[T]]!='undefined'&&(typeof ja[M]=='undefined'&&(ja[M]={}),ja[M][v[T]]=y[z][v[T]],Y=!0);Y&&++M}else for(;z<l;++z)typeof y[z][v]!='undefined'&&(typeof ja[M]=='undefined'&&(ja[M]={}),ja[M][v]=y[z][v],++M);return JSON.clone(ja)};return r}
|
|
636
636
|
typeof module!=='undefined'&&module.exports?module.exports=Collection:typeof define==='function'&&define.amd&&define('lib/collection',[],function(){return Collection});var readyList=[{name:'gina',ctx:window.gina,fn:window.onGinaLoaded}],readyFired=!1,readyEventHandlersInstalled=!1;
|
|
637
|
-
function ready(){if(!readyFired){readyFired=!0;var
|
|
637
|
+
function ready(){if(!readyFired){readyFired=!0;var k=null,G=function(F,L){if(L[F])if(L[F].name=='gina')var U=window.setInterval(function(q,O){try{if(typeof O=='undefined'&&(O=window.readyList),O[q].ctx=window.gina,k=O[q].fn.call(window,O[q].ctx,window.require))window.clearInterval(U),++q,G(q,O)}catch(A){throw window.clearInterval(U),A;}},50,F,L);else L[F].ctx=window.originalContext||null,L[F].fn.call(window,L[F].ctx,window.require),++F,G(F,L);else L=[]};G(0,readyList)}}
|
|
638
638
|
function readyStateChange(){document.readyState==='complete'&&gina.ready()}
|
|
639
|
-
if(typeof window.gina=='undefined'){var gina={_global:{register:function(
|
|
640
|
-
'interactive'?setTimeout(ready,1):readyEventHandlersInstalled||(document.addEventListener?(document.addEventListener('DOMContentLoaded',ready,!1),window.addEventListener('load',ready,!1)):(document.attachEvent('onreadystatechange',readyStateChange),window.attachEvent('onload',ready)),readyEventHandlersInstalled=!0))}};window.gina=gina}define('core',['require','gina'],function(
|
|
641
|
-
require('vendor/engine.io core helpers/prototypes helpers/binding helpers/dateFormat gina/link gina/validator gina/popin gina/storage gina/nav utils/dom utils/events utils/data utils/effects utils/polyfill lib/inherits lib/form-validator lib/collection lib/domain lib/routing lib/loading-state'.split(' '),function(){var
|
|
639
|
+
if(typeof window.gina=='undefined'){var gina={_global:{register:function(k){if(typeof k!='undefined')for(let G in k)window[G]=k[G]},unregister:function(k){if(typeof k=='undefined'||!Array.isArray(k))throw Error('`variables` needs to ba an array');for(let G=0,F=k.length;G<F;G++)delete window[k[G]]},initialized:[]},ready:function(k,G){readyFired?setTimeout(function(){k(G)},1):(readyList.push({name:'anonymous',fn:k,ctx:G}),document.readyState==='complete'||!document.attachEvent&&document.readyState===
|
|
640
|
+
'interactive'?setTimeout(ready,1):readyEventHandlersInstalled||(document.addEventListener?(document.addEventListener('DOMContentLoaded',ready,!1),window.addEventListener('load',ready,!1)):(document.attachEvent('onreadystatechange',readyStateChange),window.attachEvent('onload',ready)),readyEventHandlersInstalled=!0))}};window.gina=gina}define('core',['require','gina'],function(k){k('gina')(window.gina)});require.config({packages:['gina']});
|
|
641
|
+
require('vendor/engine.io core helpers/prototypes helpers/binding helpers/dateFormat gina/link gina/validator gina/popin gina/storage gina/nav utils/dom utils/events utils/data utils/effects utils/polyfill lib/inherits lib/form-validator lib/collection lib/domain lib/routing lib/loading-state'.split(' '),function(){var k=0,G=function(){try{if(!window.gina||!window.gina.isFrameworkLoaded)k++<100&&(window.setTimeout||function(A){A()})(G,50);else if(!window.gina.hasPopinHandler){var O=require('gina/popin');
|
|
642
642
|
if(typeof O=='function')(new O({name:'gina-dialog-boot'})).on('ready',function(){})}}catch(A){typeof console!='undefined'&&console.error&&console.error('[gina] popin boot failed',A.stack||A)}};G();var F=0,L=function(){try{if(!window.gina||!window.gina.isFrameworkLoaded)F++<100&&(window.setTimeout||function(ba){ba()})(L,50);else if(!window.gina.hasValidator){var O=window.gina.forms,A=O&&O.rules?O.rules:null;if(A&&Object.keys(A).length){var P=require('gina/validator');if(typeof P=='function')(new P(A)).on('ready',
|
|
643
643
|
function(){})}}}catch(ba){typeof console!='undefined'&&console.error&&console.error('[gina] validator boot failed',ba.stack||ba)}};L();var U=0,q=function(){try{if(!window.gina||!window.gina.isFrameworkLoaded)U++<100&&(window.setTimeout||function(A){A()})(q,50);else if(!window.gina.hasNavHandler&&typeof document.querySelector=='function'&&document.querySelector('[data-gina-nav]:not([data-gina-nav="false"])')){var O=require('gina/nav');if(typeof O=='function')(new O({})).on('ready',function(){})}}catch(A){typeof console!=
|
|
644
644
|
'undefined'&&console.error&&console.error('[gina] nav boot failed',A.stack||A)}};q()});
|
|
645
|
-
function getDependencies(
|
|
646
|
-
F.dispatchEvent(new CustomEvent('deps.loaded',{detail:{data:null,error:P,timestamp:new Date}}))}},args:['routing',{url:(typeof window!=='undefined'&&window.__ginaWebroot||
|
|
647
|
-
for(var tags=document.getElementsByTagName('script'),t=0,len=tags.length;t<len;++t)if(/(gina\.min\.js|gina\.js)/.test(tags[t].getAttribute('src'))){tags[t].onload=function(
|
|
645
|
+
function getDependencies(k,G){var F=new EventTarget,L=[{func:async function(U,q){q=q.url;var O=null,A=null,P=null;try{O=await fetch(q);if(!O.ok)throw Error('[ROUTING] HTTP '+O.status+' fetching '+q);A=await O.text();typeof k=='undefined'&&(k={});typeof window.gina.config=='undefined'&&(k.config={});k.config[U]=JSON.parse(A);F.dispatchEvent(new CustomEvent('deps.loaded',{detail:{data:A,error:P,timestamp:new Date}}))}catch(ba){P=Error('[ROUTING] Could not load routing\n'+(ba.stack||ba.message||ba)),
|
|
646
|
+
F.dispatchEvent(new CustomEvent('deps.loaded',{detail:{data:null,error:P,timestamp:new Date}}))}},args:['routing',{url:(typeof window!=='undefined'&&window.__ginaWebroot||k&&k.config&&k.config.webroot||'/')+'_gina/assets/routing.json'}]}];F.addEventListener('deps.loaded',U=>{L.splice(0,1);L.length||G()});try{for(let U=0,q=L.length;U<q;U++)L[U].func.apply(null,L[U].args)}catch(U){console.error(U.stack||U.message||U)}}
|
|
647
|
+
for(var tags=document.getElementsByTagName('script'),t=0,len=tags.length;t<len;++t)if(/(gina\.min\.js|gina\.js)/.test(tags[t].getAttribute('src'))){tags[t].onload=function(k){console.debug('Core Gina loaded !');getDependencies(gina,function(){if(window.onGinaLoaded)var G=window.onGinaLoaded;document.addEventListener?document.addEventListener('ginaloaded',function(F){window.gina=F.detail;G(F.detail)}):document.attachEvent&&document.attachEvent('ginaloaded',function(F){window.gina=F.detail;G(F.detail)})})}();
|
|
648
648
|
break};
|