-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathwebdemo-legacy.min.js.download
96 lines (95 loc) · 43.7 KB
/
webdemo-legacy.min.js.download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
/*
Copyright The Closure Library Authors.
SPDX-License-Identifier: Apache-2.0
*/
var $jscomp=$jscomp||{};$jscomp.scope={};$jscomp.arrayIteratorImpl=function(a){var b=0;return function(){return b<a.length?{done:!1,value:a[b++]}:{done:!0}}};$jscomp.arrayIterator=function(a){return{next:$jscomp.arrayIteratorImpl(a)}};$jscomp.ASSUME_ES5=!1;$jscomp.ASSUME_NO_NATIVE_MAP=!1;$jscomp.ASSUME_NO_NATIVE_SET=!1;$jscomp.SIMPLE_FROUND_POLYFILL=!1;$jscomp.ISOLATE_POLYFILLS=!1;$jscomp.FORCE_POLYFILL_PROMISE=!1;$jscomp.FORCE_POLYFILL_PROMISE_WHEN_NO_UNHANDLED_REJECTION=!1;
$jscomp.defineProperty=$jscomp.ASSUME_ES5||"function"==typeof Object.defineProperties?Object.defineProperty:function(a,b,c){if(a==Array.prototype||a==Object.prototype)return a;a[b]=c.value;return a};$jscomp.getGlobal=function(a){a=["object"==typeof globalThis&&globalThis,a,"object"==typeof window&&window,"object"==typeof self&&self,"object"==typeof global&&global];for(var b=0;b<a.length;++b){var c=a[b];if(c&&c.Math==Math)return c}throw Error("Cannot find global object");};$jscomp.global=$jscomp.getGlobal(this);
$jscomp.IS_SYMBOL_NATIVE="function"===typeof Symbol&&"symbol"===typeof Symbol("x");$jscomp.TRUST_ES6_POLYFILLS=!$jscomp.ISOLATE_POLYFILLS||$jscomp.IS_SYMBOL_NATIVE;$jscomp.polyfills={};$jscomp.propertyToPolyfillSymbol={};$jscomp.POLYFILL_PREFIX="$jscp$";$jscomp.polyfill=function(a,b,c,d){b&&($jscomp.ISOLATE_POLYFILLS?$jscomp.polyfillIsolated(a,b,c,d):$jscomp.polyfillUnisolated(a,b,c,d))};
$jscomp.polyfillUnisolated=function(a,b){var c=$jscomp.global;a=a.split(".");for(var d=0;d<a.length-1;d++){var f=a[d];if(!(f in c))return;c=c[f]}a=a[a.length-1];d=c[a];b=b(d);b!=d&&null!=b&&$jscomp.defineProperty(c,a,{configurable:!0,writable:!0,value:b})};
$jscomp.polyfillIsolated=function(a,b,c){var d=a.split("."),f=1===d.length;a=d[0];a=!f&&a in $jscomp.polyfills?$jscomp.polyfills:$jscomp.global;for(var g=0;g<d.length-1;g++){var l=d[g];if(!(l in a))return;a=a[l]}d=d[d.length-1];c=$jscomp.IS_SYMBOL_NATIVE&&"es6"===c?a[d]:null;b=b(c);null!=b&&(f?$jscomp.defineProperty($jscomp.polyfills,d,{configurable:!0,writable:!0,value:b}):b!==c&&(void 0===$jscomp.propertyToPolyfillSymbol[d]&&(f=1E9*Math.random()>>>0,$jscomp.propertyToPolyfillSymbol[d]=$jscomp.IS_SYMBOL_NATIVE?
$jscomp.global.Symbol(d):$jscomp.POLYFILL_PREFIX+f+"$"+d),f=$jscomp.propertyToPolyfillSymbol[d],$jscomp.defineProperty(a,f,{configurable:!0,writable:!0,value:b})))};$jscomp.initSymbol=function(){};
$jscomp.polyfill("Symbol",function(a){if(a)return a;var b=function(g,l){this.$jscomp$symbol$id_=g;$jscomp.defineProperty(this,"description",{configurable:!0,writable:!0,value:l})};b.prototype.toString=function(){return this.$jscomp$symbol$id_};a=1E9*Math.random()>>>0;var c="jscomp_symbol_"+a+"_",d=0,f=function(g){if(this instanceof f)throw new TypeError("Symbol is not a constructor");return new b(c+(g||"")+"_"+d++,g)};return f},"es6","es3");
$jscomp.polyfill("Symbol.iterator",function(a){if(a)return a;a=Symbol("Symbol.iterator");for(var b="Array Int8Array Uint8Array Uint8ClampedArray Int16Array Uint16Array Int32Array Uint32Array Float32Array Float64Array".split(" "),c=0;c<b.length;c++){var d=$jscomp.global[b[c]];"function"===typeof d&&"function"!=typeof d.prototype[a]&&$jscomp.defineProperty(d.prototype,a,{configurable:!0,writable:!0,value:function(){return $jscomp.iteratorPrototype($jscomp.arrayIteratorImpl(this))}})}return a},"es6",
"es3");$jscomp.iteratorPrototype=function(a){a={next:a};a[Symbol.iterator]=function(){return this};return a};$jscomp.createTemplateTagFirstArg=function(a){return a.raw=a};$jscomp.createTemplateTagFirstArgWithRaw=function(a,b){a.raw=b;return a};$jscomp.underscoreProtoCanBeSet=function(){var a={a:!0},b={};try{return b.__proto__=a,b.a}catch(c){}return!1};
$jscomp.setPrototypeOf=$jscomp.TRUST_ES6_POLYFILLS&&"function"==typeof Object.setPrototypeOf?Object.setPrototypeOf:$jscomp.underscoreProtoCanBeSet()?function(a,b){a.__proto__=b;if(a.__proto__!==b)throw new TypeError(a+" is not extensible");return a}:null;$jscomp.owns=function(a,b){return Object.prototype.hasOwnProperty.call(a,b)};
$jscomp.assign=$jscomp.TRUST_ES6_POLYFILLS&&"function"==typeof Object.assign?Object.assign:function(a,b){for(var c=1;c<arguments.length;c++){var d=arguments[c];if(d)for(var f in d)$jscomp.owns(d,f)&&(a[f]=d[f])}return a};$jscomp.makeIterator=function(a){var b="undefined"!=typeof Symbol&&Symbol.iterator&&a[Symbol.iterator];return b?b.call(a):$jscomp.arrayIterator(a)};
$jscomp.polyfill("Promise",function(a){function b(){this.batch_=null}function c(e){return e instanceof g?e:new g(function(h){h(e)})}if(a&&(!($jscomp.FORCE_POLYFILL_PROMISE||$jscomp.FORCE_POLYFILL_PROMISE_WHEN_NO_UNHANDLED_REJECTION&&"undefined"===typeof $jscomp.global.PromiseRejectionEvent)||!$jscomp.global.Promise||-1===$jscomp.global.Promise.toString().indexOf("[native code]")))return a;b.prototype.asyncExecute=function(e){if(null==this.batch_){this.batch_=[];var h=this;this.asyncExecuteFunction(function(){h.executeBatch_()})}this.batch_.push(e)};
var d=$jscomp.global.setTimeout;b.prototype.asyncExecuteFunction=function(e){d(e,0)};b.prototype.executeBatch_=function(){for(;this.batch_&&this.batch_.length;){var e=this.batch_;this.batch_=[];for(var h=0;h<e.length;++h){var k=e[h];e[h]=null;try{k()}catch(m){this.asyncThrow_(m)}}}this.batch_=null};b.prototype.asyncThrow_=function(e){this.asyncExecuteFunction(function(){throw e;})};var f={PENDING:0,FULFILLED:1,REJECTED:2},g=function(e){this.state_=f.PENDING;this.result_=void 0;this.onSettledCallbacks_=
[];this.isRejectionHandled_=!1;var h=this.createResolveAndReject_();try{e(h.resolve,h.reject)}catch(k){h.reject(k)}};g.prototype.createResolveAndReject_=function(){function e(m){return function(n){k||(k=!0,m.call(h,n))}}var h=this,k=!1;return{resolve:e(this.resolveTo_),reject:e(this.reject_)}};g.prototype.resolveTo_=function(e){if(e===this)this.reject_(new TypeError("A Promise cannot resolve to itself"));else if(e instanceof g)this.settleSameAsPromise_(e);else{a:switch(typeof e){case "object":var h=
null!=e;break a;case "function":h=!0;break a;default:h=!1}h?this.resolveToNonPromiseObj_(e):this.fulfill_(e)}};g.prototype.resolveToNonPromiseObj_=function(e){var h=void 0;try{h=e.then}catch(k){this.reject_(k);return}"function"==typeof h?this.settleSameAsThenable_(h,e):this.fulfill_(e)};g.prototype.reject_=function(e){this.settle_(f.REJECTED,e)};g.prototype.fulfill_=function(e){this.settle_(f.FULFILLED,e)};g.prototype.settle_=function(e,h){if(this.state_!=f.PENDING)throw Error("Cannot settle("+e+
", "+h+"): Promise already settled in state"+this.state_);this.state_=e;this.result_=h;this.state_===f.REJECTED&&this.scheduleUnhandledRejectionCheck_();this.executeOnSettledCallbacks_()};g.prototype.scheduleUnhandledRejectionCheck_=function(){var e=this;d(function(){if(e.notifyUnhandledRejection_()){var h=$jscomp.global.console;"undefined"!==typeof h&&h.error(e.result_)}},1)};g.prototype.notifyUnhandledRejection_=function(){if(this.isRejectionHandled_)return!1;var e=$jscomp.global.CustomEvent,h=
$jscomp.global.Event,k=$jscomp.global.dispatchEvent;if("undefined"===typeof k)return!0;"function"===typeof e?e=new e("unhandledrejection",{cancelable:!0}):"function"===typeof h?e=new h("unhandledrejection",{cancelable:!0}):(e=$jscomp.global.document.createEvent("CustomEvent"),e.initCustomEvent("unhandledrejection",!1,!0,e));e.promise=this;e.reason=this.result_;return k(e)};g.prototype.executeOnSettledCallbacks_=function(){if(null!=this.onSettledCallbacks_){for(var e=0;e<this.onSettledCallbacks_.length;++e)l.asyncExecute(this.onSettledCallbacks_[e]);
this.onSettledCallbacks_=null}};var l=new b;g.prototype.settleSameAsPromise_=function(e){var h=this.createResolveAndReject_();e.callWhenSettled_(h.resolve,h.reject)};g.prototype.settleSameAsThenable_=function(e,h){var k=this.createResolveAndReject_();try{e.call(h,k.resolve,k.reject)}catch(m){k.reject(m)}};g.prototype.then=function(e,h){function k(p,q){return"function"==typeof p?function(r){try{m(p(r))}catch(t){n(t)}}:q}var m,n,u=new g(function(p,q){m=p;n=q});this.callWhenSettled_(k(e,m),k(h,n));return u};
g.prototype.catch=function(e){return this.then(void 0,e)};g.prototype.callWhenSettled_=function(e,h){function k(){switch(m.state_){case f.FULFILLED:e(m.result_);break;case f.REJECTED:h(m.result_);break;default:throw Error("Unexpected state: "+m.state_);}}var m=this;null==this.onSettledCallbacks_?l.asyncExecute(k):this.onSettledCallbacks_.push(k);this.isRejectionHandled_=!0};g.resolve=c;g.reject=function(e){return new g(function(h,k){k(e)})};g.race=function(e){return new g(function(h,k){for(var m=
$jscomp.makeIterator(e),n=m.next();!n.done;n=m.next())c(n.value).callWhenSettled_(h,k)})};g.all=function(e){var h=$jscomp.makeIterator(e),k=h.next();return k.done?c([]):new g(function(m,n){function u(r){return function(t){p[r]=t;q--;0==q&&m(p)}}var p=[],q=0;do p.push(void 0),q++,c(k.value).callWhenSettled_(u(p.length-1),n),k=h.next();while(!k.done)})};return g},"es6","es3");var goog=goog||{};goog.global=this||self;
goog.exportPath_=function(a,b,c,d){a=a.split(".");d=d||goog.global;a[0]in d||"undefined"==typeof d.execScript||d.execScript("var "+a[0]);for(var f;a.length&&(f=a.shift());)if(a.length||void 0===b)d=d[f]&&d[f]!==Object.prototype[f]?d[f]:d[f]={};else if(!c&&goog.isObject(b)&&goog.isObject(d[f]))for(var g in b)b.hasOwnProperty(g)&&(d[f][g]=b[g]);else d[f]=b};goog.define=function(a,b){return a=b};goog.FEATURESET_YEAR=2012;goog.DEBUG=!0;goog.LOCALE="en";goog.getLocale=function(){return goog.LOCALE};
goog.TRUSTED_SITE=!0;goog.DISALLOW_TEST_ONLY_CODE=!goog.DEBUG;goog.ENABLE_CHROME_APP_SAFE_SCRIPT_LOADING=!1;goog.provide=function(a){if(goog.isInModuleLoader_())throw Error("goog.provide cannot be used within a module.");goog.constructNamespace_(a)};goog.constructNamespace_=function(a,b,c){goog.exportPath_(a,b,c)};goog.NONCE_PATTERN_=/^[\w+/_-]+[=]{0,2}$/;
goog.getScriptNonce_=function(a){a=(a||goog.global).document;return(a=a.querySelector&&a.querySelector("script[nonce]"))&&(a=a.nonce||a.getAttribute("nonce"))&&goog.NONCE_PATTERN_.test(a)?a:""};goog.VALID_MODULE_RE_=/^[a-zA-Z_$][a-zA-Z0-9._$]*$/;
goog.module=function(a){if("string"!==typeof a||!a||-1==a.search(goog.VALID_MODULE_RE_))throw Error("Invalid module identifier");if(!goog.isInGoogModuleLoader_())throw Error("Module "+a+" has been loaded incorrectly. Note, modules cannot be loaded as normal scripts. They require some kind of pre-processing step. You're likely trying to load a module via a script tag or as a part of a concatenated bundle without rewriting the module. For more info see: https://github.com/google/closure-library/wiki/goog.module:-an-ES6-module-like-alternative-to-goog.provide.");if(goog.moduleLoaderState_.moduleName)throw Error("goog.module may only be called once per module.");
goog.moduleLoaderState_.moduleName=a};goog.module.get=function(){return null};goog.module.getInternal_=function(){return null};goog.ModuleType={ES6:"es6",GOOG:"goog"};goog.moduleLoaderState_=null;goog.isInModuleLoader_=function(){return goog.isInGoogModuleLoader_()||goog.isInEs6ModuleLoader_()};goog.isInGoogModuleLoader_=function(){return!!goog.moduleLoaderState_&&goog.moduleLoaderState_.type==goog.ModuleType.GOOG};
goog.isInEs6ModuleLoader_=function(){var a=!!goog.moduleLoaderState_&&goog.moduleLoaderState_.type==goog.ModuleType.ES6;return a?!0:(a=goog.global.$jscomp)?"function"!=typeof a.getCurrentModulePath?!1:!!a.getCurrentModulePath():!1};goog.module.declareLegacyNamespace=function(){goog.moduleLoaderState_.declareLegacyNamespace=!0};
goog.declareModuleId=function(a){if(goog.moduleLoaderState_)goog.moduleLoaderState_.moduleName=a;else{var b=goog.global.$jscomp;if(!b||"function"!=typeof b.getCurrentModulePath)throw Error('Module with namespace "'+a+'" has been loaded incorrectly.');b=b.require(b.getCurrentModulePath());goog.loadedModules_[a]={exports:b,type:goog.ModuleType.ES6,moduleId:a}}};
goog.setTestOnly=function(a){if(goog.DISALLOW_TEST_ONLY_CODE)throw a=a||"",Error("Importing test-only code into non-debug environment"+(a?": "+a:"."));};goog.forwardDeclare=function(){};goog.getObjectByName=function(a,b){a=a.split(".");b=b||goog.global;for(var c=0;c<a.length;c++)if(b=b[a[c]],null==b)return null;return b};goog.addDependency=function(){};goog.ENABLE_DEBUG_LOADER=!0;goog.logToConsole_=function(a){goog.global.console&&goog.global.console.error(a)};goog.require=function(){};
goog.requireType=function(){return{}};goog.basePath="";goog.nullFunction=function(){};goog.abstractMethod=function(){throw Error("unimplemented abstract method");};goog.addSingletonGetter=function(a){a.instance_=void 0;a.getInstance=function(){if(a.instance_)return a.instance_;goog.DEBUG&&(goog.instantiatedSingletons_[goog.instantiatedSingletons_.length]=a);return a.instance_=new a}};goog.instantiatedSingletons_=[];goog.LOAD_MODULE_USING_EVAL=!0;goog.SEAL_MODULE_EXPORTS=goog.DEBUG;
goog.loadedModules_={};goog.DEPENDENCIES_ENABLED=!1;goog.TRANSPILE="detect";goog.ASSUME_ES_MODULES_TRANSPILED=!1;goog.TRANSPILE_TO_LANGUAGE="";goog.TRANSPILER="transpile.js";goog.TRUSTED_TYPES_POLICY_NAME="goog";goog.hasBadLetScoping=null;
goog.loadModule=function(a){var b=goog.moduleLoaderState_;try{goog.moduleLoaderState_={moduleName:"",declareLegacyNamespace:!1,type:goog.ModuleType.GOOG};var c={},d=c;if("function"===typeof a)d=a.call(void 0,d);else if("string"===typeof a)d=goog.loadModuleFromSource_.call(void 0,d,a);else throw Error("Invalid module definition");var f=goog.moduleLoaderState_.moduleName;if("string"===typeof f&&f){goog.moduleLoaderState_.declareLegacyNamespace?(a=c!==d,goog.constructNamespace_(f,d,a)):goog.SEAL_MODULE_EXPORTS&&
Object.seal&&"object"==typeof d&&null!=d&&Object.seal(d);var g={exports:d,type:goog.ModuleType.GOOG,moduleId:goog.moduleLoaderState_.moduleName};goog.loadedModules_[f]=g}else throw Error('Invalid module name "'+f+'"');}finally{goog.moduleLoaderState_=b}};goog.loadModuleFromSource_=function(a,b){eval(goog.CLOSURE_EVAL_PREFILTER_.createScript(b));return a};
goog.normalizePath_=function(a){a=a.split("/");for(var b=0;b<a.length;)"."==a[b]?a.splice(b,1):b&&".."==a[b]&&a[b-1]&&".."!=a[b-1]?a.splice(--b,2):b++;return a.join("/")};goog.loadFileSync_=function(a){if(goog.global.CLOSURE_LOAD_FILE_SYNC)return goog.global.CLOSURE_LOAD_FILE_SYNC(a);try{var b=new goog.global.XMLHttpRequest;b.open("get",a,!1);b.send();return 0==b.status||200==b.status?b.responseText:null}catch(c){return null}};
goog.transpile_=function(a,b,c){var d=goog.global.$jscomp;d||(goog.global.$jscomp=d={});var f=d.transpile;if(!f){var g=goog.basePath+goog.TRANSPILER,l=goog.loadFileSync_(g);if(l){(function(){(0,eval)(l+"\n//# sourceURL="+g)}).call(goog.global);if(goog.global.$gwtExport&&goog.global.$gwtExport.$jscomp&&!goog.global.$gwtExport.$jscomp.transpile)throw Error('The transpiler did not properly export the "transpile" method. $gwtExport: '+JSON.stringify(goog.global.$gwtExport));goog.global.$jscomp.transpile=
goog.global.$gwtExport.$jscomp.transpile;d=goog.global.$jscomp;f=d.transpile}}if(!f){var e=" requires transpilation but no transpiler was found.";e+=' Please add "//javascript/closure:transpiler" as a data dependency to ensure it is included.';f=d.transpile=function(h,k){goog.logToConsole_(k+e);return h}}return f(a,b,c)};goog.typeOf=function(a){var b=typeof a;return"object"!=b?b:a?Array.isArray(a)?"array":b:"null"};
goog.isArrayLike=function(a){var b=goog.typeOf(a);return"array"==b||"object"==b&&"number"==typeof a.length};goog.isDateLike=function(a){return goog.isObject(a)&&"function"==typeof a.getFullYear};goog.isObject=function(a){var b=typeof a;return"object"==b&&null!=a||"function"==b};goog.getUid=function(a){return Object.prototype.hasOwnProperty.call(a,goog.UID_PROPERTY_)&&a[goog.UID_PROPERTY_]||(a[goog.UID_PROPERTY_]=++goog.uidCounter_)};goog.hasUid=function(a){return!!a[goog.UID_PROPERTY_]};
goog.removeUid=function(a){null!==a&&"removeAttribute"in a&&a.removeAttribute(goog.UID_PROPERTY_);try{delete a[goog.UID_PROPERTY_]}catch(b){}};goog.UID_PROPERTY_="closure_uid_"+(1E9*Math.random()>>>0);goog.uidCounter_=0;
goog.cloneObject=function(a){var b=goog.typeOf(a);if("object"==b||"array"==b){if("function"===typeof a.clone)return a.clone();if("undefined"!==typeof Map&&a instanceof Map)return new Map(a);if("undefined"!==typeof Set&&a instanceof Set)return new Set(a);b="array"==b?[]:{};for(var c in a)b[c]=goog.cloneObject(a[c]);return b}return a};goog.bindNative_=function(a,b,c){return a.call.apply(a.bind,arguments)};
goog.bindJs_=function(a,b,c){if(!a)throw Error();if(2<arguments.length){var d=Array.prototype.slice.call(arguments,2);return function(){var f=Array.prototype.slice.call(arguments);Array.prototype.unshift.apply(f,d);return a.apply(b,f)}}return function(){return a.apply(b,arguments)}};goog.bind=function(a,b,c){Function.prototype.bind&&-1!=Function.prototype.bind.toString().indexOf("native code")?goog.bind=goog.bindNative_:goog.bind=goog.bindJs_;return goog.bind.apply(null,arguments)};
goog.partial=function(a,b){var c=Array.prototype.slice.call(arguments,1);return function(){var d=c.slice();d.push.apply(d,arguments);return a.apply(this,d)}};goog.mixin=function(a,b){for(var c in b)a[c]=b[c]};goog.now=function(){return Date.now()};goog.globalEval=function(a){(0,eval)(a)};
goog.getCssName=function(a,b){if("."==String(a).charAt(0))throw Error('className passed in goog.getCssName must not start with ".". You passed: '+a);var c=function(f){return goog.cssNameMapping_[f]||f},d=function(f){f=f.split("-");for(var g=[],l=0;l<f.length;l++)g.push(c(f[l]));return g.join("-")};d=goog.cssNameMapping_?"BY_WHOLE"==goog.cssNameMappingStyle_?c:d:function(f){return f};a=b?a+"-"+d(b):d(a);return goog.global.CLOSURE_CSS_NAME_MAP_FN?goog.global.CLOSURE_CSS_NAME_MAP_FN(a):a};
goog.setCssNameMapping=function(a,b){goog.cssNameMapping_=a;goog.cssNameMappingStyle_=b};goog.getMsg=function(a,b,c){c&&c.html&&(a=a.replace(/</g,"<"));c&&c.unescapeHtmlEntities&&(a=a.replace(/</g,"<").replace(/>/g,">").replace(/'/g,"'").replace(/"/g,'"').replace(/&/g,"&"));b&&(a=a.replace(/\{\$([^}]+)}/g,function(d,f){return null!=b&&f in b?b[f]:d}));return a};goog.getMsgWithFallback=function(a){return a};goog.exportSymbol=function(a,b,c){goog.exportPath_(a,b,!0,c)};
goog.exportProperty=function(a,b,c){a[b]=c};goog.inherits=function(a,b){function c(){}c.prototype=b.prototype;a.superClass_=b.prototype;a.prototype=new c;a.prototype.constructor=a;a.base=function(d,f,g){for(var l=Array(arguments.length-2),e=2;e<arguments.length;e++)l[e-2]=arguments[e];return b.prototype[f].apply(d,l)}};goog.scope=function(a){if(goog.isInModuleLoader_())throw Error("goog.scope is not supported within a module.");a.call(goog.global)};
goog.defineClass=function(a,b){var c=b.constructor,d=b.statics;c&&c!=Object.prototype.constructor||(c=function(){throw Error("cannot instantiate an interface (no constructor defined).");});c=goog.defineClass.createSealingConstructor_(c,a);a&&goog.inherits(c,a);delete b.constructor;delete b.statics;goog.defineClass.applyProperties_(c.prototype,b);null!=d&&(d instanceof Function?d(c):goog.defineClass.applyProperties_(c,d));return c};goog.defineClass.SEAL_CLASS_INSTANCES=goog.DEBUG;
goog.defineClass.createSealingConstructor_=function(a){if(!goog.defineClass.SEAL_CLASS_INSTANCES)return a;var b=function(){var c=a.apply(this,arguments)||this;c[goog.UID_PROPERTY_]=c[goog.UID_PROPERTY_];return c};return b};goog.defineClass.OBJECT_PROTOTYPE_FIELDS_="constructor hasOwnProperty isPrototypeOf propertyIsEnumerable toLocaleString toString valueOf".split(" ");
goog.defineClass.applyProperties_=function(a,b){for(var c in b)Object.prototype.hasOwnProperty.call(b,c)&&(a[c]=b[c]);for(var d=0;d<goog.defineClass.OBJECT_PROTOTYPE_FIELDS_.length;d++)c=goog.defineClass.OBJECT_PROTOTYPE_FIELDS_[d],Object.prototype.hasOwnProperty.call(b,c)&&(a[c]=b[c])};goog.identity_=function(a){return a};
goog.createTrustedTypesPolicy=function(a){var b=null,c=goog.global.trustedTypes;if(!c||!c.createPolicy)return b;try{b=c.createPolicy(a,{createHTML:goog.identity_,createScript:goog.identity_,createScriptURL:goog.identity_})}catch(d){goog.logToConsole_(d.message)}return b};var module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper={DomHelper:function(){this.workplace=document;this.body=document.body;this.queryInput=this.workplace.getElementById(module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.QUERY_INPUT_ID);this.queryResult=this.workplace.getElementById(module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.QUERY_RESULT_ID);this.queryResultWrapper=
this.workplace.getElementById(module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.QUERY_RESULT_WRAPPER_ID);this.mic=this.workplace.getElementById(module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.QUERY_MIC_ID);this.preloader=this.workplace.getElementById(module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.PRELOADER_ID);this.agentAvatar=this.workplace.getElementById(module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.ID_AGENT_AVATAR_IMAGE)}};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.showNode=function(a){a.style.display="block"};module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.escapeString=function(a){return a&&a.toString()?a.toString():a};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.prototype.checkAvatar=function(){""===window.AGENT_AVATAR_ID&&(this.agentAvatar.src=module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.DEFAULT_AVATAR_SRC)};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.prototype.hidePreloader=function(){var a=this;setTimeout(function(){return a.preloader.style.opacity="0"},200);setTimeout(function(){return a.preloader.style.display="none"},500)};module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.prototype.setInputValue=function(a){this.queryInput.value=a;return this};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.prototype.addUserRequestNode=function(a){var b=this.workplace.createElement("div");b.className=module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.CLASS_USER_REQUEST;b.textContent=a;this.queryResult.appendChild(b);return this};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.prototype.generateEmptyServerResponseNode=function(){var a=this.workplace.createElement("div");a.className=module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.CLASS_SERVER_RESPONSE;a.textContent=module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.DEFAULT_EMPTY_NODE_CONTENT;this.queryResult.appendChild(a);
return a};module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.prototype.setErrorOnNode=function(a,b){b.textContent=a;b.className+=" "+module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.CLASS_SERVER_RESPONSE_ERROR;return b};module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.prototype.setContentOnNode=function(a,b){b.textContent=a;return this};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.prototype.scrollResultWrapperNodeToBottom=function(){this.queryResultWrapper.scrollTop=this.queryResultWrapper.scrollHeight;return this};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.prototype.handleStartRecognition=function(){this.mic.className+=" "+module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.CLASS_MIC_ACTIVE;return this};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.prototype.handleStopRecognition=function(){var a=new RegExp("(?:^|\\s)"+module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.CLASS_MIC_ACTIVE+"(?!\\S)","gi");this.mic.className=this.mic.className.replace(a,"");return this};module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.QUERY_INPUT_ID="query";
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.QUERY_RESULT_ID="result";module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.QUERY_RESULT_WRAPPER_ID="resultWrapper";module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.QUERY_MIC_ID="mic";
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.PRELOADER_ID="preloader";module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.CLASS_USER_REQUEST="user-request";module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.CLASS_SERVER_RESPONSE="server-response";
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.CLASS_SERVER_RESPONSE_ERROR="server-response-error";module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.ID_AGENT_AVATAR_IMAGE="agent-avatar";module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.CLASS_MIC_ACTIVE="active";
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.DEFAULT_EMPTY_NODE_CONTENT="...";module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.DEFAULT_AVATAR_SRC="https://www.gstatic.com/dialogflow-console/common/assets/img/logo-short.png";var module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest={},module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest=function(){};
module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.ajax=function(a,b,c,d){c=void 0===c?null:c;d=void 0===d?null:d;return new Promise(function(f,g){var l=module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.createXMLHTTPObject(),e=b,h=null;if(c&&a===module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.Method.GET){e+="?";var k=0,m;for(m in c)c.hasOwnProperty(m)&&
(k++&&(e+="&"),e+=encodeURIComponent(m)+"="+encodeURIComponent(c[m]))}else c&&(d||(d={}),d["Content-Type"]="application/json",h=JSON.stringify(c));l.open(a,e);if(d)for(var n in d)d.hasOwnProperty(n)&&l.setRequestHeader(n,d[n]);h?l.send(h):l.send();l.onload=function(){200<=l.status&&300>l.status?f(l):g(l)};l.onerror=function(){g(l)}})};
module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.get=function(a,b,c){b=void 0===b?null:b;c=void 0===c?null:c;return module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.ajax(module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.Method.GET,a,b,c)};
module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.post=function(a,b,c){b=void 0===b?null:b;c=void 0===c?null:c;return module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.ajax(module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.Method.POST,a,b,c)};
module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.put=function(a,b,c){b=void 0===b?null:b;c=void 0===c?null:c;return module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.ajax(module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.Method.PUT,a,b,c)};
module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.delete=function(a,b,c){b=void 0===b?null:b;c=void 0===c?null:c;return module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.ajax(module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.Method.DELETE,a,b,c)};
module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.createXMLHTTPObject=function(){for(var a=null,b=0;b<module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.XMLHttpFactories.length;b++)if(module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.XMLHttpFactories.hasOwnProperty(b)){try{a=module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.XMLHttpFactories[b]()}catch(c){continue}break}return a};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest.XhrRequest=module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest;module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest.XMLHttpFactories=[function(){return new XMLHttpRequest},function(){return new ActiveXObject("Msxml2.XMLHTTP")},function(){return new ActiveXObject("Msxml3.XMLHTTP")},function(){return new ActiveXObject("Microsoft.XMLHTTP")}];
var XhrRequest$jscomp$inline_10=module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest_XhrRequest=module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest.XhrRequest||(module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest.XhrRequest={}),Method$jscomp$inline_11=XhrRequest$jscomp$inline_10.Method||(XhrRequest$jscomp$inline_10.Method={});Method$jscomp$inline_11.GET="GET";
Method$jscomp$inline_11.POST="POST";Method$jscomp$inline_11.PUT="PUT";Method$jscomp$inline_11.DELETE="DELETE";var module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App={},module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App_V2_ENABLED=window.V2_ENABLED;
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App=function(a){var b=this;this.domHelper=a;this.handleMicClick=function(){b.isRecognizing?b.recognition.stop():b.recognition.start()};this.hanleInputKeyDown=function(c){c.keyCode===module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.KEY_CODES.ENTER&&(c.preventDefault(),c.stopPropagation(),b.handleInput())};this.handleInput=function(){var c=b.domHelper.queryInput.value;""!==
c.replace(/\s/g,"")&&(b.domHelper.addUserRequestNode(module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.escapeString(c)),c=b.domHelper.generateEmptyServerResponseNode(),c=b.generateCallbacksForNode(c),module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App_V2_ENABLED?module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest.XhrRequest.post(module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.MESSENGER_API_URL_BASE+
"/"+window.AGENT_ID+"/sessions/webdemo-"+b.sessionId+"?platform=webdemo",b.buildV2Payload(b.domHelper.queryInput.value)).then(c.success,c.error):module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$XhrRequest.XhrRequest.get(module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.API_URL,b.buildPayLoad(b.domHelper.queryInput.value)).then(c.success,c.error),b.domHelper.setInputValue("").scrollResultWrapperNodeToBottom())};this.sessionId=
this.guid()};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.prototype.bindEventHandlers=function(){this.domHelper.queryInput.addEventListener("keydown",this.hanleInputKeyDown,!1);"webkitSpeechRecognition"in window&&(this.initRecognition(),module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.showNode(this.domHelper.mic),this.domHelper.mic.addEventListener("click",this.handleMicClick,!1));this.domHelper.checkAvatar();this.domHelper.hidePreloader()};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.prototype.initRecognition=function(){var a=this,b=new webkitSpeechRecognition;b.onstart=function(){a.isRecognizing=!0;a.domHelper.handleStartRecognition()};b.onerror=function(){};b.onend=function(){a.domHelper.handleStopRecognition();a.isRecognizing=!1};b.onresult=function(c){for(var d="",f=c.resultIndex;f<c.results.length;++f)c.results[f].isFinal&&(d+=c.results[f][0].transcript);a.domHelper.setInputValue(d);
a.handleInput()};b.lang=window.AGENT_LANGUAGE||"en-US";this.recognition=b};module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.prototype.buildPayLoad=function(a){return{q:encodeURI(a),sessionId:encodeURI(this.sessionId)}};module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.prototype.buildV2Payload=function(a){return{queryInput:{text:{text:a,languageCode:window.AGENT_LANGUAGE||"en"}}}};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.prototype.handleV2Response=function(a,b){var c;var d=a.response&&a.response.indexOf&&0===a.response.indexOf(")]}'\n")?a.response.substring(5):a.responseText&&a.responseText.indexOf&&0===a.responseText.indexOf(")]}'\n")?a.responseText.substring(5):a.response?a.response:a.responseText;a={responseId:""};try{a=JSON.parse(d)}catch(g){this.handleError(null,b);return}d=this.getV2Speech(a);this.domHelper.setContentOnNode(d,
b).scrollResultWrapperNodeToBottom();if(a.outputAudio&&(null===(c=a.outputAudioConfig)||void 0===c?0:c.audioEncoding)){var f=document.createElement("audio");f.id="audio-"+a.responseId;f.src=this.generateAudioDataUri(a.outputAudioConfig.audioEncoding,a.outputAudio);a=document.createElement("span");a.className="material-icons-extended";a.innerText="volume_up";a.style.cursor="pointer";a.style.fontSize="18px";a.style.display="inline-block";a.style.marginLeft="8px";a.style.verticalAlign="baseline";a.addEventListener("click",
function(){f.play()});a.addEventListener("click",function(){f.play()});b.appendChild(f);b.appendChild(a)}};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.prototype.handleResponse=function(a,b){var c=a.response?a.response:a.responseText;a=null;try{a=JSON.parse(c)}catch(f){return this.handleError(a,b)}if(!(a.status&&a.status.code&&a.status.code===module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.HTTP_STATUS.OK&&a.result&&a.result))return this.handleError(a,b);c=this.getSpeech(a.result);this.domHelper.setContentOnNode(c,
b).scrollResultWrapperNodeToBottom();if(a.audioDataUri){var d=document.createElement("audio");d.id="audio-"+a.id;d.src=a.audioDataUri;a=document.createElement("span");a.className="material-icons-extended";a.innerText="volume_up";a.style.cursor="pointer";a.style.fontSize="18px";a.style.display="inline-block";a.style.marginLeft="8px";a.style.verticalAlign="baseline";a.addEventListener("click",function(){d.play()});b.appendChild(d);b.appendChild(a)}};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.prototype.generateCallbacksForNode=function(a){var b=this;return{success:function(c){module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App_V2_ENABLED?b.handleV2Response(c,a):b.handleResponse(c,a)},error:function(c){module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App_V2_ENABLED?b.handleError(null,a):b.handleResponse(c,a)}}};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.prototype.getSpeech=function(a){a=a.speech||(a.fulfillment?a.fulfillment.speech:module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.DEFAULT_NO_ANSWER);a||(a=module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.DEFAULT_NO_ANSWER);return module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.escapeString(a)};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.prototype.getV2Speech=function(a){var b,c;return(null===(b=a.queryResult)||void 0===b?0:b.fulfillmentText)?module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper.escapeString(null===(c=a.queryResult)||void 0===c?void 0:c.fulfillmentText):module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.DEFAULT_NO_ANSWER};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.prototype.handleError=function(a,b){a=a&&a.status&&a.status.errorDetails?a.status.errorDetails:module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.DEFAULT_ERROR;this.domHelper.setErrorOnNode(a,b)};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.prototype.guid=function(){var a=function(){return Math.floor(65536*(1+Math.random())).toString(16).substring(1)};return a()+a()+"-"+a()+"-"+a()+"-"+a()+"-"+a()+a()+a()};
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.prototype.generateAudioDataUri=function(a,b){var c="";"OUTPUT_AUDIO_ENCODING_MP3"===a?c="audio/mp3":"OUTPUT_AUDIO_ENCODING_OGG_OPUS"===a?c="audio/ogg;codecs=opus":"OUTPUT_AUDIO_ENCODING_LINEAR_16"===a&&(c="audio/wav");return"data:"+c+";base64,"+b};module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.API_URL=location.href+"/demoQuery";
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.MESSENGER_API_URL_BASE="/v1/integrations/messenger/webhook";module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.DEFAULT_ERROR="Sorry, it seemed like there was an error during request.";module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.DEFAULT_NO_ANSWER="[empty response]";
module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.HTTP_STATUS={OK:200};module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App.KEY_CODES={ENTER:13};window.addStyleString('body {\n margin: 0;\n background: white;\n}\naudio {\n -webkit-transition: all 0.5s linear;\n -moz-transition: all 0.5s linear;\n -o-transition: all 0.5s linear;\n transition: all 0.5s linear;\n -moz-box-shadow: 2px 2px 4px 0px #006773;\n -webkit-box-shadow: 2px 2px 4px 0px #006773;\n box-shadow: 2px 2px 4px 0px #006773;\n -moz-border-radius: 7px 7px 7px 7px;\n -webkit-border-radius: 7px 7px 7px 7px ;\n border-radius: 7px 7px 7px 7px;\n float: right;\n margin-right: 15px;\n}\nform {\n margin: 0;\n}\n.b-agent-demo {\n font-family: "Roboto", "Helvetica Neue", Helvetica, Arial, sans-serif;\n font-weight: 300;\n width: 100%;\n height: auto;\n color: #2b313f;\n font-size: 12px;\n overflow: hidden;\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n}\n.b-agent-demo .user-request,\n.b-agent-demo .server-response {\n display: inline-block;\n padding: 15px 25px;\n border-radius: 3px;\n border: 1px solid #eee;\n margin-bottom: 5px;\n font-size: 16px;\n clear: both;\n}\n.b-agent-demo .user-request.server-response-error,\n.b-agent-demo .server-response.server-response-error {\n background-color: #f76949;\n}\n.b-agent-demo .user-request {\n background-color: #efefef;\n float: left;\n margin-right: 15px;\n margin-top: 15px;\n margin-left: 15px;\n}\n.b-agent-demo .server-response {\n color: #ffffff;\n background-color: #a5d175;\n float: right;\n margin-top: 15px;\n margin-right: 15px;\n margin-left: 15px;\n}\n.b-agent-demo .b-agent-demo_result {\n overflow-y: auto;\n background: white;\n position: fixed;\n top: 110px;\n bottom: 55px;\n width: 100%;\n}\n.b-agent-demo .b-agent-demo_result-table {\n height: 100%;\n min-height: 100%;\n width: 100%;\n}\n.b-agent-demo .b-agent-demo_result-table td {\n vertical-align: bottom;\n}\n.b-agent-demo .b-agent-demo_header {\n min-height: 80px;\n height: 80px;\n overflow: hidden;\n position: fixed;\n top: 0;\n width: 100%;\n background-color: #2b303e;\n display: table;\n}\n.b-agent-demo .b-agent-demo_header-wrapper {\n display: table-cell;\n vertical-align: middle;\n}\n.b-agent-demo .b-agent-demo_header-icon {\n position: absolute;\n top: 20px;\n left: 20px;\n width: 40px;\n height: 40px;\n border-radius: 100%;\n /*background-color: @response-color;*/\n overflow: hidden;\n vertical-align: middle;\n text-align: center;\n}\n.b-agent-demo .b-agent-demo_header-icon img {\n max-height: 100%;\n max-width: 100%;\n width: auto;\n height: auto;\n position: absolute;\n top: 0;\n bottom: 0;\n left: 0;\n right: 0;\n border: 0;\n margin: auto;\n}\n.b-agent-demo .b-agent-demo_header-agent-name {\n padding-left: 80px;\n font-size: 18px;\n color: #ffffff;\n}\n.b-agent-demo .b-agent-demo_header-description {\n color: #b7bbc4;\n padding-left: 80px;\n padding-top: 7px;\n font-size: 12px;\n display: block;\n /* Fallback for non-webkit */\n display: -webkit-box;\n max-height: 24px;\n /* Fallback for non-webkit */\n margin: 0 auto;\n line-height: 1;\n -webkit-line-clamp: 2;\n -webkit-box-orient: vertical;\n overflow: hidden;\n text-overflow: ellipsis;\n}\n.b-agent-demo .b-agent-demo_input {\n position: fixed;\n bottom: 0;\n height: 55px;\n border-top: 1px solid lightgray;\n background-color: white;\n width: 100%;\n}\n.b-agent-demo #agentDemoForm {\n display: block;\n margin-left: 15px;\n margin-right: 55px;\n}\n.b-agent-demo #query {\n width: 100%;\n border: 0;\n font-size: 16px;\n font-weight: 300;\n margin: 0;\n height: 55px;\n}\n.b-agent-demo #query:focus {\n outline: none;\n outline-offset: 0;\n}\n.b-agent-demo .b-agent-demo_input-microphone {\n display: none;\n position: absolute;\n font-size: 20px;\n width: 54px;\n height: 54px;\n right: 0;\n bottom: 0;\n cursor: pointer;\n text-align: center;\n /* line-height: 30px; */\n line-height: 54px;\n background: white;\n color: #b7bbc4;\n}\n.b-agent-demo .b-agent-demo_input-microphone.active {\n color: #f76949;\n}\n.b-agent-demo .b-agent-demo_powered_by {\n position: fixed;\n left: 0;\n right: 0;\n top: 80px;\n height: 30px;\n background-color: #F8F8F8;\n vertical-align: middle;\n}\n.b-agent-demo .b-agent-demo_powered_by span {\n color: #b7bbc4;\n text-transform: uppercase;\n float: right;\n vertical-align: middle;\n line-height: 20px;\n margin-top: 5px;\n margin-right: 10px;\n font-size: 10px;\n margin-left: -10px;\n}\n.b-agent-demo .b-agent-demo_powered_by img {\n margin-top: 7px;\n height: 16px;\n margin-right: 20px;\n float: right;\n vertical-align: middle;\n border: 0;\n}\n.clearfix {\n clear: both;\n}\n');var module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$main_domHelper=new module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$DomHelper.DomHelper,module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$main_app=new module$exports$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$App.App(module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$main_domHelper);module$contents$google3$third_party$apiai$ui$legacy$src$main$webapp$js$agentDemoApp$main_app.bindEventHandlers();