graphdb-workbench 2.4.1 → 2.4.2-TR2

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 (141) hide show
  1. package/dist/{0.7daec4382561aa8681d5.bundle.js → 0.c6e0a1afafc7ffdfaccc.bundle.js} +1 -1
  2. package/dist/{10.25c3009270232c3ad844.bundle.js → 10.2fd5d150b0f308c19b16.bundle.js} +1 -1
  3. package/dist/108.99fadee1ed0c7110af9a.bundle.js +1 -0
  4. package/dist/{11.08c502782a3bd04cb48b.bundle.js → 11.d13b4e6a939fc0b5a125.bundle.js} +1 -1
  5. package/dist/{114.3a6135cc10951d23cb56.bundle.js → 114.2f1bbfe1abb21122d2e1.bundle.js} +1 -1
  6. package/dist/{117.45f91d2cf367836dadae.bundle.js → 117.23e75248d8a499cef320.bundle.js} +1 -1
  7. package/dist/{12.0ca290ed18d2524f66e7.bundle.js → 12.dd3a24172cf3cdec30f0.bundle.js} +2 -2
  8. package/dist/{124.7ce2385e2ce2ac41a255.bundle.js → 124.8e3d5ba12c298ea9a439.bundle.js} +1 -1
  9. package/dist/{128.4eb95500c74ddcbc0ec1.bundle.js → 128.280921c83837d6b5ed1e.bundle.js} +1 -1
  10. package/dist/{13.6a3e4e38a9efa1adf29e.bundle.js → 13.3eb06b80cef486be700e.bundle.js} +1 -1
  11. package/dist/{130.8d0c570a8363e55b4892.bundle.js → 130.9aea5c200bad449041e5.bundle.js} +1 -1
  12. package/dist/{133.c9432441d39dbdf45a46.bundle.js → 133.7ff3260122aed5f9da82.bundle.js} +1 -1
  13. package/dist/{134.64ab677e16aa2b0c78b1.bundle.js → 134.937aed94c3cba12e70de.bundle.js} +1 -1
  14. package/dist/{136.22f6c4a19299925123a0.bundle.js → 136.50ad256ff91ae8bd138c.bundle.js} +1 -1
  15. package/dist/{138.1eae7a838df0b1e52ff4.bundle.js → 138.3d79db7fc7908d986c2d.bundle.js} +1 -1
  16. package/dist/14.82b9ba9a0a77131aa582.bundle.js +1 -0
  17. package/dist/{144.d2120bcd066b96e7ee58.bundle.js → 144.24d2001adcd0546ce679.bundle.js} +1 -1
  18. package/dist/{146.a2f5b077f3eec4961a4b.bundle.js → 146.0bf605fa5b7cc102937f.bundle.js} +1 -1
  19. package/dist/{15.54781c280e23072b66c5.bundle.js → 15.b27c1c98f320b78e704c.bundle.js} +1 -1
  20. package/dist/{150.f3a633da2c7c2b9cd7c4.bundle.js → 150.7224dc087612aa0ff0c1.bundle.js} +1 -1
  21. package/dist/{153.f710bf5c73f7d736a4b1.bundle.js → 153.8fbeed8e7e94213c6df1.bundle.js} +1 -1
  22. package/dist/{155.46f2a94df187ed492591.bundle.js → 155.68e389692623c7b68878.bundle.js} +1 -1
  23. package/dist/{16.24206eca9306f6f153d6.bundle.js → 16.9f43f2a2cb3de6b50964.bundle.js} +1 -1
  24. package/dist/168.34a1790ea589d9926a97.bundle.js +1 -1
  25. package/dist/{17.f3d91ad6fab1a190a416.bundle.js → 17.7a20974aaea2122ed42f.bundle.js} +1 -1
  26. package/dist/170.e24cfa80d3f51df2b1b5.bundle.js +1 -0
  27. package/dist/171.49aabfdb3574cef3d14b.bundle.js +1 -0
  28. package/dist/173.5e3fea538a2a2d5b5c0c.bundle.js +1 -1
  29. package/dist/{18.119e4e696a9b2da67a3f.bundle.js → 18.db18b987a6ea55fddc4a.bundle.js} +2 -2
  30. package/dist/{19.f461a770949b2e409d05.bundle.js → 19.9a73670b7772d8bf1969.bundle.js} +1 -1
  31. package/dist/{2.308618aec7201e8045bd.bundle.js → 2.888ee146d785447620e1.bundle.js} +2 -2
  32. package/dist/{20.635488a03f910fa4518b.bundle.js → 20.918905a6efc81c27dcf6.bundle.js} +1 -1
  33. package/dist/200.76fd30afe28687f92b15.bundle.js +1 -1
  34. package/dist/{21.9bbe46c05fe4a34a9cf8.bundle.js → 21.fa61daf65c6bc29e06a2.bundle.js} +1 -1
  35. package/dist/{22.0ae31e473d0af170b177.bundle.js → 22.3850ed5528218c3beb66.bundle.js} +2 -2
  36. package/dist/23.dc3e430b47f766cc2366.bundle.js +1 -1
  37. package/dist/{24.8d3f4b05a5101a6a685b.bundle.js → 24.4c9b73b3909403e82055.bundle.js} +1 -1
  38. package/dist/{31.9a07cc30c05a1a698b98.bundle.js → 25.a5373b84a4b761ac765f.bundle.js} +2 -2
  39. package/dist/{25.2a489b131bab984243fa.bundle.js → 26.60c61d8ca245bad6597d.bundle.js} +1 -1
  40. package/dist/{26.377d1bc26079a8159e3c.bundle.js → 27.56996601ec3795c65c3d.bundle.js} +1 -1
  41. package/dist/{27.60396d05fddda4894ce3.bundle.js → 28.79f65106f49c5036504b.bundle.js} +1 -1
  42. package/dist/{28.aebd82e778f3fcd55219.bundle.js → 29.3f41e0d8e9f58188a02b.bundle.js} +1 -1
  43. package/dist/30.4712f3e92b6469d3d8dd.bundle.js +1 -0
  44. package/dist/{30.acdf84b0bcd3f178c2fd.bundle.js → 31.a05a0072057c061cd0dc.bundle.js} +1 -1
  45. package/dist/{32.f88a50038df0d43ccfc4.bundle.js → 32.27c9ee63125cca89f908.bundle.js} +1 -1
  46. package/dist/33.c659ec3148f68ca30b34.bundle.js +1 -0
  47. package/dist/{33.d4463e934ae20163667d.bundle.js → 34.e5150a1b66426d5f5af7.bundle.js} +1 -1
  48. package/dist/{34.3046d2d28129a67d4483.bundle.js → 35.0766d50ada31ef79b4b0.bundle.js} +1 -1
  49. package/dist/{35.69758da395b815346a2f.bundle.js → 36.25471fd55c32f7f02568.bundle.js} +1 -1
  50. package/dist/37.356f6302c079cea446b6.bundle.js +1 -0
  51. package/dist/{37.ac5b9eaa607c43ec69df.bundle.js → 38.94b303a3b944480a495a.bundle.js} +1 -1
  52. package/dist/{38.b776c45fe26516ca8160.bundle.js → 39.a5409bc3fec719768f37.bundle.js} +1 -1
  53. package/dist/{4.870de73e2e763f35280a.bundle.js → 4.83e133ed3a567a27c699.bundle.js} +1 -1
  54. package/dist/{39.c74b936329bf2477fbdb.bundle.js → 40.61f5dedc12beb42c1f44.bundle.js} +1 -1
  55. package/dist/{40.2c1f1cc8c521b8209885.bundle.js → 41.62789a75dd9dddbc1297.bundle.js} +1 -1
  56. package/dist/42.0df0808308a3829462fb.bundle.js +1 -0
  57. package/dist/{42.b6c558e4b660bdb0be4d.bundle.js → 43.3876fb2ec9b5b6b646df.bundle.js} +1 -1
  58. package/dist/{43.42c27c3277a302252fc5.bundle.js → 44.e63112a4f3ee65c29a0a.bundle.js} +1 -1
  59. package/dist/{44.96d4cf9f701897a90fce.bundle.js → 45.2b1cf89f777bb5fda383.bundle.js} +1 -1
  60. package/dist/{45.2c4bc26cf5fbe9b84cb6.bundle.js → 46.f07b159fc6cc07492e2b.bundle.js} +1 -1
  61. package/dist/{46.d63a366dbcb649ed1fbb.bundle.js → 47.1bacc6e38fde37677380.bundle.js} +1 -1
  62. package/dist/{47.0ecc5620f91346c3e7d4.bundle.js → 48.345db2f50dae9ec7d11a.bundle.js} +1 -1
  63. package/dist/49.b0d0df9a0bd2458a38f7.bundle.js +1 -0
  64. package/dist/{5.adea5d522be945b9d8d3.bundle.js → 5.93d75276b7a283deddc8.bundle.js} +1 -1
  65. package/dist/{49.3da99bdb2271cf2adc7b.bundle.js → 50.f453781f031f1511a294.bundle.js} +1 -1
  66. package/dist/{50.6695e410303c03ad694c.bundle.js → 51.9a911ea64d2bbe27a6b8.bundle.js} +1 -1
  67. package/dist/{51.95f30e28e67312c9df42.bundle.js → 52.0673b651acdd40122168.bundle.js} +1 -1
  68. package/dist/{52.b0f496f823a213178075.bundle.js → 53.9b5d43c58aa368765457.bundle.js} +1 -1
  69. package/dist/{53.716d3c94c3d0959a26a8.bundle.js → 54.028884d762d361c54c23.bundle.js} +1 -1
  70. package/dist/{54.44b8cf059fe5ba4bf144.bundle.js → 55.4966f01604a6c84d301e.bundle.js} +1 -1
  71. package/dist/{55.891486b3fa68d44f3a52.bundle.js → 56.da176c234be30906ed18.bundle.js} +1 -1
  72. package/dist/{56.3548e08f4add9390e771.bundle.js → 57.413a1beccae08b5eb787.bundle.js} +1 -1
  73. package/dist/{57.9f0dbb2e3b44c19c8dcd.bundle.js → 58.8ba78ec049c5c97e4391.bundle.js} +1 -1
  74. package/dist/{58.a76e6e35994e2cb1a7f6.bundle.js → 59.25436d0038d7be337d24.bundle.js} +1 -1
  75. package/dist/{59.6dfdee0f9651ff9aa2f6.bundle.js → 60.571f2c6fcdec505acb5a.bundle.js} +1 -1
  76. package/dist/{60.2b410d552e467b555529.bundle.js → 61.8dca89c50677ace894ee.bundle.js} +1 -1
  77. package/dist/{61.03a75a3d8faf4c165a0c.bundle.js → 62.3a5f8d2165a2f6058360.bundle.js} +1 -1
  78. package/dist/{62.86ba4d7804758d2e3f48.bundle.js → 63.2ea3fe6eb8be5ab57564.bundle.js} +1 -1
  79. package/dist/{63.5e2ca7ce2ea95b397fe7.bundle.js → 64.4e84a027a9f1d66a69db.bundle.js} +1 -1
  80. package/dist/{64.6a8854031771d4d4ef74.bundle.js → 65.da0571f9102cc340a6b9.bundle.js} +1 -1
  81. package/dist/{65.9e598abd11534c42a0c1.bundle.js → 66.104f9f5e48af12f94fbe.bundle.js} +1 -1
  82. package/dist/{7.0af6bb74bf88aa8f14ca.bundle.js → 7.39ff1f0ec65d7d7b73f5.bundle.js} +2 -2
  83. package/dist/{72.c82f209992278009e1a3.bundle.js → 72.25f264649b4e7f9dd670.bundle.js} +1 -1
  84. package/dist/{75.13e0f311c6c98067c4f8.bundle.js → 75.89f4b3371fc1c8679763.bundle.js} +1 -1
  85. package/dist/76.7d3ef13875f7533cc029.bundle.js +1 -0
  86. package/dist/{77.0373cd7f1c2851df3908.bundle.js → 77.122517ab9f81c08963fd.bundle.js} +1 -1
  87. package/dist/81.e4cdfbb440c07a0f9d1e.bundle.js +1 -0
  88. package/dist/{83.a6c2ad332de0ee224136.bundle.js → 83.0837870d0e1682a6487c.bundle.js} +1 -1
  89. package/dist/9.0e4d38f2390c619f5b26.bundle.js +1 -0
  90. package/dist/{bundle.c7f3e729665657fc72ff.bundle.js → bundle.a9867344f97149ebf778.bundle.js} +12 -12
  91. package/dist/css/new-sparql.css +31 -1
  92. package/dist/index.html +3 -3
  93. package/dist/js/angular/core/directives/autocomplete/templates/autocomplete.html +1 -1
  94. package/dist/js/angular/core/directives/operations-statuses-monitor/templates/operations-statuses-monitor.html +14 -13
  95. package/dist/js/angular/core/directives/queryeditor/templates/query-editor.html +4 -23
  96. package/dist/js/angular/core/directives/rdfresourcesearch/templates/rdfResourceSearchTemplate.html +1 -1
  97. package/dist/js/angular/security/templates/user.html +1 -1
  98. package/dist/license-checker.json +2 -2
  99. package/dist/pages/aclmanagement.html +1 -1
  100. package/dist/pages/autocomplete.html +1 -1
  101. package/dist/pages/choose-repository-type.html +1 -1
  102. package/dist/pages/cluster-management/clusterInfo.html +3 -3
  103. package/dist/pages/create-index.html +4 -4
  104. package/dist/pages/dependencies.html +1 -1
  105. package/dist/pages/domainRangeInfo.html +2 -2
  106. package/dist/pages/edit.html +1 -1
  107. package/dist/pages/explore.html +1 -1
  108. package/dist/pages/export.html +1 -1
  109. package/dist/pages/find.html +1 -1
  110. package/dist/pages/graph-config/saveGraphConfig.html +11 -11
  111. package/dist/pages/graphs-visualizations.html +7 -7
  112. package/dist/pages/guides.html +1 -1
  113. package/dist/pages/import.html +1 -1
  114. package/dist/pages/jdbc-create.html +5 -5
  115. package/dist/pages/monitor/backup-and-restore.html +1 -1
  116. package/dist/pages/monitor/queries.html +1 -1
  117. package/dist/pages/monitor/resources.html +2 -2
  118. package/dist/pages/namespaces.html +2 -2
  119. package/dist/pages/plugins.html +1 -1
  120. package/dist/pages/rdfClassHierarchyInfo.html +7 -7
  121. package/dist/pages/rdfrank.html +2 -2
  122. package/dist/pages/repositories.html +2 -2
  123. package/dist/pages/repository.html +2 -2
  124. package/dist/pages/similarity-indexes.html +1 -1
  125. package/dist/pages/sparql-template-create.html +5 -5
  126. package/dist/pages/sparql.html +3 -3
  127. package/dist/pages/webapi.html +2 -2
  128. package/dist/res/swagger/index.html +27 -27
  129. package/package.json +1 -1
  130. package/dist/108.83bb7ce803f462882200.bundle.js +0 -1
  131. package/dist/14.8343a1e9afdb39f1c2dc.bundle.js +0 -1
  132. package/dist/170.d5527024ac9107b542c3.bundle.js +0 -1
  133. package/dist/171.c0e7ce3fd59ef1bfc4f5.bundle.js +0 -1
  134. package/dist/29.9a6f92841eb0a4870045.bundle.js +0 -1
  135. package/dist/36.8f7908db8f70bbd3318c.bundle.js +0 -1
  136. package/dist/41.ca5e37c70938b397f260.bundle.js +0 -1
  137. package/dist/48.f8b0ea5f9306e24ac2d0.bundle.js +0 -1
  138. package/dist/66.7b18071c05eb5efb213b.bundle.js +0 -1
  139. package/dist/76.44bdcc2130c6a744bc55.bundle.js +0 -1
  140. package/dist/81.c14757a485d616ca95ba.bundle.js +0 -1
  141. package/dist/9.1e2a1467755135bb1717.bundle.js +0 -1
