altair-static 4.1.0 → 4.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (98) hide show
  1. package/build/dist/100.js +1 -0
  2. package/build/dist/108.js +1 -0
  3. package/build/dist/267.js +1 -0
  4. package/build/dist/379.js +1 -0
  5. package/build/dist/3rdpartylicenses.txt +844 -93
  6. package/build/dist/471.js +1 -0
  7. package/build/dist/527.js +1 -0
  8. package/build/dist/604.js +1 -0
  9. package/build/dist/729.js +1 -0
  10. package/build/dist/747.js +1 -0
  11. package/build/dist/790.js +1 -0
  12. package/build/dist/794.js +1 -0
  13. package/build/dist/873.js +1 -0
  14. package/build/dist/929.js +1 -0
  15. package/build/dist/934.js +1 -0
  16. package/build/dist/assets/i18n/ach-UG.json +157 -153
  17. package/build/dist/assets/i18n/cs-CZ.json +4 -0
  18. package/build/dist/assets/i18n/da-DK.json +4 -0
  19. package/build/dist/assets/i18n/de-DE.json +4 -0
  20. package/build/dist/assets/i18n/default.json +10 -1
  21. package/build/dist/assets/i18n/en-US.json +4 -0
  22. package/build/dist/assets/i18n/es-ES.json +4 -0
  23. package/build/dist/assets/i18n/fi-FI.json +4 -0
  24. package/build/dist/assets/i18n/fr-FR.json +4 -0
  25. package/build/dist/assets/i18n/hu-HU.json +4 -0
  26. package/build/dist/assets/i18n/it-IT.json +4 -0
  27. package/build/dist/assets/i18n/ja-JP.json +4 -0
  28. package/build/dist/assets/i18n/ko-KR.json +4 -0
  29. package/build/dist/assets/i18n/nl-NL.json +4 -0
  30. package/build/dist/assets/i18n/no-NO.json +4 -0
  31. package/build/dist/assets/i18n/pl-PL.json +4 -0
  32. package/build/dist/assets/i18n/pt-BR.json +4 -0
  33. package/build/dist/assets/i18n/pt-PT.json +4 -0
  34. package/build/dist/assets/i18n/ro-RO.json +4 -0
  35. package/build/dist/assets/i18n/ru-RU.json +30 -26
  36. package/build/dist/assets/i18n/sr-SP.json +4 -0
  37. package/build/dist/assets/i18n/sv-SE.json +4 -0
  38. package/build/dist/assets/i18n/tr-TR.json +4 -0
  39. package/build/dist/assets/i18n/uk-UA.json +4 -0
  40. package/build/dist/assets/i18n/vi-VN.json +4 -0
  41. package/build/dist/assets/i18n/zh-CN.json +12 -8
  42. package/build/dist/assets/i18n/zh-TW.json +4 -0
  43. package/build/dist/index.html +3 -3
  44. package/build/dist/main.js +1 -0
  45. package/build/dist/polyfills.js +1 -0
  46. package/build/dist/runtime.js +1 -0
  47. package/build/dist/styles.css +2 -2
  48. package/build/index.d.ts +1 -0
  49. package/build/index.js +4 -1
  50. package/build/index.test.d.ts +1 -0
  51. package/build/index.test.js +17 -6
  52. package/build/utils/get-altair-html.d.ts +1 -0
  53. package/build/utils/get-dist.d.ts +1 -0
  54. package/package.json +4 -4
  55. package/src/index.test.ts +21 -6
  56. package/src/index.ts +6 -3
  57. package/tsconfig.json +1 -0
  58. package/build/dist/108-es2018.js +0 -1
  59. package/build/dist/108-es5.js +0 -1
  60. package/build/dist/283-es2018.js +0 -1
  61. package/build/dist/283-es5.js +0 -1
  62. package/build/dist/379-es2018.js +0 -1
  63. package/build/dist/379-es5.js +0 -1
  64. package/build/dist/471-es2018.js +0 -1
  65. package/build/dist/471-es5.js +0 -1
  66. package/build/dist/527-es2018.js +0 -1
  67. package/build/dist/527-es5.js +0 -1
  68. package/build/dist/604-es2018.js +0 -1
  69. package/build/dist/604-es5.js +0 -1
  70. package/build/dist/672-es2018.js +0 -1
  71. package/build/dist/672-es5.js +0 -1
  72. package/build/dist/709-es2018.js +0 -1
  73. package/build/dist/709-es5.js +0 -1
  74. package/build/dist/729-es2018.js +0 -1
  75. package/build/dist/729-es5.js +0 -1
  76. package/build/dist/747-es2018.js +0 -1
  77. package/build/dist/747-es5.js +0 -1
  78. package/build/dist/790-es2018.js +0 -1
  79. package/build/dist/790-es5.js +0 -1
  80. package/build/dist/794-es2018.js +0 -1
  81. package/build/dist/794-es5.js +0 -1
  82. package/build/dist/866-es2018.js +0 -1
  83. package/build/dist/866-es5.js +0 -1
  84. package/build/dist/873-es2018.js +0 -1
  85. package/build/dist/873-es5.js +0 -1
  86. package/build/dist/934-es2018.js +0 -1
  87. package/build/dist/934-es5.js +0 -1
  88. package/build/dist/main-es2018.js +0 -1
  89. package/build/dist/main-es5.js +0 -1
  90. package/build/dist/polyfills-es2018.js +0 -1
  91. package/build/dist/polyfills-es5.js +0 -1
  92. package/build/dist/runtime-es2018.js +0 -1
  93. package/build/dist/runtime-es5.js +0 -1
  94. package/build/index.js.map +0 -1
  95. package/build/index.test.js.map +0 -1
  96. package/build/utils/get-altair-html.js.map +0 -1
  97. package/build/utils/get-dist.js.map +0 -1
  98. package/scripts/prepare_dist.js +0 -77
