UNPKG

angular-formio

Version:

Form.io Angular JSON Form Renderer ========================== This library serves as a Dynamic JSON Powered Form rendering library for [Angular](https://angular.io). This works by providing a JSON schema to a ```<formio>``` Angular component, where that f

945 lines (937 loc) 178 kB
(function (global, factory) { typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/common'), require('@angular/forms'), require('@angular/router'), require('rxjs'), require('formiojs'), require('lodash'), require('formiojs/utils/Evaluator'), require('ngx-bootstrap/pagination')) : typeof define === 'function' && define.amd ? define('index', ['exports', '@angular/core', '@angular/common', '@angular/forms', '@angular/router', 'rxjs', 'formiojs', 'lodash', 'formiojs/utils/Evaluator', 'ngx-bootstrap/pagination'], factory) : (global = global || self, factory(global['formio-grid'] = {}, global.core, global.common, global.forms, global.router, global.rxjs, global.formiojs, global.lodash, global.Evaluator, global.pagination)); }(this, (function (exports, core, common, forms, router, rxjs, formiojs, lodash, Evaluator, pagination) { 'use strict'; Evaluator = Evaluator && Evaluator.hasOwnProperty('default') ? Evaluator['default'] : Evaluator; /** * @fileoverview added by tsickle * Generated from: components/loader/formio.loader.ts * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc */ var FormioLoader = /** @class */ (function () { function FormioLoader() { this.loading$ = new rxjs.BehaviorSubject(true); this.loading = true; } /** * @param {?} loading * @return {?} */ FormioLoader.prototype.setLoading = /** * @param {?} loading * @return {?} */ function (loading) { this.loading = loading; this.loading$.next(loading); }; FormioLoader.decorators = [ { type: core.Injectable }, ]; return FormioLoader; }()); /** * @fileoverview added by tsickle * Generated from: formio.config.ts * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc */ var FormioAppConfig = /** @class */ (function () { function FormioAppConfig() { this.appUrl = ''; this.apiUrl = ''; } FormioAppConfig.decorators = [ { type: core.Injectable }, ]; return FormioAppConfig; }()); /** * @fileoverview added by tsickle * Generated from: formio.service.ts * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc */ var FormioService = /** @class */ (function () { function FormioService(url, options) { this.url = url; this.options = options; this.formio = new formiojs.Formio(this.url, this.options); } /** * @param {?} fn * @return {?} */ FormioService.prototype.requestWrapper = /** * @param {?} fn * @return {?} */ function (fn) { /** @type {?} */ var record; /** @type {?} */ var called = false; return rxjs.Observable.create((/** * @param {?} observer * @return {?} */ function (observer) { try { if (!called) { called = true; fn() .then((/** * @param {?} _record * @return {?} */ function (_record) { record = _record; observer.next(record); observer.complete(); })) .catch((/** * @param {?} err * @return {?} */ function (err) { return observer.error(err); })); } else if (record) { observer.next(record); observer.complete(); } } catch (err) { observer.error(err); } })); }; /** * @param {?} form * @return {?} */ FormioService.prototype.saveForm = /** * @param {?} form * @return {?} */ function (form) { var _this = this; return this.requestWrapper((/** * @return {?} */ function () { return _this.formio.saveForm(form); })); }; /** * @param {?=} options * @return {?} */ FormioService.prototype.loadForm = /** * @param {?=} options * @return {?} */ function (options) { var _this = this; return this.requestWrapper((/** * @return {?} */ function () { return _this.formio.loadForm(options); })); }; /** * @return {?} */ FormioService.prototype.loadSubmission = /** * @return {?} */ function () { var _this = this; return this.requestWrapper((/** * @return {?} */ function () { return _this.formio.loadSubmission(); })); }; /** * @param {?} submission * @return {?} */ FormioService.prototype.saveSubmission = /** * @param {?} submission * @return {?} */ function (submission) { var _this = this; return this.requestWrapper((/** * @return {?} */ function () { return _this.formio.saveSubmission(submission); })); }; /** * @return {?} */ FormioService.prototype.loadSubmissions = /** * @return {?} */ function () { var _this = this; return this.requestWrapper((/** * @return {?} */ function () { return _this.formio.loadSubmissions(); })); }; return FormioService; }()); /** * @fileoverview added by tsickle * Generated from: components/alerts/formio.alerts.ts * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc */ var FormioAlerts = /** @class */ (function () { function FormioAlerts() { this.alerts = []; } /** * @param {?} alert * @return {?} */ FormioAlerts.prototype.setAlert = /** * @param {?} alert * @return {?} */ function (alert) { this.alerts = [alert]; }; /** * @param {?} alert * @return {?} */ FormioAlerts.prototype.addAlert = /** * @param {?} alert * @return {?} */ function (alert) { this.alerts.push(alert); }; /** * @param {?} alerts * @return {?} */ FormioAlerts.prototype.setAlerts = /** * @param {?} alerts * @return {?} */ function (alerts) { this.alerts = alerts; }; return FormioAlerts; }()); /** * @fileoverview added by tsickle * Generated from: custom-component/custom-tags.service.ts * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc */ var CustomTagsService = /** @class */ (function () { function CustomTagsService() { this.tags = []; } /** * @param {?} tag * @return {?} */ CustomTagsService.prototype.addCustomTag = /** * @param {?} tag * @return {?} */ function (tag) { this.tags.push(tag); }; CustomTagsService.decorators = [ { type: core.Injectable }, ]; return CustomTagsService; }()); /** * @fileoverview added by tsickle * Generated from: FormioBaseComponent.ts * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc */ var FormioBaseComponent = /** @class */ (function () { function FormioBaseComponent(ngZone, loader, config, customTags) { var _this = this; this.ngZone = ngZone; this.loader = loader; this.config = config; this.customTags = customTags; this.submission = {}; this.noeval = false; this.readOnly = false; this.viewOnly = false; this.hooks = {}; this.render = new core.EventEmitter(); this.customEvent = new core.EventEmitter(); this.submit = new core.EventEmitter(); this.prevPage = new core.EventEmitter(); this.nextPage = new core.EventEmitter(); this.beforeSubmit = new core.EventEmitter(); this.change = new core.EventEmitter(); this.invalid = new core.EventEmitter(); this.errorChange = new core.EventEmitter(); this.formLoad = new core.EventEmitter(); this.submissionLoad = new core.EventEmitter(); this.ready = new core.EventEmitter(); this.initialized = false; this.alerts = new FormioAlerts(); this.submitting = false; this.formioReady = new Promise((/** * @param {?} ready * @return {?} */ function (ready) { _this.formioReadyResolve = ready; })); } /** * @return {?} */ FormioBaseComponent.prototype.getRenderer = /** * @return {?} */ function () { return this.renderer; }; /** * @return {?} */ FormioBaseComponent.prototype.getRendererOptions = /** * @return {?} */ function () { /** @type {?} */ var extraTags = this.customTags ? this.customTags.tags : []; return lodash.assign({}, { icons: lodash.get(this.config, 'icons', 'fontawesome'), noAlerts: lodash.get(this.options, 'noAlerts', true), readOnly: this.readOnly, viewAsHtml: this.viewOnly, i18n: lodash.get(this.options, 'i18n', null), fileService: lodash.get(this.options, 'fileService', null), hooks: this.hooks, sanitizeConfig: { addTags: extraTags } }, this.renderOptions || {}); }; /** * @return {?} */ FormioBaseComponent.prototype.createRenderer = /** * @return {?} */ function () { /** @type {?} */ var Renderer = this.getRenderer(); /** @type {?} */ var form = (new Renderer(this.formioElement ? this.formioElement.nativeElement : null, this.form, this.getRendererOptions())); return form.instance; }; /** * @param {?} form * @return {?} */ FormioBaseComponent.prototype.setForm = /** * @param {?} form * @return {?} */ function (form) { var _this = this; this.form = form; if (this.formio) { this.formio.destroy(); } // Clear out the element to render the new form. if (this.formioElement && this.formioElement.nativeElement) { this.formioElement.nativeElement.innerHTML = ''; } this.formio = this.createRenderer(); if (this.url) { this.formio.setUrl(this.url, this.formioOptions || {}); } if (this.src) { this.formio.setUrl(this.src, this.formioOptions || {}); } this.formio.nosubmit = true; this.formio.on('prevPage', (/** * @param {?} data * @return {?} */ function (data) { return _this.ngZone.run((/** * @return {?} */ function () { return _this.onPrevPage(data); })); })); this.formio.on('nextPage', (/** * @param {?} data * @return {?} */ function (data) { return _this.ngZone.run((/** * @return {?} */ function () { return _this.onNextPage(data); })); })); this.formio.on('change', (/** * @param {?} value * @return {?} */ function (value) { return _this.ngZone.run((/** * @return {?} */ function () { return _this.change.emit(value); })); })); this.formio.on('customEvent', (/** * @param {?} event * @return {?} */ function (event) { return _this.ngZone.run((/** * @return {?} */ function () { return _this.customEvent.emit(event); })); })); this.formio.on('submit', (/** * @param {?} submission * @return {?} */ function (submission) { return _this.ngZone.run((/** * @return {?} */ function () { return _this.submitForm(submission); })); })); this.formio.on('error', (/** * @param {?} err * @return {?} */ function (err) { return _this.ngZone.run((/** * @return {?} */ function () { return _this.onError(err); })); })); this.formio.on('render', (/** * @return {?} */ function () { return _this.ngZone.run((/** * @return {?} */ function () { return _this.render.emit(); })); })); this.formio.on('formLoad', (/** * @param {?} loadedForm * @return {?} */ function (loadedForm) { return _this.ngZone.run((/** * @return {?} */ function () { return _this.formLoad.emit(loadedForm); })); })); return this.formio.ready.then((/** * @return {?} */ function () { _this.ngZone.run((/** * @return {?} */ function () { _this.loader.setLoading(false); _this.ready.emit(_this); _this.formioReadyResolve(_this.formio); if (_this.formio.submissionReady) { _this.formio.submissionReady.then((/** * @param {?} submission * @return {?} */ function (submission) { _this.submissionLoad.emit(submission); })); } })); return _this.formio; })); }; /** * @return {?} */ FormioBaseComponent.prototype.initialize = /** * @return {?} */ function () { if (this.initialized) { return; } /** @type {?} */ var extraTags = this.customTags ? this.customTags.tags : []; this.options = Object.assign({ errors: { message: 'Please fix the following errors before submitting.' }, alerts: { submitMessage: 'Submission Complete.' }, disableAlerts: false, hooks: { beforeSubmit: null }, sanitizeConfig: { addTags: extraTags } }, this.options); this.initialized = true; }; /** * @return {?} */ FormioBaseComponent.prototype.ngOnInit = /** * @return {?} */ function () { var _this = this; Evaluator.noeval = this.noeval; this.initialize(); if (this.language) { this.language.subscribe((/** * @param {?} lang * @return {?} */ function (lang) { _this.formio.language = lang; })); } if (this.refresh) { this.refresh.subscribe((/** * @param {?} refresh * @return {?} */ function (refresh) { return _this.onRefresh(refresh); })); } if (this.error) { this.error.subscribe((/** * @param {?} err * @return {?} */ function (err) { return _this.onError(err); })); } if (this.success) { this.success.subscribe((/** * @param {?} message * @return {?} */ function (message) { _this.alerts.setAlert({ type: 'success', message: message || lodash.get(_this.options, 'alerts.submitMessage') }); })); } if (this.src) { if (!this.service) { this.service = new FormioService(this.src); } this.loader.setLoading(true); this.service.loadForm({ params: { live: 1 } }).subscribe((/** * @param {?} form * @return {?} */ function (form) { if (form && form.components) { _this.ngZone.runOutsideAngular((/** * @return {?} */ function () { _this.setForm(form); })); } // if a submission is also provided. if (lodash.isEmpty(_this.submission) && _this.service && _this.service.formio.submissionId) { _this.service.loadSubmission().subscribe((/** * @param {?} submission * @return {?} */ function (submission) { if (_this.readOnly) { _this.formio.options.readOnly = true; } _this.submission = _this.formio.submission = submission; }), (/** * @param {?} err * @return {?} */ function (err) { return _this.onError(err); })); } }), (/** * @param {?} err * @return {?} */ function (err) { return _this.onError(err); })); } if (this.url && !this.service) { this.service = new FormioService(this.url); } }; /** * @return {?} */ FormioBaseComponent.prototype.ngOnDestroy = /** * @return {?} */ function () { if (this.formio) { this.formio.destroy(); } }; /** * @param {?} refresh * @return {?} */ FormioBaseComponent.prototype.onRefresh = /** * @param {?} refresh * @return {?} */ function (refresh) { var _this = this; this.formioReady.then((/** * @return {?} */ function () { if (refresh.form) { _this.formio.setForm(refresh.form).then((/** * @return {?} */ function () { if (refresh.submission) { _this.formio.setSubmission(refresh.submission); } })); } else if (refresh.submission) { _this.formio.setSubmission(refresh.submission); } else { switch (refresh.property) { case 'submission': _this.formio.submission = refresh.value; break; case 'form': _this.formio.form = refresh.value; break; } } })); }; /** * @param {?} changes * @return {?} */ FormioBaseComponent.prototype.ngOnChanges = /** * @param {?} changes * @return {?} */ function (changes) { var _this = this; Evaluator.noeval = this.noeval; this.initialize(); if (changes.form && changes.form.currentValue) { this.ngZone.runOutsideAngular((/** * @return {?} */ function () { _this.setForm(changes.form.currentValue); })); } this.formioReady.then((/** * @return {?} */ function () { if (changes.submission && changes.submission.currentValue) { _this.formio.submission = changes.submission.currentValue; } if (changes.hideComponents && changes.hideComponents.currentValue) { _this.formio.hideComponents(changes.hideComponents.currentValue); } })); }; /** * @param {?} data * @return {?} */ FormioBaseComponent.prototype.onPrevPage = /** * @param {?} data * @return {?} */ function (data) { this.alerts.setAlerts([]); this.prevPage.emit(data); }; /** * @param {?} data * @return {?} */ FormioBaseComponent.prototype.onNextPage = /** * @param {?} data * @return {?} */ function (data) { this.alerts.setAlerts([]); this.nextPage.emit(data); }; /** * @param {?} submission * @param {?} saved * @param {?=} noemit * @return {?} */ FormioBaseComponent.prototype.onSubmit = /** * @param {?} submission * @param {?} saved * @param {?=} noemit * @return {?} */ function (submission, saved, noemit) { this.submitting = false; if (saved) { this.formio.emit('submitDone', submission); } if (!noemit) { this.submit.emit(submission); } if (!this.success) { this.alerts.setAlert({ type: 'success', message: lodash.get(this.options, 'alerts.submitMessage') }); } }; /** * @param {?} err * @return {?} */ FormioBaseComponent.prototype.onError = /** * @param {?} err * @return {?} */ function (err) { var _this = this; this.alerts.setAlerts([]); this.submitting = false; this.loader.setLoading(false); if (!err) { return; } // Make sure it is an array. /** @type {?} */ var errors = Array.isArray(err) ? err : [err]; // Emit these errors again. this.errorChange.emit(errors); if (err.silent) { return; } if (this.formio) { this.formio.emit('submitError', errors); } // Iterate through each one and set the alerts array. errors.forEach((/** * @param {?} error * @return {?} */ function (error) { var _a = error ? error.details ? { message: error.details.map((/** * @param {?} detail * @return {?} */ function (detail) { return detail.message; })).join(' '), paths: error.details.map((/** * @param {?} detail * @return {?} */ function (detail) { return detail.path; })), } : { message: error.message || error.toString(), paths: error.path ? [error.path] : [], } : { message: '', paths: [], }, message = _a.message, paths = _a.paths; _this.alerts.addAlert({ type: 'danger', message: message, }); if (_this.formio) { paths.forEach((/** * @param {?} path * @return {?} */ function (path) { /** @type {?} */ var component = _this.formio.getComponent(path); /** @type {?} */ var components = Array.isArray(component) ? component : [component]; components.forEach((/** * @param {?} comp * @return {?} */ function (comp) { return comp.setCustomValidity(message, true); })); })); } })); }; /** * @param {?} submission * @return {?} */ FormioBaseComponent.prototype.submitExecute = /** * @param {?} submission * @return {?} */ function (submission) { var _this = this; if (this.service && !this.url) { this.service .saveSubmission(submission) .subscribe((/** * @param {?} sub * @return {?} */ function (sub) { return _this.onSubmit(sub, true); }), (/** * @param {?} err * @return {?} */ function (err) { return _this.onError(err); })); } else { this.onSubmit(submission, false); } }; /** * @param {?} submission * @return {?} */ FormioBaseComponent.prototype.submitForm = /** * @param {?} submission * @return {?} */ function (submission) { var _this = this; // Keep double submits from occurring... if (this.submitting) { return; } this.submitting = true; this.beforeSubmit.emit(submission); // if they provide a beforeSubmit hook, then allow them to alter the submission asynchronously // or even provide a custom Error method. /** @type {?} */ var beforeSubmit = lodash.get(this.options, 'hooks.beforeSubmit'); if (beforeSubmit) { beforeSubmit(submission, (/** * @param {?} err * @param {?} sub * @return {?} */ function (err, sub) { if (err) { _this.onError(err); return; } _this.submitExecute(sub); })); } else { this.submitExecute(submission); } }; /** @nocollapse */ FormioBaseComponent.ctorParameters = function () { return [ { type: core.NgZone }, { type: FormioLoader }, { type: FormioAppConfig, decorators: [{ type: core.Optional }] }, { type: CustomTagsService, decorators: [{ type: core.Optional }] } ]; }; FormioBaseComponent.propDecorators = { form: [{ type: core.Input }], submission: [{ type: core.Input }], src: [{ type: core.Input }], url: [{ type: core.Input }], service: [{ type: core.Input }], options: [{ type: core.Input }], noeval: [{ type: core.Input }], formioOptions: [{ type: core.Input }], renderOptions: [{ type: core.Input }], readOnly: [{ type: core.Input }], viewOnly: [{ type: core.Input }], hideComponents: [{ type: core.Input }], refresh: [{ type: core.Input }], error: [{ type: core.Input }], success: [{ type: core.Input }], language: [{ type: core.Input }], hooks: [{ type: core.Input }], renderer: [{ type: core.Input }], render: [{ type: core.Output }], customEvent: [{ type: core.Output }], submit: [{ type: core.Output }], prevPage: [{ type: core.Output }], nextPage: [{ type: core.Output }], beforeSubmit: [{ type: core.Output }], change: [{ type: core.Output }], invalid: [{ type: core.Output }], errorChange: [{ type: core.Output }], formLoad: [{ type: core.Output }], submissionLoad: [{ type: core.Output }], ready: [{ type: core.Output }], formioElement: [{ type: core.ViewChild, args: ['formio', { static: true },] }] }; return FormioBaseComponent; }()); var __extends = (undefined && undefined.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { extendStatics(d, b); function __() { this.constructor = d; } d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); }; })(); /* tslint:disable */ var FormioComponent = /** @class */ (function (_super) { __extends(FormioComponent, _super); function FormioComponent(ngZone, loader, config, customTags) { var _this = _super.call(this, ngZone, loader, config, customTags) || this; _this.ngZone = ngZone; _this.loader = loader; _this.config = config; _this.customTags = customTags; if (_this.config) { formiojs.Formio.setBaseUrl(_this.config.apiUrl); formiojs.Formio.setProjectUrl(_this.config.appUrl); } else { console.warn('You must provide an AppConfig within your application!'); } return _this; } /** * @return {?} */ FormioComponent.prototype.getRenderer = /** * @return {?} */ function () { return this.renderer || formiojs.Form; }; FormioComponent.decorators = [ { type: core.Component, args: [{ selector: 'formio', template: "<div> <div *ngIf=\"loader.loading$ | async\" style=\"position:relative;height:200px\"> <formio-loader></formio-loader> </div> <formio-alerts *ngIf=\"!this.options?.disableAlerts\" [alerts]=\"alerts\"></formio-alerts> <div #formio></div> </div> ", styles: ["@charset \"UTF-8\";.flatpickr-calendar{background:0 0;opacity:0;display:none;text-align:center;visibility:hidden;padding:0;-webkit-animation:none;animation:none;direction:ltr;border:0;font-size:14px;line-height:24px;border-radius:5px;position:absolute;width:307.875px;-webkit-box-sizing:border-box;box-sizing:border-box;-ms-touch-action:manipulation;touch-action:manipulation;background:#fff;-webkit-box-shadow:1px 0 0 #e6e6e6,-1px 0 0 #e6e6e6,0 1px 0 #e6e6e6,0 -1px 0 #e6e6e6,0 3px 13px rgba(0,0,0,.08);box-shadow:1px 0 0 #e6e6e6,-1px 0 0 #e6e6e6,0 1px 0 #e6e6e6,0 -1px 0 #e6e6e6,0 3px 13px rgba(0,0,0,.08)}.flatpickr-calendar.inline,.flatpickr-calendar.open{opacity:1;max-height:640px;visibility:visible}.flatpickr-calendar.open{display:inline-block;z-index:99999}.flatpickr-calendar.animate.open{-webkit-animation:fpFadeInDown .3s cubic-bezier(.23,1,.32,1);animation:fpFadeInDown .3s cubic-bezier(.23,1,.32,1)}.flatpickr-calendar.inline{display:block;position:relative;top:2px}.flatpickr-calendar.static{position:absolute;top:calc(100% + 2px)}.flatpickr-calendar.static.open{z-index:999;display:block}.flatpickr-calendar.multiMonth .flatpickr-days .dayContainer:nth-child(n+1) .flatpickr-day.inRange:nth-child(7n+7){-webkit-box-shadow:none!important;box-shadow:none!important}.flatpickr-calendar.multiMonth .flatpickr-days .dayContainer:nth-child(n+2) .flatpickr-day.inRange:nth-child(7n+1){-webkit-box-shadow:-2px 0 0 #e6e6e6,5px 0 0 #e6e6e6;box-shadow:-2px 0 0 #e6e6e6,5px 0 0 #e6e6e6}.flatpickr-calendar .hasTime .dayContainer,.flatpickr-calendar .hasWeeks .dayContainer{border-bottom:0;border-bottom-right-radius:0;border-bottom-left-radius:0}.flatpickr-calendar .hasWeeks .dayContainer{border-left:0}.flatpickr-calendar.showTimeInput.hasTime .flatpickr-time{height:40px;border-top:1px solid #e6e6e6}.flatpickr-calendar.noCalendar.hasTime .flatpickr-time{height:auto}.flatpickr-calendar:after,.flatpickr-calendar:before{position:absolute;display:block;pointer-events:none;border:solid transparent;content:'';height:0;width:0;left:22px}.flatpickr-calendar.rightMost:after,.flatpickr-calendar.rightMost:before{left:auto;right:22px}.flatpickr-calendar:before{border-width:5px;margin:0 -5px}.flatpickr-calendar:after{border-width:4px;margin:0 -4px}.flatpickr-calendar.arrowTop:after,.flatpickr-calendar.arrowTop:before{bottom:100%}.flatpickr-calendar.arrowTop:before{border-bottom-color:#e6e6e6}.flatpickr-calendar.arrowTop:after{border-bottom-color:#fff}.flatpickr-calendar.arrowBottom:after,.flatpickr-calendar.arrowBottom:before{top:100%}.flatpickr-calendar.arrowBottom:before{border-top-color:#e6e6e6}.flatpickr-calendar.arrowBottom:after{border-top-color:#fff}.flatpickr-calendar:focus{outline:0}.flatpickr-wrapper{position:relative;display:inline-block}.flatpickr-months{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex}.flatpickr-months .flatpickr-month{background:0 0;color:rgba(0,0,0,.9);fill:rgba(0,0,0,.9);height:34px;line-height:1;text-align:center;position:relative;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;overflow:hidden;-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1}.flatpickr-months .flatpickr-next-month,.flatpickr-months .flatpickr-prev-month{text-decoration:none;cursor:pointer;position:absolute;top:0;height:34px;padding:10px;z-index:3;color:rgba(0,0,0,.9);fill:rgba(0,0,0,.9)}.flatpickr-months .flatpickr-next-month.flatpickr-disabled,.flatpickr-months .flatpickr-prev-month.flatpickr-disabled{display:none}.flatpickr-months .flatpickr-next-month i,.flatpickr-months .flatpickr-prev-month i{position:relative}.flatpickr-months .flatpickr-next-month.flatpickr-prev-month,.flatpickr-months .flatpickr-prev-month.flatpickr-prev-month{left:0}.flatpickr-months .flatpickr-next-month.flatpickr-next-month,.flatpickr-months .flatpickr-prev-month.flatpickr-next-month{right:0}.flatpickr-months .flatpickr-next-month:hover,.flatpickr-months .flatpickr-prev-month:hover{color:#959ea9}.flatpickr-months .flatpickr-next-month:hover svg,.flatpickr-months .flatpickr-prev-month:hover svg{fill:#f64747}.flatpickr-months .flatpickr-next-month svg,.flatpickr-months .flatpickr-prev-month svg{width:14px;height:14px}.flatpickr-months .flatpickr-next-month svg path,.flatpickr-months .flatpickr-prev-month svg path{-webkit-transition:fill .1s;transition:fill .1s;fill:inherit}.numInputWrapper{position:relative;height:auto}.numInputWrapper input,.numInputWrapper span{display:inline-block}.numInputWrapper input{width:100%}.numInputWrapper input::-ms-clear{display:none}.numInputWrapper input::-webkit-inner-spin-button,.numInputWrapper input::-webkit-outer-spin-button{margin:0;-webkit-appearance:none}.numInputWrapper span{position:absolute;right:0;width:14px;padding:0 4px 0 2px;height:50%;line-height:50%;opacity:0;cursor:pointer;border:1px solid rgba(57,57,57,.15);-webkit-box-sizing:border-box;box-sizing:border-box}.numInputWrapper span:hover{background:rgba(0,0,0,.1)}.numInputWrapper span:active{background:rgba(0,0,0,.2)}.numInputWrapper span:after{display:block;content:\"\";position:absolute}.numInputWrapper span.arrowUp{top:0;border-bottom:0}.numInputWrapper span.arrowUp:after{border-left:4px solid transparent;border-right:4px solid transparent;border-bottom:4px solid rgba(57,57,57,.6);top:26%}.numInputWrapper span.arrowDown{top:50%}.numInputWrapper span.arrowDown:after{border-left:4px solid transparent;border-right:4px solid transparent;border-top:4px solid rgba(57,57,57,.6);top:40%}.numInputWrapper span svg{width:inherit;height:auto}.numInputWrapper span svg path{fill:rgba(0,0,0,.5)}.numInputWrapper:hover{background:rgba(0,0,0,.05)}.numInputWrapper:hover span{opacity:1}.flatpickr-current-month{font-size:135%;line-height:inherit;font-weight:300;color:inherit;position:absolute;width:75%;left:12.5%;padding:7.48px 0 0 0;line-height:1;height:34px;display:inline-block;text-align:center;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}.flatpickr-current-month span.cur-month{font-family:inherit;font-weight:700;color:inherit;display:inline-block;margin-left:.5ch;padding:0}.flatpickr-current-month span.cur-month:hover{background:rgba(0,0,0,.05)}.flatpickr-current-month .numInputWrapper{width:6ch;width:7ch\\0;display:inline-block}.flatpickr-current-month .numInputWrapper span.arrowUp:after{border-bottom-color:rgba(0,0,0,.9)}.flatpickr-current-month .numInputWrapper span.arrowDown:after{border-top-color:rgba(0,0,0,.9)}.flatpickr-current-month input.cur-year{background:0 0;-webkit-box-sizing:border-box;box-sizing:border-box;color:inherit;cursor:text;padding:0 0 0 .5ch;margin:0;display:inline-block;font-size:inherit;font-family:inherit;font-weight:300;line-height:inherit;height:auto;border:0;border-radius:0;vertical-align:initial;-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield}.flatpickr-current-month input.cur-year:focus{outline:0}.flatpickr-current-month input.cur-year[disabled],.flatpickr-current-month input.cur-year[disabled]:hover{font-size:100%;color:rgba(0,0,0,.5);background:0 0;pointer-events:none}.flatpickr-current-month .flatpickr-monthDropdown-months{appearance:menulist;background:0 0;border:none;border-radius:0;box-sizing:border-box;color:inherit;cursor:pointer;font-size:inherit;font-family:inherit;font-weight:300;height:auto;line-height:inherit;margin:-1px 0 0 0;outline:0;padding:0 0 0 .5ch;position:relative;vertical-align:initial;-webkit-box-sizing:border-box;-webkit-appearance:menulist;-moz-appearance:menulist;width:auto}.flatpickr-current-month .flatpickr-monthDropdown-months:active,.flatpickr-current-month .flatpickr-monthDropdown-months:focus{outline:0}.flatpickr-current-month .flatpickr-monthDropdown-months:hover{background:rgba(0,0,0,.05)}.flatpickr-current-month .flatpickr-monthDropdown-months .flatpickr-monthDropdown-month{background-color:transparent;outline:0;padding:0}.flatpickr-weekdays{background:0 0;text-align:center;overflow:hidden;width:100%;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:center;-webkit-align-items:center;-ms-flex-align:center;align-items:center;height:28px}.flatpickr-weekdays .flatpickr-weekdaycontainer{display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1}span.flatpickr-weekday{cursor:default;font-size:90%;background:0 0;color:rgba(0,0,0,.54);line-height:1;margin:0;text-align:center;display:block;-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;font-weight:bolder}.dayContainer,.flatpickr-weeks{padding:1px 0 0 0}.flatpickr-days{position:relative;overflow:hidden;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-align:start;-webkit-align-items:flex-start;-ms-flex-align:start;align-items:flex-start;width:307.875px}.flatpickr-days:focus{outline:0}.dayContainer{padding:0;outline:0;text-align:left;width:307.875px;min-width:307.875px;max-width:307.875px;-webkit-box-sizing:border-box;box-sizing:border-box;display:inline-block;display:-ms-flexbox;display:-webkit-box;display:-webkit-flex;display:flex;-webkit-flex-wrap:wrap;flex-wrap:wrap;-ms-flex-wrap:wrap;-ms-flex-pack:justify;-webkit-justify-content:space-around;justify-content:space-around;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0);opacity:1}.dayContainer+.dayContainer{-webkit-box-shadow:-1px 0 0 #e6e6e6;box-shadow:-1px 0 0 #e6e6e6}.flatpickr-day{background:0 0;border:1px solid transparent;border-radius:150px;-webkit-box-sizing:border-box;box-sizing:border-box;color:#393939;cursor:pointer;font-weight:400;width:14.2857143%;-webkit-flex-basis:14.2857143%;-ms-flex-preferred-size:14.2857143%;flex-basis:14.2857143%;max-width:39px;height:39px;line-height:39px;margin:0;display:inline-block;position:relative;-webkit-box-pack:center;-webkit-justify-content:center;-ms-flex-pack:center;justify-content:center;text-align:center}.flatpickr-day.inRange,.flatpickr-day.nextMonthDay.inRange,.flatpickr-day.nextMonthDay.today.inRange,.flatpickr-day.nextMonthDay:focus,.flatpickr-day.nextMonthDay:hover,.flatpickr-day.prevMonthDay.inRange,.flatpickr-day.prevMonthDay.today.inRange,.flatpickr-day.prevMonthDay:focus,.flatpickr-day.prevMonthDay:hover,.flatpickr-day.today.inRange,.flatpickr-day:focus,.flatpickr-day:hover{cursor:pointer;outline:0;background:#e6e6e6;border-color:#e6e6e6}.flatpickr-day.today{border-color:#959ea9}.flatpickr-day.today:focus,.flatpickr-day.today:hover{border-color:#959ea9;background:#959ea9;color:#fff}.flatpickr-day.endRange,.flatpickr-day.endRange.inRange,.flatpickr-day.endRange.nextMonthDay,.flatpickr-day.endRange.prevMonthDay,.flatpickr-day.endRange:focus,.flatpickr-day.endRange:hover,.flatpickr-day.selected,.flatpickr-day.selected.inRange,.flatpickr-day.selected.nextMonthDay,.flatpickr-day.selected.prevMonthDay,.flatpickr-day.selected:focus,.flatpickr-day.selected:hover,.flatpickr-day.startRange,.flatpickr-day.startRange.inRange,.flatpickr-day.startRange.nextMonthDay,.flatpickr-day.startRange.prevMonthDay,.flatpickr-day.startRange:focus,.flatpickr-day.startRange:hover{background:#569ff7;-webkit-box-shadow:none;box-shadow:none;color:#fff;border-color:#569ff7}.flatpickr-day.endRange.startRange,.flatpickr-day.selected.startRange,.flatpickr-day.startRange.startRange{border-radius:50px 0 0 50px}.flatpickr-day.endRange.endRange,.flatpickr-day.selected.endRange,.flatpickr-day.startRange.endRange{border-radius:0 50px 50px 0}.flatpickr-day.endRange.startRange+.endRange:not(:nth-child(7n+1)),.flatpickr-day.selected.startRange+.endRange:not(:nth-child(7n+1)),.flatpickr-day.startRange.startRange+.endRange:not(:nth-child(7n+1)){-webkit-box-shadow:-10px 0 0 #569ff7;box-shadow:-10px 0 0 #569ff7}.flatpickr-day.endRange.startRange.endRange,.flatpickr-day.selected.startRange.endRange,.flatpickr-day.startRange.startRange.endRange{border-radius:50px}.flatpickr-day.inRange{border-radius:0;-webkit-box-shadow:-5px 0 0 #e6e6e6,5px 0 0 #e6e6e6;box-shadow:-5px 0 0 #e6e6e6,5px 0 0 #e6e6e6}.flatpickr-day.flatpickr-disabled,.flatpickr-day.flatpickr-disabled:hover,.flatpickr-day.nextMonthDay,.flatpickr-day.notAllowed,.flatpickr-day.notAllowed.nextMonthDay,.flatpickr-day.notAllowed.prevMonthDay,.flatpickr-day.prevMonthDay{color:rgba(57,57,57,.3);background:0 0;border-color:transparent;cursor:default}.flatpickr-day.flatpickr-disabled,.flatpickr-day.flatpickr-disabled:hover{cursor:not-allowed;color:rgba(57,57,57,.1)}.flatpickr-day.week.selected{border-radius:0;-webkit-box-shadow:-5px 0 0 #569ff7,5px 0 0 #569ff7;box-shadow:-5px 0 0 #569ff7,5px 0 0 #569ff7}.flatpickr-day.hidden{visibility:hidden}.rangeMode .flatpickr-day{margin-top:1px}.flatpickr-weekwrapper{float:left}.flatpickr-weekwrapper .flatpickr-weeks{padding:0 12px;-webkit-box-shadow:1px 0 0 #e6e6e6;box-shadow:1px 0 0 #e6e6e6}.flatpickr-weekwrapper .flatpickr-weekday{float:none;width:100%;line-height:28px}.flatpickr-weekwrapper span.flatpickr-day,.flatpickr-weekwrapper span.flatpickr-day:hover{display:block;width:100%;max-width:none;color:rgba(57,57,57,.3);background:0 0;cursor:default;border:none}.flatpickr-innerContainer{display:block;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex;-webkit-box-sizing:border-box;box-sizing:border-box;overflow:hidden}.flatpickr-rContainer{display:inline-block;padding:0;-webkit-box-sizing:border-box;box-sizing:border-box}.flatpickr-time{text-align:center;outline:0;display:block;height:0;line-height:40px;max-height:40px;-webkit-box-sizing:border-box;box-sizing:border-box;overflow:hidden;display:-webkit-box;display:-webkit-flex;display:-ms-flexbox;display:flex}.flatpickr-time:after{content:\"\";display:table;clear:both}.flatpickr-time .numInputWrapper{-webkit-box-flex:1;-webkit-flex:1;-ms-flex:1;flex:1;width:40%;height:40px;float:left}.flatpickr-time .numInputWrapper span.arrowUp:after{border-bottom-color:#393939}.flatpickr-time .numInputWrapper span.arrowDown:after{border-top-color:#393939}.flatpickr-time.hasSeconds .numInputWrapper{width:26%}.flatpickr-time.time24hr .numInputWrapper{width:49%}.flatpickr-time input{background:0 0;-webkit-box-shadow:none;box-shadow:none;border:0;border-radius:0;text-align:center;margin:0;padding:0;height:inherit;line-height:inherit;color:#393939;font-size:14px;position:relative;-webkit-box-sizing:border-box;box-sizing:border-box;-webkit-appearance:textfield;-moz-appearance:textfield;appearance:textfield}.flatpickr-time input.flatpickr-hour{font-weight:700}.flatpickr-time input.flatpickr-minute,.flatpickr-time input.flatpickr-second{font-weight:400}.flatpickr-time input:focus{outline:0;border:0}.flatpickr-time .flatpickr-am-pm,.flatpickr-time .flatpickr-time-separator{height:inherit;float:left;line-height:inherit;color:#393939;font-weight:700;width:2%;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-align-self:center;-ms-flex-item-align:center;align-self:center}.flatpickr-time .flatpickr-am-pm{outline:0;width:18%;cursor:pointer;text-align:center;font-weight:400}.flatpickr-time .flatpickr-am-pm:focus,.flatpickr-time .flatpickr-am-pm:hover,.flatpickr-time input:focus,.flatpickr-time input:hover{background:#eee}.flatpickr-input[readonly]{cursor:pointer}@-webkit-keyframes fpFadeInDown{from{opacity:0;-webkit-transform:translate3d(0,-20px,0);transform:translate3d(0,-20px,0)}to{opacity:1;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}}@keyframes fpFadeInDown{from{opacity:0;-webkit-transform:translate3d(0,-20px,0);transform:translate3d(0,-20px,0)}to{opacity:1;-webkit-transform:translate3d(0,0,0);transform:translate3d(0,0,0)}}.choices{position:relative;margin-bottom:24px;font-size:16px}.choices:focus{outline:0}.choices:last-child{margin-bottom:0}.choices.is-disabled .choices__inner,.choices.is-disabled .choices__input{background-color:#eaeaea;cursor:not-allowed;-webkit-user-select:none;-ms-user-select:none;user-select:none}.choices.is-disabled .choices__item{cursor:not-allowed}.choices [hidden]{display:none!important}.choices[data-type*=select-one]{cursor:pointer}.choices[data-type*=select-one] .choices__inner{padding-bottom:7.5px}.choices[data-type*=select-one] .choices__input{display:block;width:100%;padding:10px;border-bottom:1px solid #ddd;background-color:#fff;margin:0}.choices[data-type*=select-one] .choices__button{background-image:url(data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iMjEiIGhlaWdodD0iMjEiIHZpZXdCb3g9IjAgMCAyMSAyMSIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyBmaWxsPSIjMDAwIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPjxwYXRoIGQ9Ik0yLjU5Mi4wNDRsMTguMzY0IDE4LjM2NC0yLjU0OCAyLjU0OEwuMDQ0IDIuNTkyeiIvPjxwYXRoIGQ9Ik0wIDE4LjM2NEwxOC4zNjQgMGwyLjU0OCAyLjU0OEwyLjU0OCAyMC45MTJ6Ii8+PC9nPj