@@ -1 +1 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[32,40,64],{63:function(e,t,s){"use strict";s.r(t),s.d(t,"mapAclRulesResponse",(function(){return l}));var c=s(64);const l=e=>{const t=new c.ACListModel;return e&&e.data&&e.data.forEach(e=>{t.appendNewRule(e.subject,e.predicate,e.object,e.context,e.role,e.policy)}),t}},64:function(e,t,s){"use strict";s.r(t),s.d(t,"ACListModel",(function(){return c})),s.d(t,"ACRuleModel",(function(){return l})),s.d(t,"ACL_POLICY",(function(){return i}));class c{constructor(e=[]){this._aclRules=e}size(){return this.aclRules.length}appendNewRule(e,t,s,c,i,r){this.aclRules.push(new l(e,t,s,c,i,r))}addRule(e){this.aclRules.splice(e,0,new l)}removeRule(e){this.aclRules.splice(e,1)}replaceRule(e,t){this.aclRules.splice(e,1,t)}getRule(e){return this.aclRules[e]}isRuleDuplicated(e){const t=this.aclRules[e];return this.aclRules.some((s,c)=>e!==c&&angular.equals(t,s))}getRuleCopy(e){const t=this.aclRules[e];return{subject:t.subject,predicate:t.predicate,object:t.object,context:t.context,role:t.role,policy:t.policy}}moveUp(e){const t=this.aclRules[e-1];this.aclRules[e-1]=this.aclRules[e],this.aclRules[e]=t}moveDown(e){const t=this.aclRules[e+1];this.aclRules[e+1]=this.aclRules[e],this.aclRules[e]=t}toJSON(){return this.aclRules.map(e=>({subject:e.subject,predicate:e.predicate,object:e.object,context:e.context,role:e.role,policy:e.policy}))}get aclRules(){return this._aclRules}set aclRules(e){this._aclRules=e}}class l{constructor(e="*",t="*",s="*",c="*",l="CUSTOM_",r=i.ALLOW){this._subject=e,this._predicate=t,this._object=s,this._context=c,this._role=l,this._policy=r}get subject(){return this._subject}set subject(e){this._subject=e}get predicate(){return this._predicate}set predicate(e){this._predicate=e}get object(){return this._object}set object(e){this._object=e}get context(){return this._context}set context(e){this._context=e}get role(){return this._role}set role(e){this._role=e}get policy(){return this._policy}set policy(e){this._policy=e}}const i={ALLOW:"allow",DENY:"deny"}},86:function(e,t,s){"use strict";s.r(t);s(63);angular.module("graphdb.framework.rest.aclmanagement.service",[]).factory("AclManagementRestService",c),c.$inject=["$http"];function c(e){return{getAcl:function(t){return e.get(`rest/repositories/${t}/acl`)},updateAcl:function(t,s){return e.put(`rest/repositories/${t}/acl`,s)}}}}}]);
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[32,41,65],{64:function(e,t,s){"use strict";s.r(t),s.d(t,"mapAclRulesResponse",(function(){return l}));var c=s(65);const l=e=>{const t=new c.ACListModel;return e&&e.data&&e.data.forEach(e=>{t.appendNewRule(e.subject,e.predicate,e.object,e.context,e.role,e.policy)}),t}},65:function(e,t,s){"use strict";s.r(t),s.d(t,"ACListModel",(function(){return c})),s.d(t,"ACRuleModel",(function(){return l})),s.d(t,"ACL_POLICY",(function(){return i}));class c{constructor(e=[]){this._aclRules=e}size(){return this.aclRules.length}appendNewRule(e,t,s,c,i,r){this.aclRules.push(new l(e,t,s,c,i,r))}addRule(e){this.aclRules.splice(e,0,new l)}removeRule(e){this.aclRules.splice(e,1)}replaceRule(e,t){this.aclRules.splice(e,1,t)}getRule(e){return this.aclRules[e]}isRuleDuplicated(e){const t=this.aclRules[e];return this.aclRules.some((s,c)=>e!==c&&angular.equals(t,s))}getRuleCopy(e){const t=this.aclRules[e];return{subject:t.subject,predicate:t.predicate,object:t.object,context:t.context,role:t.role,policy:t.policy}}moveUp(e){const t=this.aclRules[e-1];this.aclRules[e-1]=this.aclRules[e],this.aclRules[e]=t}moveDown(e){const t=this.aclRules[e+1];this.aclRules[e+1]=this.aclRules[e],this.aclRules[e]=t}toJSON(){return this.aclRules.map(e=>({subject:e.subject,predicate:e.predicate,object:e.object,context:e.context,role:e.role,policy:e.policy}))}get aclRules(){return this._aclRules}set aclRules(e){this._aclRules=e}}class l{constructor(e="*",t="*",s="*",c="*",l="CUSTOM_",r=i.ALLOW){this._subject=e,this._predicate=t,this._object=s,this._context=c,this._role=l,this._policy=r}get subject(){return this._subject}set subject(e){this._subject=e}get predicate(){return this._predicate}set predicate(e){this._predicate=e}get object(){return this._object}set object(e){this._object=e}get context(){return this._context}set context(e){this._context=e}get role(){return this._role}set role(e){this._role=e}get policy(){return this._policy}set policy(e){this._policy=e}}const i={ALLOW:"allow",DENY:"deny"}},87:function(e,t,s){"use strict";s.r(t);s(64);angular.module("graphdb.framework.rest.aclmanagement.service",[]).factory("AclManagementRestService",c),c.$inject=["$http"];function c(e){return{getAcl:function(t){return e.get(`rest/repositories/${t}/acl`)},updateAcl:function(t,s){return e.put(`rest/repositories/${t}/acl`,s)}}}}}]);
@@ -0,0 +1 @@
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[33,42,138],{138:function(e,t,o){"use strict";o.r(t);o(91);angular.module("graphdb.framework.autocomplete",["ngRoute","graphdb.framework.autocomplete.controllers"])},60:function(e,t,o){"use strict";o.r(t),o.d(t,"mapNamespacesResponse",(function(){return n}));const n=e=>e&&e.data?e.data.results.bindings.map(e=>({prefix:e.prefix.value,uri:e.namespace.value})):[]},91:function(e,t,o){"use strict";o.r(t);o(31);var n=o(60),r=o(0);function i(e,t,o,i,c,a,s,l,u,d,f,p){let g;function m(){g&&t.cancel(g)}e.pluginName="autocomplete",e.setPluginIsActive=function(t){e.pluginIsActive=t};const b=function(){d.checkAutocompleteStatus().success((function(t){e.autocompleteEnabled=t,f.setAutocompleteStatus(t)})).error((function(e){o.error(getError(e))}))},I=function(){d.refreshIndexIRIs().success((function(t){e.shouldIndexIRIs=t})).error((function(e){o.error(getError(e))}))},L=function(){d.refreshIndexStatus().success((function(t){e.indexStatus=t})).error((function(e){o.error(getError(e))}))},v=function(){d.refreshLabelConfig().success((function(t){e.labelConfig=t})).error((function(e){o.error(getError(e))}))};e.checkForPlugin=function(){e.pluginFound=!1,e.setLoader(!0),d.checkForPlugin().success((function(t){e.pluginFound=!0===t,e.pluginFound?(R(),b(),I(),L(),v()):(e.autocompleteEnabled=!1,e.loading=!1)})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}))};const h=function(){g=t((function(){e.$broadcast("checkIsActive"),e.autocompleteEnabled&&L()}),5e3)};e.$on("$destroy",(function(){m()}));e.setLoader=function(t,o){s.cancel(e.loaderTimeout),t?e.loaderTimeout=s((function(){e.loader=t,e.loaderMessage=o}),300):e.loader=!1},e.getLoaderMessage=function(){return e.loaderMessage||p.instant("common.loading")},e.toggleAutocomplete=function(){const t=!e.autocompleteEnabled;e.setLoader(!0,t?p.instant("autocomplete.enabling"):p.instant("autocomplete.disabling")),d.toggleAutocomplete(t).success((function(){b(),L()})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}))},e.toggleIndexIRIs=function(){e.setLoader(!0,p.instant("autocomplete.index.iri")),d.toggleIndexIRIs(!e.shouldIndexIRIs).success((function(){I(),L()})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}))},e.buildIndex=function(){e.setLoader(!0,p.instant("autocomplete.index.build")),d.buildIndex().success((function(){e.indexStatus="BUILDING"})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}))},e.interruptIndexing=function(){e.setLoader(!0,p.instant("index.interrupt")),d.interruptIndexing().success((function(){L()})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}))},e.getDegradedReason=function(){return i.getDegradedReason()},e.addLabel=function(){e.editLabel({labelIri:"",languages:""},!0)},e.editLabel=function(t,n){a.open({templateUrl:"js/angular/autocomplete/templates/modal/add-label.html",controller:"AddLabelCtrl",resolve:{data:function(){return{label:t,isNew:n}}}}).result.then((function(t){!function(t){e.setLoader(!0,p.instant("autocomplete.update"));const n=t.labelIri;if(t.labelIri=u.expandPrefix(t.labelIri,e.namespaces),u.isValidIri(t,t.labelIri)&&""!==t.labelIri)d.addLabelConfig(t).success((function(){v(),L()})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}));else{const t=Object(r.decodeHTML)(p.instant("not.valid.iri",{value:n}));o.error(t),e.setLoader(!1)}}(t)}))},e.removeLabel=function(t){!function(t){e.setLoader(!0,p.instant("autocomplete.update")),d.removeLabelConfig(t).success((function(){v(),L()})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}))}(t)},e.$on("repositoryIsSet",(function(){m(),c.isLicenseValid()&&i.getActiveRepository()&&!i.isActiveRepoOntopType()&&!i.isActiveRepoFedXType()&&(e.checkForPlugin(),h())}));const R=()=>{l.getNamespaces(i.getActiveRepository()).then(n.mapNamespacesResponse).then(t=>{e.namespaces=t}).catch(e=>{const t=getError(e);o.error(t,p.instant("error.getting.namespaces.for.repo"))})};c.isLicenseValid()&&i.getActiveRepository()&&!i.isActiveRepoOntopType()&&!i.isActiveRepoFedXType()&&(e.checkForPlugin(),h())}function c(e,t,o,n){e.label=angular.copy(n.label),e.isNew=n.isNew,e.ok=function(){e.form.$valid&&t.close(e.label)},e.cancel=function(){t.dismiss("cancel")},e.setTemplate=function(t){e.label.labelIri=t,o((function(){$("#wb-autocomplete-languages").focus()}),0)}}angular.module("graphdb.framework.autocomplete.controllers",["toastr","graphdb.framework.rest.autocomplete.service"]).controller("AutocompleteCtrl",i).controller("AddLabelCtrl",c),i.$inject=["$scope","$interval","toastr","$repositories","$licenseService","$uibModal","$timeout","RDF4JRepositoriesRestService","UriUtils","AutocompleteRestService","$autocompleteStatus","$translate"],c.$inject=["$scope","$uibModalInstance","$timeout","data"]}}]);
@@ -1 +1 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[33,72],{298:function(t,e,n){var o,r,a;r=[],void 0===(a="function"==typeof(o=function(){return function(){var t=function(){return"n"},e=function(){return[0,0]},n=function(){return" "},o=u(),r=null,a=null,s=null,c=null;function d(t){var e;r="svg"===(e=(e=t).node()).tagName.toLowerCase()?e:e.ownerSVGElement,a=r.createSVGPoint(),document.body.appendChild(o)}d.show=function(){var o=Array.prototype.slice.call(arguments);o[o.length-1]instanceof SVGElement&&(s=o.pop());var r,a=n.apply(this,o),u=e.apply(this,o),p=t.apply(this,o),h=f(),y=l.length,_=document.documentElement.scrollTop||document.body.scrollTop,g=document.documentElement.scrollLeft||document.body.scrollLeft,S=c.apply(this,o);for(h.html(a).style({opacity:1,"pointer-events":"all"});y--;)h.classed(l[y],!1);return r=i.get(p).apply(this),S?h.style(S):h.classed(p,!0).style({top:r.top+u[0]+_+"px",left:r.left+u[1]+g+"px"}),d},d.hide=function(){return f().style({opacity:0,"pointer-events":"none"}),d},d.attr=function(t,e){if(arguments.length<2&&"string"==typeof t)return f().attr(t);var n=Array.prototype.slice.call(arguments);return d3.selection.prototype.attr.apply(f(),n),d},d.style=function(t,e){if(arguments.length<2&&"string"==typeof t)return f().style(t);var n=Array.prototype.slice.call(arguments);return d3.selection.prototype.style.apply(f(),n),d},d.direction=function(e){return arguments.length?(t=null==e?e:d3.functor(e),d):t},d.offset=function(t){return arguments.length?(e=null==t?t:d3.functor(t),d):e},d.html=function(t){return arguments.length?(n=null==t?t:d3.functor(t),d):n},d.customPosition=function(t){return arguments.length?(c=null==t?t:d3.functor(t),d):c},d.destroy=function(){return o&&(f().remove(),o=null),d};var i=d3.map({n:function(){var t=p();return{top:t.n.y-o.offsetHeight,left:t.n.x-o.offsetWidth/2}},s:function(){var t=p();return{top:t.s.y,left:t.s.x-o.offsetWidth/2}},e:function(){var t=p();return{top:t.e.y-o.offsetHeight/2,left:t.e.x}},w:function(){var t=p();return{top:t.w.y-o.offsetHeight/2,left:t.w.x-o.offsetWidth}},nw:function(){var t=p();return{top:t.nw.y-o.offsetHeight,left:t.nw.x-o.offsetWidth}},ne:function(){var t=p();return{top:t.ne.y-o.offsetHeight,left:t.ne.x}},sw:function(){var t=p();return{top:t.sw.y,left:t.sw.x-o.offsetWidth}},se:function(){var t=p();return{top:t.se.y,left:t.e.x}}}),l=i.keys();function u(){var t=d3.select(document.createElement("div"));return t.style({position:"absolute",top:0,opacity:0,"pointer-events":"none","box-sizing":"border-box"}),t.node()}function f(){return null===o&&(o=u(),document.body.appendChild(o)),d3.select(o)}function p(){for(var t=s||d3.event.target;void 0===t.getScreenCTM&&"undefined"===t.parentNode;)t=t.parentNode;var e={},n=t.getScreenCTM(),o=t.getBBox(),r=o.width,c=o.height,d=o.x,i=o.y;return a.x=d,a.y=i,e.nw=a.matrixTransform(n),a.x+=r,e.ne=a.matrixTransform(n),a.y+=c,e.se=a.matrixTransform(n),a.x-=r,e.sw=a.matrixTransform(n),a.y-=c/2,e.w=a.matrixTransform(n),a.x+=r,e.e=a.matrixTransform(n),a.x-=r/2,a.y-=c/2,e.n=a.matrixTransform(n),a.y+=c,e.s=a.matrixTransform(n),e}return d}})?o.apply(e,r):o)||(t.exports=a)},88:function(t,e,n){"use strict";n.r(e),n.d(e,"clusterColors",(function(){return r})),n.d(e,"createClusterSvgElement",(function(){return a})),n.d(e,"createClusterZone",(function(){return s})),n.d(e,"setCreateClusterZone",(function(){return c})),n.d(e,"updateClusterZoneLabels",(function(){return d})),n.d(e,"moveElement",(function(){return i})),n.d(e,"createNodes",(function(){return l})),n.d(e,"updateNodes",(function(){return u})),n.d(e,"createLinks",(function(){return p})),n.d(e,"updateLinks",(function(){return h})),n.d(e,"setLinkColor",(function(){return y})),n.d(e,"setLinkStyle",(function(){return g})),n.d(e,"positionNodesOnClusterZone",(function(){return S}));var o=n(77);const r={ontoOrange:"var(--primary-color)",ontoBlue:"var(--secondary-color)",ontoGreen:"var(--tertiary-color)",ontoGrey:"var(--gray-color)"};function a(t){return d3.select(t).append("svg")}function s(t){const e=t.append("g");return e.append("circle").classed("cluster-zone",!0).style("fill","transparent").style("stroke-width","2"),e}function c(t,e,n,o=!1){if(e.select(".cluster-zone").classed("no-cluster",!t).classed("has-access",o),t)e.selectAll("#no-cluster-zone").remove();else{const t=e.append("g").attr("id","no-cluster-zone");t.append("text").attr("id","no-cluster-label").text(n.no_cluster_configured).attr("y",-50).classed("h2",!0).style("text-anchor","middle"),o&&t.append("text").attr("id","create-cluster-label").classed("h3",!0).text(n.create_cluster_btn).style("text-anchor","middle"),t.append("text").attr("y",130).attr("class","icon-any repo").attr("fill",r.ontoOrange).style("text-anchor","middle").classed("settings-icon",!0).text("")}}function d(t,e,n){t||(e.select("#no-cluster-zone #no-cluster-label").text(n.no_cluster_configured),e.select("#no-cluster-zone #create-cluster-label").text(n.create_cluster_btn))}function i(t,e,n){t.attr("transform",()=>`translate(${e}, ${n})`)}function l(t,e,n){const o=t.enter().append("g").attr("id","node-group").classed("legend",n);!function(t,e){const n=Math.sqrt(3)/2,o=[[e+0,0],[e/2+0,e*n+0],[-e/2+0,e*n+0],[0-e,0],[-e/2+0,-e*n+0],[e/2+0,-e*n+0],[e+0,0],[e/2+0,e*n+0]];t.selectAll("path.area").data([o]).enter().append("path").attr("class","node member").attr("d",d3.svg.line())}(o,e),t.exit().remove(),o.append("text").attr("class","icon-any node-icon"),function(t,e,n){const o=t.append("g");n?o.append("foreignObject").attr("y",e).attr("x",-e).attr("width",2*e).attr("height",10).attr("class","label-wrapper").append("xhtml:div").attr("class","id id-host"):(o.append("rect").attr("class","id-host-background").attr("rx",6),o.append("text").attr("y",e+15).attr("class","id id-host"),o.append("rect").attr("class","node-info-background").attr("rx",6),o.append("text").attr("y",e+45).attr("class","node-info-text"))}(o,e,n)}function u(t){!function(t){t.select(".node-icon").classed("icon-any",(function(t){return!f(t)})).classed("fa-d3",f).text((function(t){return f(t)?function(t){if(_.isEmpty(t.recoveryStatus))return"";switch(t.recoveryStatus.state){case o.RecoveryState.SEARCHING_FOR_NODE:return"";case o.RecoveryState.WAITING_FOR_SNAPSHOT:return"";case o.RecoveryState.RECEIVING_SNAPSHOT:return"";case o.RecoveryState.APPLYING_SNAPSHOT:return"";case o.RecoveryState.BUILDING_SNAPSHOT:return"";case o.RecoveryState.SENDING_SNAPSHOT:return"";default:return""}}(t):function(t){if(t.nodeState===o.NodeState.LEADER)return"";if(t.nodeState===o.NodeState.FOLLOWER)return"";if(t.nodeState===o.NodeState.CANDIDATE)return"";if(t.nodeState===o.NodeState.NO_CONNECTION)return"";if(t.nodeState===o.NodeState.OUT_OF_SYNC)return"";if(t.nodeState===o.NodeState.READ_ONLY)return"";if(t.nodeState===o.NodeState.RESTRICTED)return"";return""}(t)}))}(t),function(t){t.select(".node.member").classed("leader",t=>t.nodeState===o.NodeState.LEADER).classed("follower",t=>t.nodeState===o.NodeState.FOLLOWER).classed("candidate",t=>t.nodeState===o.NodeState.CANDIDATE).classed("other",t=>t.nodeState!==o.NodeState.LEADER&&t.nodeState!==o.NodeState.FOLLOWER&&t.nodeState!==o.NodeState.CANDIDATE)}(t),function(t){t.select(".id.id-host").each((function(t){t.labelNode=this})).text((function(t){return t.hostname})),t.select(".id-host-background").attr("width",(function(t){return d3.select(t.labelNode).node().getBBox().width+10})).attr("height",(function(t){return d3.select(t.labelNode).node().getBBox().height+10})).attr("x",(function(t){return d3.select(t.labelNode).node().getBBox().x-5})).attr("y",(function(t){return d3.select(t.labelNode).node().getBBox().y-5}))}(t),function(t){t.select(".node-info-text").each((function(t){t.infoNode=this})).text((function(t){return t.recoveryStatus&&t.recoveryStatus.message})),t.select(".node-info-background").attr("width",(function(t){return d3.select(t.infoNode).node().getBBox().width+10})).attr("height",(function(t){return d3.select(t.infoNode).node().getBBox().height+10})).attr("x",(function(t){return d3.select(t.infoNode).node().getBBox().x-5})).attr("y",(function(t){return d3.select(t.infoNode).node().getBBox().y-5})).classed("hidden",(function(t){return _.isEmpty(t.recoveryStatus)}))}(t)}function f(t){return!_.isEmpty(t.recoveryStatus)}function p(t){t.enter().append("path").classed("link",!0),t.exit().remove()}function h(t,e){t.attr("stroke",y).style("stroke-dasharray",g).attr("d",t=>function(t,e){const n=e.find(e=>e.address===t.source),o=e.find(e=>e.address===t.target),r=o.x-n.x,a=o.y-n.y,s=Math.sqrt(r*r+a*a),c=r/s,d=a/s,i=n.x+55*c,l=n.y+55*d,u=o.x-55*c,f=o.y-55*d;return"M"+i+","+l+"L"+u+","+f}(t,e))}function y(t){return t.status===o.LinkState.IN_SYNC||t.status===o.LinkState.SYNCING?r.ontoGreen:t.status===o.LinkState.OUT_OF_SYNC?r.ontoGrey:"none"}function g(t){return t.status===o.LinkState.OUT_OF_SYNC||t.status===o.LinkState.SYNCING?"10 10":"none"}function S(t,e,n,o){t.attr("transform",(r,a)=>{const s=2*Math.PI*a/t[0].length;var c=e+Math.cos(s)*o,d=n+Math.sin(s)*o;return r.x=c,r.y=d,`translate(${c}, ${d})`})}},94:function(t,e,n){"use strict";n.r(e);n(10);var o=n(88),r=n(77),a=n(298),s=n.n(a);let c=240;const d=angular.module("graphdb.framework.clustermanagement.directives",["graphdb.framework.utils.localstorageadapter"]),i={no_cluster_configured:"",create_cluster_btn:"",legend_node_state:"",legend_link_state:"",node_state_leader:"Leader",node_state_follower:"Follower",node_state_candidate:"Candidate",node_state_no_cluster:"No cluster",node_state_out_of_sync:"Out of sync",node_state_no_connection:"No connection",node_state_read_only:"Read only",node_state_restricted:"Restricted",link_state_in_sync:"In sync",link_state_syncing:"Syncing",link_state_out_of_sync:"Out of sync",recovery_state:{searching_for_node:"Searching for node",waiting_for_snapshot:"Waiting for snapshot from node",receiving_snapshot:"Receiving a snapshot from node",applying_snapshot:"Applying a snapshot",building_snapshot:"Building a snapshot for node",sending_snapshot:"Sending a snapshot to node"}},l={node_state:"legend_node_state",link_state:"legend_link_state"};d.directive("clusterGraphicalView",["$window","LocalStorageAdapter","LSKeys","UriUtils","$translate","$rootScope",function(t,e,n,r,a,d){return{restrict:"A",link:function(p,h){const y=p.isAdmin();function g(t,e=""){Object.keys(t).forEach(n=>{let o="";e&&(o+=e),o+="."+n;const r=t[n];"string"==typeof r?t[n]=a.instant("cluster_management.cluster_graphical_view"+o):"object"==typeof r&&g(r,o)})}function S(){const o="collapsedMenu"===e.get(n.MENU_STATE);return c=o?70:240,Math.max(Math.floor(.95*(t.innerWidth-c)),600)}function m(){return Math.max(.95*(t.innerHeight-250),600)}let N,x,v;p.showLegend=!1,d.$on("$translateChangeSuccess",(function(){g(i),function(){o.updateClusterZoneLabels(T,O,i),Object.keys(l).forEach(t=>{d3.select("#"+t).text(B(t))}),N&&N.remove();D(),F()}()})),p.$on("$destroy",(function(){G.destroy()}));let T,E,O,w,C,k,L=S(),b=m(),A=Math.min(L,b)/2-100,R=L/2,I=b/2;function B(t){return i[l[t]]}function D(){N=E.append("g").attr("id","legend-group").classed("hidden",!p.showLegend).classed("legend-group",!0)}p.width=function(){return L},p.height=function(){return b};const G=s()().attr("class","d3-tip").customPosition((function(){const t=k.getBoundingClientRect(),e=document.documentElement.scrollTop||document.body.scrollTop,n=document.documentElement.scrollLeft||document.body.scrollLeft;return{left:t.left+n+"px",top:t.top-30+e+"px"}})).html((function(t){return t.toolTip})),M=function(t,e){k=e,G.show(t,k)},Y=function(){k=null,G.hide()};function F(){const t=u(),e=f();!function(t,e){t.forEach(t=>{const e=_.get(i,t.customText);t.toolTip=t.hostname=e}),e.forEach(t=>{t.toolTip=t.linkTypeText=i[t.linkTypeKey]})}(t,e),N.append("rect").attr("id","legend-background").attr("class","legend-background").attr("fill","#EEEEEE");const n=N.append("text").attr("id","node_state").attr("class","id id-host").attr("x",200).attr("y",24).text(B("node_state")),r=N.append("text").attr("id","link_state").attr("class","id id-host").attr("x",200).attr("y",319).text(B("link_state")),a=N.selectAll("#node-group").data(t);o.createNodes(a,25,!0),o.updateNodes(a),a.select(".node.member").on("mouseover",(function(t){d3.event.stopPropagation(),M(t,this)})).on("mouseout",Y),a.attr("transform",(function(t){const e=Math.floor(t.id/4);return`translate(${35+65*(t.id%4)}, ${59+65*e})`})),N.call((function(){x=this.node().getBBox().width})),n.attr("x",10+x/2),r.attr("x",10+x/2);const s=x/3,c=N.append("g").attr("id","links-group");c.attr("transform","translate(10, 329)"),e.forEach((t,e)=>{const n=s-5,r=c.append("g").classed("link",!0).classed("legend",!0).attr("transform",()=>`translate(${e*s}, 0)`);r.append("path").classed("link",!0).attr("stroke-dasharray",()=>o.setLinkStyle(t)).attr("stroke",()=>o.setLinkColor(t)).attr("d",()=>`M5,0,${n},0`),r.append("foreignObject").attr("y",10).attr("x",5).attr("width",s-10).attr("height",10).attr("class","label-wrapper").append("xhtml:div").attr("class","id id-host").style("font-size","9px").html(t.linkTypeText),r.on("mouseover",(function(){d3.event.stopPropagation(),M(t,this)})).on("mouseout",Y)}),N.call((function(t){v=this.node().getBBox().height,x=this.node().getBBox().width})),N.select(".legend-background").attr("height",v+50).attr("width",x+20).attr("rx","6"),P()}function P(){const t=b-(v+40+50);o.moveElement(N,0,t)}function H(){A=Math.min(L,b)/2-100,R=L/2,I=b/2,o.moveElement(O,R,I),O.select(".cluster-zone").attr("r",A)}function U(){H(),T!==p.clusterModel.hasCluster&&(T=!!p.clusterModel.hasCluster,function(t){let e;o.setCreateClusterZone(t,O,i,y),!t&&y&&(e=()=>{p.$apply((function(){p.showCreateClusterDialog()}))}),O.on("mouseup",e)}(T));const t=_.cloneDeep(p.clusterModel.nodes)||[],e=_.cloneDeep(p.clusterModel.links)||[];!function(t){t.forEach(t=>{if(t.hostname=r.shortenIri(t.endpoint),!_.isEmpty(t.recoveryStatus)){const e="cluster_management.cluster_graphical_view.recovery_state."+t.recoveryStatus.state.toLowerCase();t.recoveryStatus.message=a.instant(e,{node:t.recoveryStatus.affectedNodes.join(", ")})}});const e=w.selectAll("#node-group").data(t,t=>t.address);e.on("click",t=>{p.childContext.selectNode(t);const e=d3.select(".nodetooltip"),n=$(window).width();d3.event.pageX<n/2?(e.style("left",d3.event.pageX+"px"),e.style("right","")):(e.style("left",""),e.style("right",n-d3.event.pageX+"px")),e.style("top",d3.event.pageY-28+"px")}),o.createNodes(e,50),o.updateNodes(e),o.positionNodesOnClusterZone(e,R,I,A)}(t),function(t,e){const n=C.selectAll(".link").data(t,t=>t.id);o.createLinks(n),o.updateLinks(n,e)}(e,t)}p.childContext.redraw=U,p.childContext.resize=function(){L=S(),b=m(),E.attr("width",L),E.attr("height",b),U(),P()},p.childContext.toggleLegend=()=>{p.showLegend=!p.showLegend,N.classed("hidden",!p.showLegend)},g(i),function(t){E=o.createClusterSvgElement(h[0]).attr("width",L).attr("height",b),E.call(G),O=o.createClusterZone(E,t),C=E.append("g").attr("id","links-group"),w=E.append("g").attr("id","nodes-group"),D()}(!(!p.clusterModel.nodes||!p.clusterModel.nodes.length)),F(),U()}}}]);const u=function(){const t=[];return t.push({nodeState:r.NodeState.LEADER,customText:"node_state_leader"}),t.push({nodeState:r.NodeState.FOLLOWER,customText:"node_state_follower"}),t.push({nodeState:r.NodeState.CANDIDATE,customText:"node_state_candidate"}),t.push({nodeState:r.NodeState.NO_CLUSTER,customText:"node_state_no_cluster"}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"node_state_out_of_sync"}),t.push({nodeState:r.NodeState.NO_CONNECTION,customText:"node_state_no_connection"}),t.push({nodeState:r.NodeState.READ_ONLY,customText:"node_state_read_only"}),t.push({nodeState:r.NodeState.RESTRICTED,customText:"node_state_restricted"}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"recovery_state.searching_for_node",recoveryStatus:{state:r.RecoveryState.SEARCHING_FOR_NODE}}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"recovery_state.waiting_for_snapshot",recoveryStatus:{state:r.RecoveryState.WAITING_FOR_SNAPSHOT}}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"recovery_state.receiving_snapshot",recoveryStatus:{state:r.RecoveryState.RECEIVING_SNAPSHOT}}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"recovery_state.applying_snapshot",recoveryStatus:{state:r.RecoveryState.APPLYING_SNAPSHOT}}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"recovery_state.building_snapshot",recoveryStatus:{state:r.RecoveryState.BUILDING_SNAPSHOT}}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"recovery_state.sending_snapshot",recoveryStatus:{state:r.RecoveryState.SENDING_SNAPSHOT}}),t.forEach((t,e)=>t.id=e),t},f=function(){const t=[];return t.push({status:r.LinkState.IN_SYNC,linkTypeKey:"link_state_in_sync"}),t.push({status:r.LinkState.SYNCING,linkTypeKey:"link_state_syncing"}),t.push({status:r.LinkState.OUT_OF_SYNC,linkTypeKey:"link_state_out_of_sync"}),t.forEach((t,e)=>t.id=e),t}}}]);
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[34,72],{298:function(t,e,n){var o,r,a;r=[],void 0===(a="function"==typeof(o=function(){return function(){var t=function(){return"n"},e=function(){return[0,0]},n=function(){return" "},o=u(),r=null,a=null,s=null,c=null;function d(t){var e;r="svg"===(e=(e=t).node()).tagName.toLowerCase()?e:e.ownerSVGElement,a=r.createSVGPoint(),document.body.appendChild(o)}d.show=function(){var o=Array.prototype.slice.call(arguments);o[o.length-1]instanceof SVGElement&&(s=o.pop());var r,a=n.apply(this,o),u=e.apply(this,o),p=t.apply(this,o),h=f(),y=l.length,_=document.documentElement.scrollTop||document.body.scrollTop,g=document.documentElement.scrollLeft||document.body.scrollLeft,S=c.apply(this,o);for(h.html(a).style({opacity:1,"pointer-events":"all"});y--;)h.classed(l[y],!1);return r=i.get(p).apply(this),S?h.style(S):h.classed(p,!0).style({top:r.top+u[0]+_+"px",left:r.left+u[1]+g+"px"}),d},d.hide=function(){return f().style({opacity:0,"pointer-events":"none"}),d},d.attr=function(t,e){if(arguments.length<2&&"string"==typeof t)return f().attr(t);var n=Array.prototype.slice.call(arguments);return d3.selection.prototype.attr.apply(f(),n),d},d.style=function(t,e){if(arguments.length<2&&"string"==typeof t)return f().style(t);var n=Array.prototype.slice.call(arguments);return d3.selection.prototype.style.apply(f(),n),d},d.direction=function(e){return arguments.length?(t=null==e?e:d3.functor(e),d):t},d.offset=function(t){return arguments.length?(e=null==t?t:d3.functor(t),d):e},d.html=function(t){return arguments.length?(n=null==t?t:d3.functor(t),d):n},d.customPosition=function(t){return arguments.length?(c=null==t?t:d3.functor(t),d):c},d.destroy=function(){return o&&(f().remove(),o=null),d};var i=d3.map({n:function(){var t=p();return{top:t.n.y-o.offsetHeight,left:t.n.x-o.offsetWidth/2}},s:function(){var t=p();return{top:t.s.y,left:t.s.x-o.offsetWidth/2}},e:function(){var t=p();return{top:t.e.y-o.offsetHeight/2,left:t.e.x}},w:function(){var t=p();return{top:t.w.y-o.offsetHeight/2,left:t.w.x-o.offsetWidth}},nw:function(){var t=p();return{top:t.nw.y-o.offsetHeight,left:t.nw.x-o.offsetWidth}},ne:function(){var t=p();return{top:t.ne.y-o.offsetHeight,left:t.ne.x}},sw:function(){var t=p();return{top:t.sw.y,left:t.sw.x-o.offsetWidth}},se:function(){var t=p();return{top:t.se.y,left:t.e.x}}}),l=i.keys();function u(){var t=d3.select(document.createElement("div"));return t.style({position:"absolute",top:0,opacity:0,"pointer-events":"none","box-sizing":"border-box"}),t.node()}function f(){return null===o&&(o=u(),document.body.appendChild(o)),d3.select(o)}function p(){for(var t=s||d3.event.target;void 0===t.getScreenCTM&&"undefined"===t.parentNode;)t=t.parentNode;var e={},n=t.getScreenCTM(),o=t.getBBox(),r=o.width,c=o.height,d=o.x,i=o.y;return a.x=d,a.y=i,e.nw=a.matrixTransform(n),a.x+=r,e.ne=a.matrixTransform(n),a.y+=c,e.se=a.matrixTransform(n),a.x-=r,e.sw=a.matrixTransform(n),a.y-=c/2,e.w=a.matrixTransform(n),a.x+=r,e.e=a.matrixTransform(n),a.x-=r/2,a.y-=c/2,e.n=a.matrixTransform(n),a.y+=c,e.s=a.matrixTransform(n),e}return d}})?o.apply(e,r):o)||(t.exports=a)},88:function(t,e,n){"use strict";n.r(e),n.d(e,"clusterColors",(function(){return r})),n.d(e,"createClusterSvgElement",(function(){return a})),n.d(e,"createClusterZone",(function(){return s})),n.d(e,"setCreateClusterZone",(function(){return c})),n.d(e,"updateClusterZoneLabels",(function(){return d})),n.d(e,"moveElement",(function(){return i})),n.d(e,"createNodes",(function(){return l})),n.d(e,"updateNodes",(function(){return u})),n.d(e,"createLinks",(function(){return p})),n.d(e,"updateLinks",(function(){return h})),n.d(e,"setLinkColor",(function(){return y})),n.d(e,"setLinkStyle",(function(){return g})),n.d(e,"positionNodesOnClusterZone",(function(){return S}));var o=n(78);const r={ontoOrange:"var(--primary-color)",ontoBlue:"var(--secondary-color)",ontoGreen:"var(--tertiary-color)",ontoGrey:"var(--gray-color)"};function a(t){return d3.select(t).append("svg")}function s(t){const e=t.append("g");return e.append("circle").classed("cluster-zone",!0).style("fill","transparent").style("stroke-width","2"),e}function c(t,e,n,o=!1){if(e.select(".cluster-zone").classed("no-cluster",!t).classed("has-access",o),t)e.selectAll("#no-cluster-zone").remove();else{const t=e.append("g").attr("id","no-cluster-zone");t.append("text").attr("id","no-cluster-label").text(n.no_cluster_configured).attr("y",-50).classed("h2",!0).style("text-anchor","middle"),o&&t.append("text").attr("id","create-cluster-label").classed("h3",!0).text(n.create_cluster_btn).style("text-anchor","middle"),t.append("text").attr("y",130).attr("class","icon-any repo").attr("fill",r.ontoOrange).style("text-anchor","middle").classed("settings-icon",!0).text("")}}function d(t,e,n){t||(e.select("#no-cluster-zone #no-cluster-label").text(n.no_cluster_configured),e.select("#no-cluster-zone #create-cluster-label").text(n.create_cluster_btn))}function i(t,e,n){t.attr("transform",()=>`translate(${e}, ${n})`)}function l(t,e,n){const o=t.enter().append("g").attr("id","node-group").classed("legend",n);!function(t,e){const n=Math.sqrt(3)/2,o=[[e+0,0],[e/2+0,e*n+0],[-e/2+0,e*n+0],[0-e,0],[-e/2+0,-e*n+0],[e/2+0,-e*n+0],[e+0,0],[e/2+0,e*n+0]];t.selectAll("path.area").data([o]).enter().append("path").attr("class","node member").attr("d",d3.svg.line())}(o,e),t.exit().remove(),o.append("text").attr("class","icon-any node-icon"),function(t,e,n){const o=t.append("g");n?o.append("foreignObject").attr("y",e).attr("x",-e).attr("width",2*e).attr("height",10).attr("class","label-wrapper").append("xhtml:div").attr("class","id id-host"):(o.append("rect").attr("class","id-host-background").attr("rx",6),o.append("text").attr("y",e+15).attr("class","id id-host"),o.append("rect").attr("class","node-info-background").attr("rx",6),o.append("text").attr("y",e+45).attr("class","node-info-text"))}(o,e,n)}function u(t){!function(t){t.select(".node-icon").classed("icon-any",(function(t){return!f(t)})).classed("fa-d3",f).text((function(t){return f(t)?function(t){if(_.isEmpty(t.recoveryStatus))return"";switch(t.recoveryStatus.state){case o.RecoveryState.SEARCHING_FOR_NODE:return"";case o.RecoveryState.WAITING_FOR_SNAPSHOT:return"";case o.RecoveryState.RECEIVING_SNAPSHOT:return"";case o.RecoveryState.APPLYING_SNAPSHOT:return"";case o.RecoveryState.BUILDING_SNAPSHOT:return"";case o.RecoveryState.SENDING_SNAPSHOT:return"";default:return""}}(t):function(t){if(t.nodeState===o.NodeState.LEADER)return"";if(t.nodeState===o.NodeState.FOLLOWER)return"";if(t.nodeState===o.NodeState.CANDIDATE)return"";if(t.nodeState===o.NodeState.NO_CONNECTION)return"";if(t.nodeState===o.NodeState.OUT_OF_SYNC)return"";if(t.nodeState===o.NodeState.READ_ONLY)return"";if(t.nodeState===o.NodeState.RESTRICTED)return"";return""}(t)}))}(t),function(t){t.select(".node.member").classed("leader",t=>t.nodeState===o.NodeState.LEADER).classed("follower",t=>t.nodeState===o.NodeState.FOLLOWER).classed("candidate",t=>t.nodeState===o.NodeState.CANDIDATE).classed("other",t=>t.nodeState!==o.NodeState.LEADER&&t.nodeState!==o.NodeState.FOLLOWER&&t.nodeState!==o.NodeState.CANDIDATE)}(t),function(t){t.select(".id.id-host").each((function(t){t.labelNode=this})).text((function(t){return t.hostname})),t.select(".id-host-background").attr("width",(function(t){return d3.select(t.labelNode).node().getBBox().width+10})).attr("height",(function(t){return d3.select(t.labelNode).node().getBBox().height+10})).attr("x",(function(t){return d3.select(t.labelNode).node().getBBox().x-5})).attr("y",(function(t){return d3.select(t.labelNode).node().getBBox().y-5}))}(t),function(t){t.select(".node-info-text").each((function(t){t.infoNode=this})).text((function(t){return t.recoveryStatus&&t.recoveryStatus.message})),t.select(".node-info-background").attr("width",(function(t){return d3.select(t.infoNode).node().getBBox().width+10})).attr("height",(function(t){return d3.select(t.infoNode).node().getBBox().height+10})).attr("x",(function(t){return d3.select(t.infoNode).node().getBBox().x-5})).attr("y",(function(t){return d3.select(t.infoNode).node().getBBox().y-5})).classed("hidden",(function(t){return _.isEmpty(t.recoveryStatus)}))}(t)}function f(t){return!_.isEmpty(t.recoveryStatus)}function p(t){t.enter().append("path").classed("link",!0),t.exit().remove()}function h(t,e){t.attr("stroke",y).style("stroke-dasharray",g).attr("d",t=>function(t,e){const n=e.find(e=>e.address===t.source),o=e.find(e=>e.address===t.target),r=o.x-n.x,a=o.y-n.y,s=Math.sqrt(r*r+a*a),c=r/s,d=a/s,i=n.x+55*c,l=n.y+55*d,u=o.x-55*c,f=o.y-55*d;return"M"+i+","+l+"L"+u+","+f}(t,e))}function y(t){return t.status===o.LinkState.IN_SYNC||t.status===o.LinkState.SYNCING?r.ontoGreen:t.status===o.LinkState.OUT_OF_SYNC?r.ontoGrey:"none"}function g(t){return t.status===o.LinkState.OUT_OF_SYNC||t.status===o.LinkState.SYNCING?"10 10":"none"}function S(t,e,n,o){t.attr("transform",(r,a)=>{const s=2*Math.PI*a/t[0].length;var c=e+Math.cos(s)*o,d=n+Math.sin(s)*o;return r.x=c,r.y=d,`translate(${c}, ${d})`})}},94:function(t,e,n){"use strict";n.r(e);n(10);var o=n(88),r=n(78),a=n(298),s=n.n(a);let c=240;const d=angular.module("graphdb.framework.clustermanagement.directives",["graphdb.framework.utils.localstorageadapter"]),i={no_cluster_configured:"",create_cluster_btn:"",legend_node_state:"",legend_link_state:"",node_state_leader:"Leader",node_state_follower:"Follower",node_state_candidate:"Candidate",node_state_no_cluster:"No cluster",node_state_out_of_sync:"Out of sync",node_state_no_connection:"No connection",node_state_read_only:"Read only",node_state_restricted:"Restricted",link_state_in_sync:"In sync",link_state_syncing:"Syncing",link_state_out_of_sync:"Out of sync",recovery_state:{searching_for_node:"Searching for node",waiting_for_snapshot:"Waiting for snapshot from node",receiving_snapshot:"Receiving a snapshot from node",applying_snapshot:"Applying a snapshot",building_snapshot:"Building a snapshot for node",sending_snapshot:"Sending a snapshot to node"}},l={node_state:"legend_node_state",link_state:"legend_link_state"};d.directive("clusterGraphicalView",["$window","LocalStorageAdapter","LSKeys","UriUtils","$translate","$rootScope",function(t,e,n,r,a,d){return{restrict:"A",link:function(p,h){const y=p.isAdmin();function g(t,e=""){Object.keys(t).forEach(n=>{let o="";e&&(o+=e),o+="."+n;const r=t[n];"string"==typeof r?t[n]=a.instant("cluster_management.cluster_graphical_view"+o):"object"==typeof r&&g(r,o)})}function S(){const o="collapsedMenu"===e.get(n.MENU_STATE);return c=o?70:240,Math.max(Math.floor(.95*(t.innerWidth-c)),600)}function m(){return Math.max(.95*(t.innerHeight-250),600)}let N,x,v;p.showLegend=!1,d.$on("$translateChangeSuccess",(function(){g(i),function(){o.updateClusterZoneLabels(T,O,i),Object.keys(l).forEach(t=>{d3.select("#"+t).text(B(t))}),N&&N.remove();D(),F()}()})),p.$on("$destroy",(function(){G.destroy()}));let T,E,O,w,C,k,L=S(),b=m(),A=Math.min(L,b)/2-100,R=L/2,I=b/2;function B(t){return i[l[t]]}function D(){N=E.append("g").attr("id","legend-group").classed("hidden",!p.showLegend).classed("legend-group",!0)}p.width=function(){return L},p.height=function(){return b};const G=s()().attr("class","d3-tip").customPosition((function(){const t=k.getBoundingClientRect(),e=document.documentElement.scrollTop||document.body.scrollTop,n=document.documentElement.scrollLeft||document.body.scrollLeft;return{left:t.left+n+"px",top:t.top-30+e+"px"}})).html((function(t){return t.toolTip})),M=function(t,e){k=e,G.show(t,k)},Y=function(){k=null,G.hide()};function F(){const t=u(),e=f();!function(t,e){t.forEach(t=>{const e=_.get(i,t.customText);t.toolTip=t.hostname=e}),e.forEach(t=>{t.toolTip=t.linkTypeText=i[t.linkTypeKey]})}(t,e),N.append("rect").attr("id","legend-background").attr("class","legend-background").attr("fill","#EEEEEE");const n=N.append("text").attr("id","node_state").attr("class","id id-host").attr("x",200).attr("y",24).text(B("node_state")),r=N.append("text").attr("id","link_state").attr("class","id id-host").attr("x",200).attr("y",319).text(B("link_state")),a=N.selectAll("#node-group").data(t);o.createNodes(a,25,!0),o.updateNodes(a),a.select(".node.member").on("mouseover",(function(t){d3.event.stopPropagation(),M(t,this)})).on("mouseout",Y),a.attr("transform",(function(t){const e=Math.floor(t.id/4);return`translate(${35+65*(t.id%4)}, ${59+65*e})`})),N.call((function(){x=this.node().getBBox().width})),n.attr("x",10+x/2),r.attr("x",10+x/2);const s=x/3,c=N.append("g").attr("id","links-group");c.attr("transform","translate(10, 329)"),e.forEach((t,e)=>{const n=s-5,r=c.append("g").classed("link",!0).classed("legend",!0).attr("transform",()=>`translate(${e*s}, 0)`);r.append("path").classed("link",!0).attr("stroke-dasharray",()=>o.setLinkStyle(t)).attr("stroke",()=>o.setLinkColor(t)).attr("d",()=>`M5,0,${n},0`),r.append("foreignObject").attr("y",10).attr("x",5).attr("width",s-10).attr("height",10).attr("class","label-wrapper").append("xhtml:div").attr("class","id id-host").style("font-size","9px").html(t.linkTypeText),r.on("mouseover",(function(){d3.event.stopPropagation(),M(t,this)})).on("mouseout",Y)}),N.call((function(t){v=this.node().getBBox().height,x=this.node().getBBox().width})),N.select(".legend-background").attr("height",v+50).attr("width",x+20).attr("rx","6"),P()}function P(){const t=b-(v+40+50);o.moveElement(N,0,t)}function H(){A=Math.min(L,b)/2-100,R=L/2,I=b/2,o.moveElement(O,R,I),O.select(".cluster-zone").attr("r",A)}function U(){H(),T!==p.clusterModel.hasCluster&&(T=!!p.clusterModel.hasCluster,function(t){let e;o.setCreateClusterZone(t,O,i,y),!t&&y&&(e=()=>{p.$apply((function(){p.showCreateClusterDialog()}))}),O.on("mouseup",e)}(T));const t=_.cloneDeep(p.clusterModel.nodes)||[],e=_.cloneDeep(p.clusterModel.links)||[];!function(t){t.forEach(t=>{if(t.hostname=r.shortenIri(t.endpoint),!_.isEmpty(t.recoveryStatus)){const e="cluster_management.cluster_graphical_view.recovery_state."+t.recoveryStatus.state.toLowerCase();t.recoveryStatus.message=a.instant(e,{node:t.recoveryStatus.affectedNodes.join(", ")})}});const e=w.selectAll("#node-group").data(t,t=>t.address);e.on("click",t=>{p.childContext.selectNode(t);const e=d3.select(".nodetooltip"),n=$(window).width();d3.event.pageX<n/2?(e.style("left",d3.event.pageX+"px"),e.style("right","")):(e.style("left",""),e.style("right",n-d3.event.pageX+"px")),e.style("top",d3.event.pageY-28+"px")}),o.createNodes(e,50),o.updateNodes(e),o.positionNodesOnClusterZone(e,R,I,A)}(t),function(t,e){const n=C.selectAll(".link").data(t,t=>t.id);o.createLinks(n),o.updateLinks(n,e)}(e,t)}p.childContext.redraw=U,p.childContext.resize=function(){L=S(),b=m(),E.attr("width",L),E.attr("height",b),U(),P()},p.childContext.toggleLegend=()=>{p.showLegend=!p.showLegend,N.classed("hidden",!p.showLegend)},g(i),function(t){E=o.createClusterSvgElement(h[0]).attr("width",L).attr("height",b),E.call(G),O=o.createClusterZone(E,t),C=E.append("g").attr("id","links-group"),w=E.append("g").attr("id","nodes-group"),D()}(!(!p.clusterModel.nodes||!p.clusterModel.nodes.length)),F(),U()}}}]);const u=function(){const t=[];return t.push({nodeState:r.NodeState.LEADER,customText:"node_state_leader"}),t.push({nodeState:r.NodeState.FOLLOWER,customText:"node_state_follower"}),t.push({nodeState:r.NodeState.CANDIDATE,customText:"node_state_candidate"}),t.push({nodeState:r.NodeState.NO_CLUSTER,customText:"node_state_no_cluster"}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"node_state_out_of_sync"}),t.push({nodeState:r.NodeState.NO_CONNECTION,customText:"node_state_no_connection"}),t.push({nodeState:r.NodeState.READ_ONLY,customText:"node_state_read_only"}),t.push({nodeState:r.NodeState.RESTRICTED,customText:"node_state_restricted"}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"recovery_state.searching_for_node",recoveryStatus:{state:r.RecoveryState.SEARCHING_FOR_NODE}}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"recovery_state.waiting_for_snapshot",recoveryStatus:{state:r.RecoveryState.WAITING_FOR_SNAPSHOT}}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"recovery_state.receiving_snapshot",recoveryStatus:{state:r.RecoveryState.RECEIVING_SNAPSHOT}}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"recovery_state.applying_snapshot",recoveryStatus:{state:r.RecoveryState.APPLYING_SNAPSHOT}}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"recovery_state.building_snapshot",recoveryStatus:{state:r.RecoveryState.BUILDING_SNAPSHOT}}),t.push({nodeState:r.NodeState.OUT_OF_SYNC,customText:"recovery_state.sending_snapshot",recoveryStatus:{state:r.RecoveryState.SENDING_SNAPSHOT}}),t.forEach((t,e)=>t.id=e),t},f=function(){const t=[];return t.push({status:r.LinkState.IN_SYNC,linkTypeKey:"link_state_in_sync"}),t.push({status:r.LinkState.SYNCING,linkTypeKey:"link_state_syncing"}),t.push({status:r.LinkState.OUT_OF_SYNC,linkTypeKey:"link_state_out_of_sync"}),t.forEach((t,e)=>t.id=e),t}}}]);
@@ -1 +1 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[34,44,75],{116:function(e,i,a){"use strict";a.r(i);a(32),a(65);var t=a(1);function n(e,i,a,n,s,r){e.guides=[],e.pageSizeOptions=[10,20,50,100],e.page=1,e.pageSize=e.pageSizeOptions[0],e.translationSubscription=void 0,e.init=function(){a.getGuides().then(i=>{e.guides=n("orderBy")(i,"guideOrder"),e.guides.forEach(e=>{switch(e.translatedGuideName=t.GuideUtils.translateLocalMessage(s,r,e.guideName),e.translatedGuideDescription=t.GuideUtils.translateLocalMessage(s,r,e.guideDescription),e.guideLevel){case void 0:case 0:e.guideLevelLabel="view.guides.level.beginner";break;case 1:e.guideLevelLabel="view.guides.level.intermediate";break;default:e.guideLevelLabel="view.guides.level.advanced"}}),e.matchedElements=e.guides,e.changePagination()})},e.startGuide=function(e){a.startGuide(e)},this.translationSubscription||(this.translationSubscription=i.$on("$translateChangeSuccess",()=>{e.init()})),e.changePagination=function(){angular.isDefined(e.guides)&&(e.displayedGuides=e.guides.slice(e.pageSize*(e.page-1),e.pageSize*e.page))},e.changePageSize=function(i){e.page=1,e.pageSize=i||e.pageSizeOptions[0],e.changePagination()},e.init()}angular.module("graphdb.framework.guides.controllers",["ui.bootstrap","graphdb.framework.guides.services","graphdb.framework.core.directives.paginations"]).controller("GuidesCtrl",n),n.$inject=["$scope","$rootScope","GuidesService","$filter","$translate","$interpolate"]},154:function(e,i,a){"use strict";a.r(i);a(116);angular.module("graphdb.framework.guides",["ui.bootstrap","graphdb.framework.guides.controllers"])},65:function(e,i){angular.module("graphdb.framework.core.directives.paginations",[]).directive("paginations",(function(){return{template:'<uib-pagination class="nav navbar-right" total-items="matchedElements.length" items-per-page="pageSize" ng-model="page" ng-change="changePagination()" direction-links="false" boundary-links="true" max-size="5" rotate="true"></uib-pagination>'}}))}}]);
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[35,45,75],{116:function(e,i,a){"use strict";a.r(i);a(32),a(66);var t=a(2);function n(e,i,a,n,s,r){e.guides=[],e.pageSizeOptions=[10,20,50,100],e.page=1,e.pageSize=e.pageSizeOptions[0],e.translationSubscription=void 0,e.init=function(){a.getGuides().then(i=>{e.guides=n("orderBy")(i,"guideOrder"),e.guides.forEach(e=>{switch(e.translatedGuideName=t.GuideUtils.translateLocalMessage(s,r,e.guideName),e.translatedGuideDescription=t.GuideUtils.translateLocalMessage(s,r,e.guideDescription),e.guideLevel){case void 0:case 0:e.guideLevelLabel="view.guides.level.beginner";break;case 1:e.guideLevelLabel="view.guides.level.intermediate";break;default:e.guideLevelLabel="view.guides.level.advanced"}}),e.matchedElements=e.guides,e.changePagination()})},e.startGuide=function(e){a.startGuide(e)},this.translationSubscription||(this.translationSubscription=i.$on("$translateChangeSuccess",()=>{e.init()})),e.changePagination=function(){angular.isDefined(e.guides)&&(e.displayedGuides=e.guides.slice(e.pageSize*(e.page-1),e.pageSize*e.page))},e.changePageSize=function(i){e.page=1,e.pageSize=i||e.pageSizeOptions[0],e.changePagination()},e.init()}angular.module("graphdb.framework.guides.controllers",["ui.bootstrap","graphdb.framework.guides.services","graphdb.framework.core.directives.paginations"]).controller("GuidesCtrl",n),n.$inject=["$scope","$rootScope","GuidesService","$filter","$translate","$interpolate"]},154:function(e,i,a){"use strict";a.r(i);a(116);angular.module("graphdb.framework.guides",["ui.bootstrap","graphdb.framework.guides.controllers"])},66:function(e,i){angular.module("graphdb.framework.core.directives.paginations",[]).directive("paginations",(function(){return{template:'<uib-pagination class="nav navbar-right" total-items="matchedElements.length" items-per-page="pageSize" ng-model="page" ng-change="changePagination()" direction-links="false" boundary-links="true" max-size="5" rotate="true"></uib-pagination>'}}))}}]);
@@ -1 +1 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[35,136],{113:function(e,t,n){"use strict";n.r(t);var r=n(302);n(83);function a(e,t){return{restrict:"A",template:'<div id="dependencies-chord"></div>',scope:{dependenciesData:"="},link:function(n){n.$watch("dependenciesData",(function(){if(n.dependenciesData){const a=n.dependenciesData;!function(a,s){if(function(){let e=!0;for(const t of a){if(t.some(e=>0!==e)){e=!1;break}}return e}())return;const i=d3.scale.category20(),o=d3.select("body").append("div").attr("class","tooltip").style("opacity",0);d3.select("body").on("click",(function(){o.style("opacity",0)}));const c=Math.min(800,800)/2.8,d=c-24,l=d3.svg.arc().innerRadius(d).outerRadius(c),p=d3.layout.chord().padding(.04).sortSubgroups(d3.descending).sortChords(d3.ascending),u=d3.svg.chord().radius(d),g=d3.select("#dependencies-chord").append("svg").attr("viewBox","0 0 800 800").attr("preserveAspectRatio","xMidYMid meet").style("font","10px sans-serif").append("g").attr("id","circle").attr("transform","translate(400,400)");g.append("circle").attr("r",c).style("fill","none"),p.matrix(a);const f=g.selectAll(".group").data(p.groups).enter().append("g").attr("class","group").on("mouseover",(function(e,t){h.classed("fade",(function(e){return e.source.index!==t&&e.target.index!==t}))}));f.append("title").text((function(e,t){return s[t]})),f.append("path").attr("id",(function(e,t){return"group"+t})).attr("d",l).style("fill",(function(e,t){return i(t)})),f.append("text").each((function(e){e.angle=(e.startAngle+e.endAngle)/2})).attr("dy",".35em").attr("transform",(function(e){return"rotate("+(180*e.angle/Math.PI-90)+")translate("+(d+26)+")"+(e.angle>Math.PI?"rotate(180)":"")})).style("text-anchor",(function(e){return e.angle>Math.PI?"end":null})).text((function(e){return s[e.index]}));const h=g.selectAll(".chord").data(p.chords).enter().append("path").attr("class","chord").style("fill",(function(e){return i(e.target.index)})).style("fill-opacity",".67").style("stroke","#000").style("stroke-width",".25px").style("cursor","pointer").attr("d",u);h.on("mouseover",(function(){d3.select(this).style({"fill-opacity":"1"})})),h.on("mouseout",(function(){d3.select(this).style({"fill-opacity":".67"})})),h.on("click",(function(e){const r=s[e.source.index],a=s[e.target.index],i=d3.event.pageX,c=d3.event.pageY;t.getPredicates(r,a,n.selectedGraph&&n.selectedGraph.contextID.uri).success((function(e){let t="<div class='dependencies-tooltip'>"+("<div class='row'>"+r+" <i class='fa fa-exchange'></i> "+a+"</div>")+_.map(e.slice(0,10),(function(e){const t=" <i class='fa fa-long-arrow-"+("out"===e.direction?"right":"left")+"'></i>";return"<div class='row'>"+e.predicate+" : "+e.weight+t+" </div>"})).join("");e.length>10?t=t+"<div class='pull-right'>And "+(e.length-10).toString()+" more...</div></div>":t+="</div>",o.html(t).style("left",i+"px").style("top",c+"px")})),o.transition().duration(200).style("opacity",1)})),d3.select("#circle").on("mouseleave",(function(){g.selectAll(".chord").classed("fade",!1)})),d3.select("#download-svg").on("mouseover",(function(){const t=r.a.Export.generateBase64ImageSource(".dependencies-chord svg");d3.select(this).attr({href:t,download:"dependencies-"+e.getActiveRepository()+".svg"})}))}(a.matrix,a.nodes,a.direction)}}))}}}angular.module("graphdb.framework.graphexplore.directives.dependencies",["graphdb.framework.graphexplore.controllers.dependencies","graphdb.framework.rest.graphexplore.data.service"]).directive("dependenciesChord",a),a.$inject=["$repositories","GraphDataRestService"]},302:function(e,t,n){"use strict";var r=n(297),a=a||{};a.Export={getCSSRules:function(e){const t=$('link[href="'+e+'"]')[0].sheet.rules;let n="";return _.each(t,(function(e){n+=e.cssText})),n},generateBase64ImageSource:function(e){e||(e="svg");const t=r.selectAll(e).attr("version","1.1").attr("xmlns","http://www.w3.org/2000/svg").node().parentNode.innerHTML;return"data:image/svg+xml;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(t)))}},t.a=a},83:function(e,t){angular.module("graphdb.framework.rest.graphexplore.data.service",[]).factory("GraphDataRestService",n),n.$inject=["$http"];function n(e){return{getClassHierarchyData:function(t){return e.get("rest/class-hierarchy",{params:{graphURI:t}})},reloadClassHierarchy:function(t){return e.get("rest/class-hierarchy",{params:{doReload:!0,graphURI:t}})},getClassInstances:function(t){return e.get("rest/class-hierarchy/class-instances",{params:{targetUri:t}})},getDomainRangeData:function(t,n){return e.get("rest/domain-range",{params:{targetUri:t,collapsed:n}})},checkDomainRangeData:function(t){return e.head("rest/domain-range",{params:{targetUri:t}})},getRelationshipsData:function(t,n,r){return e.get("rest/dependencies/matrix",{params:{mode:n,classes:_.map(t,(function(e){return e.name})),graphURI:r}})},getRelationshipsClasses:function(t,n){return e.get("rest/dependencies/classes",{params:{mode:t,graphURI:n}})},getRelationshipsStatus:function(t){return e.get("rest/dependencies/status",{params:{graphURI:t}})},calculateRelationships:function(t){return e.get("rest/dependencies/update",{params:{graphURI:t}})},getPredicates:function(t,n,r){return e.get("rest/dependencies/predicates",{params:{from:t,to:n,mode:"all",graphURI:r}})},getInstanceNode:function(t){return e.get("rest/explore-graph/node",{params:{iri:t}})},getInstanceNodeLinks:function(t){return e.get("rest/explore-graph/links",{params:{iri:t}})},getRdfsLabelAndComment:function(t,n,r){const a=r||{};return e({url:"rest/explore/details",method:"GET",params:_.extend(a,{uri:t,languages:n}),headers:{Accept:"application/json"}})}}}}}]);
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[36,136],{113:function(e,t,n){"use strict";n.r(t);var r=n(302);n(84);function a(e,t){return{restrict:"A",template:'<div id="dependencies-chord"></div>',scope:{dependenciesData:"="},link:function(n){n.$watch("dependenciesData",(function(){if(n.dependenciesData){const a=n.dependenciesData;!function(a,s){if(function(){let e=!0;for(const t of a){if(t.some(e=>0!==e)){e=!1;break}}return e}())return;const i=d3.scale.category20(),o=d3.select("body").append("div").attr("class","tooltip").style("opacity",0);d3.select("body").on("click",(function(){o.style("opacity",0)}));const c=Math.min(800,800)/2.8,d=c-24,l=d3.svg.arc().innerRadius(d).outerRadius(c),p=d3.layout.chord().padding(.04).sortSubgroups(d3.descending).sortChords(d3.ascending),u=d3.svg.chord().radius(d),g=d3.select("#dependencies-chord").append("svg").attr("viewBox","0 0 800 800").attr("preserveAspectRatio","xMidYMid meet").style("font","10px sans-serif").append("g").attr("id","circle").attr("transform","translate(400,400)");g.append("circle").attr("r",c).style("fill","none"),p.matrix(a);const f=g.selectAll(".group").data(p.groups).enter().append("g").attr("class","group").on("mouseover",(function(e,t){h.classed("fade",(function(e){return e.source.index!==t&&e.target.index!==t}))}));f.append("title").text((function(e,t){return s[t]})),f.append("path").attr("id",(function(e,t){return"group"+t})).attr("d",l).style("fill",(function(e,t){return i(t)})),f.append("text").each((function(e){e.angle=(e.startAngle+e.endAngle)/2})).attr("dy",".35em").attr("transform",(function(e){return"rotate("+(180*e.angle/Math.PI-90)+")translate("+(d+26)+")"+(e.angle>Math.PI?"rotate(180)":"")})).style("text-anchor",(function(e){return e.angle>Math.PI?"end":null})).text((function(e){return s[e.index]}));const h=g.selectAll(".chord").data(p.chords).enter().append("path").attr("class","chord").style("fill",(function(e){return i(e.target.index)})).style("fill-opacity",".67").style("stroke","#000").style("stroke-width",".25px").style("cursor","pointer").attr("d",u);h.on("mouseover",(function(){d3.select(this).style({"fill-opacity":"1"})})),h.on("mouseout",(function(){d3.select(this).style({"fill-opacity":".67"})})),h.on("click",(function(e){const r=s[e.source.index],a=s[e.target.index],i=d3.event.pageX,c=d3.event.pageY;t.getPredicates(r,a,n.selectedGraph&&n.selectedGraph.contextID.uri).success((function(e){let t="<div class='dependencies-tooltip'>"+("<div class='row'>"+r+" <i class='fa fa-exchange'></i> "+a+"</div>")+_.map(e.slice(0,10),(function(e){const t=" <i class='fa fa-long-arrow-"+("out"===e.direction?"right":"left")+"'></i>";return"<div class='row'>"+e.predicate+" : "+e.weight+t+" </div>"})).join("");e.length>10?t=t+"<div class='pull-right'>And "+(e.length-10).toString()+" more...</div></div>":t+="</div>",o.html(t).style("left",i+"px").style("top",c+"px")})),o.transition().duration(200).style("opacity",1)})),d3.select("#circle").on("mouseleave",(function(){g.selectAll(".chord").classed("fade",!1)})),d3.select("#download-svg").on("mouseover",(function(){const t=r.a.Export.generateBase64ImageSource(".dependencies-chord svg");d3.select(this).attr({href:t,download:"dependencies-"+e.getActiveRepository()+".svg"})}))}(a.matrix,a.nodes,a.direction)}}))}}}angular.module("graphdb.framework.graphexplore.directives.dependencies",["graphdb.framework.graphexplore.controllers.dependencies","graphdb.framework.rest.graphexplore.data.service"]).directive("dependenciesChord",a),a.$inject=["$repositories","GraphDataRestService"]},302:function(e,t,n){"use strict";var r=n(297),a=a||{};a.Export={getCSSRules:function(e){const t=$('link[href="'+e+'"]')[0].sheet.rules;let n="";return _.each(t,(function(e){n+=e.cssText})),n},generateBase64ImageSource:function(e){e||(e="svg");const t=r.selectAll(e).attr("version","1.1").attr("xmlns","http://www.w3.org/2000/svg").node().parentNode.innerHTML;return"data:image/svg+xml;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(t)))}},t.a=a},84:function(e,t){angular.module("graphdb.framework.rest.graphexplore.data.service",[]).factory("GraphDataRestService",n),n.$inject=["$http"];function n(e){return{getClassHierarchyData:function(t){return e.get("rest/class-hierarchy",{params:{graphURI:t}})},reloadClassHierarchy:function(t){return e.get("rest/class-hierarchy",{params:{doReload:!0,graphURI:t}})},getClassInstances:function(t){return e.get("rest/class-hierarchy/class-instances",{params:{targetUri:t}})},getDomainRangeData:function(t,n){return e.get("rest/domain-range",{params:{targetUri:t,collapsed:n}})},checkDomainRangeData:function(t){return e.head("rest/domain-range",{params:{targetUri:t}})},getRelationshipsData:function(t,n,r){return e.get("rest/dependencies/matrix",{params:{mode:n,classes:_.map(t,(function(e){return e.name})),graphURI:r}})},getRelationshipsClasses:function(t,n){return e.get("rest/dependencies/classes",{params:{mode:t,graphURI:n}})},getRelationshipsStatus:function(t){return e.get("rest/dependencies/status",{params:{graphURI:t}})},calculateRelationships:function(t){return e.get("rest/dependencies/update",{params:{graphURI:t}})},getPredicates:function(t,n,r){return e.get("rest/dependencies/predicates",{params:{from:t,to:n,mode:"all",graphURI:r}})},getInstanceNode:function(t){return e.get("rest/explore-graph/node",{params:{iri:t}})},getInstanceNodeLinks:function(t){return e.get("rest/explore-graph/links",{params:{iri:t}})},getRdfsLabelAndComment:function(t,n,r){const a=r||{};return e({url:"rest/explore/details",method:"GET",params:_.extend(a,{uri:t,languages:n}),headers:{Accept:"application/json"}})}}}}}]);
@@ -0,0 +1 @@
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[37],{110:function(t,e,r){"use strict";r.r(e);var a=r(302),n=r(301);r(10);function o(t,e,r,o,s,i,c,l,d,u,p,f,g){return{restrict:"AE",template:'<div id="domain-range"></div>',scope:{showPredicatesInfoPanel:"=",selectedPredicate:"=",collapseEdges:"="},link:function(u){const p=l((function(){!function(u){d3.selection.prototype.moveToFront=function(){return this.each((function(){d3.select(this.parentNode.appendChild(this))}))},d3.selection.prototype.moveToBack=function(){return this.each((function(){const t=this.parentNode.firstChild;t&&this.parentNode.insertBefore(this,t)}))};var p=d3.layout.force().size([1200,600]).charge(-900),h=p.drag().on("dragstart",(function(t){d3.select(this).classed("selected",t.selected=!0)})),y=d3.select("#domain-range").append("svg").attr("viewBox","0 0 1200 600").attr("preserveAspectRatio","xMidYMid meet").on("dblclick.zoom",null),x=y.append("defs");x.append("marker").attr({id:"arrow",viewBox:"0 -5 10 10",refX:10,refY:0,markerUnits:"strokeWidth",markerWidth:5,markerHeight:5,orient:"auto",fill:f}).append("path").attr({d:"M0,-5L10,0L0,5",class:"arrowHead"}),x.append("marker").attr({id:"collapsed-arrow",viewBox:"0 -5 10 10",refX:9,refY:0,markerUnits:"strokeWidth",markerWidth:4,markerHeight:4,orient:"auto",fill:f}).append("path").attr({d:"M0,-5L10,0L0,5",class:"arrowHead"}),x.append("marker").attr({id:"arrow-loop",viewBox:"0 -5 10 10",refX:7,refY:0,markerUnits:"strokeWidth",markerWidth:5,markerHeight:5,orient:"auto",fill:f}).append("path").attr({d:"M0,-5L10,0L0,5",class:"arrowHead"}),d3.select("#download-svg").on("mouseover",(function(){var t=a.a.Export.getCSSRules("css/domain-range-graph.css?v=2.4.2-TR2");$("defs").append('<style type="text/css"><![CDATA['+t+"]]></style>");var e=a.a.Export.generateBase64ImageSource("#domain-range svg");d3.select(this).attr({href:e,download:"domain-range-graph-"+r.getActiveRepository()+".svg"})}));var m=d3.select(".legend-container").append("svg").attr("viewBox","0 0 "+1200/7+" "+1200/7*1.2).attr("preserveAspectRatio","xMidYMid meet");m.append("rect").attr({width:1200/7,height:1200/7*1.2}).style("fill","rgba(235, 235, 235, 0.9)");var v=16+1200/18/2.5,k=v+1200/90;m.append("circle").attr({class:"legend-class-node",cx:(16+v)/2,cy:30,r:1200/18/4.5});m.append("text").attr({x:k,y:30+1200/370}).style("font-size",1200/90/1.1+"px").text("main class node");m.append("circle").attr({class:"legend-object-node",cx:(16+v)/2,cy:70,r:1200/110/1.25});m.append("text").attr({x:k,y:30+1200/370+40}).style("font-size",1200/90/1.1+"px").text("class node");m.append("circle").attr({class:"legend-datatype-node",cx:(16+v)/2,cy:70+1200/45,r:1200/110/2});m.append("text").attr({x:k,y:99.90990990990991}).style("font-size",1200/90/1.1+"px").text("datatype node");d3.select(".legend-class-node");m.append("line").attr({class:"property-arrow",x1:16,y1:123.33333333333334,x2:v,y2:123.33333333333334}).style("stroke-width",1.2).attr("marker-end","url("+s.absUrl()+"#arrow)"),m.append("text").attr({x:k,y:126.57657657657658}).style("font-size",1200/90/1.1+"px").text("explicit property");m.append("line").attr({class:"implicit-property-arrow",x1:16,y1:150,x2:v,y2:150}).style("stroke-width",1.2).attr("marker-end","url("+s.absUrl()+"#arrow)"),m.append("text").attr({x:k,y:150+1200/370}).style("font-size",1200/90/1.1+"px").text("implicit property");m.append("line").attr({class:"collapsed-property-arrow",x1:16,y1:150+1200/45,x2:v,y2:150+1200/45}).style("stroke-width",2).attr("marker-end","url("+s.absUrl()+"#collapsed-arrow)"),m.append("text").attr({x:k,y:179.9099099099099}).style("font-size",1200/90/1.1+"px").text("collapsed property");var b=y,w=s.search().uri,E=s.search().name,N=s.search().collapsed;o.getDomainRangeData(w,N).success((function(t,e,r){u.domainRangeGraphData=t})).error((function(t){d.error("Request for "+E+" failed!")})),$(window).on("popstate",(function(){i.set(c.DOMAIN_RANGE_WENT_BACK,!0)})),e.onpopstate=function(e){e.state&&t.$broadcast("changeCollapsedEdgesState",e.state.collapsed)},u.$watch("collapseEdges",(function(){angular.isUndefined(u.collapseEdges)||(i.set(c.DOMAIN_RANGE_COLLAPSE_EDGES,u.collapseEdges),"true"!==i.get(c.DOMAIN_RANGE_WENT_BACK)&&function(e){t.$broadcast("switchEdgeMode",{uri:w,name:E,collapsed:e})}(u.collapseEdges),i.remove(c.DOMAIN_RANGE_WENT_BACK))})),u.$watch("domainRangeGraphData",(function(){if(u.domainRangeGraphData){var r=angular.copy(u.domainRangeGraphData);p.nodes(r.nodes).links(r.links);var a=b.selectAll(".link").data(r.links).enter().append("g");function o(t){t.style("stroke",f),t.style("stroke-width",2),t.attr("marker-end","url("+s.absUrl()+"#collapsed-arrow)")}var i,c,d=0;a.each((function(t){if(t.objectPropNodeClassUri!==w)i=a.append("line").attr({class:"link","marker-end":"url("+s.absUrl()+"#arrow)"}).style("stroke-width",1.2).each((function(t){switch(t.propertyType){case"objectLeft":t.targetRadius=1200/18;break;case"objectRight":t.targetRadius=1200/110;break;case"datatype":t.targetRadius=1200/110/2;break;default:t.targetRadius=0}var e=d3.select(this);t.targetNodeEdgeCount>1?o(e):t.implicit&&e.style("stroke-dasharray","3, 3")}));else{if(angular.isUndefined(c)){c=d3.select(this).append("path").attr({d:"M 0 0 A "+1200/18/2+" "+1200/18/2+" 0 1 1 0 "+1200/18/2,class:"loop-link",fill:"none","marker-end":"url("+s.absUrl()+"#arrow-loop)"}).style("stroke-width",1.2)}(d+=t.targetNodeEdgeCount)>1&&o(d3.select(".loop-link"))}}));var y={};function x(){$.isEmptyObject(y)||(y.text.style("fill","black"),y.background.style("fill","#f0f0f0"))}function m(t){x(),y.text=d3.select(this),y.background=d3.select(this.previousSibling),y.text.style("fill","white"),y.background.style("fill",f),l((function(){u.showPredicatesInfoPanel=!0,u.selectedPredicate=t})),d3.event.stopPropagation()}$("document").ready((function(){$("#domain-range").bind("click",x)}));var v=a.append("text").attr("class",(function(t){return t.objectPropNodeClassUri===w?"loop-link-property-name":"property-name"})).attr("dx",(function(t){return 1200/18/2*("objectLeft"===t.propertyType?1:-1)})).style("text-anchor",(function(t){return"objectLeft"===t.propertyType?"end":"start"})).style("font-size",1200/90).text((function(t){return t.targetNodeEdgeCount>1?t.targetNodeEdgeCount+" predicates":t.name}));v.each((function(t){var r=d3.select(this);/\d\spredicates/.test(r.text())?r.style("font-weight","bold").on("click",m):r.on("click",(function(t){e.open("resource?uri="+encodeURIComponent(t.uri),"_blank")}))}));var k=a.append("rect").attr("class",(function(t){return t.objectPropNodeClassUri!==w?"link-background":"loop-link-background"})).attr("width",(function(t){return t.calculatedWidth=this.previousSibling.getBBox().width,t.calculatedWidth+4})).attr("height",(function(t){return t.calculatedHeight=this.previousSibling.getBBox().height,t.calculatedHeight+2})).attr("transform",(function(t){var e=2-1200/18/2*("objectLeft"===t.propertyType?1:-1);return"objectLeft"===t.propertyType&&(e+=t.calculatedWidth),"translate(-"+e+",-"+(2+t.calculatedHeight/2)+")"})).on("click",(function(t){d3.event.stopPropagation()})),N=b.selectAll(".node").data(r.nodes).enter().append("g"),R=N.filter((function(t){return t.objectPropClassUri!==w})).append("circle").each((function(t){var e=d3.select(this);"main"===t.classPosition?e.attr({class:"class-node",r:1200/18}).attr("marker-end","url("+s.absUrl()+"#loop-link)"):null===t.objectPropClassName?e.attr({class:"datatype-node",r:1200/110/2}):e.attr({class:"object-prop-node",r:1200/110})})).call(h);d3.selectAll(".object-prop-node").on("dblclick",(function(e,r){u.$apply((function(){t.$broadcast("reloadDomainRangeGraphView",e,r)}))})),N.filter((function(t){return t.objectPropClassName&&t.objectPropClassUri!==w})).append("text").attr("class",(function(t){return t.classPosition+"-class-label"})).style("font-size",1200/90).text((function(t){return t.objectPropClassName})).on("click",(function(t){e.open("resource?uri="+encodeURIComponent(t.objectPropClassUri),"_blank")}));var C=N.select("text");b.select(".class-node").each((function(){d3.select(this.parentNode).append("text").attr("class","rdf-class-label").style("font-size",(function(t){return n.a.Text.calcFontSize(E,1200/18)})).text(E).on("click",(function(t){e.open("resource?uri="+encodeURIComponent(w),"_blank")}))}));var T=b.select(".class-node + text"),A=d3.select(".class-node"),L=d3.selectAll(".loop-link-background"),_=d3.selectAll(".loop-link-property-name");if(v=d3.selectAll(".property-name"),!angular.isUndefined(c)){var M=[];L.each((function(t,e){d3.select(this);M.push({idx:e,width:t.calculatedWidth,height:t.calculatedHeight})}))}p.on("tick",(function(t){var e=8*t.alpha;function r(t){var e=t.x+1200/18*2,r=t.y-1200/18/1.9;var a=[];L.each((function(n,o){a.push(n),o<g?function(a,n){var o=$.grep(M,(function(t){return t.idx==n}));n>0&&(e+=parseFloat(n*(o[0].height/(n/1.4)))),a.attr({transform:"rotate(270, "+t.x+","+t.y+") translate("+e+","+r+")",width:o[0].height,height:o[0].width})}(d3.select(this),o):d3.select(this).remove()})),function(t){var e;d3.select(".view-more-preds-label").style("font-weight","bold").each((function(r){r.target.allEdges=t,e=this.getComputedTextLength()})).on("click",m),d3.select(".view-more-preds-rect").attr("height",e+4)}(a)}i.filter((function(t){return t.objectPropNodeClassUri!==w})).attr("x1",(function(t){return t.source.x})).attr("y1",(function(t){return t.source.y})).attr("x2",(function(t){return t.targetX})).attr("y2",(function(t){return t.targetY})).each((function(t){!function(t){"objectLeft"===t.propertyType?(t.source.x-=8*e,t.source.y-=e/9):(t.target.x+=8*e,t.target.y-=e/9)}(t);var r=Math.atan2(t.target.y-t.source.y,t.target.x-t.source.x);t.targetX=t.target.x-Math.cos(r)*t.targetRadius,t.targetY=t.target.y-Math.sin(r)*t.targetRadius})),R.each((function(t){"main"!==t.classPosition||angular.isUndefined(c)||(!function(t){var e=t.x+64,r=t.y-1200/18/5.7-5;c.attr("transform","rotate(270, "+t.x+","+t.y+") translate("+e+","+r+")")}(t),function(t){function e(e,r){var a=$.grep(M,(function(t){return t.idx==r})),n=0;r>0&&(n=parseFloat(2*r*(a[0].height/1.4)));var o=t.x,s=t.y-1200/18*2.1-n;e.attr({x:o,y:s}).moveToFront()}_.each((function(t,r){var a=d3.select(this),n=_.size()-g;n<0?e(a,r):(0==r&&!u.collapseEdges&&n>1&&(!function(t,e,r){t.classed("view-more-preds-label",!0).text(r+" predicates more ..."),null!==this.nextSibling&&e.classed("view-more-preds-rect",!0)}(a,d3.select(this.nextSibling),n),e(a,r)),r<g?e(a,r):a.remove())}))}(t),r(t)),t.objectPropClassUri!==w&&d3.select(this).attr("cx",(function(t){return"main"===t.classPosition?function(t){!window.ActiveXObject&&"ActiveXObject"in window&&(Math.log10=function(t){return Math.log(t)/Math.LN10});var e=A.attr("cx")-600,r=.5*Math.log10(Math.abs(e));return t.x+=e>0?-r:r,t.x}(t):t.x})).attr("cy",(function(t){return t.y}))})),T.attr("x",(function(t){return t.x})).attr("y",(function(t){return t.y})).moveToFront(),k.filter((function(t){return t.objectPropNodeClassUri!==w})).attr("x",(function(t){return t.target.x>t.source.x?t.source.x+(t.target.x-t.source.x)/2:t.target.x+(t.source.x-t.target.x)/2})).attr("y",(function(t){return t.target.y>t.source.y?t.source.y+(t.target.y-t.source.y)/2:t.target.y+(t.source.y-t.target.y)/2})).moveToFront(),v.attr("x",(function(t){return t.target.x>t.source.x?t.source.x+(t.target.x-t.source.x)/2:t.target.x+(t.source.x-t.target.x)/2})).attr("y",(function(t){return t.target.y>t.source.y?t.source.y+(t.target.y-t.source.y)/2:t.target.y+(t.source.y-t.target.y)/2})).moveToFront(),C.attr("x",(function(t){return"right"===t.classPosition?t.x+1200/110*1.2:t.x-1200/110*1.2})).attr("y",(function(t){return t.y})).moveToFront()})).linkDistance(1200/3.5).start()}}))}(u)}),50);u.$on("$destroy",(function(){l.cancel(p)}))}}}angular.module("graphdb.framework.graphexplore.directives.domainrange",["graphdb.framework.graphexplore.controllers.domainrange","graphdb.framework.utils.localstorageadapter"]).constant("ONTO_RED","var(--primary-color)").constant("ONTO_GREEN","var(--tertiary-color)").constant("ONTO_BLUE","var(--secondary-color)").constant("NON_COLLAPSED_REFLEXIVE_LINK_LIMIT",6).directive("domainRangeGraph",o),o.$inject=["$rootScope","$window","$repositories","GraphDataRestService","$location","LocalStorageAdapter","LSKeys","$timeout","toastr","ONTO_RED","ONTO_GREEN","ONTO_BLUE","NON_COLLAPSED_REFLEXIVE_LINK_LIMIT"]},301:function(t,e,r){"use strict";var a=a||{};a.Text=function(){function t(t,e,r,a){r=r||10;var n=e/3;return"string"==typeof t?(n*=10/(t.substring(0,e/3).length+1.5),n+=1,t.match(/[\u0900-\u0DFF\u1100-\u11FF\u2E80-\u2EFF\u3000-\u9FFF]/)&&(n*=.6),n<r&&(n=r),Math.round(n)):(n<r&&(n=r),Math.round(n))}return{calcFontSizeRaw:t,calcFontSize:function(e,r,a,n){return t(e,r,a)+"px"},getTextWithElipsisIfNeeded:function(t,e){return"string"==typeof t&&t.length>e?t.substring(0,e-3)+"...":t}}}(),a.Transition={fadeIn:function(t,e){t.style("opacity",0).transition().duration(e).style("opacity",1)},fadeOut:function(t,e){t.style("opacity",1).transition().duration(e).style("opacity",0)}},a.Click={delayDblClick:function(){var t=d3.dispatch("click","dblclick");return d3.rebind((function(e){var r,a=null;e.on("mousedown",(function(){r=d3.mouse(document.body),new Date})),e.on("mouseup",(function(e){var n,o;n=r,o=d3.mouse(document.body),Math.sqrt(Math.pow(n[0]-o[0],2),Math.pow(n[1]-o[1],2))>5||(a?(window.clearTimeout(a),a=null,t.dblclick(e)):a=window.setTimeout((d3.event,function(){t.click(e),a=null}),250))}))}),t,"on")}},e.a=a},302:function(t,e,r){"use strict";var a=r(297),n=n||{};n.Export={getCSSRules:function(t){const e=$('link[href="'+t+'"]')[0].sheet.rules;let r="";return _.each(e,(function(t){r+=t.cssText})),r},generateBase64ImageSource:function(t){t||(t="svg");const e=a.selectAll(t).attr("version","1.1").attr("xmlns","http://www.w3.org/2000/svg").node().parentNode.innerHTML;return"data:image/svg+xml;charset=utf-8;base64,"+btoa(unescape(encodeURIComponent(e)))}},e.a=n}}]);
@@ -1 +1 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[37,60,131],{57:function(t,a,e){"use strict";e.r(a),e.d(a,"ChartData",(function(){return r}));class r{static get DEFAULT_MULTIPLIER(){return 1.2}static get MAXIMUM_DIVISIONS(){return 10}static get COLORS(){return["#003663","#E84E0F","#02A99A","#999999"]}constructor(t,a,e,r){this.filter=r,this.initialChartSetup(t,a,e)}initialChartSetup(t,a,e,r=!0){this.disableRangeUpdate=a,this.disableOldDataRemoval=e,this.translateService=t,this.range=150,this.chartOptions=this.getDefaultChartOptions(t),this.chartSetup(this.chartOptions),r&&(this.dataHolder=this.createDataHolder(),this.firstLoad=!0)}refresh(){this.initialChartSetup(this.translateService,this.disableRangeUpdate,this.disableOldDataRemoval,!1),this.translateLabels(this.dataHolder),this.updateRange(this.dataHolder)}translateLabels(t){this.createDataHolder().forEach((a,e)=>{t[e].originalKey?t[e].originalKey=a.key:t[e].key=a.key})}setSubTitle(t){this.chartOptions.title.enable=!0;const a=t.map(t=>{if(Array.isArray(t.value)&&!t.value.length)return;const a=Array.isArray(t.value)?t.value.join("/"):t.value;return t.label+(void 0!==a?`<span class="data-value">${a}</span>`:"")});this.chartOptions.title.html=a.map(t=>`<span class="info-element">${t}</span>`)}chartSetup(t){}createDataHolder(){throw new Error("Must implement data holder creation")}addData(t,a){this.removeOldData(this.dataHolder,this.range),this.addNewData(this.dataHolder,t,a,this.isFirstLoad()),this.updateRange(this.dataHolder),this.firstLoad&&(this.firstLoad=!1)}removeOldData(t,a){this.disableOldDataRemoval||t[0].values.length>a&&t.forEach(t=>t.values.shift())}addNewData(t,a,e,r){}updateRange(t,a){if(this.disableRangeUpdate)return;const[e]=r.calculateMaxChartValueAndDivisions(t,a);this.chartOptions.chart.yDomain=[0,e]}isFirstLoad(){return this.firstLoad}getDefaultChartOptions(t){return{chart:{interpolate:"monotone",type:"lineChart",height:500,margin:{left:80,right:80},x:function(t){return t[0]},y:function(t){return t[1]},clipEdge:!0,noData:t.instant("resource.no_data"),showControls:!1,duration:0,rightAlignYAxis:!1,useInteractiveGuideline:!0,xAxis:{showMaxMin:!1,tickFormat:function(t){return d3.time.format("%X")(new Date(t))}},yAxis:{showMaxMin:!1,tickFormat:function(t){return t}},legend:{maxKeyLength:100},color:r.COLORS},title:{enable:!0,className:"chart-additional-info",html:" "}}}static getMaxValueFromDataHolder(t){return Math.max(...t.filter(t=>!t.disabled).flatMap(t=>r.getMaxValueForDataSeries(t)))}static getMaxValueForDataSeries(t){return Math.max(...t.values.map(t=>t[1]))}static calculateMaxChartValueAndDivisions(t,a){let e;e=Array.isArray(t)?r.getMaxValueFromDataHolder(t):r.getMaxValueForDataSeries(t);const s=Math.round(e*(a||r.DEFAULT_MULTIPLIER))||1;return[s,Math.ceil(s/r.MAXIMUM_DIVISIONS)]}static getIntegerRangeForValues(t,a){const[e,s]=r.calculateMaxChartValueAndDivisions(t,a);return d3.range(0,e+1,s)}static formatBytesValue(t,a){let e=t;a&&(e=Math.max(...a.filter(t=>!t.disabled).flatMap(t=>t.values).flatMap(t=>t[1])));const r=Math.floor(Math.log(e)/Math.log(1024));return`${(parseFloat(t)/Math.pow(1024,r)).toFixed(2)} ${["Bytes","KB","MB","GB","TB","PB","EB","ZB","YB"][r]}`}formatNumber(t){if(t&&this.filter)return this.filter("currency")(t,"",0)}}},59:function(t,a,e){"use strict";e.r(a),e.d(a,"HeapMemoryChart",(function(){return s}));var r=e(57);class s extends r.ChartData{constructor(t){super(t,!1,!1)}createDataHolder(){return[{key:this.translateService.instant("resource.memory.committed"),values:[]},{key:this.translateService.instant("resource.memory.used"),area:"true",values:[]}]}addNewData(t,a,e){const[r,s]=t,i=this.parseData(e);r.values.push([a,i.committed]),s.values.push([a,i.used]),this.setMaxHeapSize(i.max)}parseData(t){return t.heapMemoryUsage}setMaxHeapSize(t){if(t>0){const a=[{label:this.translateService.instant("resource.memory.heap.max"),value:s.formatBytesValue(t)}];this.setSubTitle(a)}}updateRange(t){this.setScale(t),super.updateRange(t)}setScale(t){this.chartOptions.chart.yAxis.tickFormat=a=>s.formatBytesValue(a,t)}}},68:function(t,a,e){"use strict";e.r(a),e.d(a,"NonHeapMemoryChart",(function(){return s}));var r=e(59);class s extends r.HeapMemoryChart{constructor(t){super(t,!1,!1)}parseData(t){return t.nonHeapMemoryUsage}}}}]);
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[38,61,131],{57:function(t,a,e){"use strict";e.r(a),e.d(a,"ChartData",(function(){return r}));class r{static get DEFAULT_MULTIPLIER(){return 1.2}static get MAXIMUM_DIVISIONS(){return 10}static get COLORS(){return["#003663","#E84E0F","#02A99A","#999999"]}constructor(t,a,e,r){this.filter=r,this.initialChartSetup(t,a,e)}initialChartSetup(t,a,e,r=!0){this.disableRangeUpdate=a,this.disableOldDataRemoval=e,this.translateService=t,this.range=150,this.chartOptions=this.getDefaultChartOptions(t),this.chartSetup(this.chartOptions),r&&(this.dataHolder=this.createDataHolder(),this.firstLoad=!0)}refresh(){this.initialChartSetup(this.translateService,this.disableRangeUpdate,this.disableOldDataRemoval,!1),this.translateLabels(this.dataHolder),this.updateRange(this.dataHolder)}translateLabels(t){this.createDataHolder().forEach((a,e)=>{t[e].originalKey?t[e].originalKey=a.key:t[e].key=a.key})}setSubTitle(t){this.chartOptions.title.enable=!0;const a=t.map(t=>{if(Array.isArray(t.value)&&!t.value.length)return;const a=Array.isArray(t.value)?t.value.join("/"):t.value;return t.label+(void 0!==a?`<span class="data-value">${a}</span>`:"")});this.chartOptions.title.html=a.map(t=>`<span class="info-element">${t}</span>`)}chartSetup(t){}createDataHolder(){throw new Error("Must implement data holder creation")}addData(t,a){this.removeOldData(this.dataHolder,this.range),this.addNewData(this.dataHolder,t,a,this.isFirstLoad()),this.updateRange(this.dataHolder),this.firstLoad&&(this.firstLoad=!1)}removeOldData(t,a){this.disableOldDataRemoval||t[0].values.length>a&&t.forEach(t=>t.values.shift())}addNewData(t,a,e,r){}updateRange(t,a){if(this.disableRangeUpdate)return;const[e]=r.calculateMaxChartValueAndDivisions(t,a);this.chartOptions.chart.yDomain=[0,e]}isFirstLoad(){return this.firstLoad}getDefaultChartOptions(t){return{chart:{interpolate:"monotone",type:"lineChart",height:500,margin:{left:80,right:80},x:function(t){return t[0]},y:function(t){return t[1]},clipEdge:!0,noData:t.instant("resource.no_data"),showControls:!1,duration:0,rightAlignYAxis:!1,useInteractiveGuideline:!0,xAxis:{showMaxMin:!1,tickFormat:function(t){return d3.time.format("%X")(new Date(t))}},yAxis:{showMaxMin:!1,tickFormat:function(t){return t}},legend:{maxKeyLength:100},color:r.COLORS},title:{enable:!0,className:"chart-additional-info",html:" "}}}static getMaxValueFromDataHolder(t){return Math.max(...t.filter(t=>!t.disabled).flatMap(t=>r.getMaxValueForDataSeries(t)))}static getMaxValueForDataSeries(t){return Math.max(...t.values.map(t=>t[1]))}static calculateMaxChartValueAndDivisions(t,a){let e;e=Array.isArray(t)?r.getMaxValueFromDataHolder(t):r.getMaxValueForDataSeries(t);const s=Math.round(e*(a||r.DEFAULT_MULTIPLIER))||1;return[s,Math.ceil(s/r.MAXIMUM_DIVISIONS)]}static getIntegerRangeForValues(t,a){const[e,s]=r.calculateMaxChartValueAndDivisions(t,a);return d3.range(0,e+1,s)}static formatBytesValue(t,a){let e=t;a&&(e=Math.max(...a.filter(t=>!t.disabled).flatMap(t=>t.values).flatMap(t=>t[1])));const r=Math.floor(Math.log(e)/Math.log(1024));return`${(parseFloat(t)/Math.pow(1024,r)).toFixed(2)} ${["Bytes","KB","MB","GB","TB","PB","EB","ZB","YB"][r]}`}formatNumber(t){if(t&&this.filter)return this.filter("currency")(t,"",0)}}},59:function(t,a,e){"use strict";e.r(a),e.d(a,"HeapMemoryChart",(function(){return s}));var r=e(57);class s extends r.ChartData{constructor(t){super(t,!1,!1)}createDataHolder(){return[{key:this.translateService.instant("resource.memory.committed"),values:[]},{key:this.translateService.instant("resource.memory.used"),area:"true",values:[]}]}addNewData(t,a,e){const[r,s]=t,i=this.parseData(e);r.values.push([a,i.committed]),s.values.push([a,i.used]),this.setMaxHeapSize(i.max)}parseData(t){return t.heapMemoryUsage}setMaxHeapSize(t){if(t>0){const a=[{label:this.translateService.instant("resource.memory.heap.max"),value:s.formatBytesValue(t)}];this.setSubTitle(a)}}updateRange(t){this.setScale(t),super.updateRange(t)}setScale(t){this.chartOptions.chart.yAxis.tickFormat=a=>s.formatBytesValue(a,t)}}},69:function(t,a,e){"use strict";e.r(a),e.d(a,"NonHeapMemoryChart",(function(){return s}));var r=e(59);class s extends r.HeapMemoryChart{constructor(t){super(t,!1,!1)}parseData(t){return t.nonHeapMemoryUsage}}}}]);
@@ -1,2 +1,2 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[38],{192:function(e,t,n){"use strict";n.r(t);n(6),n(23),n(135),n(24),n(307);angular.module("graphdb.framework.security",["toastr","ui.bootstrap","ngRoute","graphdb.framework.security.controllers","graphdb.framework.core.interceptors.unauthorized","graphdb.framework.core.interceptors.authentication","graphdb.framework.core.services.jwtauth"])},307:function(e,t){
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[39],{192:function(e,t,n){"use strict";n.r(t);n(7),n(23),n(135),n(24),n(307);angular.module("graphdb.framework.security",["toastr","ui.bootstrap","ngRoute","graphdb.framework.security.controllers","graphdb.framework.core.interceptors.unauthorized","graphdb.framework.core.interceptors.authentication","graphdb.framework.core.services.jwtauth"])},307:function(e,t){
2
2
  /*! ngTagsInput v3.2.0 License: MIT */!function(){"use strict";var e=8,t=9,n=13,i=27,a=32,r=38,o=40,s=37,u=39,l=46,c=188,g=9007199254740991,d=["text","email","url"],p=angular.module("ngTagsInput",[]);p.directive("tagsInput",["$timeout","$document","$window","$q","tagsInputConfig","tiUtil",function(t,i,r,o,p,f){function m(e,t,n,i){var a,r,s,u,l={};return a=function(t){return f.safeToString(t[e.displayProperty])},r=function(t,n){t[e.displayProperty]=n},s=function(t){var i=a(t),r=i&&i.length>=e.minLength&&i.length<=e.maxLength&&e.allowedTagsPattern.test(i)&&!f.findInObjectArray(l.items,t,e.keyProperty||e.displayProperty);return o.when(r&&n({$tag:t})).then(f.promisifyValue)},u=function(e){return o.when(i({$tag:e})).then(f.promisifyValue)},l.items=[],l.addText=function(e){var t={};return r(t,e),l.add(t)},l.add=function(n){var i=a(n);return e.replaceSpacesWithDashes&&(i=f.replaceSpacesWithDashes(i)),r(n,i),s(n).then((function(){l.items.push(n),t.trigger("tag-added",{$tag:n})})).catch((function(){i&&t.trigger("invalid-tag",{$tag:n})}))},l.remove=function(e){var n=l.items[e];return u(n).then((function(){return l.items.splice(e,1),l.clearSelection(),t.trigger("tag-removed",{$tag:n}),n}))},l.select=function(e){0>e?e=l.items.length-1:e>=l.items.length&&(e=0),l.index=e,l.selected=l.items[e]},l.selectPrior=function(){l.select(--l.index)},l.selectNext=function(){l.select(++l.index)},l.removeSelected=function(){return l.remove(l.index)},l.clearSelection=function(){l.selected=null,l.index=-1},l.getItems=function(){return e.useStrings?l.items.map(a):l.items},l.clearSelection(),l}function h(e){return-1!==d.indexOf(e)}return{restrict:"E",require:"ngModel",scope:{tags:"=ngModel",text:"=?",templateScope:"=?",tagClass:"&",onTagAdding:"&",onTagAdded:"&",onInvalidTag:"&",onTagRemoving:"&",onTagRemoved:"&",onTagClicked:"&"},replace:!1,transclude:!0,templateUrl:"ngTagsInput/tags-input.html",controller:["$scope","$attrs","$element",function(e,t,n){e.events=f.simplePubSub(),p.load("tagsInput",e,t,{template:[String,"ngTagsInput/tag-item.html"],type:[String,"text",h],placeholder:[String,"Add a tag"],tabindex:[Number,null],removeTagSymbol:[String,String.fromCharCode(215)],replaceSpacesWithDashes:[Boolean,!0],minLength:[Number,3],maxLength:[Number,g],addOnEnter:[Boolean,!0],addOnSpace:[Boolean,!1],addOnComma:[Boolean,!0],addOnBlur:[Boolean,!0],addOnPaste:[Boolean,!1],pasteSplitPattern:[RegExp,/,/],allowedTagsPattern:[RegExp,/.+/],enableEditingLastTag:[Boolean,!1],minTags:[Number,0],maxTags:[Number,g],displayProperty:[String,"text"],keyProperty:[String,""],allowLeftoverText:[Boolean,!1],addFromAutocompleteOnly:[Boolean,!1],spellcheck:[Boolean,!0],useStrings:[Boolean,!1]}),e.tagList=new m(e.options,e.events,f.handleUndefinedResult(e.onTagAdding,!0),f.handleUndefinedResult(e.onTagRemoving,!0)),this.registerAutocomplete=function(){return n.find("input"),{addTag:function(t){return e.tagList.add(t)},getTags:function(){return e.tagList.items},getCurrentTagText:function(){return e.newTag.text()},getOptions:function(){return e.options},getTemplateScope:function(){return e.templateScope},on:function(t,n){return e.events.on(t,n,!0),this}}},this.registerTagItem=function(){return{getOptions:function(){return e.options},removeTag:function(t){e.disabled||e.tagList.remove(t)}}}}],link:function(o,g,d,p){var m,h,v=[n,c,a,e,l,s,u],T=o.tagList,y=o.events,$=o.options,x=g.find("input"),b=["minTags","maxTags","allowLeftoverText"];m=function(){p.$setValidity("maxTags",T.items.length<=$.maxTags),p.$setValidity("minTags",T.items.length>=$.minTags),p.$setValidity("leftoverText",!(!o.hasFocus&&!$.allowLeftoverText)||!o.newTag.text())},h=function(){t((function(){x[0].focus()}))},p.$isEmpty=function(e){return!e||!e.length},o.newTag={text:function(e){return angular.isDefined(e)?(o.text=e,void y.trigger("input-change",e)):o.text||""},invalid:null},o.track=function(e){return e[$.keyProperty||$.displayProperty]},o.getTagClass=function(e,t){var n=e===T.selected;return[o.tagClass({$tag:e,$index:t,$selected:n}),{selected:n}]},o.$watch("tags",(function(e){if(e){if(T.items=f.makeObjectArray(e,$.displayProperty),$.useStrings)return;o.tags=T.items}else T.items=[]})),o.$watch("tags.length",(function(){m(),p.$validate()})),d.$observe("disabled",(function(e){o.disabled=e})),o.eventHandlers={input:{keydown:function(e){y.trigger("input-keydown",e)},focus:function(){o.hasFocus||(o.hasFocus=!0,y.trigger("input-focus"))},blur:function(){t((function(){var e=i.prop("activeElement"),t=e===x[0],n=g[0].contains(e);(t||!n)&&(o.hasFocus=!1,y.trigger("input-blur"))}))},paste:function(e){e.getTextData=function(){var t=e.clipboardData||e.originalEvent&&e.originalEvent.clipboardData;return t?t.getData("text/plain"):r.clipboardData.getData("Text")},y.trigger("input-paste",e)}},host:{click:function(){o.disabled||h()}},tag:{click:function(e){y.trigger("tag-clicked",{$tag:e})}}},y.on("tag-added",o.onTagAdded).on("invalid-tag",o.onInvalidTag).on("tag-removed",o.onTagRemoved).on("tag-clicked",o.onTagClicked).on("tag-added",(function(){o.newTag.text("")})).on("tag-added tag-removed",(function(){o.tags=T.getItems(),p.$setDirty(),h()})).on("invalid-tag",(function(){o.newTag.invalid=!0})).on("option-change",(function(e){-1!==b.indexOf(e.name)&&m()})).on("input-change",(function(){T.clearSelection(),o.newTag.invalid=null})).on("input-focus",(function(){g.triggerHandler("focus"),p.$setValidity("leftoverText",!0)})).on("input-blur",(function(){$.addOnBlur&&!$.addFromAutocompleteOnly&&T.addText(o.newTag.text()),g.triggerHandler("blur"),m()})).on("input-keydown",(function(t){var i,r,g,d,p=t.keyCode,m={};f.isModifierOn(t)||-1===v.indexOf(p)||(m[n]=$.addOnEnter,m[c]=$.addOnComma,m[a]=$.addOnSpace,i=!$.addFromAutocompleteOnly&&m[p],r=(p===e||p===l)&&T.selected,d=p===e&&0===o.newTag.text().length&&$.enableEditingLastTag,g=(p===e||p===s||p===u)&&0===o.newTag.text().length&&!$.enableEditingLastTag,i?T.addText(o.newTag.text()):d?(T.selectPrior(),T.removeSelected().then((function(e){e&&o.newTag.text(e[$.displayProperty])}))):r?T.removeSelected():g&&(p===s||p===e?T.selectPrior():p===u&&T.selectNext()),(i||g||r||d)&&t.preventDefault())})).on("input-paste",(function(e){if($.addOnPaste){var t=e.getTextData().split($.pasteSplitPattern);t.length>1&&(t.forEach((function(e){T.addText(e)})),e.preventDefault())}}))}}}]),p.directive("tiTagItem",["tiUtil",function(e){return{restrict:"E",require:"^tagsInput",template:'<ng-include src="$$template"></ng-include>',scope:{$scope:"=scope",data:"="},link:function(t,n,i,a){var r=a.registerTagItem(),o=r.getOptions();t.$$template=o.template,t.$$removeTagSymbol=o.removeTagSymbol,t.$getDisplayText=function(){return e.safeToString(t.data[o.displayProperty])},t.$removeTag=function(){r.removeTag(t.$index)},t.$watch("$parent.$index",(function(e){t.$index=e}))}}}]),p.directive("autoComplete",["$document","$timeout","$sce","$q","tagsInputConfig","tiUtil",function(e,a,s,u,l,c){function g(e,t,n){var i,a,r,o={};return r=function(){return t.tagsInput.keyProperty||t.tagsInput.displayProperty},i=function(e,n){return e.filter((function(e){return!c.findInObjectArray(n,e,r(),(function(e,n){return t.tagsInput.replaceSpacesWithDashes&&(e=c.replaceSpacesWithDashes(e),n=c.replaceSpacesWithDashes(n)),c.defaultComparer(e,n)}))}))},o.reset=function(){a=null,o.items=[],o.visible=!1,o.index=-1,o.selected=null,o.query=null},o.show=function(){t.selectFirstMatch?o.select(0):o.selected=null,o.visible=!0},o.load=c.debounce((function(n,s){o.query=n;var l=u.when(e({$query:n}));a=l,l.then((function(e){l===a&&(e=c.makeObjectArray(e.data||e,r()),e=i(e,s),o.items=e.slice(0,t.maxResultsToShow),o.items.length>0?o.show():o.reset())}))}),t.debounceDelay),o.selectNext=function(){o.select(++o.index)},o.selectPrior=function(){o.select(--o.index)},o.select=function(e){0>e?e=o.items.length-1:e>=o.items.length&&(e=0),o.index=e,o.selected=o.items[e],n.trigger("suggestion-selected",e)},o.reset(),o}return{restrict:"E",require:"^tagsInput",scope:{source:"&",matchClass:"&"},templateUrl:"ngTagsInput/auto-complete.html",controller:["$scope","$element","$attrs",function(e,t,n){e.events=c.simplePubSub(),l.load("autoComplete",e,n,{template:[String,"ngTagsInput/auto-complete-match.html"],debounceDelay:[Number,100],minLength:[Number,3],highlightMatchedText:[Boolean,!0],maxResultsToShow:[Number,10],loadOnDownArrow:[Boolean,!1],loadOnEmpty:[Boolean,!1],loadOnFocus:[Boolean,!1],selectFirstMatch:[Boolean,!0],displayProperty:[String,""]}),e.suggestionList=new g(e.source,e.options,e.events),this.registerAutocompleteMatch=function(){return{getOptions:function(){return e.options},getQuery:function(){return e.suggestionList.query}}}}],link:function(e,a,s,u){var l,g=[n,t,i,r,o],d=e.suggestionList,p=u.registerAutocomplete(),f=e.options,m=e.events;f.tagsInput=p.getOptions(),l=function(e){return e&&e.length>=f.minLength||!e&&f.loadOnEmpty},e.templateScope=p.getTemplateScope(),e.addSuggestionByIndex=function(t){d.select(t),e.addSuggestion()},e.addSuggestion=function(){var e=!1;return d.selected&&(p.addTag(angular.copy(d.selected)),d.reset(),e=!0),e},e.track=function(e){return e[f.tagsInput.keyProperty||f.tagsInput.displayProperty]},e.getSuggestionClass=function(t,n){var i=t===d.selected;return[e.matchClass({$match:t,$index:n,$selected:i}),{selected:i}]},p.on("tag-added tag-removed invalid-tag input-blur",(function(){d.reset()})).on("input-change",(function(e){l(e)?d.load(e,p.getTags()):d.reset()})).on("input-focus",(function(){var e=p.getCurrentTagText();f.loadOnFocus&&l(e)&&d.load(e,p.getTags())})).on("input-keydown",(function(a){var s=a.keyCode,u=!1;if(!c.isModifierOn(a)&&-1!==g.indexOf(s))return d.visible?s===o?(d.selectNext(),u=!0):s===r?(d.selectPrior(),u=!0):s===i?(d.reset(),u=!0):(s===n||s===t)&&(u=e.addSuggestion()):s===o&&e.options.loadOnDownArrow&&(d.load(p.getCurrentTagText(),p.getTags()),u=!0),u?(a.preventDefault(),a.stopImmediatePropagation(),!1):void 0})),m.on("suggestion-selected",(function(e){!function(e,t){var n=e.find("li").eq(t),i=n.parent(),a=n.prop("offsetTop"),r=n.prop("offsetHeight"),o=i.prop("clientHeight"),s=i.prop("scrollTop");s>a?i.prop("scrollTop",a):a+r>o+s&&i.prop("scrollTop",a+r-o)}(a,e)}))}}}]),p.directive("tiAutocompleteMatch",["$sce","tiUtil",function(e,t){return{restrict:"E",require:"^autoComplete",template:'<ng-include src="$$template"></ng-include>',scope:{$scope:"=scope",data:"="},link:function(n,i,a,r){var o=r.registerAutocompleteMatch(),s=o.getOptions();n.$$template=s.template,n.$index=n.$parent.$index,n.$highlight=function(n){return s.highlightMatchedText&&(n=t.safeHighlight(n,o.getQuery())),e.trustAsHtml(n)},n.$getDisplayText=function(){return t.safeToString(n.data[s.displayProperty||s.tagsInput.displayProperty])}}}}]),p.directive("tiTranscludeAppend",(function(){return function(e,t,n,i,a){a((function(e){t.append(e)}))}})),p.directive("tiAutosize",["tagsInputConfig",function(e){return{restrict:"A",require:"ngModel",link:function(t,n,i,a){var r,o,s=e.getTextAutosizeThreshold();(r=angular.element('<span class="input"></span>')).css("display","none").css("visibility","hidden").css("width","auto").css("white-space","pre"),n.parent().append(r),o=function(e){var t,a=e;return angular.isString(a)&&0===a.length&&(a=i.placeholder),a&&(r.text(a),r.css("display",""),t=r.prop("offsetWidth"),r.css("display","none")),n.css("width",t?t+s+"px":""),e},a.$parsers.unshift(o),a.$formatters.unshift(o),i.$observe("placeholder",(function(e){a.$modelValue||o(e)}))}}}]),p.directive("tiBindAttrs",(function(){return function(e,t,n){e.$watch(n.tiBindAttrs,(function(e){angular.forEach(e,(function(e,t){n.$set(t,e)}))}),!0)}})),p.provider("tagsInputConfig",(function(){var e={},t={},n=3;this.setDefaults=function(t,n){return e[t]=n,this},this.setActiveInterpolation=function(e,n){return t[e]=n,this},this.setTextAutosizeThreshold=function(e){return n=e,this},this.$get=["$interpolate",function(i){var a={};return a[String]=function(e){return e},a[Number]=function(e){return parseInt(e,10)},a[Boolean]=function(e){return"true"===e.toLowerCase()},a[RegExp]=function(e){return new RegExp(e)},{load:function(n,r,o,s){var u=function(){return!0};r.options={},angular.forEach(s,(function(s,l){var c,g,d,p,f,m;c=s[0],g=s[1],d=s[2]||u,p=a[c],f=function(){var t=e[n]&&e[n][l];return angular.isDefined(t)?t:g},m=function(e){r.options[l]=e&&d(e)?p(e):f()},t[n]&&t[n][l]?o.$observe(l,(function(e){m(e),r.events.trigger("option-change",{name:l,newValue:e})})):m(o[l]&&i(o[l])(r.$parent))}))},getTextAutosizeThreshold:function(){return n}}}]})),p.factory("tiUtil",["$timeout","$q",function(e,t){var n={debounce:function(t,n){var i;return function(){var a=arguments;e.cancel(i),i=e((function(){t.apply(null,a)}),n)}},makeObjectArray:function(e,t){if(!angular.isArray(e)||0===e.length||angular.isObject(e[0]))return e;var n=[];return e.forEach((function(e){var i={};i[t]=e,n.push(i)})),n},findInObjectArray:function(e,t,i,a){var r=null;return a=a||n.defaultComparer,e.some((function(e){return a(e[i],t[i])?(r=e,!0):void 0})),r},defaultComparer:function(e,t){return n.safeToString(e).toLowerCase()===n.safeToString(t).toLowerCase()},safeHighlight:function(e,t){if(e=n.encodeHTML(e),!(t=n.encodeHTML(t)))return e;var i=new RegExp("&[^;]+;|"+function(e){return e.replace(/([.?*+^$[\]\\(){}|-])/g,"\\$1")}(t),"gi");return e.replace(i,(function(e){return e.toLowerCase()===t.toLowerCase()?"<em>"+e+"</em>":e}))},safeToString:function(e){return angular.isUndefined(e)||null==e?"":e.toString().trim()},encodeHTML:function(e){return n.safeToString(e).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;")},handleUndefinedResult:function(e,t){return function(){var n=e.apply(null,arguments);return angular.isUndefined(n)?t:n}},replaceSpacesWithDashes:function(e){return n.safeToString(e).replace(/\s/g,"-")},isModifierOn:function(e){return e.shiftKey||e.ctrlKey||e.altKey||e.metaKey},promisifyValue:function(e){return e=!!angular.isUndefined(e)||e,t[e?"when":"reject"]()},simplePubSub:function(){var e={};return{on:function(t,n,i){return t.split(" ").forEach((function(t){e[t]||(e[t]=[]),(i?[].unshift:[].push).call(e[t],n)})),this},trigger:function(t,i){return(e[t]||[]).every((function(e){return n.handleUndefinedResult(e,!0)(i)})),this}}}};return n}]),p.run(["$templateCache",function(e){e.put("ngTagsInput/tags-input.html",'<div class="host" tabindex="-1" ng-click="eventHandlers.host.click()" ti-transclude-append><div class="tags" ng-class="{focused: hasFocus}"><ul class="tag-list"><li class="tag-item" ng-repeat="tag in tagList.items track by track(tag)" ng-class="getTagClass(tag, $index)" ng-click="eventHandlers.tag.click(tag)"><ti-tag-item scope="templateScope" data="::tag"></ti-tag-item></li></ul><input class="input" autocomplete="off" ng-model="newTag.text" ng-model-options="{getterSetter: true}" ng-keydown="eventHandlers.input.keydown($event)" ng-focus="eventHandlers.input.focus($event)" ng-blur="eventHandlers.input.blur($event)" ng-paste="eventHandlers.input.paste($event)" ng-trim="false" ng-class="{\'invalid-tag\': newTag.invalid}" ng-disabled="disabled" ti-bind-attrs="{type: options.type, placeholder: options.placeholder, tabindex: options.tabindex, spellcheck: options.spellcheck}" ti-autosize></div></div>'),e.put("ngTagsInput/tag-item.html",'<span ng-bind="$getDisplayText()"></span> <a class="remove-button" ng-click="$removeTag()" ng-bind="::$$removeTagSymbol"></a>'),e.put("ngTagsInput/auto-complete.html",'<div class="autocomplete" ng-if="suggestionList.visible"><ul class="suggestion-list"><li class="suggestion-item" ng-repeat="item in suggestionList.items track by track(item)" ng-class="getSuggestionClass(item, $index)" ng-click="addSuggestionByIndex($index)" ng-mouseenter="suggestionList.select($index)"><ti-autocomplete-match scope="templateScope" data="::item"></ti-autocomplete-match></li></ul></div>'),e.put("ngTagsInput/auto-complete-match.html",'<span ng-bind-html="$highlight($getDisplayText())"></span>')}])}()}}]);
@@ -1 +1 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[4,133],{60:function(e,t){angular.module("graphdb.framework.rest.cluster.service",[]).factory("ClusterRestService",n),n.$inject=["$http"];function n(e){return{getClusterConfig:function(){return e.get("rest/cluster/config")},createCluster:function(t){return e.post("rest/cluster/config",t)},updateCluster:function(t){t.nodes&&delete t.nodes;return e.patch("rest/cluster/config",t)},deleteCluster:function(t){const n=$.param({force:t});return e.delete("rest/cluster/config?"+n)},addNodesToCluster:function(t){return e.post("rest/cluster/config/node",{nodes:t})},removeNodesFromCluster:function(t){return e.delete("rest/cluster/config/node",{data:{nodes:t},headers:{"Content-Type":"application/json"}})},getClusterStatus:function(){return e.get("rest/cluster/group/status")},getNodeStatus:function(){return e.get("rest/cluster/node/status")}}}},77:function(e,t,n){"use strict";n.r(t),n.d(t,"NodeState",(function(){return r})),n.d(t,"RecoveryState",(function(){return s})),n.d(t,"LinkState",(function(){return a}));n(6),n(60);var o=n(84);angular.module("graphdb.framework.clustermanagement.controllers",["ui.bootstrap","graphdb.framework.core.services.repositories","graphdb.framework.rest.repositories.service","graphdb.framework.rest.cluster.service","toastr","pageslide-directive"]).controller("ClusterManagementCtrl",l).controller("CreateClusterCtrl",i).controller("DeleteClusterCtrl",u).controller("EditClusterCtrl",f).controller("AddLocationFromClusterCtrl",g).controller("AddNodesDialogCtrl",p).controller("RemoveNodesDialogCtrl",C).factory("RemoteLocationsService",d);const r={LEADER:"LEADER",FOLLOWER:"FOLLOWER",CANDIDATE:"CANDIDATE",OUT_OF_SYNC:"OUT_OF_SYNC",NO_CONNECTION:"NO_CONNECTION",READ_ONLY:"READ_ONLY",RESTRICTED:"RESTRICTED",NO_CLUSTER:"NO_CLUSTER"},s={SEARCHING_FOR_NODE:"SEARCHING_FOR_NODE",WAITING_FOR_SNAPSHOT:"WAITING_FOR_SNAPSHOT",RECEIVING_SNAPSHOT:"RECEIVING_SNAPSHOT",APPLYING_SNAPSHOT:"APPLYING_SNAPSHOT",BUILDING_SNAPSHOT:"BUILDING_SNAPSHOT",SENDING_SNAPSHOT:"SENDING_SNAPSHOT"},a={IN_SYNC:"IN_SYNC",OUT_OF_SYNC:"OUT_OF_SYNC",SYNCING:"SYNCING",NO_CONNECTION:"NO_CONNECTION"};function l(e,t,n,s,l,c,i,u,d,g,f,m,p,C,h,N,_){e.loader=!0,e.isLeader=!1,e.currentNode=null,e.clusterModel={},e.NodeState=r,e.leaderChanged=!1,e.currentLeader=null,e.isAdmin=function(){return u.isAuthenticated()&&u.isAdmin()},e.childContext={},e.shouldShowClusterSettingsPanel=!1;let L;function S(t){L||(L=e.getClusterStatus().then(()=>{if(t||!e.clusterConfiguration)return e.getClusterConfiguration()}).then(()=>{if(!e.currentNode||e.leaderChanged)return e.getCurrentNodeStatus()}).finally(()=>{L=null,e.childContext.redraw()}))}function $(){return N.getLocationsWithRpcAddresses().then(t=>{const n=t.find(e=>e.isLocal);n&&(n.endpoint=e.currentNode.endpoint,n.rpcAddress=e.currentNode.address),e.clusterModel.locations=t})}function v(t){s.success(t),e.getClusterConfiguration()}function O(e,t,n){let r=e.message||e;400===t&&Array.isArray(e)?r=e.reduce((e,t)=>e+`<div>${t}</div>`,""):412!==t||Object(o.isString)(e)||(r=Object.keys(e).reduce((t,n)=>t+`<div>${n} - ${e[n]}</div>`,"")),s.error(r,n,{allowHtml:!0})}e.onopen=e.onclose=()=>angular.noop(),e.toggleSidePanel=()=>{e.shouldShowClusterSettingsPanel=!e.shouldShowClusterSettingsPanel},e.toggleLegend=()=>{e.childContext.toggleLegend&&e.childContext.toggleLegend()},e.setLoader=function(t,n){m.cancel(e.loaderTimeout),t?(e.loaderMessage=n,e.loaderTimeout=m((function(){e.loader=t}),50)):e.loader=!1},e.childContext.selectNode=function(t){e.selectedNode!==t?e.selectedNode=t:e.selectedNode=null,e.$apply()},e.getLoaderMessage=function(){return e.loaderMessage||h.instant("common.loading")},e.getClusterConfiguration=()=>p.getClusterConfig().then(t=>{if(e.clusterConfiguration=t.data,!e.currentNode)return e.getCurrentNodeStatus()}).catch(()=>{e.clusterConfiguration=null}),e.getClusterStatus=function(){return p.getClusterStatus().then((function(t){const n=t.data.slice(),o=n.find(e=>e.nodeState===r.LEADER);var s,l;s=e.currentLeader,(l=o)&&s&&s.address===l.address||(e.currentLeader=o,e.leaderChanged=!0),e.currentNode=n.find(t=>t.address===e.currentNode.address);const c=[];o&&Object.keys(o.syncStatus).forEach(e=>{const t=o.syncStatus[e];t!==a.NO_CONNECTION&&c.push({id:`${o.address}-${e}`,source:o.address,target:e,status:t})}),e.clusterModel.hasCluster=!0,e.clusterModel.nodes=n,e.clusterModel.links=c})).catch((function(t){404===t.status&&(e.clusterModel.hasCluster=!1,e.clusterModel.nodes=[],e.clusterModel.links=[],e.clusterConfiguration=null)}))},e.showCreateClusterDialog=function(){c.open({templateUrl:"js/angular/clustermanagement/templates/modal/cluster-create-dialog.html",controller:"CreateClusterCtrl",size:"lg",resolve:{data:function(){return{clusterModel:e.clusterModel}}}}).result.finally((function(){$(),S(!0)}))},e.showDeleteDialog=()=>{c.open({templateUrl:"js/angular/clustermanagement/templates/modal/cluster-delete-dialog.html",controller:"DeleteClusterCtrl"}).result.then((function(t){const n=h.instant("cluster_management.delete_cluster_dialog.loader_message");e.setLoader(!0,n),p.deleteCluster(t).then(t=>{if(Object.values(t.data).every(e=>"Cluster was deleted on this node."===e)){const e=h.instant("cluster_management.delete_cluster_dialog.notifications.success_delete");s.success(e)}else{const e=h.instant("cluster_management.delete_cluster_dialog.notifications.success_delete_partial"),n=Object.keys(t.data).reduce((e,n)=>e+`<div>${n} - ${t.data[n]}</div>`,"");s.warning(n,e,{allowHtml:!0})}e.getClusterConfiguration()}).catch(e=>{const t=h.instant("cluster_management.delete_cluster_dialog.notifications.fail_delete");O(e.data,e.status,t)}).finally(()=>{e.setLoader(!1),S(!0),_.$broadcast("reloadLocations")})}))},e.showEditConfigurationDialog=()=>{c.open({templateUrl:"js/angular/clustermanagement/templates/modal/cluster-edit-dialog.html",controller:"EditClusterCtrl",size:"lg",resolve:{data:function(){return{clusterConfiguration:e.clusterConfiguration}}}}).result.finally((function(){S(!0)}))},e.getCurrentNodeStatus=()=>p.getNodeStatus().then(t=>{e.leaderChanged=!1,e.currentNode=t.data}).catch(t=>{e.currentNode=t.data,e.clusterModel.hasCluster=!1}).then(()=>$()),e.showAddNodeToClusterDialog=()=>{c.open({templateUrl:"js/angular/clustermanagement/templates/modal/add-nodes-dialog.html",controller:"AddNodesDialogCtrl",size:"lg",resolve:{data:function(){return{clusterModel:e.clusterModel,clusterConfiguration:e.clusterConfiguration}}}}).result.then((function(t){const n=h.instant("cluster_management.cluster_page.add_nodes_loader");e.setLoader(!0,n);const o=t.map(e=>e.rpcAddress);p.addNodesToCluster(o).then(()=>{v(h.instant("cluster_management.cluster_page.notifications.add_nodes_success"))}).catch(e=>{const t=h.instant("cluster_management.cluster_page.notifications.add_nodes_fail");O(e.data,e.status,t)}).finally(()=>{e.setLoader(!1),S(!0)})})).finally(()=>$())},e.showRemoveNodesFromClusterDialog=()=>{c.open({templateUrl:"js/angular/clustermanagement/templates/modal/remove-nodes-dialog.html",controller:"RemoveNodesDialogCtrl",size:"lg",resolve:{data:function(){return{clusterModel:e.clusterModel}}}}).result.then((function(t){const n=h.instant("cluster_management.cluster_page.remove_nodes_loader");e.setLoader(!0,n);const o=t.map(e=>e.address);p.removeNodesFromCluster(o).then(()=>{v(h.instant("cluster_management.cluster_page.notifications.remove_nodes_success"))}).catch(e=>{const t=h.instant("cluster_management.cluster_page.notifications.remove_nodes_fail");O(e.data,e.status,t)}).finally(()=>{e.setLoader(!1),S(!0)})}))},(e.loader=!0,e.getCurrentNodeStatus().then(()=>e.getClusterConfiguration()).then(()=>e.getClusterStatus()).finally(()=>{e.setLoader(!1)})).finally(()=>{const t=g((function(){S()}),1e3);e.$on("$destroy",(function(){g.cancel(t)}))});const T=angular.element(d),A=function(){e.childContext.resize()};T.bind("resize",A);const E=function(t){const n=t.target,o=document.getElementById("nodeTooltip");e.selectedNode&&o!==n&&!o.contains(n)&&e.childContext.selectNode(null)};T.bind("mousedown",E),e.$on("$destroy",(function(){T.unbind("resize",A),T.unbind("mousedown",E)}))}l.$inject=["$scope","$http","$q","toastr","$repositories","$uibModal","$sce","$jwtAuth","$window","$interval","ModalService","$timeout","ClusterRestService","$location","$translate","RemoteLocationsService","$rootScope"];const c=function(){const e=document.getElementById("advancedOptions");if(e){const t=e.getAttribute("aria-expanded");if(t&&"true"===t)return"fa fa-angle-down"}return"fa fa-angle-right"};function i(e,t,n,o,r,s,a,l,i,u){e.pageTitle=s.instant("cluster_management.cluster_page.create_page_title"),e.autofocusId="autofocus",e.errors=[],e.clusterConfiguration={electionMinTimeout:8e3,electionRangeTimeout:6e3,heartbeatInterval:2e3,messageSizeKB:64,verificationTimeout:1500,transactionLogMaximumSizeGB:50,nodes:[]},e.locations=a.clusterModel.locations.filter(e=>!e.isLocal),e.selectedLocations=a.clusterModel.locations.filter(e=>e.isLocal),e.loader=!1,e.getAdvancedOptionsClass=c,e.createCluster=function(){return e.setLoader(!0,s.instant("cluster_management.cluster_page.creating_cluster_loader")),e.clusterConfiguration.nodes=e.selectedLocations.map(e=>e.rpcAddress),o.createCluster(e.clusterConfiguration).then(()=>{r.success(s.instant("cluster_management.cluster_page.notifications.create_success")),t.close()}).catch((function(t){!function(t,n){let o;delete e.preconditionErrors,e.errors.splice(0),412===n?e.preconditionErrors=Object.keys(t).map(e=>`${e} - ${t[e]}`):400===n?e.errors.push(...t):409===n?e.errors.push(t):(t.message||"string"==typeof t)&&(o=t.message||t);r.error(o,s.instant("cluster_management.cluster_page.notifications.create_failed"))}(t.data,t.status)})).finally(()=>{e.setLoader(!1),u.$broadcast("reloadLocations")})},e.isClusterConfigurationValid=()=>{const t=!e.clusterConfigurationForm.$invalid,n=e.selectedLocations&&e.selectedLocations.length>=2;return t&&n},e.setLoader=function(t,o){n.cancel(e.loaderTimeout),t?e.loaderTimeout=n((function(){e.loader=t,e.loaderMessage=o}),300):e.loader=!1},e.addNodeToList=function(t){t.rpcAddress&&(e.selectedLocations.push(t),e.locations=e.locations.filter(e=>e.endpoint!==t.endpoint))},e.removeNodeFromList=function(t,n){n.isLocal||(e.selectedLocations.splice(t,1),e.locations.push(n))},e.addLocation=function(){i.addLocation().then(t=>{t&&e.locations.push(t)})},e.ok=function(){e.isClusterConfigurationValid()?e.createCluster():r.warning(s.instant("cluster_management.cluster_page.notifications.form_invalid"))},e.cancel=function(){t.dismiss("cancel")}}function u(e,t){e.forceDelete=!1,e.ok=function(){t.close(e.forceDelete)},e.cancel=function(){t.dismiss("cancel")}}function d(e,t,n,o,r){return{addLocation:function(){let e;return n.open({templateUrl:"js/angular/templates/modal/add-location.html",windowClass:"addLocationDialog",controller:"AddLocationFromClusterCtrl"}).result.then(n=>(e=n,e.isLocal=!1,e.endpoint=e.uri,function(e){let n;return o.addLocation(e).catch(e=>{const n=getError(e.data,e.status);return t.error(n,r.instant("common.error")),!1}).then(e=>!!e&&s()).then(t=>{if(!1!==t)return n=t.find(t=>t.endpoint===e.uri),n})}(e)))},getLocationsWithRpcAddresses:s};function s(){return o.getLocations().then((function(e){return e.data.map(e=>({isLocal:e.local,endpoint:e.uri,rpcAddress:e.rpcAddress||"",error:e.errorMsg}))})).catch((function(e){const n=getError(e.data,e.status);t.error(n,r.instant("common.error"))})).then(e=>{if(e)return function(e){const t=e.filter(e=>!e.isLocal&&!e.error).map(e=>function(e){return o.getLocationRpcAddress(e.endpoint)}(e).then(t=>(e.rpcAddress=t.data,e.isAvailable=!0,e)).catch(t=>{e.isAvailable=!1,e.error=getError(t.data,t.status)}));return Promise.allSettled(t).then(()=>e)}(e)})}}function g(e,t,n,o,r){e.newLocation={uri:"",authType:"signature",username:"",password:"",active:!1},e.docBase=m(o),e.isValidLocation=function(){return(e.newLocation.uri.length<6||0===e.newLocation.uri.indexOf("http:")||0===e.newLocation.uri.indexOf("https:"))&&e.newLocation.uri.indexOf("/repositories")<=-1},e.ok=function(){e.newLocation?t.close(e.newLocation):n.error(r.instant("location.cannot.be.empty.error"))},e.cancel=function(){t.dismiss("cancel")}}function f(e,t,n,o,r,s,a){e.pageTitle=s.instant("cluster_management.cluster_page.edit_page_title"),e.errors=[],e.clusterConfiguration=angular.copy(a.clusterConfiguration),e.loader=!1,e.updateCluster=function(){return e.setLoader(!0,s.instant("cluster_management.cluster_page.updating_cluster_loader")),o.updateCluster(e.clusterConfiguration).then(()=>{r.success(s.instant("cluster_management.cluster_page.notifications.update_success")),t.close()}).catch((function(t){!function(t,n){delete e.preconditionErrors,r.error(s.instant("cluster_management.cluster_page.notifications.update_failed")),e.errors.splice(0),409===n||"string"==typeof t?e.errors.push(t):412===n?e.preconditionErrors=Object.keys(t).map(e=>`${e} - ${t[e]}`):400===n&&e.errors.push(...t)}(t.data,t.status)})).finally(()=>e.setLoader(!1))},e.isClusterConfigurationValid=()=>!e.clusterConfigurationForm.$invalid,e.setLoader=function(t,o){n.cancel(e.loaderTimeout),t?e.loaderTimeout=n((function(){e.loader=t,e.loaderMessage=o}),300):e.loader=!1},e.ok=function(){e.isClusterConfigurationValid()?e.updateCluster():r.warning(s.instant("cluster_management.cluster_page.notifications.form_invalid"))},e.cancel=function(){t.dismiss("cancel")}}i.$inject=["$scope","$uibModalInstance","$timeout","ClusterRestService","toastr","$translate","data","$uibModal","RemoteLocationsService","$rootScope"],u.$inject=["$scope","$uibModalInstance"],d.$inject=["$http","toastr","$uibModal","LocationsRestService","$translate"],g.$inject=["$scope","$uibModalInstance","toastr","productInfo","$translate"],f.$inject=["$scope","$uibModalInstance","$timeout","ClusterRestService","toastr","$translate","data"];const m=function(e){return"https://graphdb.ontotext.com/documentation/"+e.productShortVersion};function p(e,t,n,o,r){const s=angular.copy(n.clusterConfiguration),a=angular.copy(n.clusterModel);e.nodes=[],e.clusterNodes=a.nodes.map(e=>({rpcAddress:e.address,endpoint:e.endpoint})),e.locations=a.locations.filter(e=>!s.nodes.includes(e.rpcAddress)),e.locations.forEach(e=>e.isNew=!0),e.addNodeToList=function(t){t.rpcAddress&&(e.nodes.push(t),e.locations=e.locations.filter(e=>e.endpoint!==t.endpoint))},e.removeNodeFromList=function(t,n){e.nodes.splice(t,1),e.locations.push(n)},e.addLocation=function(){r.addLocation().then(t=>{t&&e.locations.push(t)})},e.ok=function(){t.close(e.nodes)},e.cancel=function(){t.dismiss("cancel")}}function C(e,t,n){const o=angular.copy(n.clusterModel);e.clusterNodes=o.nodes,e.clusterNodes.forEach(e=>e.shouldRemove=!1),e.nodesToRemoveCount=0,e.leftNodesLessThanTwo=!1,e.toggleNode=function(t,n){n.shouldRemove=!n.shouldRemove,n.shouldRemove?e.nodesToRemoveCount++:e.nodesToRemoveCount--,e.leftNodesLessThanTwo=e.clusterNodes.length-e.nodesToRemoveCount<2},e.ok=function(){const n=e.clusterNodes.filter(e=>e.shouldRemove);t.close(n)},e.cancel=function(){t.dismiss("cancel")}}p.$inject=["$scope","$uibModalInstance","data","$uibModal","RemoteLocationsService"],C.$inject=["$scope","$uibModalInstance","data"]}}]);
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[4,133],{61:function(e,t){angular.module("graphdb.framework.rest.cluster.service",[]).factory("ClusterRestService",n),n.$inject=["$http"];function n(e){return{getClusterConfig:function(){return e.get("rest/cluster/config")},createCluster:function(t){return e.post("rest/cluster/config",t)},updateCluster:function(t){t.nodes&&delete t.nodes;return e.patch("rest/cluster/config",t)},deleteCluster:function(t){const n=$.param({force:t});return e.delete("rest/cluster/config?"+n)},addNodesToCluster:function(t){return e.post("rest/cluster/config/node",{nodes:t})},removeNodesFromCluster:function(t){return e.delete("rest/cluster/config/node",{data:{nodes:t},headers:{"Content-Type":"application/json"}})},getClusterStatus:function(){return e.get("rest/cluster/group/status")},getNodeStatus:function(){return e.get("rest/cluster/node/status")}}}},78:function(e,t,n){"use strict";n.r(t),n.d(t,"NodeState",(function(){return r})),n.d(t,"RecoveryState",(function(){return s})),n.d(t,"LinkState",(function(){return a}));n(7),n(61);var o=n(85);angular.module("graphdb.framework.clustermanagement.controllers",["ui.bootstrap","graphdb.framework.core.services.repositories","graphdb.framework.rest.repositories.service","graphdb.framework.rest.cluster.service","toastr","pageslide-directive"]).controller("ClusterManagementCtrl",l).controller("CreateClusterCtrl",i).controller("DeleteClusterCtrl",u).controller("EditClusterCtrl",f).controller("AddLocationFromClusterCtrl",g).controller("AddNodesDialogCtrl",p).controller("RemoveNodesDialogCtrl",C).factory("RemoteLocationsService",d);const r={LEADER:"LEADER",FOLLOWER:"FOLLOWER",CANDIDATE:"CANDIDATE",OUT_OF_SYNC:"OUT_OF_SYNC",NO_CONNECTION:"NO_CONNECTION",READ_ONLY:"READ_ONLY",RESTRICTED:"RESTRICTED",NO_CLUSTER:"NO_CLUSTER"},s={SEARCHING_FOR_NODE:"SEARCHING_FOR_NODE",WAITING_FOR_SNAPSHOT:"WAITING_FOR_SNAPSHOT",RECEIVING_SNAPSHOT:"RECEIVING_SNAPSHOT",APPLYING_SNAPSHOT:"APPLYING_SNAPSHOT",BUILDING_SNAPSHOT:"BUILDING_SNAPSHOT",SENDING_SNAPSHOT:"SENDING_SNAPSHOT"},a={IN_SYNC:"IN_SYNC",OUT_OF_SYNC:"OUT_OF_SYNC",SYNCING:"SYNCING",NO_CONNECTION:"NO_CONNECTION"};function l(e,t,n,s,l,c,i,u,d,g,f,m,p,C,h,N,_){e.loader=!0,e.isLeader=!1,e.currentNode=null,e.clusterModel={},e.NodeState=r,e.leaderChanged=!1,e.currentLeader=null,e.isAdmin=function(){return u.isAuthenticated()&&u.isAdmin()},e.childContext={},e.shouldShowClusterSettingsPanel=!1;let L;function S(t){L||(L=e.getClusterStatus().then(()=>{if(t||!e.clusterConfiguration)return e.getClusterConfiguration()}).then(()=>{if(!e.currentNode||e.leaderChanged)return e.getCurrentNodeStatus()}).finally(()=>{L=null,e.childContext.redraw()}))}function $(){return N.getLocationsWithRpcAddresses().then(t=>{const n=t.find(e=>e.isLocal);n&&(n.endpoint=e.currentNode.endpoint,n.rpcAddress=e.currentNode.address),e.clusterModel.locations=t})}function v(t){s.success(t),e.getClusterConfiguration()}function O(e,t,n){let r=e.message||e;400===t&&Array.isArray(e)?r=e.reduce((e,t)=>e+`<div>${t}</div>`,""):412!==t||Object(o.isString)(e)||(r=Object.keys(e).reduce((t,n)=>t+`<div>${n} - ${e[n]}</div>`,"")),s.error(r,n,{allowHtml:!0})}e.onopen=e.onclose=()=>angular.noop(),e.toggleSidePanel=()=>{e.shouldShowClusterSettingsPanel=!e.shouldShowClusterSettingsPanel},e.toggleLegend=()=>{e.childContext.toggleLegend&&e.childContext.toggleLegend()},e.setLoader=function(t,n){m.cancel(e.loaderTimeout),t?(e.loaderMessage=n,e.loaderTimeout=m((function(){e.loader=t}),50)):e.loader=!1},e.childContext.selectNode=function(t){e.selectedNode!==t?e.selectedNode=t:e.selectedNode=null,e.$apply()},e.getLoaderMessage=function(){return e.loaderMessage||h.instant("common.loading")},e.getClusterConfiguration=()=>p.getClusterConfig().then(t=>{if(e.clusterConfiguration=t.data,!e.currentNode)return e.getCurrentNodeStatus()}).catch(()=>{e.clusterConfiguration=null}),e.getClusterStatus=function(){return p.getClusterStatus().then((function(t){const n=t.data.slice(),o=n.find(e=>e.nodeState===r.LEADER);var s,l;s=e.currentLeader,(l=o)&&s&&s.address===l.address||(e.currentLeader=o,e.leaderChanged=!0),e.currentNode=n.find(t=>t.address===e.currentNode.address);const c=[];o&&Object.keys(o.syncStatus).forEach(e=>{const t=o.syncStatus[e];t!==a.NO_CONNECTION&&c.push({id:`${o.address}-${e}`,source:o.address,target:e,status:t})}),e.clusterModel.hasCluster=!0,e.clusterModel.nodes=n,e.clusterModel.links=c})).catch((function(t){404===t.status&&(e.clusterModel.hasCluster=!1,e.clusterModel.nodes=[],e.clusterModel.links=[],e.clusterConfiguration=null)}))},e.showCreateClusterDialog=function(){c.open({templateUrl:"js/angular/clustermanagement/templates/modal/cluster-create-dialog.html",controller:"CreateClusterCtrl",size:"lg",resolve:{data:function(){return{clusterModel:e.clusterModel}}}}).result.finally((function(){$(),S(!0)}))},e.showDeleteDialog=()=>{c.open({templateUrl:"js/angular/clustermanagement/templates/modal/cluster-delete-dialog.html",controller:"DeleteClusterCtrl"}).result.then((function(t){const n=h.instant("cluster_management.delete_cluster_dialog.loader_message");e.setLoader(!0,n),p.deleteCluster(t).then(t=>{if(Object.values(t.data).every(e=>"Cluster was deleted on this node."===e)){const e=h.instant("cluster_management.delete_cluster_dialog.notifications.success_delete");s.success(e)}else{const e=h.instant("cluster_management.delete_cluster_dialog.notifications.success_delete_partial"),n=Object.keys(t.data).reduce((e,n)=>e+`<div>${n} - ${t.data[n]}</div>`,"");s.warning(n,e,{allowHtml:!0})}e.getClusterConfiguration()}).catch(e=>{const t=h.instant("cluster_management.delete_cluster_dialog.notifications.fail_delete");O(e.data,e.status,t)}).finally(()=>{e.setLoader(!1),S(!0),_.$broadcast("reloadLocations")})}))},e.showEditConfigurationDialog=()=>{c.open({templateUrl:"js/angular/clustermanagement/templates/modal/cluster-edit-dialog.html",controller:"EditClusterCtrl",size:"lg",resolve:{data:function(){return{clusterConfiguration:e.clusterConfiguration}}}}).result.finally((function(){S(!0)}))},e.getCurrentNodeStatus=()=>p.getNodeStatus().then(t=>{e.leaderChanged=!1,e.currentNode=t.data}).catch(t=>{e.currentNode=t.data,e.clusterModel.hasCluster=!1}).then(()=>$()),e.showAddNodeToClusterDialog=()=>{c.open({templateUrl:"js/angular/clustermanagement/templates/modal/add-nodes-dialog.html",controller:"AddNodesDialogCtrl",size:"lg",resolve:{data:function(){return{clusterModel:e.clusterModel,clusterConfiguration:e.clusterConfiguration}}}}).result.then((function(t){const n=h.instant("cluster_management.cluster_page.add_nodes_loader");e.setLoader(!0,n);const o=t.map(e=>e.rpcAddress);p.addNodesToCluster(o).then(()=>{v(h.instant("cluster_management.cluster_page.notifications.add_nodes_success"))}).catch(e=>{const t=h.instant("cluster_management.cluster_page.notifications.add_nodes_fail");O(e.data,e.status,t)}).finally(()=>{e.setLoader(!1),S(!0)})})).finally(()=>$())},e.showRemoveNodesFromClusterDialog=()=>{c.open({templateUrl:"js/angular/clustermanagement/templates/modal/remove-nodes-dialog.html",controller:"RemoveNodesDialogCtrl",size:"lg",resolve:{data:function(){return{clusterModel:e.clusterModel}}}}).result.then((function(t){const n=h.instant("cluster_management.cluster_page.remove_nodes_loader");e.setLoader(!0,n);const o=t.map(e=>e.address);p.removeNodesFromCluster(o).then(()=>{v(h.instant("cluster_management.cluster_page.notifications.remove_nodes_success"))}).catch(e=>{const t=h.instant("cluster_management.cluster_page.notifications.remove_nodes_fail");O(e.data,e.status,t)}).finally(()=>{e.setLoader(!1),S(!0)})}))},(e.loader=!0,e.getCurrentNodeStatus().then(()=>e.getClusterConfiguration()).then(()=>e.getClusterStatus()).finally(()=>{e.setLoader(!1)})).finally(()=>{const t=g((function(){S()}),1e3);e.$on("$destroy",(function(){g.cancel(t)}))});const T=angular.element(d),A=function(){e.childContext.resize()};T.bind("resize",A);const E=function(t){const n=t.target,o=document.getElementById("nodeTooltip");e.selectedNode&&o!==n&&!o.contains(n)&&e.childContext.selectNode(null)};T.bind("mousedown",E),e.$on("$destroy",(function(){T.unbind("resize",A),T.unbind("mousedown",E)}))}l.$inject=["$scope","$http","$q","toastr","$repositories","$uibModal","$sce","$jwtAuth","$window","$interval","ModalService","$timeout","ClusterRestService","$location","$translate","RemoteLocationsService","$rootScope"];const c=function(){const e=document.getElementById("advancedOptions");if(e){const t=e.getAttribute("aria-expanded");if(t&&"true"===t)return"fa fa-angle-down"}return"fa fa-angle-right"};function i(e,t,n,o,r,s,a,l,i,u){e.pageTitle=s.instant("cluster_management.cluster_page.create_page_title"),e.autofocusId="autofocus",e.errors=[],e.clusterConfiguration={electionMinTimeout:8e3,electionRangeTimeout:6e3,heartbeatInterval:2e3,messageSizeKB:64,verificationTimeout:1500,transactionLogMaximumSizeGB:50,nodes:[]},e.locations=a.clusterModel.locations.filter(e=>!e.isLocal),e.selectedLocations=a.clusterModel.locations.filter(e=>e.isLocal),e.loader=!1,e.getAdvancedOptionsClass=c,e.createCluster=function(){return e.setLoader(!0,s.instant("cluster_management.cluster_page.creating_cluster_loader")),e.clusterConfiguration.nodes=e.selectedLocations.map(e=>e.rpcAddress),o.createCluster(e.clusterConfiguration).then(()=>{r.success(s.instant("cluster_management.cluster_page.notifications.create_success")),t.close()}).catch((function(t){!function(t,n){let o;delete e.preconditionErrors,e.errors.splice(0),412===n?e.preconditionErrors=Object.keys(t).map(e=>`${e} - ${t[e]}`):400===n?e.errors.push(...t):409===n?e.errors.push(t):(t.message||"string"==typeof t)&&(o=t.message||t);r.error(o,s.instant("cluster_management.cluster_page.notifications.create_failed"))}(t.data,t.status)})).finally(()=>{e.setLoader(!1),u.$broadcast("reloadLocations")})},e.isClusterConfigurationValid=()=>{const t=!e.clusterConfigurationForm.$invalid,n=e.selectedLocations&&e.selectedLocations.length>=2;return t&&n},e.setLoader=function(t,o){n.cancel(e.loaderTimeout),t?e.loaderTimeout=n((function(){e.loader=t,e.loaderMessage=o}),300):e.loader=!1},e.addNodeToList=function(t){t.rpcAddress&&(e.selectedLocations.push(t),e.locations=e.locations.filter(e=>e.endpoint!==t.endpoint))},e.removeNodeFromList=function(t,n){n.isLocal||(e.selectedLocations.splice(t,1),e.locations.push(n))},e.addLocation=function(){i.addLocation().then(t=>{t&&e.locations.push(t)})},e.ok=function(){e.isClusterConfigurationValid()?e.createCluster():r.warning(s.instant("cluster_management.cluster_page.notifications.form_invalid"))},e.cancel=function(){t.dismiss("cancel")}}function u(e,t){e.forceDelete=!1,e.ok=function(){t.close(e.forceDelete)},e.cancel=function(){t.dismiss("cancel")}}function d(e,t,n,o,r){return{addLocation:function(){let e;return n.open({templateUrl:"js/angular/templates/modal/add-location.html",windowClass:"addLocationDialog",controller:"AddLocationFromClusterCtrl"}).result.then(n=>(e=n,e.isLocal=!1,e.endpoint=e.uri,function(e){let n;return o.addLocation(e).catch(e=>{const n=getError(e.data,e.status);return t.error(n,r.instant("common.error")),!1}).then(e=>!!e&&s()).then(t=>{if(!1!==t)return n=t.find(t=>t.endpoint===e.uri),n})}(e)))},getLocationsWithRpcAddresses:s};function s(){return o.getLocations().then((function(e){return e.data.map(e=>({isLocal:e.local,endpoint:e.uri,rpcAddress:e.rpcAddress||"",error:e.errorMsg}))})).catch((function(e){const n=getError(e.data,e.status);t.error(n,r.instant("common.error"))})).then(e=>{if(e)return function(e){const t=e.filter(e=>!e.isLocal&&!e.error).map(e=>function(e){return o.getLocationRpcAddress(e.endpoint)}(e).then(t=>(e.rpcAddress=t.data,e.isAvailable=!0,e)).catch(t=>{e.isAvailable=!1,e.error=getError(t.data,t.status)}));return Promise.allSettled(t).then(()=>e)}(e)})}}function g(e,t,n,o,r){e.newLocation={uri:"",authType:"signature",username:"",password:"",active:!1},e.docBase=m(o),e.isValidLocation=function(){return(e.newLocation.uri.length<6||0===e.newLocation.uri.indexOf("http:")||0===e.newLocation.uri.indexOf("https:"))&&e.newLocation.uri.indexOf("/repositories")<=-1},e.ok=function(){e.newLocation?t.close(e.newLocation):n.error(r.instant("location.cannot.be.empty.error"))},e.cancel=function(){t.dismiss("cancel")}}function f(e,t,n,o,r,s,a){e.pageTitle=s.instant("cluster_management.cluster_page.edit_page_title"),e.errors=[],e.clusterConfiguration=angular.copy(a.clusterConfiguration),e.loader=!1,e.updateCluster=function(){return e.setLoader(!0,s.instant("cluster_management.cluster_page.updating_cluster_loader")),o.updateCluster(e.clusterConfiguration).then(()=>{r.success(s.instant("cluster_management.cluster_page.notifications.update_success")),t.close()}).catch((function(t){!function(t,n){delete e.preconditionErrors,r.error(s.instant("cluster_management.cluster_page.notifications.update_failed")),e.errors.splice(0),409===n||"string"==typeof t?e.errors.push(t):412===n?e.preconditionErrors=Object.keys(t).map(e=>`${e} - ${t[e]}`):400===n&&e.errors.push(...t)}(t.data,t.status)})).finally(()=>e.setLoader(!1))},e.isClusterConfigurationValid=()=>!e.clusterConfigurationForm.$invalid,e.setLoader=function(t,o){n.cancel(e.loaderTimeout),t?e.loaderTimeout=n((function(){e.loader=t,e.loaderMessage=o}),300):e.loader=!1},e.ok=function(){e.isClusterConfigurationValid()?e.updateCluster():r.warning(s.instant("cluster_management.cluster_page.notifications.form_invalid"))},e.cancel=function(){t.dismiss("cancel")}}i.$inject=["$scope","$uibModalInstance","$timeout","ClusterRestService","toastr","$translate","data","$uibModal","RemoteLocationsService","$rootScope"],u.$inject=["$scope","$uibModalInstance"],d.$inject=["$http","toastr","$uibModal","LocationsRestService","$translate"],g.$inject=["$scope","$uibModalInstance","toastr","productInfo","$translate"],f.$inject=["$scope","$uibModalInstance","$timeout","ClusterRestService","toastr","$translate","data"];const m=function(e){return"https://graphdb.ontotext.com/documentation/"+e.productShortVersion};function p(e,t,n,o,r){const s=angular.copy(n.clusterConfiguration),a=angular.copy(n.clusterModel);e.nodes=[],e.clusterNodes=a.nodes.map(e=>({rpcAddress:e.address,endpoint:e.endpoint})),e.locations=a.locations.filter(e=>!s.nodes.includes(e.rpcAddress)),e.locations.forEach(e=>e.isNew=!0),e.addNodeToList=function(t){t.rpcAddress&&(e.nodes.push(t),e.locations=e.locations.filter(e=>e.endpoint!==t.endpoint))},e.removeNodeFromList=function(t,n){e.nodes.splice(t,1),e.locations.push(n)},e.addLocation=function(){r.addLocation().then(t=>{t&&e.locations.push(t)})},e.ok=function(){t.close(e.nodes)},e.cancel=function(){t.dismiss("cancel")}}function C(e,t,n){const o=angular.copy(n.clusterModel);e.clusterNodes=o.nodes,e.clusterNodes.forEach(e=>e.shouldRemove=!1),e.nodesToRemoveCount=0,e.leftNodesLessThanTwo=!1,e.toggleNode=function(t,n){n.shouldRemove=!n.shouldRemove,n.shouldRemove?e.nodesToRemoveCount++:e.nodesToRemoveCount--,e.leftNodesLessThanTwo=e.clusterNodes.length-e.nodesToRemoveCount<2},e.ok=function(){const n=e.clusterNodes.filter(e=>e.shouldRemove);t.close(n)},e.cancel=function(){t.dismiss("cancel")}}p.$inject=["$scope","$uibModalInstance","data","$uibModal","RemoteLocationsService"],C.$inject=["$scope","$uibModalInstance","data"]}}]);
@@ -1 +1 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[39],{299:function(n,o){n.exports=function(){throw new Error("define cannot be used indirect")}},300:function(n,o){(function(o){n.exports=o}).call(this,{})}}]);
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[40],{299:function(n,o){n.exports=function(){throw new Error("define cannot be used indirect")}},300:function(n,o){(function(o){n.exports=o}).call(this,{})}}]);
@@ -1 +1 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[40,64],{63:function(e,t,s){"use strict";s.r(t),s.d(t,"mapAclRulesResponse",(function(){return l}));var c=s(64);const l=e=>{const t=new c.ACListModel;return e&&e.data&&e.data.forEach(e=>{t.appendNewRule(e.subject,e.predicate,e.object,e.context,e.role,e.policy)}),t}},64:function(e,t,s){"use strict";s.r(t),s.d(t,"ACListModel",(function(){return c})),s.d(t,"ACRuleModel",(function(){return l})),s.d(t,"ACL_POLICY",(function(){return i}));class c{constructor(e=[]){this._aclRules=e}size(){return this.aclRules.length}appendNewRule(e,t,s,c,i,u){this.aclRules.push(new l(e,t,s,c,i,u))}addRule(e){this.aclRules.splice(e,0,new l)}removeRule(e){this.aclRules.splice(e,1)}replaceRule(e,t){this.aclRules.splice(e,1,t)}getRule(e){return this.aclRules[e]}isRuleDuplicated(e){const t=this.aclRules[e];return this.aclRules.some((s,c)=>e!==c&&angular.equals(t,s))}getRuleCopy(e){const t=this.aclRules[e];return{subject:t.subject,predicate:t.predicate,object:t.object,context:t.context,role:t.role,policy:t.policy}}moveUp(e){const t=this.aclRules[e-1];this.aclRules[e-1]=this.aclRules[e],this.aclRules[e]=t}moveDown(e){const t=this.aclRules[e+1];this.aclRules[e+1]=this.aclRules[e],this.aclRules[e]=t}toJSON(){return this.aclRules.map(e=>({subject:e.subject,predicate:e.predicate,object:e.object,context:e.context,role:e.role,policy:e.policy}))}get aclRules(){return this._aclRules}set aclRules(e){this._aclRules=e}}class l{constructor(e="*",t="*",s="*",c="*",l="CUSTOM_",u=i.ALLOW){this._subject=e,this._predicate=t,this._object=s,this._context=c,this._role=l,this._policy=u}get subject(){return this._subject}set subject(e){this._subject=e}get predicate(){return this._predicate}set predicate(e){this._predicate=e}get object(){return this._object}set object(e){this._object=e}get context(){return this._context}set context(e){this._context=e}get role(){return this._role}set role(e){this._role=e}get policy(){return this._policy}set policy(e){this._policy=e}}const i={ALLOW:"allow",DENY:"deny"}}}]);
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[41,65],{64:function(e,t,s){"use strict";s.r(t),s.d(t,"mapAclRulesResponse",(function(){return l}));var c=s(65);const l=e=>{const t=new c.ACListModel;return e&&e.data&&e.data.forEach(e=>{t.appendNewRule(e.subject,e.predicate,e.object,e.context,e.role,e.policy)}),t}},65:function(e,t,s){"use strict";s.r(t),s.d(t,"ACListModel",(function(){return c})),s.d(t,"ACRuleModel",(function(){return l})),s.d(t,"ACL_POLICY",(function(){return i}));class c{constructor(e=[]){this._aclRules=e}size(){return this.aclRules.length}appendNewRule(e,t,s,c,i,u){this.aclRules.push(new l(e,t,s,c,i,u))}addRule(e){this.aclRules.splice(e,0,new l)}removeRule(e){this.aclRules.splice(e,1)}replaceRule(e,t){this.aclRules.splice(e,1,t)}getRule(e){return this.aclRules[e]}isRuleDuplicated(e){const t=this.aclRules[e];return this.aclRules.some((s,c)=>e!==c&&angular.equals(t,s))}getRuleCopy(e){const t=this.aclRules[e];return{subject:t.subject,predicate:t.predicate,object:t.object,context:t.context,role:t.role,policy:t.policy}}moveUp(e){const t=this.aclRules[e-1];this.aclRules[e-1]=this.aclRules[e],this.aclRules[e]=t}moveDown(e){const t=this.aclRules[e+1];this.aclRules[e+1]=this.aclRules[e],this.aclRules[e]=t}toJSON(){return this.aclRules.map(e=>({subject:e.subject,predicate:e.predicate,object:e.object,context:e.context,role:e.role,policy:e.policy}))}get aclRules(){return this._aclRules}set aclRules(e){this._aclRules=e}}class l{constructor(e="*",t="*",s="*",c="*",l="CUSTOM_",u=i.ALLOW){this._subject=e,this._predicate=t,this._object=s,this._context=c,this._role=l,this._policy=u}get subject(){return this._subject}set subject(e){this._subject=e}get predicate(){return this._predicate}set predicate(e){this._predicate=e}get object(){return this._object}set object(e){this._object=e}get context(){return this._context}set context(e){this._context=e}get role(){return this._role}set role(e){this._role=e}get policy(){return this._policy}set policy(e){this._policy=e}}const i={ALLOW:"allow",DENY:"deny"}}}]);
@@ -0,0 +1 @@
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[42,138],{60:function(e,t,o){"use strict";o.r(t),o.d(t,"mapNamespacesResponse",(function(){return n}));const n=e=>e&&e.data?e.data.results.bindings.map(e=>({prefix:e.prefix.value,uri:e.namespace.value})):[]},91:function(e,t,o){"use strict";o.r(t);o(31);var n=o(60),r=o(0);function i(e,t,o,i,c,a,s,l,u,d,f,p){let g;function m(){g&&t.cancel(g)}e.pluginName="autocomplete",e.setPluginIsActive=function(t){e.pluginIsActive=t};const b=function(){d.checkAutocompleteStatus().success((function(t){e.autocompleteEnabled=t,f.setAutocompleteStatus(t)})).error((function(e){o.error(getError(e))}))},I=function(){d.refreshIndexIRIs().success((function(t){e.shouldIndexIRIs=t})).error((function(e){o.error(getError(e))}))},L=function(){d.refreshIndexStatus().success((function(t){e.indexStatus=t})).error((function(e){o.error(getError(e))}))},v=function(){d.refreshLabelConfig().success((function(t){e.labelConfig=t})).error((function(e){o.error(getError(e))}))};e.checkForPlugin=function(){e.pluginFound=!1,e.setLoader(!0),d.checkForPlugin().success((function(t){e.pluginFound=!0===t,e.pluginFound?(h(),b(),I(),L(),v()):(e.autocompleteEnabled=!1,e.loading=!1)})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}))};const R=function(){g=t((function(){e.$broadcast("checkIsActive"),e.autocompleteEnabled&&L()}),5e3)};e.$on("$destroy",(function(){m()}));e.setLoader=function(t,o){s.cancel(e.loaderTimeout),t?e.loaderTimeout=s((function(){e.loader=t,e.loaderMessage=o}),300):e.loader=!1},e.getLoaderMessage=function(){return e.loaderMessage||p.instant("common.loading")},e.toggleAutocomplete=function(){const t=!e.autocompleteEnabled;e.setLoader(!0,t?p.instant("autocomplete.enabling"):p.instant("autocomplete.disabling")),d.toggleAutocomplete(t).success((function(){b(),L()})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}))},e.toggleIndexIRIs=function(){e.setLoader(!0,p.instant("autocomplete.index.iri")),d.toggleIndexIRIs(!e.shouldIndexIRIs).success((function(){I(),L()})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}))},e.buildIndex=function(){e.setLoader(!0,p.instant("autocomplete.index.build")),d.buildIndex().success((function(){e.indexStatus="BUILDING"})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}))},e.interruptIndexing=function(){e.setLoader(!0,p.instant("index.interrupt")),d.interruptIndexing().success((function(){L()})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}))},e.getDegradedReason=function(){return i.getDegradedReason()},e.addLabel=function(){e.editLabel({labelIri:"",languages:""},!0)},e.editLabel=function(t,n){a.open({templateUrl:"js/angular/autocomplete/templates/modal/add-label.html",controller:"AddLabelCtrl",resolve:{data:function(){return{label:t,isNew:n}}}}).result.then((function(t){!function(t){e.setLoader(!0,p.instant("autocomplete.update"));const n=t.labelIri;if(t.labelIri=u.expandPrefix(t.labelIri,e.namespaces),u.isValidIri(t,t.labelIri)&&""!==t.labelIri)d.addLabelConfig(t).success((function(){v(),L()})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}));else{const t=Object(r.decodeHTML)(p.instant("not.valid.iri",{value:n}));o.error(t),e.setLoader(!1)}}(t)}))},e.removeLabel=function(t){!function(t){e.setLoader(!0,p.instant("autocomplete.update")),d.removeLabelConfig(t).success((function(){v(),L()})).error((function(e){o.error(getError(e))})).finally((function(){e.setLoader(!1)}))}(t)},e.$on("repositoryIsSet",(function(){m(),c.isLicenseValid()&&i.getActiveRepository()&&!i.isActiveRepoOntopType()&&!i.isActiveRepoFedXType()&&(e.checkForPlugin(),R())}));const h=()=>{l.getNamespaces(i.getActiveRepository()).then(n.mapNamespacesResponse).then(t=>{e.namespaces=t}).catch(e=>{const t=getError(e);o.error(t,p.instant("error.getting.namespaces.for.repo"))})};c.isLicenseValid()&&i.getActiveRepository()&&!i.isActiveRepoOntopType()&&!i.isActiveRepoFedXType()&&(e.checkForPlugin(),R())}function c(e,t,o,n){e.label=angular.copy(n.label),e.isNew=n.isNew,e.ok=function(){e.form.$valid&&t.close(e.label)},e.cancel=function(){t.dismiss("cancel")},e.setTemplate=function(t){e.label.labelIri=t,o((function(){$("#wb-autocomplete-languages").focus()}),0)}}angular.module("graphdb.framework.autocomplete.controllers",["toastr","graphdb.framework.rest.autocomplete.service"]).controller("AutocompleteCtrl",i).controller("AddLabelCtrl",c),i.$inject=["$scope","$interval","toastr","$repositories","$licenseService","$uibModal","$timeout","RDF4JRepositoriesRestService","UriUtils","AutocompleteRestService","$autocompleteStatus","$translate"],c.$inject=["$scope","$uibModalInstance","$timeout","data"]}}]);
@@ -1 +1 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[42,68],{140:function(o,e,n){"use strict";n.r(e);n(92);angular.module("graphdb.framework.monitoring.backupandrestore",["graphdb.framework.monitoring.backupandrestore.controllers"])},92:function(o,e){function n(o,e,n){o.loading=!1,o.initialized=!1,o.backupAndRestoreInfos=void 0,o.hasClusterOperation=!1,o.paused=!1;let a=void 0;o.hasToShowValue=o=>"boolean"==typeof o||!!o,o.togglePause=()=>{o.paused=!o.paused};const r=()=>{o.loading||o.paused||(o.loading=!0,n.monitorBackup().then(e=>{o.backupAndRestoreInfos=e,o.initialized=!0,o.hasClusterOperation=o.backupAndRestoreInfos.some(o=>o.nodePerformingClusterBackup)}).finally(()=>o.loading=!1))};o.$on("$destroy",()=>{a&&e.cancel(a)}),r(),a=e(()=>r(),2e3)}angular.module("graphdb.framework.monitoring.backupandrestore.controllers",[]).controller("BackupAndRestoreCtrl",n),n.$inject=["$scope","$interval","MonitoringRestService"]}}]);
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[43,68],{140:function(o,e,n){"use strict";n.r(e);n(92);angular.module("graphdb.framework.monitoring.backupandrestore",["graphdb.framework.monitoring.backupandrestore.controllers"])},92:function(o,e){function n(o,e,n){o.loading=!1,o.initialized=!1,o.backupAndRestoreInfos=void 0,o.hasClusterOperation=!1,o.paused=!1;let a=void 0;o.hasToShowValue=o=>"boolean"==typeof o||!!o,o.togglePause=()=>{o.paused=!o.paused};const r=()=>{o.loading||o.paused||(o.loading=!0,n.monitorBackup().then(e=>{o.backupAndRestoreInfos=e,o.initialized=!0,o.hasClusterOperation=o.backupAndRestoreInfos.some(o=>o.nodePerformingClusterBackup)}).finally(()=>o.loading=!1))};o.$on("$destroy",()=>{a&&e.cancel(a)}),r(),a=e(()=>r(),2e3)}angular.module("graphdb.framework.monitoring.backupandrestore.controllers",[]).controller("BackupAndRestoreCtrl",n),n.$inject=["$scope","$interval","MonitoringRestService"]}}]);
@@ -1 +1 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[43,70],{142:function(t,e,o){"use strict";o.r(e);o(93);angular.module("graphdb.framework.chatgpt",["ngRoute","graphdb.framework.chatgpt.controllers"])},93:function(t,e){function o(t,e,o,n,r,s,i,a,c){function l(){o(()=>{document.getElementById("messages-scrollable").scrollIntoView({behavior:"smooth",block:"end",inline:"nearest"})},0)}function u(){t.history=[],t.askSettings={queryTemplate:{query:"string"},groundTruths:[],echoVectorQuery:!1,topK:5};const e=c.get("ttyg"),o=s.getActiveRepository();if(e&&e[o]){const n=e[o];n.history&&(t.history=n.history),t.connectorID=n.connectorID,n.askSettings&&(t.askSettings=n.askSettings)}l()}function g(){const e=c.get("ttyg")||{};e[s.getActiveRepository()]={history:t.history,connectorID:t.connectorID,askSettings:t.askSettings},c.set("ttyg",e)}t.helpTemplateUrl="js/angular/chatgpt/templates/chatInfo.html",t.getIcon=function(t){return"question"===t?"user":"assistant"===t?"data":"help"},t.ask=function(){if(!t.question.trim())return;const o=t.history.filter(t=>!t.error),n={connectorID:t.connectorID,question:t.question,askSettings:t.askSettings,history:o},r={role:"question",content:t.question};e.post("/rest/chat/retrieval?repositoryID="+s.getActiveRepository(),n).then(e=>{t.history.pop(),e.data.forEach(e=>t.history.push(e))}).catch(t=>{r.error=!0,i.error(getError(t,0,100))}).finally(()=>{t.loader=!1,l(),g()}),t.history.push(r),t.loader=!0,l(),t.question=""},t.clear=function(){a.openSimpleModal({title:n.instant("common.confirm"),message:n.instant("ttyg.clear.history.confirmation"),warning:!0}).result.then((function(){t.history=[],g()}))},t.openSettings=function(){r.open({templateUrl:"js/angular/chatgpt/templates/modal/settings.html",controller:"ChatGptSettingsCtrl",size:"lg",resolve:{data:function(){return{askSettings:t.askSettings,connectorID:t.connectorID}}}}).result.then((function(e){t.connectorID=e.connectorID,t.askSettings=e.askSettings,g()}))},t.$on("repositoryIsSet",(function(){u()})),s.getActiveRepository()&&u()}function n(t,e,o,n){t.dialogTitle=e.instant("ttyg.settings.title"),t.save=function(){if(t.form.$valid){const e={queryTemplate:JSON.parse(t.queryTemplate),groundTruths:t.groundTruths.split("\n"),topK:t.topK,echoVectorQuery:t.echoVectorQuery};o.close({askSettings:e,connectorID:t.connectorID})}},t.cancel=function(){o.dismiss("cancel")},t.connectorID=n.connectorID,t.queryTemplate=JSON.stringify(n.askSettings.queryTemplate,null," "),t.topK=n.askSettings.topK,t.echoVectorQuery=n.askSettings.echoVectorQuery,t.groundTruths=n.askSettings.groundTruths.map(t=>t.trim()).filter(t=>""!==t).join("\n")}angular.module("graphdb.framework.chatgpt.controllers",["toastr","graphdb.framework.utils.localstorageadapter"]).controller("ChatGptCtrl",o).controller("ChatGptSettingsCtrl",n),o.$inject=["$scope","$http","$timeout","$translate","$uibModal","$repositories","toastr","ModalService","LocalStorageAdapter"],n.$inject=["$scope","$translate","$uibModalInstance","data"]}}]);
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[44,70],{142:function(t,e,o){"use strict";o.r(e);o(93);angular.module("graphdb.framework.chatgpt",["ngRoute","graphdb.framework.chatgpt.controllers"])},93:function(t,e){function o(t,e,o,n,r,s,i,a,c){function l(){o(()=>{document.getElementById("messages-scrollable").scrollIntoView({behavior:"smooth",block:"end",inline:"nearest"})},0)}function u(){t.history=[],t.askSettings={queryTemplate:{query:"string"},groundTruths:[],echoVectorQuery:!1,topK:5};const e=c.get("ttyg"),o=s.getActiveRepository();if(e&&e[o]){const n=e[o];n.history&&(t.history=n.history),t.connectorID=n.connectorID,n.askSettings&&(t.askSettings=n.askSettings)}l()}function g(){const e=c.get("ttyg")||{};e[s.getActiveRepository()]={history:t.history,connectorID:t.connectorID,askSettings:t.askSettings},c.set("ttyg",e)}t.helpTemplateUrl="js/angular/chatgpt/templates/chatInfo.html",t.getIcon=function(t){return"question"===t?"user":"assistant"===t?"data":"help"},t.ask=function(){if(!t.question.trim())return;const o=t.history.filter(t=>!t.error),n={connectorID:t.connectorID,question:t.question,askSettings:t.askSettings,history:o},r={role:"question",content:t.question};e.post("/rest/chat/retrieval?repositoryID="+s.getActiveRepository(),n).then(e=>{t.history.pop(),e.data.forEach(e=>t.history.push(e))}).catch(t=>{r.error=!0,i.error(getError(t,0,100))}).finally(()=>{t.loader=!1,l(),g()}),t.history.push(r),t.loader=!0,l(),t.question=""},t.clear=function(){a.openSimpleModal({title:n.instant("common.confirm"),message:n.instant("ttyg.clear.history.confirmation"),warning:!0}).result.then((function(){t.history=[],g()}))},t.openSettings=function(){r.open({templateUrl:"js/angular/chatgpt/templates/modal/settings.html",controller:"ChatGptSettingsCtrl",size:"lg",resolve:{data:function(){return{askSettings:t.askSettings,connectorID:t.connectorID}}}}).result.then((function(e){t.connectorID=e.connectorID,t.askSettings=e.askSettings,g()}))},t.$on("repositoryIsSet",(function(){u()})),s.getActiveRepository()&&u()}function n(t,e,o,n){t.dialogTitle=e.instant("ttyg.settings.title"),t.save=function(){if(t.form.$valid){const e={queryTemplate:JSON.parse(t.queryTemplate),groundTruths:t.groundTruths.split("\n"),topK:t.topK,echoVectorQuery:t.echoVectorQuery};o.close({askSettings:e,connectorID:t.connectorID})}},t.cancel=function(){o.dismiss("cancel")},t.connectorID=n.connectorID,t.queryTemplate=JSON.stringify(n.askSettings.queryTemplate,null," "),t.topK=n.askSettings.topK,t.echoVectorQuery=n.askSettings.echoVectorQuery,t.groundTruths=n.askSettings.groundTruths.map(t=>t.trim()).filter(t=>""!==t).join("\n")}angular.module("graphdb.framework.chatgpt.controllers",["toastr","graphdb.framework.utils.localstorageadapter"]).controller("ChatGptCtrl",o).controller("ChatGptSettingsCtrl",n),o.$inject=["$scope","$http","$timeout","$translate","$uibModal","$repositories","toastr","ModalService","LocalStorageAdapter"],n.$inject=["$scope","$translate","$uibModalInstance","data"]}}]);
@@ -1 +1 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[44,75],{116:function(e,i,a){"use strict";a.r(i);a(32),a(65);var n=a(1);function t(e,i,a,t,s,r){e.guides=[],e.pageSizeOptions=[10,20,50,100],e.page=1,e.pageSize=e.pageSizeOptions[0],e.translationSubscription=void 0,e.init=function(){a.getGuides().then(i=>{e.guides=t("orderBy")(i,"guideOrder"),e.guides.forEach(e=>{switch(e.translatedGuideName=n.GuideUtils.translateLocalMessage(s,r,e.guideName),e.translatedGuideDescription=n.GuideUtils.translateLocalMessage(s,r,e.guideDescription),e.guideLevel){case void 0:case 0:e.guideLevelLabel="view.guides.level.beginner";break;case 1:e.guideLevelLabel="view.guides.level.intermediate";break;default:e.guideLevelLabel="view.guides.level.advanced"}}),e.matchedElements=e.guides,e.changePagination()})},e.startGuide=function(e){a.startGuide(e)},this.translationSubscription||(this.translationSubscription=i.$on("$translateChangeSuccess",()=>{e.init()})),e.changePagination=function(){angular.isDefined(e.guides)&&(e.displayedGuides=e.guides.slice(e.pageSize*(e.page-1),e.pageSize*e.page))},e.changePageSize=function(i){e.page=1,e.pageSize=i||e.pageSizeOptions[0],e.changePagination()},e.init()}angular.module("graphdb.framework.guides.controllers",["ui.bootstrap","graphdb.framework.guides.services","graphdb.framework.core.directives.paginations"]).controller("GuidesCtrl",t),t.$inject=["$scope","$rootScope","GuidesService","$filter","$translate","$interpolate"]},65:function(e,i){angular.module("graphdb.framework.core.directives.paginations",[]).directive("paginations",(function(){return{template:'<uib-pagination class="nav navbar-right" total-items="matchedElements.length" items-per-page="pageSize" ng-model="page" ng-change="changePagination()" direction-links="false" boundary-links="true" max-size="5" rotate="true"></uib-pagination>'}}))}}]);
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[45,75],{116:function(e,i,a){"use strict";a.r(i);a(32),a(66);var n=a(2);function t(e,i,a,t,s,r){e.guides=[],e.pageSizeOptions=[10,20,50,100],e.page=1,e.pageSize=e.pageSizeOptions[0],e.translationSubscription=void 0,e.init=function(){a.getGuides().then(i=>{e.guides=t("orderBy")(i,"guideOrder"),e.guides.forEach(e=>{switch(e.translatedGuideName=n.GuideUtils.translateLocalMessage(s,r,e.guideName),e.translatedGuideDescription=n.GuideUtils.translateLocalMessage(s,r,e.guideDescription),e.guideLevel){case void 0:case 0:e.guideLevelLabel="view.guides.level.beginner";break;case 1:e.guideLevelLabel="view.guides.level.intermediate";break;default:e.guideLevelLabel="view.guides.level.advanced"}}),e.matchedElements=e.guides,e.changePagination()})},e.startGuide=function(e){a.startGuide(e)},this.translationSubscription||(this.translationSubscription=i.$on("$translateChangeSuccess",()=>{e.init()})),e.changePagination=function(){angular.isDefined(e.guides)&&(e.displayedGuides=e.guides.slice(e.pageSize*(e.page-1),e.pageSize*e.page))},e.changePageSize=function(i){e.page=1,e.pageSize=i||e.pageSizeOptions[0],e.changePagination()},e.init()}angular.module("graphdb.framework.guides.controllers",["ui.bootstrap","graphdb.framework.guides.services","graphdb.framework.core.directives.paginations"]).controller("GuidesCtrl",t),t.$inject=["$scope","$rootScope","GuidesService","$filter","$translate","$interpolate"]},66:function(e,i){angular.module("graphdb.framework.core.directives.paginations",[]).directive("paginations",(function(){return{template:'<uib-pagination class="nav navbar-right" total-items="matchedElements.length" items-per-page="pageSize" ng-model="page" ng-change="changePagination()" direction-links="false" boundary-links="true" max-size="5" rotate="true"></uib-pagination>'}}))}}]);
@@ -1 +1 @@
1
- (window.webpackJsonp=window.webpackJsonp||[]).push([[45,153],{80:function(e,t){angular.module("graphdb.workbench.utils.filetypes",[]).value("FileTypes",[{name:"JSON",type:"application/rdf+json",extension:".json"},{name:"JSON-LD",type:"application/ld+json",extension:".jsonld"},{name:"RDF-XML",type:"application/rdf+xml",extension:".rdf"},{name:"N3",type:"text/rdf+n3",extension:".n3"},{name:"N-Triples",type:"text/plain",extension:".nt"},{name:"N-Quads",type:"text/x-nquads",extension:".nq"},{name:"Turtle",type:"text/turtle",extension:".ttl"},{name:"Turtle*",type:"application/x-turtlestar",extension:".ttls"},{name:"TriX",type:"application/trix",extension:".trix"},{name:"TriG",type:"application/x-trig",extension:".trig"},{name:"TriG*",type:"application/x-trigstar",extension:".trigs"},{name:"Binary RDF",type:"application/x-binary-rdf",extension:".brf"}])},98:function(e,t,n){"use strict";n.r(t);n(6),n(22),n(24),n(80);var o=n(0),r=n(84);angular.module("graphdb.framework.impex.export.controllers",["ngCookies","ui.bootstrap","toastr","graphdb.framework.core.services.repositories","graphdb.framework.core.services.jwtauth","graphdb.workbench.utils.filetypes"]).controller("ExportCtrl",["$scope","$http","$location","$timeout","ModalService","filterFilter","$repositories","toastr","RDF4JRepositoriesRestService","FileTypes","$translate","AuthTokenService",function(e,t,n,a,i,s,p,l,c,g,d,u){e.getActiveRepository=function(){return p.getActiveRepository()},e.exportFormats=g,e.deleting={},e.showExportDDTooltip=!0,e.page=1,e.pageSize=10,e.pageSizeOptions=[10,20,50,100],e.displayGraphs=[],e.exportFilter="",e.export=!0,e.exportMultipleGraphs=!1,e.repoExportFormat={name:"TriG",type:"application/x-trig",extension:".trig"},e.selectedGraphs={exportGraphs:{}},e.$watch((function(){return p.getActiveRepository()}),(function(){e.exportFilter="",e.getGraphs(),e.selectedAll=!1,a((function(){e.changePageSize(10)}),100)})),e.isShacl=function(e){return"http%3A%2F%2Frdf4j.org%2Fschema%2Frdf4j%23SHACLShapeGraph"===e},e.getGraphs=function(){e.getActiveRepository()?(e.loader=!0,c.getGraphs(e.getActiveRepository()).success((function(t){t.results.bindings.unshift({contextID:{type:"default",value:"import.default.graph"}}),e.graphsByValue={},Object.keys(t.results.bindings).forEach((function(n){const o=t.results.bindings[n];"bnode"===o.contextID.type?o.contextID.value="_:"+o.contextID.value:"default"===o.contextID.type?(o.contextID.uri=encodeURIComponent("http://www.openrdf.org/schema/sesame#nil"),o.contextID.clearUri="DEFAULT",o.contextID.exportUri="null",o.contextID.longName="default graph"):(o.contextID.uri=encodeURIComponent(o.contextID.value),o.contextID.clearUri="GRAPH <"+o.contextID.value+">",o.contextID.exportUri=encodeURIComponent("<"+o.contextID.value+">"),o.contextID.longName="named graph "+o.contextID.value),e.graphsByValue[o.contextID.value]=o.contextID})),e.graphs=t.results.bindings,e.filteredGraphs=Object(r.cloneDeep)(e.graphs),e.displayGraphs=e.filteredGraphs.slice(e.pageSize*(e.page-1),e.pageSize*e.page),e.loader=!1,e.selectedGraphs.exportGraphs={},e.matchedElements=e.graphs})).error((function(t,n){const o=getError(t,n);"There is no active location!"===o&&(p.setRepository(""),l.error(o,d.instant("common.error"))),e.loader=!1}))):e.loader=!1},e.onGraphSearch=function(){e.matchedElements=[],e.deselectAll(),e.filterResults()},e.filterResults=function(){angular.forEach(e.graphs,(function(t){-1!==t.contextID.value.indexOf(e.exportFilter)&&e.matchedElements.push(t)}))},e.downloadExport=function(e,t){let n=e+"&Accept="+encodeURIComponent(t.type);const o=u.getAuthToken();o&&(n=n+"&authToken="+encodeURIComponent(o));let r=window.open(n);a((function(){"about:blank"!==r.document.location.href&&(r.close(),l.error("Could not export graph. Check GraphDB logs for detailed reason."))}),100)},e.openExportDDTooltip=function(){e.showExportDDTooltip&&(a((function(){$("#tooltipTarget").trigger("showExportDDTooltip")}),0),a((function(){$("#tooltipTarget").trigger("showExportDDTooltip")}),3e3),e.showExportDDTooltip=!1)},e.exportRepo=function(t,n){"application/rdf+xml"===t.type||"text/plain"===t.type||"text/turtle"===t.type||"application/x-turtlestar"===t.type||"text/rdf+n3"===t.type?i.openSimpleModal({title:d.instant("common.warning"),message:Object(o.decodeHTML)(d.instant("export.format.warning.msg")),warning:!0}).result.then((function(){e.startDownload(t,n)})):e.startDownload(t,n)},e.startDownload=function(t,n){let o;const r=p.getActiveRepositoryObject();o=n?`repositories/${r.id}/statements?infer=false&context=${e.graphsByValue[n.value].exportUri}&location=${encodeURIComponent(r.location)}`:`repositories/${r.id}/statements?infer=false&location=${encodeURIComponent(r.location)}`,e.downloadExport(o,t)},e.hasMultipleSelected=function(){if(_.isEmpty(e.selectedGraphs.exportGraphs))return!_.isEmpty(e.selectedGraphs.exportGraphs);for(const t in e.selectedGraphs.exportGraphs)if(!0===e.selectedGraphs.exportGraphs[t])return!0;return!1},e.exportSelectedGraphs=function(t){let n="";for(const t in e.selectedGraphs.exportGraphs)e.selectedGraphs.exportGraphs[t]&&(n+="context="+e.graphsByValue[t].exportUri+"&");if(n){const r=function(){n=n.substring(0,n.length-1);const o="repositories/"+e.getActiveRepository()+"/statements?infer=false&"+n;e.downloadExport(o,t)};"application/rdf+xml"===t.type||"text/plain"===t.type||"text/turtle"===t.type||"application/x-turtlestar"===t.type||"text/rdf+n3"===t.type?i.openSimpleModal({title:d.instant("common.warning"),message:Object(o.decodeHTML)(d.instant("export.format.warning.msg")),warning:!0}).result.then((function(){r()})):r()}else i.openSimpleModal({title:d.instant("export.multiple.graph"),message:d.instant("export.check.graphs.msg"),warning:!0})},e.$watch("exportFilter",(function(){if(e.filteredGraphs=s(e.graphs,e.exportFilter),e.getActiveRepository()&&angular.element(document).find(".btn.btn-secondary.btn-sm.dropdown-toggle span").length){const t=angular.element(document).find(".btn.btn-secondary.btn-sm.dropdown-toggle span")[0].innerHTML.trim();let n;"All"===t&&(n=e.filteredGraphs.length),e.filteredGraphs&&e.filteredGraphs.length>e.pageSize&&"All"!==t&&(n=e.pageSize),e.changePageSize(n),e.changePagination()}})),e.changePagination=function(){e.selectedAll=!1,angular.isDefined(e.filteredGraphs)&&(e.displayGraphs=e.filteredGraphs.slice(e.pageSize*(e.page-1),e.pageSize*e.page))},e.changePageSize=function(t){$(".ot-graph-page-size").removeClass("active"),e.page=1,t&&(e.pageSize=t,e.changePagination()),e.filteredGraphs&&""!==e.exportFilter&&(e.displayGraphs=e.filteredGraphs)},e.checkAll=function(){e.selectedAll=e.selectedAll||!1,angular.forEach(e.displayGraphs,(function(t){t.contextID.uri&&(e.selectedGraphs.exportGraphs[t.contextID.value]=e.selectedAll)}))},e.deselectAll=function(){e.selectedAll=!1,angular.forEach(e.displayGraphs,(function(t){t.contextID.uri&&(e.selectedGraphs.exportGraphs[t.contextID.value]=!1)}))},e.dropRepository=function(){e.canWriteActiveRepo()&&(e.deleting["*"]=!0,i.openSimpleModal({title:d.instant("export.confirm.clear.msg"),message:d.instant("export.warning.clear.repo.msg",{repo:p.getActiveRepository()}),warning:!0}).result.then((function(){a((function(){c.addStatements(p.getActiveRepository(),"update=CLEAR ALL").then((function(){e.deleting["*"]=!1,l.success(d.instant("export.cleared.repo",{repo:p.getActiveRepository()})),e.getGraphs()}),(function(t){e.deleting["*"]=!1;const n=t.data;"string"==typeof n&&n.indexOf("Clearing all statements in the repository is incompatible with collecting history")>-1?l.error(d.instant("export.clearing.statements.warning")):l.error(d.instant("export.cleared.repo.failed.msg",{repo:p.getActiveRepository()}),t)}))}),100)})))},e.dropContext=function(t){e.canWriteActiveRepo()&&(angular.isDefined(t)?function(t){const n=t.contextID.longName;e.deleting[t]=!0,i.openSimpleModal({title:d.instant("export.confirm.clear.graph"),message:d.instant("export.clear.graph.warning",{longName:n}),warning:!0}).result.then((function(){a((function(){const o="update=CLEAR "+t.contextID.clearUri;c.addStatements(p.getActiveRepository(),o).then((function(){e.deleting[t]=!1,l.success(d.instant("export.cleared.graph",{longName:n})),e.getGraphs(),e.exportFilter="",e.filteredGraphs.length=0,e.updateResults(),e.changePageSize(e.pageSize)}),(function(o){e.deleting[t]=!1,l.error(d.instant("export.clear.graph.msg",{longName:n}),getError(o,o.status))}))}),100)}),(function(){e.deleting[t]=!1}))}(t):function(t){const n=[];angular.forEach(e.selectedGraphs.exportGraphs,(function(e,t){e&&n.push(t)})),n.length>0&&(e.deleting[t]=!0,i.openSimpleModal({title:d.instant("export.confirm.clear.graph"),message:d.instant("export.warning.clear.graph.msg"),warning:!0}).result.then((function(){a((function(){let t=0;angular.forEach(n,(function(o){const r="update=CLEAR "+e.graphsByValue[o].clearUri;c.addStatements(p.getActiveRepository(),r).then((function(){e.loader=!0,e.selectedGraphs.exportGraphs[o]=!1,delete e.selectedGraphs.exportGraphs[o],t++,n.length===t&&(e.selectedAll=!1,e.exportFilter="",e.filteredGraphs.length=0,e.getGraphs(),e.updateResults(),e.changePageSize(e.pageSize),l.success(d.instant("export.cleared.graph.msg")),e.loader=!1)}),(function(t){const n=e.graphsByValue[o].longName;l.error(d.instant("export.clear.graph.msg",{longName:n}),getError(t,t.status)),e.selectedAll=!1}))}))}),100)}),(function(){e.deleting[t]=!1})))}(t))}}])}}]);
1
+ (window.webpackJsonp=window.webpackJsonp||[]).push([[46,153],{81:function(e,t){angular.module("graphdb.workbench.utils.filetypes",[]).value("FileTypes",[{name:"JSON",type:"application/rdf+json",extension:".json"},{name:"JSON-LD",type:"application/ld+json",extension:".jsonld"},{name:"RDF-XML",type:"application/rdf+xml",extension:".rdf"},{name:"N3",type:"text/rdf+n3",extension:".n3"},{name:"N-Triples",type:"text/plain",extension:".nt"},{name:"N-Quads",type:"text/x-nquads",extension:".nq"},{name:"Turtle",type:"text/turtle",extension:".ttl"},{name:"Turtle*",type:"application/x-turtlestar",extension:".ttls"},{name:"TriX",type:"application/trix",extension:".trix"},{name:"TriG",type:"application/x-trig",extension:".trig"},{name:"TriG*",type:"application/x-trigstar",extension:".trigs"},{name:"Binary RDF",type:"application/x-binary-rdf",extension:".brf"}])},98:function(e,t,n){"use strict";n.r(t);n(7),n(22),n(24),n(81);var o=n(0),r=n(85);angular.module("graphdb.framework.impex.export.controllers",["ngCookies","ui.bootstrap","toastr","graphdb.framework.core.services.repositories","graphdb.framework.core.services.jwtauth","graphdb.workbench.utils.filetypes"]).controller("ExportCtrl",["$scope","$http","$location","$timeout","ModalService","filterFilter","$repositories","toastr","RDF4JRepositoriesRestService","FileTypes","$translate","AuthTokenService",function(e,t,n,a,i,s,p,l,c,g,d,u){e.getActiveRepository=function(){return p.getActiveRepository()},e.exportFormats=g,e.deleting={},e.showExportDDTooltip=!0,e.page=1,e.pageSize=10,e.pageSizeOptions=[10,20,50,100],e.displayGraphs=[],e.exportFilter="",e.export=!0,e.exportMultipleGraphs=!1,e.repoExportFormat={name:"TriG",type:"application/x-trig",extension:".trig"},e.selectedGraphs={exportGraphs:{}},e.$watch((function(){return p.getActiveRepository()}),(function(){e.exportFilter="",e.getGraphs(),e.selectedAll=!1,a((function(){e.changePageSize(10)}),100)})),e.isShacl=function(e){return"http%3A%2F%2Frdf4j.org%2Fschema%2Frdf4j%23SHACLShapeGraph"===e},e.getGraphs=function(){e.getActiveRepository()?(e.loader=!0,c.getGraphs(e.getActiveRepository()).success((function(t){t.results.bindings.unshift({contextID:{type:"default",value:"import.default.graph"}}),e.graphsByValue={},Object.keys(t.results.bindings).forEach((function(n){const o=t.results.bindings[n];"bnode"===o.contextID.type?o.contextID.value="_:"+o.contextID.value:"default"===o.contextID.type?(o.contextID.uri=encodeURIComponent("http://www.openrdf.org/schema/sesame#nil"),o.contextID.clearUri="DEFAULT",o.contextID.exportUri="null",o.contextID.longName="default graph"):(o.contextID.uri=encodeURIComponent(o.contextID.value),o.contextID.clearUri="GRAPH <"+o.contextID.value+">",o.contextID.exportUri=encodeURIComponent("<"+o.contextID.value+">"),o.contextID.longName="named graph "+o.contextID.value),e.graphsByValue[o.contextID.value]=o.contextID})),e.graphs=t.results.bindings,e.filteredGraphs=Object(r.cloneDeep)(e.graphs),e.displayGraphs=e.filteredGraphs.slice(e.pageSize*(e.page-1),e.pageSize*e.page),e.loader=!1,e.selectedGraphs.exportGraphs={},e.matchedElements=e.graphs})).error((function(t,n){const o=getError(t,n);"There is no active location!"===o&&(p.setRepository(""),l.error(o,d.instant("common.error"))),e.loader=!1}))):e.loader=!1},e.onGraphSearch=function(){e.matchedElements=[],e.deselectAll(),e.filterResults()},e.filterResults=function(){angular.forEach(e.graphs,(function(t){-1!==t.contextID.value.indexOf(e.exportFilter)&&e.matchedElements.push(t)}))},e.downloadExport=function(e,t){let n=e+"&Accept="+encodeURIComponent(t.type);const o=u.getAuthToken();o&&(n=n+"&authToken="+encodeURIComponent(o));let r=window.open(n);a((function(){"about:blank"!==r.document.location.href&&(r.close(),l.error("Could not export graph. Check GraphDB logs for detailed reason."))}),100)},e.openExportDDTooltip=function(){e.showExportDDTooltip&&(a((function(){$("#tooltipTarget").trigger("showExportDDTooltip")}),0),a((function(){$("#tooltipTarget").trigger("showExportDDTooltip")}),3e3),e.showExportDDTooltip=!1)},e.exportRepo=function(t,n){"application/rdf+xml"===t.type||"text/plain"===t.type||"text/turtle"===t.type||"application/x-turtlestar"===t.type||"text/rdf+n3"===t.type?i.openSimpleModal({title:d.instant("common.warning"),message:Object(o.decodeHTML)(d.instant("export.format.warning.msg")),warning:!0}).result.then((function(){e.startDownload(t,n)})):e.startDownload(t,n)},e.startDownload=function(t,n){let o;const r=p.getActiveRepositoryObject();o=n?`repositories/${r.id}/statements?infer=false&context=${e.graphsByValue[n.value].exportUri}&location=${encodeURIComponent(r.location)}`:`repositories/${r.id}/statements?infer=false&location=${encodeURIComponent(r.location)}`,e.downloadExport(o,t)},e.hasMultipleSelected=function(){if(_.isEmpty(e.selectedGraphs.exportGraphs))return!_.isEmpty(e.selectedGraphs.exportGraphs);for(const t in e.selectedGraphs.exportGraphs)if(!0===e.selectedGraphs.exportGraphs[t])return!0;return!1},e.exportSelectedGraphs=function(t){let n="";for(const t in e.selectedGraphs.exportGraphs)e.selectedGraphs.exportGraphs[t]&&(n+="context="+e.graphsByValue[t].exportUri+"&");if(n){const r=function(){n=n.substring(0,n.length-1);const o="repositories/"+e.getActiveRepository()+"/statements?infer=false&"+n;e.downloadExport(o,t)};"application/rdf+xml"===t.type||"text/plain"===t.type||"text/turtle"===t.type||"application/x-turtlestar"===t.type||"text/rdf+n3"===t.type?i.openSimpleModal({title:d.instant("common.warning"),message:Object(o.decodeHTML)(d.instant("export.format.warning.msg")),warning:!0}).result.then((function(){r()})):r()}else i.openSimpleModal({title:d.instant("export.multiple.graph"),message:d.instant("export.check.graphs.msg"),warning:!0})},e.$watch("exportFilter",(function(){if(e.filteredGraphs=s(e.graphs,e.exportFilter),e.getActiveRepository()&&angular.element(document).find(".btn.btn-secondary.btn-sm.dropdown-toggle span").length){const t=angular.element(document).find(".btn.btn-secondary.btn-sm.dropdown-toggle span")[0].innerHTML.trim();let n;"All"===t&&(n=e.filteredGraphs.length),e.filteredGraphs&&e.filteredGraphs.length>e.pageSize&&"All"!==t&&(n=e.pageSize),e.changePageSize(n),e.changePagination()}})),e.changePagination=function(){e.selectedAll=!1,angular.isDefined(e.filteredGraphs)&&(e.displayGraphs=e.filteredGraphs.slice(e.pageSize*(e.page-1),e.pageSize*e.page))},e.changePageSize=function(t){$(".ot-graph-page-size").removeClass("active"),e.page=1,t&&(e.pageSize=t,e.changePagination()),e.filteredGraphs&&""!==e.exportFilter&&(e.displayGraphs=e.filteredGraphs)},e.checkAll=function(){e.selectedAll=e.selectedAll||!1,angular.forEach(e.displayGraphs,(function(t){t.contextID.uri&&(e.selectedGraphs.exportGraphs[t.contextID.value]=e.selectedAll)}))},e.deselectAll=function(){e.selectedAll=!1,angular.forEach(e.displayGraphs,(function(t){t.contextID.uri&&(e.selectedGraphs.exportGraphs[t.contextID.value]=!1)}))},e.dropRepository=function(){e.canWriteActiveRepo()&&(e.deleting["*"]=!0,i.openSimpleModal({title:d.instant("export.confirm.clear.msg"),message:d.instant("export.warning.clear.repo.msg",{repo:p.getActiveRepository()}),warning:!0}).result.then((function(){a((function(){c.addStatements(p.getActiveRepository(),"update=CLEAR ALL").then((function(){e.deleting["*"]=!1,l.success(d.instant("export.cleared.repo",{repo:p.getActiveRepository()})),e.getGraphs()}),(function(t){e.deleting["*"]=!1;const n=t.data;"string"==typeof n&&n.indexOf("Clearing all statements in the repository is incompatible with collecting history")>-1?l.error(d.instant("export.clearing.statements.warning")):l.error(d.instant("export.cleared.repo.failed.msg",{repo:p.getActiveRepository()}),t)}))}),100)})))},e.dropContext=function(t){e.canWriteActiveRepo()&&(angular.isDefined(t)?function(t){const n=t.contextID.longName;e.deleting[t]=!0,i.openSimpleModal({title:d.instant("export.confirm.clear.graph"),message:d.instant("export.clear.graph.warning",{longName:n}),warning:!0}).result.then((function(){a((function(){const o="update=CLEAR "+t.contextID.clearUri;c.addStatements(p.getActiveRepository(),o).then((function(){e.deleting[t]=!1,l.success(d.instant("export.cleared.graph",{longName:n})),e.getGraphs(),e.exportFilter="",e.filteredGraphs.length=0,e.updateResults(),e.changePageSize(e.pageSize)}),(function(o){e.deleting[t]=!1,l.error(d.instant("export.clear.graph.msg",{longName:n}),getError(o,o.status))}))}),100)}),(function(){e.deleting[t]=!1}))}(t):function(t){const n=[];angular.forEach(e.selectedGraphs.exportGraphs,(function(e,t){e&&n.push(t)})),n.length>0&&(e.deleting[t]=!0,i.openSimpleModal({title:d.instant("export.confirm.clear.graph"),message:d.instant("export.warning.clear.graph.msg"),warning:!0}).result.then((function(){a((function(){let t=0;angular.forEach(n,(function(o){const r="update=CLEAR "+e.graphsByValue[o].clearUri;c.addStatements(p.getActiveRepository(),r).then((function(){e.loader=!0,e.selectedGraphs.exportGraphs[o]=!1,delete e.selectedGraphs.exportGraphs[o],t++,n.length===t&&(e.selectedAll=!1,e.exportFilter="",e.filteredGraphs.length=0,e.getGraphs(),e.updateResults(),e.changePageSize(e.pageSize),l.success(d.instant("export.cleared.graph.msg")),e.loader=!1)}),(function(t){const n=e.graphsByValue[o].longName;l.error(d.instant("export.clear.graph.msg",{longName:n}),getError(t,t.status)),e.selectedAll=!1}))}))}),100)}),(function(){e.deleting[t]=!1})))}(t))}}])}}]);