@@ -1 +0,0 @@
1
- !function(){"use strict";(self.webpackChunkaltair_app=self.webpackChunkaltair_app||[]).push([[747],{44461:function(e,n,t){t.d(n,{Z:function(){return o}});var i=t(34248),r=t(36386);function o(e){var n=e.prototype.toJSON;"function"==typeof n||(0,i.Z)(0),e.prototype.inspect=n,r.Z&&(e.prototype[r.Z]=n)}},95897:function(e,n,t){t.d(n,{Z:function(){return o}});var i=t(36386);function r(e){return(r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e})(e)}function o(e){return u(e,[])}function u(e,n){switch(r(e)){case"string":return JSON.stringify(e);case"function":return e.name?"[function ".concat(e.name,"]"):"[function]";case"object":return null===e?"null":function(e,n){if(-1!==n.indexOf(e))return"[Circular]";var t=[].concat(n,[e]),r=function(e){var n=e[String(i.Z)];return"function"==typeof n?n:"function"==typeof e.inspect?e.inspect:void 0}(e);if(void 0!==r){var o=r.call(e);if(o!==e)return"string"==typeof o?o:u(o,t)}else if(Array.isArray(e))return function(e,n){if(0===e.length)return"[]";if(n.length>2)return"[Array]";for(var t=Math.min(10,e.length),i=e.length-t,r=[],o=0;o<t;++o)r.push(u(e[o],n));return 1===i?r.push("... 1 more item"):i>1&&r.push("... ".concat(i," more items")),"["+r.join(", ")+"]"}(e,t);return function(e,n){var t=Object.keys(e);return 0===t.length?"{}":n.length>2?"["+function(e){var n=Object.prototype.toString.call(e).replace(/^\[object /,"").replace(/]$/,"");if("Object"===n&&"function"==typeof e.constructor){var t=e.constructor.name;if("string"==typeof t&&""!==t)return t}return n}(e)+"]":"{ "+t.map(function(t){return t+": "+u(e[t],n)}).join(", ")+" }"}(e,t)}(e,n);default:return String(e)}}},34248:function(e,n,t){function i(e,n){if(!Boolean(e))throw new Error(null!=n?n:"Unexpected invariant triggered.")}t.d(n,{Z:function(){return i}})},36386:function(e,n){var t="function"==typeof Symbol&&"function"==typeof Symbol.for?Symbol.for("nodejs.util.inspect.custom"):void 0;n.Z=t},31279:function(e,n,t){t.d(n,{Ye:function(){return r},WU:function(){return o},UG:function(){return u}});var i=t(44461),r=function(){function e(e,n,t){this.start=e.start,this.end=n.end,this.startToken=e,this.endToken=n,this.source=t}return e.prototype.toJSON=function(){return{start:this.start,end:this.end}},e}();(0,i.Z)(r);var o=function(){function e(e,n,t,i,r,o,u){this.kind=e,this.start=n,this.end=t,this.line=i,this.column=r,this.value=u,this.prev=o,this.next=null}return e.prototype.toJSON=function(){return{kind:this.kind,value:this.value,line:this.line,column:this.column}},e}();function u(e){return null!=e&&"string"==typeof e.kind}(0,i.Z)(o)},33951:function(e,n,t){function i(e){var n=e.split(/\r\n|[\n\r]/g),t=o(e);if(0!==t)for(var i=1;i<n.length;i++)n[i]=n[i].slice(t);for(var u=0;u<n.length&&r(n[u]);)++u;for(var a=n.length;a>u&&r(n[a-1]);)--a;return n.slice(u,a).join("\n")}function r(e){for(var n=0;n<e.length;++n)if(" "!==e[n]&&"\t"!==e[n])return!1;return!0}function o(e){for(var n,t=!0,i=!0,r=0,o=null,u=0;u<e.length;++u)switch(e.charCodeAt(u)){case 13:10===e.charCodeAt(u+1)&&++u;case 10:t=!1,i=!0,r=0;break;case 9:case 32:++r;break;default:i&&!t&&(null===o||r<o)&&(o=r),i=!1}return null!==(n=o)&&void 0!==n?n:0}function u(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",t=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=-1===e.indexOf("\n"),r=" "===e[0]||"\t"===e[0],o='"'===e[e.length-1],u="\\"===e[e.length-1],a=!i||o||u||t,c="";return a&&!(i&&r)&&(c+="\n"+n),c+=n?e.replace(/\n/g,"\n"+n):e,a&&(c+="\n"),'"""'+c.replace(/"""/g,'\\"""')+'"""'}t.d(n,{W7:function(){return i},Z2:function(){return o},LZ:function(){return u}})},87948:function(e,n,t){t.d(n,{h:function(){return i}});var i=Object.freeze({NAME:"Name",DOCUMENT:"Document",OPERATION_DEFINITION:"OperationDefinition",VARIABLE_DEFINITION:"VariableDefinition",SELECTION_SET:"SelectionSet",FIELD:"Field",ARGUMENT:"Argument",FRAGMENT_SPREAD:"FragmentSpread",INLINE_FRAGMENT:"InlineFragment",FRAGMENT_DEFINITION:"FragmentDefinition",VARIABLE:"Variable",INT:"IntValue",FLOAT:"FloatValue",STRING:"StringValue",BOOLEAN:"BooleanValue",NULL:"NullValue",ENUM:"EnumValue",LIST:"ListValue",OBJECT:"ObjectValue",OBJECT_FIELD:"ObjectField",DIRECTIVE:"Directive",NAMED_TYPE:"NamedType",LIST_TYPE:"ListType",NON_NULL_TYPE:"NonNullType",SCHEMA_DEFINITION:"SchemaDefinition",OPERATION_TYPE_DEFINITION:"OperationTypeDefinition",SCALAR_TYPE_DEFINITION:"ScalarTypeDefinition",OBJECT_TYPE_DEFINITION:"ObjectTypeDefinition",FIELD_DEFINITION:"FieldDefinition",INPUT_VALUE_DEFINITION:"InputValueDefinition",INTERFACE_TYPE_DEFINITION:"InterfaceTypeDefinition",UNION_TYPE_DEFINITION:"UnionTypeDefinition",ENUM_TYPE_DEFINITION:"EnumTypeDefinition",ENUM_VALUE_DEFINITION:"EnumValueDefinition",INPUT_OBJECT_TYPE_DEFINITION:"InputObjectTypeDefinition",DIRECTIVE_DEFINITION:"DirectiveDefinition",SCHEMA_EXTENSION:"SchemaExtension",SCALAR_TYPE_EXTENSION:"ScalarTypeExtension",OBJECT_TYPE_EXTENSION:"ObjectTypeExtension",INTERFACE_TYPE_EXTENSION:"InterfaceTypeExtension",UNION_TYPE_EXTENSION:"UnionTypeExtension",ENUM_TYPE_EXTENSION:"EnumTypeExtension",INPUT_OBJECT_TYPE_EXTENSION:"InputObjectTypeExtension"})},71352:function(e,n,t){t.r(n),t.d(n,{print:function(){return o}});var i=t(86729),r=t(33951);function o(e){return(0,i.Vn)(e,{leave:u})}var u={Name:function(e){return e.value},Variable:function(e){return"$"+e.name},Document:function(e){return c(e.definitions,"\n\n")+"\n"},OperationDefinition:function(e){var n=e.operation,t=e.name,i=l("(",c(e.variableDefinitions,", "),")"),r=c(e.directives," "),o=e.selectionSet;return t||r||i||"query"!==n?c([n,c([t,i]),r,o]," "):o},VariableDefinition:function(e){var n=e.directives;return e.variable+": "+e.type+l(" = ",e.defaultValue)+l(" ",c(n," "))},SelectionSet:function(e){return f(e.selections)},Field:function(e){var n=e.name,t=e.arguments,i=e.directives,r=e.selectionSet,o=l("",e.alias,": ")+n,u=o+l("(",c(t,", "),")");return u.length>80&&(u=o+l("(\n",s(c(t,"\n")),"\n)")),c([u,c(i," "),r]," ")},Argument:function(e){return e.name+": "+e.value},FragmentSpread:function(e){return"..."+e.name+l(" ",c(e.directives," "))},InlineFragment:function(e){var n=e.directives,t=e.selectionSet;return c(["...",l("on ",e.typeCondition),c(n," "),t]," ")},FragmentDefinition:function(e){var n=e.typeCondition,t=e.variableDefinitions,i=e.directives,r=e.selectionSet;return"fragment ".concat(e.name).concat(l("(",c(t,", "),")")," ")+"on ".concat(n," ").concat(l("",c(i," ")," "))+r},IntValue:function(e){return e.value},FloatValue:function(e){return e.value},StringValue:function(e,n){var t=e.value;return e.block?(0,r.LZ)(t,"description"===n?"":" "):JSON.stringify(t)},BooleanValue:function(e){return e.value?"true":"false"},NullValue:function(){return"null"},EnumValue:function(e){return e.value},ListValue:function(e){return"["+c(e.values,", ")+"]"},ObjectValue:function(e){return"{"+c(e.fields,", ")+"}"},ObjectField:function(e){return e.name+": "+e.value},Directive:function(e){return"@"+e.name+l("(",c(e.arguments,", "),")")},NamedType:function(e){return e.name},ListType:function(e){return"["+e.type+"]"},NonNullType:function(e){return e.type+"!"},SchemaDefinition:a(function(e){var n=e.operationTypes;return c(["schema",c(e.directives," "),f(n)]," ")}),OperationTypeDefinition:function(e){return e.operation+": "+e.type},ScalarTypeDefinition:a(function(e){return c(["scalar",e.name,c(e.directives," ")]," ")}),ObjectTypeDefinition:a(function(e){var n=e.directives,t=e.fields;return c(["type",e.name,l("implements ",c(e.interfaces," & ")),c(n," "),f(t)]," ")}),FieldDefinition:a(function(e){var n=e.arguments,t=e.type,i=e.directives;return e.name+(v(n)?l("(\n",s(c(n,"\n")),"\n)"):l("(",c(n,", "),")"))+": "+t+l(" ",c(i," "))}),InputValueDefinition:a(function(e){var n=e.directives;return c([e.name+": "+e.type,l("= ",e.defaultValue),c(n," ")]," ")}),InterfaceTypeDefinition:a(function(e){var n=e.directives,t=e.fields;return c(["interface",e.name,l("implements ",c(e.interfaces," & ")),c(n," "),f(t)]," ")}),UnionTypeDefinition:a(function(e){var n=e.types;return c(["union",e.name,c(e.directives," "),n&&0!==n.length?"= "+c(n," | "):""]," ")}),EnumTypeDefinition:a(function(e){var n=e.values;return c(["enum",e.name,c(e.directives," "),f(n)]," ")}),EnumValueDefinition:a(function(e){return c([e.name,c(e.directives," ")]," ")}),InputObjectTypeDefinition:a(function(e){var n=e.fields;return c(["input",e.name,c(e.directives," "),f(n)]," ")}),DirectiveDefinition:a(function(e){var n=e.arguments,t=e.repeatable,i=e.locations;return"directive @"+e.name+(v(n)?l("(\n",s(c(n,"\n")),"\n)"):l("(",c(n,", "),")"))+(t?" repeatable":"")+" on "+c(i," | ")}),SchemaExtension:function(e){var n=e.operationTypes;return c(["extend schema",c(e.directives," "),f(n)]," ")},ScalarTypeExtension:function(e){return c(["extend scalar",e.name,c(e.directives," ")]," ")},ObjectTypeExtension:function(e){var n=e.directives,t=e.fields;return c(["extend type",e.name,l("implements ",c(e.interfaces," & ")),c(n," "),f(t)]," ")},InterfaceTypeExtension:function(e){var n=e.directives,t=e.fields;return c(["extend interface",e.name,l("implements ",c(e.interfaces," & ")),c(n," "),f(t)]," ")},UnionTypeExtension:function(e){var n=e.types;return c(["extend union",e.name,c(e.directives," "),n&&0!==n.length?"= "+c(n," | "):""]," ")},EnumTypeExtension:function(e){var n=e.values;return c(["extend enum",e.name,c(e.directives," "),f(n)]," ")},InputObjectTypeExtension:function(e){var n=e.fields;return c(["extend input",e.name,c(e.directives," "),f(n)]," ")}};function a(e){return function(n){return c([n.description,e(n)],"\n")}}function c(e){var n,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return null!==(n=null==e?void 0:e.filter(function(e){return e}).join(t))&&void 0!==n?n:""}function f(e){return l("{\n",s(c(e,"\n")),"\n}")}function l(e,n){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"";return null!=n&&""!==n?e+n+t:""}function s(e){return l(" ",e.replace(/\n/g,"\n "))}function p(e){return-1!==e.indexOf("\n")}function v(e){return null!=e&&e.some(p)}},86729:function(e,n,t){t.d(n,{$_:function(){return u},Vn:function(){return a},j1:function(){return c},CK:function(){return f}});var i=t(95897),r=t(31279),o={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentSpread:["name","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["description","directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","interfaces","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","locations"],SchemaExtension:["directives","operationTypes"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","interfaces","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]},u=Object.freeze({});function a(e,n){var t=arguments.length>2&&void 0!==arguments[2]?arguments[2]:o,a=void 0,c=Array.isArray(e),l=[e],s=-1,p=[],v=void 0,d=void 0,m=void 0,y=[],E=[],T=e;do{var I=++s===l.length,N=I&&0!==p.length;if(I){if(d=0===E.length?void 0:y[y.length-1],v=m,m=E.pop(),N){if(c)v=v.slice();else{for(var D={},O=0,h=Object.keys(v);O<h.length;O++){var g=h[O];D[g]=v[g]}v=D}for(var S=0,b=0;b<p.length;b++){var _=p[b][0],V=p[b][1];c&&(_-=S),c&&null===V?(v.splice(_,1),S++):v[_]=V}}s=a.index,l=a.keys,p=a.edits,c=a.inArray,a=a.prev}else{if(d=m?c?s:l[s]:void 0,null==(v=m?m[d]:T))continue;m&&y.push(d)}var F,A=void 0;if(!Array.isArray(v)){if(!(0,r.UG)(v))throw new Error("Invalid AST Node: ".concat((0,i.Z)(v),"."));var x=f(n,v.kind,I);if(x){if((A=x.call(n,v,d,m,y,E))===u)break;if(!1===A){if(!I){y.pop();continue}}else if(void 0!==A&&(p.push([d,A]),!I)){if(!(0,r.UG)(A)){y.pop();continue}v=A}}}void 0===A&&N&&p.push([d,v]),I?y.pop():(a={inArray:c,index:s,keys:l,edits:p,prev:a},l=(c=Array.isArray(v))?v:null!==(F=t[v.kind])&&void 0!==F?F:[],s=-1,p=[],m&&E.push(m),m=v)}while(void 0!==a);return 0!==p.length&&(T=p[p.length-1][1]),T}function c(e){var n=new Array(e.length);return{enter:function(t){for(var i=0;i<e.length;i++)if(null==n[i]){var r=f(e[i],t.kind,!1);if(r){var o=r.apply(e[i],arguments);if(!1===o)n[i]=t;else if(o===u)n[i]=u;else if(void 0!==o)return o}}},leave:function(t){for(var i=0;i<e.length;i++)if(null==n[i]){var r=f(e[i],t.kind,!0);if(r){var o=r.apply(e[i],arguments);if(o===u)n[i]=u;else if(void 0!==o&&!1!==o)return o}}else n[i]===t&&(n[i]=null)}}}function f(e,n,t){var i=e[n];if(i){if(!t&&"function"==typeof i)return i;var r=t?i.leave:i.enter;if("function"==typeof r)return r}else{var o=t?e.leave:e.enter;if(o){if("function"==typeof o)return o;var u=o[n];if("function"==typeof u)return u}}}},69251:function(e,n,t){t.r(n),t.d(n,{getOperationAST:function(){return r}});var i=t(87948);function r(e,n){for(var t=null,r=0,o=e.definitions;r<o.length;r++){var u,a=o[r];if(a.kind===i.h.OPERATION_DEFINITION)if(null==n){if(t)return null;t=a}else if((null===(u=a.name)||void 0===u?void 0:u.value)===n)return a}return t}}}])}();
@@ -1 +0,0 @@
1
- (self.webpackChunkaltair_app=self.webpackChunkaltair_app||[]).push([[790],{98790:function(t,n,e){"use strict";var o=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(n,"__esModule",{value:!0}),n.ActionCableSubscriptionProvider=void 0;const i=e(71251),r=e(50591),s=o(e(80650));n.ActionCableSubscriptionProvider=class extends i.SubscriptionProvider{execute(t){const n=s.default.createConsumer(this.subscriptionUrl);return new r.Observable(e=>{this.subscription=n.subscriptions.create(Object.assign({},{channel:this.connectionParams.channel||"GraphqlChannel",channelId:Math.round(Date.now()+1e5*Math.random()).toString(16)},{}),{connected:function(){this.perform("execute",t)},received:function(t){(t.result.data||t.result.errors)&&e.next(t.result),t.more||e.complete()}})})}close(){var t;null==(t=this.subscription)||t.unsubscribe()}}},80650:function(t,n,e){var o,i;(function(){(function(){(function(){var t=[].slice;this.ActionCable={INTERNAL:{message_types:{welcome:"welcome",ping:"ping",confirmation:"confirm_subscription",rejection:"reject_subscription"},default_mount_path:"/cable",protocols:["actioncable-v1-json","actioncable-unsupported"]},WebSocket:window.WebSocket,logger:window.console,createConsumer:function(t){var n;return null==t&&(t=null!=(n=this.getConfig("url"))?n:this.INTERNAL.default_mount_path),new r.Consumer(this.createWebSocketURL(t))},getConfig:function(t){var n;return null!=(n=document.head.querySelector("meta[name='action-cable-"+t+"']"))?n.getAttribute("content"):void 0},createWebSocketURL:function(t){var n;return t&&!/^wss?:/i.test(t)?((n=document.createElement("a")).href=t,n.href=n.href,n.protocol=n.protocol.replace("http","ws"),n.href):t},startDebugging:function(){return this.debugging=!0},stopDebugging:function(){return this.debugging=null},log:function(){var n,e;if(n=1<=arguments.length?t.call(arguments,0):[],this.debugging)return n.push(Date.now()),(e=this.logger).log.apply(e,["[ActionCable]"].concat(t.call(n)))}}}).call(this)}).call(this);var r=this.ActionCable;(function(){(function(){r.ConnectionMonitor=function(){var t,n,e;function o(t){this.connection=t,this.visibilityDidChange=function(t,n){return function(){return t.apply(n,arguments)}}(this.visibilityDidChange,this),this.reconnectAttempts=0}return o.pollInterval={min:3,max:30},o.staleThreshold=6,o.prototype.start=function(){if(!this.isRunning())return this.startedAt=n(),delete this.stoppedAt,this.startPolling(),document.addEventListener("visibilitychange",this.visibilityDidChange),r.log("ConnectionMonitor started. pollInterval = "+this.getPollInterval()+" ms")},o.prototype.stop=function(){if(this.isRunning())return this.stoppedAt=n(),this.stopPolling(),document.removeEventListener("visibilitychange",this.visibilityDidChange),r.log("ConnectionMonitor stopped")},o.prototype.isRunning=function(){return null!=this.startedAt&&null==this.stoppedAt},o.prototype.recordPing=function(){return this.pingedAt=n()},o.prototype.recordConnect=function(){return this.reconnectAttempts=0,this.recordPing(),delete this.disconnectedAt,r.log("ConnectionMonitor recorded connect")},o.prototype.recordDisconnect=function(){return this.disconnectedAt=n(),r.log("ConnectionMonitor recorded disconnect")},o.prototype.startPolling=function(){return this.stopPolling(),this.poll()},o.prototype.stopPolling=function(){return clearTimeout(this.pollTimeout)},o.prototype.poll=function(){return this.pollTimeout=setTimeout((t=this,function(){return t.reconnectIfStale(),t.poll()}),this.getPollInterval());var t},o.prototype.getPollInterval=function(){var n,e,o,i;return o=(i=this.constructor.pollInterval).min,e=i.max,n=5*Math.log(this.reconnectAttempts+1),Math.round(1e3*t(n,o,e))},o.prototype.reconnectIfStale=function(){if(this.connectionIsStale())return r.log("ConnectionMonitor detected stale connection. reconnectAttempts = "+this.reconnectAttempts+", pollInterval = "+this.getPollInterval()+" ms, time disconnected = "+e(this.disconnectedAt)+" s, stale threshold = "+this.constructor.staleThreshold+" s"),this.reconnectAttempts++,this.disconnectedRecently()?r.log("ConnectionMonitor skipping reopening recent disconnect"):(r.log("ConnectionMonitor reopening"),this.connection.reopen())},o.prototype.connectionIsStale=function(){var t;return e(null!=(t=this.pingedAt)?t:this.startedAt)>this.constructor.staleThreshold},o.prototype.disconnectedRecently=function(){return this.disconnectedAt&&e(this.disconnectedAt)<this.constructor.staleThreshold},o.prototype.visibilityDidChange=function(){if("visible"===document.visibilityState)return setTimeout((t=this,function(){if(t.connectionIsStale()||!t.connection.isOpen())return r.log("ConnectionMonitor reopening stale connection on visibilitychange. visbilityState = "+document.visibilityState),t.connection.reopen()}),200);var t},n=function(){return(new Date).getTime()},e=function(t){return(n()-t)/1e3},t=function(t,n,e){return Math.max(n,Math.min(e,t))},o}()}).call(this),(function(){var t,n,e,o,i=[].slice,s=[].indexOf||function(t){for(var n=0,e=this.length;n<e;n++)if(n in this&&this[n]===t)return n;return-1};t=(e=r.INTERNAL).message_types,o=2<=(n=e.protocols).length?i.call(n,0,n.length-1):(0,[]),r.Connection=function(){function e(t){this.consumer=t,this.open=function(t,n){return function(){return t.apply(n,arguments)}}(this.open,this),this.subscriptions=this.consumer.subscriptions,this.monitor=new r.ConnectionMonitor(this),this.disconnected=!0}return e.reopenDelay=500,e.prototype.send=function(t){return!!this.isOpen()&&(this.webSocket.send(JSON.stringify(t)),!0)},e.prototype.open=function(){return this.isActive()?(r.log("Attempted to open WebSocket, but existing socket is "+this.getState()),!1):(r.log("Opening WebSocket, current state is "+this.getState()+", subprotocols: "+n),null!=this.webSocket&&this.uninstallEventHandlers(),this.webSocket=new r.WebSocket(this.consumer.url,n),this.installEventHandlers(),this.monitor.start(),!0)},e.prototype.close=function(t){var n;if((null!=t?t:{allowReconnect:!0}).allowReconnect||this.monitor.stop(),this.isActive())return null!=(n=this.webSocket)?n.close():void 0},e.prototype.reopen=function(){if(r.log("Reopening WebSocket, current state is "+this.getState()),!this.isActive())return this.open();try{return this.close()}catch(t){return r.log("Failed to reopen WebSocket",t)}finally{r.log("Reopening WebSocket in "+this.constructor.reopenDelay+"ms"),setTimeout(this.open,this.constructor.reopenDelay)}},e.prototype.getProtocol=function(){var t;return null!=(t=this.webSocket)?t.protocol:void 0},e.prototype.isOpen=function(){return this.isState("open")},e.prototype.isActive=function(){return this.isState("open","connecting")},e.prototype.isProtocolSupported=function(){var t;return t=this.getProtocol(),s.call(o,t)>=0},e.prototype.isState=function(){var t,n;return n=1<=arguments.length?i.call(arguments,0):[],t=this.getState(),s.call(n,t)>=0},e.prototype.getState=function(){var t,n;for(n in WebSocket)if(WebSocket[n]===(null!=(t=this.webSocket)?t.readyState:void 0))return n.toLowerCase();return null},e.prototype.installEventHandlers=function(){var t,n;for(t in this.events)n=this.events[t].bind(this),this.webSocket["on"+t]=n},e.prototype.uninstallEventHandlers=function(){var t;for(t in this.events)this.webSocket["on"+t]=function(){}},e.prototype.events={message:function(n){var e,o,i,r;if(this.isProtocolSupported())switch(i=JSON.parse(n.data),e=i.identifier,o=i.message,r=i.type,r){case t.welcome:return this.monitor.recordConnect(),this.subscriptions.reload();case t.ping:return this.monitor.recordPing();case t.confirmation:return this.subscriptions.notify(e,"connected");case t.rejection:return this.subscriptions.reject(e);default:return this.subscriptions.notify(e,"received",o)}},open:function(){if(r.log("WebSocket onopen event, using '"+this.getProtocol()+"' subprotocol"),this.disconnected=!1,!this.isProtocolSupported())return r.log("Protocol is unsupported. Stopping monitor and disconnecting."),this.close({allowReconnect:!1})},close:function(t){if(r.log("WebSocket onclose event"),!this.disconnected)return this.disconnected=!0,this.monitor.recordDisconnect(),this.subscriptions.notifyAll("disconnected",{willAttemptReconnect:this.monitor.isRunning()})},error:function(){return r.log("WebSocket onerror event")}},e}()}).call(this),(function(){var t=[].slice;r.Subscriptions=function(){function n(t){this.consumer=t,this.subscriptions=[]}return n.prototype.create=function(t,n){var e,o;return o=new r.Subscription(this.consumer,"object"==typeof(e=t)?e:{channel:e},n),this.add(o)},n.prototype.add=function(t){return this.subscriptions.push(t),this.consumer.ensureActiveConnection(),this.notify(t,"initialized"),this.sendCommand(t,"subscribe"),t},n.prototype.remove=function(t){return this.forget(t),this.findAll(t.identifier).length||this.sendCommand(t,"unsubscribe"),t},n.prototype.reject=function(t){var n,e,o,i,r;for(i=[],n=0,e=(o=this.findAll(t)).length;n<e;n++)this.forget(r=o[n]),this.notify(r,"rejected"),i.push(r);return i},n.prototype.forget=function(t){var n;return this.subscriptions=(function(){var e,o,i,r;for(r=[],e=0,o=(i=this.subscriptions).length;e<o;e++)(n=i[e])!==t&&r.push(n);return r}).call(this),t},n.prototype.findAll=function(t){var n,e,o,i,r;for(i=[],n=0,e=(o=this.subscriptions).length;n<e;n++)(r=o[n]).identifier===t&&i.push(r);return i},n.prototype.reload=function(){var t,n,e,o;for(o=[],t=0,n=(e=this.subscriptions).length;t<n;t++)o.push(this.sendCommand(e[t],"subscribe"));return o},n.prototype.notifyAll=function(){var n,e,o,i,r,s;for(e=arguments[0],n=2<=arguments.length?t.call(arguments,1):[],s=[],o=0,i=(r=this.subscriptions).length;o<i;o++)s.push(this.notify.apply(this,[r[o],e].concat(t.call(n))));return s},n.prototype.notify=function(){var n,e,o,i,r,s,c;for(s=arguments[0],e=arguments[1],n=3<=arguments.length?t.call(arguments,2):[],r=[],o=0,i=(c="string"==typeof s?this.findAll(s):[s]).length;o<i;o++)r.push("function"==typeof(s=c[o])[e]?s[e].apply(s,n):void 0);return r},n.prototype.sendCommand=function(t,n){return this.consumer.send({command:n,identifier:t.identifier})},n}()}).call(this),(function(){r.Subscription=function(){var t;function n(n,e,o){this.consumer=n,null==e&&(e={}),this.identifier=JSON.stringify(e),t(this,o)}return n.prototype.perform=function(t,n){return null==n&&(n={}),n.action=t,this.send(n)},n.prototype.send=function(t){return this.consumer.send({command:"message",identifier:this.identifier,data:JSON.stringify(t)})},n.prototype.unsubscribe=function(){return this.consumer.subscriptions.remove(this)},t=function(t,n){var e;if(null!=n)for(e in n)t[e]=n[e];return t},n}()}).call(this),(function(){r.Consumer=function(){function t(t){this.url=t,this.subscriptions=new r.Subscriptions(this),this.connection=new r.Connection(this)}return t.prototype.send=function(t){return this.connection.send(t)},t.prototype.connect=function(){return this.connection.open()},t.prototype.disconnect=function(){return this.connection.close({allowReconnect:!1})},t.prototype.ensureActiveConnection=function(){if(!this.connection.isActive())return this.connection.open()},t}()}).call(this)}).call(this),t.exports?t.exports=r:void 0!==(i="function"==typeof(o=r)?o.call(n,e,n,t):o)&&(t.exports=i)}).call(this)}}]);
@@ -1 +0,0 @@
1
- !function(){function t(t,n){if(!(t instanceof n))throw new TypeError("Cannot call a class as a function")}function n(t,n){for(var e=0;e<n.length;e++){var o=n[e];o.enumerable=o.enumerable||!1,o.configurable=!0,"value"in o&&(o.writable=!0),Object.defineProperty(t,o.key,o)}}function e(t,n){return(e=Object.setPrototypeOf||function(t,n){return t.__proto__=n,t})(t,n)}function o(t){var n=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch(t){return!1}}();return function(){var e,o=r(t);if(n){var s=r(this).constructor;e=Reflect.construct(o,arguments,s)}else e=o.apply(this,arguments);return i(this,e)}}function i(t,n){if(n&&("object"==typeof n||"function"==typeof n))return n;if(void 0!==n)throw new TypeError("Derived constructors may only return object or undefined");return function(t){if(void 0===t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}(t)}function r(t){return(r=Object.setPrototypeOf?Object.getPrototypeOf:function(t){return t.__proto__||Object.getPrototypeOf(t)})(t)}(self.webpackChunkaltair_app=self.webpackChunkaltair_app||[]).push([[790],{98790:function(i,r,s){"use strict";var c=this&&this.__importDefault||function(t){return t&&t.__esModule?t:{default:t}};Object.defineProperty(r,"__esModule",{value:!0}),r.ActionCableSubscriptionProvider=void 0;var u=s(71251),l=s(50591),p=c(s(80650));r.ActionCableSubscriptionProvider=function(i){!function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Super expression must either be null or a function");t.prototype=Object.create(n&&n.prototype,{constructor:{value:t,writable:!0,configurable:!0}}),n&&e(t,n)}(a,i);var r,s,c,u=o(a);function a(){return t(this,a),u.apply(this,arguments)}return r=a,(s=[{key:"execute",value:function(t){var n=this,e=p.default.createConsumer(this.subscriptionUrl);return new l.Observable(function(o){n.subscription=e.subscriptions.create(Object.assign({},{channel:n.connectionParams.channel||"GraphqlChannel",channelId:Math.round(Date.now()+1e5*Math.random()).toString(16)},{}),{connected:function(){this.perform("execute",t)},received:function(t){(t.result.data||t.result.errors)&&o.next(t.result),t.more||o.complete()}})})}},{key:"close",value:function(){var t;null==(t=this.subscription)||t.unsubscribe()}}])&&n(r.prototype,s),c&&n(r,c),a}(u.SubscriptionProvider)},80650:function(t,n,e){var o,i;(function(){(function(){(function(){var t=[].slice;this.ActionCable={INTERNAL:{message_types:{welcome:"welcome",ping:"ping",confirmation:"confirm_subscription",rejection:"reject_subscription"},default_mount_path:"/cable",protocols:["actioncable-v1-json","actioncable-unsupported"]},WebSocket:window.WebSocket,logger:window.console,createConsumer:function(t){var n;return null==t&&(t=null!=(n=this.getConfig("url"))?n:this.INTERNAL.default_mount_path),new r.Consumer(this.createWebSocketURL(t))},getConfig:function(t){var n;return null!=(n=document.head.querySelector("meta[name='action-cable-"+t+"']"))?n.getAttribute("content"):void 0},createWebSocketURL:function(t){var n;return t&&!/^wss?:/i.test(t)?((n=document.createElement("a")).href=t,n.href=n.href,n.protocol=n.protocol.replace("http","ws"),n.href):t},startDebugging:function(){return this.debugging=!0},stopDebugging:function(){return this.debugging=null},log:function(){var n,e;if(n=1<=arguments.length?t.call(arguments,0):[],this.debugging)return n.push(Date.now()),(e=this.logger).log.apply(e,["[ActionCable]"].concat(t.call(n)))}}}).call(this)}).call(this);var r=this.ActionCable;(function(){(function(){r.ConnectionMonitor=function(){var t,n,e;function o(t){this.connection=t,this.visibilityDidChange=function(t,n){return function(){return t.apply(n,arguments)}}(this.visibilityDidChange,this),this.reconnectAttempts=0}return o.pollInterval={min:3,max:30},o.staleThreshold=6,o.prototype.start=function(){if(!this.isRunning())return this.startedAt=n(),delete this.stoppedAt,this.startPolling(),document.addEventListener("visibilitychange",this.visibilityDidChange),r.log("ConnectionMonitor started. pollInterval = "+this.getPollInterval()+" ms")},o.prototype.stop=function(){if(this.isRunning())return this.stoppedAt=n(),this.stopPolling(),document.removeEventListener("visibilitychange",this.visibilityDidChange),r.log("ConnectionMonitor stopped")},o.prototype.isRunning=function(){return null!=this.startedAt&&null==this.stoppedAt},o.prototype.recordPing=function(){return this.pingedAt=n()},o.prototype.recordConnect=function(){return this.reconnectAttempts=0,this.recordPing(),delete this.disconnectedAt,r.log("ConnectionMonitor recorded connect")},o.prototype.recordDisconnect=function(){return this.disconnectedAt=n(),r.log("ConnectionMonitor recorded disconnect")},o.prototype.startPolling=function(){return this.stopPolling(),this.poll()},o.prototype.stopPolling=function(){return clearTimeout(this.pollTimeout)},o.prototype.poll=function(){return this.pollTimeout=setTimeout((t=this,function(){return t.reconnectIfStale(),t.poll()}),this.getPollInterval());var t},o.prototype.getPollInterval=function(){var n,e,o,i;return o=(i=this.constructor.pollInterval).min,e=i.max,n=5*Math.log(this.reconnectAttempts+1),Math.round(1e3*t(n,o,e))},o.prototype.reconnectIfStale=function(){if(this.connectionIsStale())return r.log("ConnectionMonitor detected stale connection. reconnectAttempts = "+this.reconnectAttempts+", pollInterval = "+this.getPollInterval()+" ms, time disconnected = "+e(this.disconnectedAt)+" s, stale threshold = "+this.constructor.staleThreshold+" s"),this.reconnectAttempts++,this.disconnectedRecently()?r.log("ConnectionMonitor skipping reopening recent disconnect"):(r.log("ConnectionMonitor reopening"),this.connection.reopen())},o.prototype.connectionIsStale=function(){var t;return e(null!=(t=this.pingedAt)?t:this.startedAt)>this.constructor.staleThreshold},o.prototype.disconnectedRecently=function(){return this.disconnectedAt&&e(this.disconnectedAt)<this.constructor.staleThreshold},o.prototype.visibilityDidChange=function(){if("visible"===document.visibilityState)return setTimeout((t=this,function(){if(t.connectionIsStale()||!t.connection.isOpen())return r.log("ConnectionMonitor reopening stale connection on visibilitychange. visbilityState = "+document.visibilityState),t.connection.reopen()}),200);var t},n=function(){return(new Date).getTime()},e=function(t){return(n()-t)/1e3},t=function(t,n,e){return Math.max(n,Math.min(e,t))},o}()}).call(this),(function(){var t,n,e,o,i=[].slice,s=[].indexOf||function(t){for(var n=0,e=this.length;n<e;n++)if(n in this&&this[n]===t)return n;return-1};t=(e=r.INTERNAL).message_types,o=2<=(n=e.protocols).length?i.call(n,0,n.length-1):[],r.Connection=function(){function e(t){this.consumer=t,this.open=function(t,n){return function(){return t.apply(n,arguments)}}(this.open,this),this.subscriptions=this.consumer.subscriptions,this.monitor=new r.ConnectionMonitor(this),this.disconnected=!0}return e.reopenDelay=500,e.prototype.send=function(t){return!!this.isOpen()&&(this.webSocket.send(JSON.stringify(t)),!0)},e.prototype.open=function(){return this.isActive()?(r.log("Attempted to open WebSocket, but existing socket is "+this.getState()),!1):(r.log("Opening WebSocket, current state is "+this.getState()+", subprotocols: "+n),null!=this.webSocket&&this.uninstallEventHandlers(),this.webSocket=new r.WebSocket(this.consumer.url,n),this.installEventHandlers(),this.monitor.start(),!0)},e.prototype.close=function(t){var n;if((null!=t?t:{allowReconnect:!0}).allowReconnect||this.monitor.stop(),this.isActive())return null!=(n=this.webSocket)?n.close():void 0},e.prototype.reopen=function(){if(r.log("Reopening WebSocket, current state is "+this.getState()),!this.isActive())return this.open();try{return this.close()}catch(t){return r.log("Failed to reopen WebSocket",t)}finally{r.log("Reopening WebSocket in "+this.constructor.reopenDelay+"ms"),setTimeout(this.open,this.constructor.reopenDelay)}},e.prototype.getProtocol=function(){var t;return null!=(t=this.webSocket)?t.protocol:void 0},e.prototype.isOpen=function(){return this.isState("open")},e.prototype.isActive=function(){return this.isState("open","connecting")},e.prototype.isProtocolSupported=function(){var t;return t=this.getProtocol(),s.call(o,t)>=0},e.prototype.isState=function(){var t,n;return n=1<=arguments.length?i.call(arguments,0):[],t=this.getState(),s.call(n,t)>=0},e.prototype.getState=function(){var t,n;for(n in WebSocket)if(WebSocket[n]===(null!=(t=this.webSocket)?t.readyState:void 0))return n.toLowerCase();return null},e.prototype.installEventHandlers=function(){var t,n;for(t in this.events)n=this.events[t].bind(this),this.webSocket["on"+t]=n},e.prototype.uninstallEventHandlers=function(){var t;for(t in this.events)this.webSocket["on"+t]=function(){}},e.prototype.events={message:function(n){var e,o,i,r;if(this.isProtocolSupported())switch(i=JSON.parse(n.data),e=i.identifier,o=i.message,r=i.type,r){case t.welcome:return this.monitor.recordConnect(),this.subscriptions.reload();case t.ping:return this.monitor.recordPing();case t.confirmation:return this.subscriptions.notify(e,"connected");case t.rejection:return this.subscriptions.reject(e);default:return this.subscriptions.notify(e,"received",o)}},open:function(){if(r.log("WebSocket onopen event, using '"+this.getProtocol()+"' subprotocol"),this.disconnected=!1,!this.isProtocolSupported())return r.log("Protocol is unsupported. Stopping monitor and disconnecting."),this.close({allowReconnect:!1})},close:function(t){if(r.log("WebSocket onclose event"),!this.disconnected)return this.disconnected=!0,this.monitor.recordDisconnect(),this.subscriptions.notifyAll("disconnected",{willAttemptReconnect:this.monitor.isRunning()})},error:function(){return r.log("WebSocket onerror event")}},e}()}).call(this),(function(){var t=[].slice;r.Subscriptions=function(){function n(t){this.consumer=t,this.subscriptions=[]}return n.prototype.create=function(t,n){var e,o;return o=new r.Subscription(this.consumer,"object"==typeof(e=t)?e:{channel:e},n),this.add(o)},n.prototype.add=function(t){return this.subscriptions.push(t),this.consumer.ensureActiveConnection(),this.notify(t,"initialized"),this.sendCommand(t,"subscribe"),t},n.prototype.remove=function(t){return this.forget(t),this.findAll(t.identifier).length||this.sendCommand(t,"unsubscribe"),t},n.prototype.reject=function(t){var n,e,o,i,r;for(i=[],n=0,e=(o=this.findAll(t)).length;n<e;n++)this.forget(r=o[n]),this.notify(r,"rejected"),i.push(r);return i},n.prototype.forget=function(t){var n;return this.subscriptions=(function(){var e,o,i,r;for(r=[],e=0,o=(i=this.subscriptions).length;e<o;e++)(n=i[e])!==t&&r.push(n);return r}).call(this),t},n.prototype.findAll=function(t){var n,e,o,i,r;for(i=[],n=0,e=(o=this.subscriptions).length;n<e;n++)(r=o[n]).identifier===t&&i.push(r);return i},n.prototype.reload=function(){var t,n,e,o;for(o=[],t=0,n=(e=this.subscriptions).length;t<n;t++)o.push(this.sendCommand(e[t],"subscribe"));return o},n.prototype.notifyAll=function(){var n,e,o,i,r,s;for(e=arguments[0],n=2<=arguments.length?t.call(arguments,1):[],s=[],o=0,i=(r=this.subscriptions).length;o<i;o++)s.push(this.notify.apply(this,[r[o],e].concat(t.call(n))));return s},n.prototype.notify=function(){var n,e,o,i,r,s,c;for(s=arguments[0],e=arguments[1],n=3<=arguments.length?t.call(arguments,2):[],r=[],o=0,i=(c="string"==typeof s?this.findAll(s):[s]).length;o<i;o++)r.push("function"==typeof(s=c[o])[e]?s[e].apply(s,n):void 0);return r},n.prototype.sendCommand=function(t,n){return this.consumer.send({command:n,identifier:t.identifier})},n}()}).call(this),(function(){r.Subscription=function(){var t;function n(n,e,o){this.consumer=n,null==e&&(e={}),this.identifier=JSON.stringify(e),t(this,o)}return n.prototype.perform=function(t,n){return null==n&&(n={}),n.action=t,this.send(n)},n.prototype.send=function(t){return this.consumer.send({command:"message",identifier:this.identifier,data:JSON.stringify(t)})},n.prototype.unsubscribe=function(){return this.consumer.subscriptions.remove(this)},t=function(t,n){var e;if(null!=n)for(e in n)t[e]=n[e];return t},n}()}).call(this),(function(){r.Consumer=function(){function t(t){this.url=t,this.subscriptions=new r.Subscriptions(this),this.connection=new r.Connection(this)}return t.prototype.send=function(t){return this.connection.send(t)},t.prototype.connect=function(){return this.connection.open()},t.prototype.disconnect=function(){return this.connection.close({allowReconnect:!1})},t.prototype.ensureActiveConnection=function(){if(!this.connection.isActive())return this.connection.open()},t}()}).call(this)}).call(this),t.exports?t.exports=r:void 0!==(i="function"==typeof(o=r)?o.call(n,e,n,t):o)&&(t.exports=i)}).call(this)}}])}();