graphdb-workbench 2.2.2-TR2 → 2.3.0-TR1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/10.2c7c4caeb5771a2a98d1.bundle.js +2 -0
- package/dist/10.2c7c4caeb5771a2a98d1.bundle.js.map +1 -0
- package/dist/102.850f372bb910e3a64905.bundle.js +2 -0
- package/dist/102.850f372bb910e3a64905.bundle.js.map +1 -0
- package/dist/104.2e04965e98d05ada03fd.bundle.js +2 -0
- package/dist/104.2e04965e98d05ada03fd.bundle.js.map +1 -0
- package/dist/{107.37693ea0237c39fda863.bundle.js → 107.e401af35eca7e21cc9c2.bundle.js} +2 -2
- package/dist/107.e401af35eca7e21cc9c2.bundle.js.map +1 -0
- package/dist/{108.3c3f9c242e6a3e18fff5.bundle.js → 108.90cf8908233ccb473643.bundle.js} +2 -2
- package/dist/108.90cf8908233ccb473643.bundle.js.map +1 -0
- package/dist/{11.f4c5533cd200c8568ff6.bundle.js → 11.f912f1a9f37160d23a3b.bundle.js} +2 -2
- package/dist/11.f912f1a9f37160d23a3b.bundle.js.map +1 -0
- package/dist/{124.6a31dfbe4ac2f9064a29.bundle.js → 124.82728aea87e9d1190441.bundle.js} +2 -2
- package/dist/124.82728aea87e9d1190441.bundle.js.map +1 -0
- package/dist/{126.48e00b0525b3ef8efbe8.bundle.js → 126.d21b0bf850be03830298.bundle.js} +2 -2
- package/dist/126.d21b0bf850be03830298.bundle.js.map +1 -0
- package/dist/140.08e0e8799d3d5fefcda5.bundle.js +2 -0
- package/dist/140.08e0e8799d3d5fefcda5.bundle.js.map +1 -0
- package/dist/141.c16968e963be850e7a7b.bundle.js +2 -0
- package/dist/141.c16968e963be850e7a7b.bundle.js.map +1 -0
- package/dist/142.0204215ce1bf7b2cf84d.bundle.js +2 -0
- package/dist/142.0204215ce1bf7b2cf84d.bundle.js.map +1 -0
- package/dist/143.c194ab0648b274f3b554.bundle.js +2 -0
- package/dist/143.c194ab0648b274f3b554.bundle.js.map +1 -0
- package/dist/145.828376c0cb6b5ba6e015.bundle.js +2 -0
- package/dist/145.828376c0cb6b5ba6e015.bundle.js.map +1 -0
- package/dist/146.581f1af823b55dc358d6.bundle.js +2 -0
- package/dist/146.581f1af823b55dc358d6.bundle.js.map +1 -0
- package/dist/147.66395fd5d79176a79c38.bundle.js +2 -0
- package/dist/147.66395fd5d79176a79c38.bundle.js.map +1 -0
- package/dist/{148.dd250d3cc5aafade33c6.bundle.js → 148.78e7398de964231883f3.bundle.js} +2 -2
- package/dist/{148.dd250d3cc5aafade33c6.bundle.js.map → 148.78e7398de964231883f3.bundle.js.map} +1 -1
- package/dist/{149.a0873076f2dd40830be9.bundle.js → 149.6eb6ef704b8da7bfc6ce.bundle.js} +2 -2
- package/dist/{149.a0873076f2dd40830be9.bundle.js.map → 149.6eb6ef704b8da7bfc6ce.bundle.js.map} +1 -1
- package/dist/{150.3bd8af24551408342185.bundle.js → 150.283dd1f6da002f1ca17f.bundle.js} +2 -2
- package/dist/{150.3bd8af24551408342185.bundle.js.map → 150.283dd1f6da002f1ca17f.bundle.js.map} +1 -1
- package/dist/154.056ec5c8aafbc07484e0.bundle.js +2 -0
- package/dist/154.056ec5c8aafbc07484e0.bundle.js.map +1 -0
- package/dist/156.e15f9befbcfaf6677387.bundle.js +2 -0
- package/dist/156.e15f9befbcfaf6677387.bundle.js.map +1 -0
- package/dist/158.29813ed563736e5c85b2.bundle.js +2 -0
- package/dist/158.29813ed563736e5c85b2.bundle.js.map +1 -0
- package/dist/16.b8bb2389b9f026a298f7.bundle.js +3 -0
- package/dist/16.b8bb2389b9f026a298f7.bundle.js.map +1 -0
- package/dist/160.d5f5ab14c56efd04e404.bundle.js +2 -0
- package/dist/160.d5f5ab14c56efd04e404.bundle.js.map +1 -0
- package/dist/161.f142c1fe18346f00882a.bundle.js +2 -0
- package/dist/161.f142c1fe18346f00882a.bundle.js.map +1 -0
- package/dist/164.d4b744057d28ed5e7e47.bundle.js +2 -0
- package/dist/164.d4b744057d28ed5e7e47.bundle.js.map +1 -0
- package/dist/166.256169db442fec472d9d.bundle.js +2 -0
- package/dist/166.256169db442fec472d9d.bundle.js.map +1 -0
- package/dist/167.f79a82f7de6734cca660.bundle.js +2 -0
- package/dist/167.f79a82f7de6734cca660.bundle.js.map +1 -0
- package/dist/169.16292782069da22a11c0.bundle.js +2 -0
- package/dist/169.16292782069da22a11c0.bundle.js.map +1 -0
- package/dist/17.675eef636eb095240fab.bundle.js +2 -0
- package/dist/17.675eef636eb095240fab.bundle.js.map +1 -0
- package/dist/171.2aecfe97c1fa24db3bf3.bundle.js +2 -0
- package/dist/171.2aecfe97c1fa24db3bf3.bundle.js.map +1 -0
- package/dist/172.558d9080f05080a0dac2.bundle.js +2 -0
- package/dist/172.558d9080f05080a0dac2.bundle.js.map +1 -0
- package/dist/173.c1546a02befda215609d.bundle.js +2 -0
- package/dist/173.c1546a02befda215609d.bundle.js.map +1 -0
- package/dist/175.943ac5019fe29113e1f2.bundle.js +2 -0
- package/dist/175.943ac5019fe29113e1f2.bundle.js.map +1 -0
- package/dist/176.96a2ffd87018134c7b29.bundle.js +2 -0
- package/dist/176.96a2ffd87018134c7b29.bundle.js.map +1 -0
- package/dist/177.443034c31f85d8ac396c.bundle.js +2 -0
- package/dist/177.443034c31f85d8ac396c.bundle.js.map +1 -0
- package/dist/180.384be4faad5d0b1716b5.bundle.js +2 -0
- package/dist/180.384be4faad5d0b1716b5.bundle.js.map +1 -0
- package/dist/181.ce536d7a1f4cb278f82c.bundle.js +2 -0
- package/dist/181.ce536d7a1f4cb278f82c.bundle.js.map +1 -0
- package/dist/182.6154b3558b619301bfdf.bundle.js +2 -0
- package/dist/{182.1b40c7e8a8424e87da32.bundle.js.map → 182.6154b3558b619301bfdf.bundle.js.map} +1 -1
- package/dist/183.67e81437028990463d1a.bundle.js +2 -0
- package/dist/183.67e81437028990463d1a.bundle.js.map +1 -0
- package/dist/20.fbcb31706f03a07e8827.bundle.js +1 -1
- package/dist/20.fbcb31706f03a07e8827.bundle.js.map +1 -1
- package/dist/21.081b98fe7cc1b3dbbd72.bundle.js +2 -0
- package/dist/21.081b98fe7cc1b3dbbd72.bundle.js.map +1 -0
- package/dist/{23.b945d0565ded44df49c5.bundle.js → 23.24787bc4590d48521f4b.bundle.js} +2 -2
- package/dist/23.24787bc4590d48521f4b.bundle.js.map +1 -0
- package/dist/24.7468162b4988a0ad6eaa.bundle.js +2 -0
- package/dist/24.7468162b4988a0ad6eaa.bundle.js.map +1 -0
- package/dist/{25.9d7a3d8f98840b1fc5da.bundle.js → 25.64b95438d07ae2d82d8c.bundle.js} +2 -2
- package/dist/25.64b95438d07ae2d82d8c.bundle.js.map +1 -0
- package/dist/{26.a15a1adb6b30ab849e62.bundle.js → 26.7b0b040185949c4eb865.bundle.js} +2 -2
- package/dist/26.7b0b040185949c4eb865.bundle.js.map +1 -0
- package/dist/{27.83b24ef9ec0fd6964d92.bundle.js → 27.78b1f59da6f702484766.bundle.js} +2 -2
- package/dist/27.78b1f59da6f702484766.bundle.js.map +1 -0
- package/dist/{3.7f19eec4e1cff6bb8ff2.bundle.js → 3.9b969c666ea9ed46ea4f.bundle.js} +2 -2
- package/dist/3.9b969c666ea9ed46ea4f.bundle.js.map +1 -0
- package/dist/{30.a2596e679fb09411b854.bundle.js → 30.67e342e8f1485d26a99b.bundle.js} +2 -2
- package/dist/30.67e342e8f1485d26a99b.bundle.js.map +1 -0
- package/dist/31.133397ed26eda58c7e18.bundle.js +2 -0
- package/dist/31.133397ed26eda58c7e18.bundle.js.map +1 -0
- package/dist/33.4d23fa109c9184727386.bundle.js +1 -1
- package/dist/33.4d23fa109c9184727386.bundle.js.map +1 -1
- package/dist/{35.8be1042671722a19f3b4.bundle.js → 35.541a97f880621d5f7031.bundle.js} +2 -2
- package/dist/35.541a97f880621d5f7031.bundle.js.map +1 -0
- package/dist/36.239dd56c03aeda760f8b.bundle.js +2 -0
- package/dist/36.239dd56c03aeda760f8b.bundle.js.map +1 -0
- package/dist/{38.f4b561d7ee5b236ba481.bundle.js → 38.c8620e7cbab859b6f236.bundle.js} +2 -2
- package/dist/38.c8620e7cbab859b6f236.bundle.js.map +1 -0
- package/dist/39.c630c0e36b0dc913bbe3.bundle.js +2 -0
- package/dist/39.c630c0e36b0dc913bbe3.bundle.js.map +1 -0
- package/dist/{4.186c084105c931abbe1a.bundle.js → 4.d3fb6d0dcca79643bcb3.bundle.js} +2 -2
- package/dist/4.d3fb6d0dcca79643bcb3.bundle.js.map +1 -0
- package/dist/40.50b40301c8cc69a70457.bundle.js +1 -1
- package/dist/40.50b40301c8cc69a70457.bundle.js.map +1 -1
- package/dist/42.45ee7b629beac3e06cc2.bundle.js +2 -0
- package/dist/42.45ee7b629beac3e06cc2.bundle.js.map +1 -0
- package/dist/43.72fbe7e5d290c40db9ec.bundle.js +2 -0
- package/dist/43.72fbe7e5d290c40db9ec.bundle.js.map +1 -0
- package/dist/{5.5f48e5c6fc10b52dd415.bundle.js → 5.a44aa21343f8bf48f0e0.bundle.js} +2 -2
- package/dist/5.a44aa21343f8bf48f0e0.bundle.js.map +1 -0
- package/dist/{53.78084dd64a27f7a6d2e8.bundle.js → 53.c6d488d0fb81a54a3e55.bundle.js} +2 -2
- package/dist/53.c6d488d0fb81a54a3e55.bundle.js.map +1 -0
- package/dist/{54.fe5e554af6ba2c5778c1.bundle.js → 54.6209da75289a30ff366b.bundle.js} +2 -2
- package/dist/54.6209da75289a30ff366b.bundle.js.map +1 -0
- package/dist/{56.9c6f6ecafc1909c42dda.bundle.js → 56.0d89e5b9f6403aab1c8e.bundle.js} +2 -2
- package/dist/56.0d89e5b9f6403aab1c8e.bundle.js.map +1 -0
- package/dist/61.6332e06d94ef4426f068.bundle.js +2 -0
- package/dist/61.6332e06d94ef4426f068.bundle.js.map +1 -0
- package/dist/{62.86f5ed4f7b582a8aa17d.bundle.js → 62.14d5882e16c3da266b6f.bundle.js} +2 -2
- package/dist/62.14d5882e16c3da266b6f.bundle.js.map +1 -0
- package/dist/{7.c7d8fb1dfdb444052435.bundle.js → 7.8ca1f2ef4d0aa49b93ac.bundle.js} +2 -2
- package/dist/7.8ca1f2ef4d0aa49b93ac.bundle.js.map +1 -0
- package/dist/{71.4dbbc366049697f736c5.bundle.js → 71.48a75ab912070cdb19f5.bundle.js} +2 -2
- package/dist/71.48a75ab912070cdb19f5.bundle.js.map +1 -0
- package/dist/9.3b571539df8c3b22cf6e.bundle.js +2 -0
- package/dist/9.3b571539df8c3b22cf6e.bundle.js.map +1 -0
- package/dist/94.38349f52df66313fbcc0.bundle.js +1 -1
- package/dist/94.38349f52df66313fbcc0.bundle.js.map +1 -1
- package/dist/97.df243fffeb4322e50f63.bundle.js +2 -0
- package/dist/97.df243fffeb4322e50f63.bundle.js.map +1 -0
- package/dist/bundle.73c02a0d535f14462730.bundle.js +92 -0
- package/dist/bundle.73c02a0d535f14462730.bundle.js.map +1 -0
- package/dist/index.html +7 -7
- package/dist/js/angular/clustermanagement/templates/modal/add-nodes-dialog.html +2 -2
- package/dist/js/angular/clustermanagement/templates/modal/cluster-create-dialog.html +8 -8
- package/dist/js/angular/clustermanagement/templates/modal/cluster-delete-dialog.html +1 -1
- package/dist/js/angular/clustermanagement/templates/modal/cluster-edit-dialog.html +5 -5
- package/dist/js/angular/core/directives/languageselector/templates/languageSelector.html +2 -2
- package/dist/js/angular/core/directives/queryeditor/templates/query-editor.html +19 -19
- package/dist/js/angular/core/directives/queryeditor/templates/query-sample.html +1 -1
- package/dist/js/angular/core/directives/rdfresourcesearch/templates/rdfResourceSearchTemplate.html +3 -3
- package/dist/js/angular/core/templates/core-errors.html +1 -1
- package/dist/js/angular/core/templates/inactive-plugin-warning-page.html +1 -1
- package/dist/js/angular/core/templates/search-resource-input.html +3 -3
- package/dist/js/angular/externalsync/templates/deleteConnector.html +1 -1
- package/dist/js/angular/graphexplore/templates/modal/save-graph.html +1 -1
- package/dist/js/angular/graphexplore/templates/rdfsCommentLabelTemplate.html +2 -2
- package/dist/js/angular/graphexplore/templates/searchIconInputTemplate.html +3 -3
- package/dist/js/angular/import/templates/filesTable.html +12 -12
- package/dist/js/angular/import/templates/settingsModal.html +19 -19
- package/dist/js/angular/import/templates/textSnippet.html +4 -4
- package/dist/js/angular/import/templates/urlImport.html +4 -4
- package/dist/js/angular/repositories/templates/fedx-repo.html +15 -15
- package/dist/js/angular/repositories/templates/ontop-repo.html +8 -8
- package/dist/js/angular/security/templates/modal/default-authorities.html +2 -2
- package/dist/js/angular/security/templates/user.html +13 -13
- package/dist/js/angular/security/templates/users.html +8 -8
- package/dist/js/angular/settings/modal/location-settings.html +1 -1
- package/dist/js/angular/templates/modal/add-location.html +3 -3
- package/dist/js/angular/templates/modal/edit-location.html +3 -3
- package/dist/js/angular/templates/modal/editRepoFile.html +1 -1
- package/dist/js/angular/templates/modal/upload-repository-config.html +2 -2
- package/dist/pages/autocomplete.html +8 -8
- package/dist/pages/choose-repository-type.html +1 -1
- package/dist/pages/cluster-management/clusterInfo.html +15 -15
- package/dist/pages/connectorsInfo.html +5 -5
- package/dist/pages/create-index.html +15 -15
- package/dist/pages/createConnector.html +23 -23
- package/dist/pages/dependencies.html +12 -12
- package/dist/pages/domainRangeInfo.html +6 -6
- package/dist/pages/edit.html +7 -7
- package/dist/pages/explore.html +10 -10
- package/dist/pages/export.html +14 -14
- package/dist/pages/find.html +2 -2
- package/dist/pages/graph-config/saveGraphConfig.html +22 -22
- package/dist/pages/graphs-visualizations.html +47 -47
- package/dist/pages/guides.html +6 -6
- package/dist/pages/home.html +10 -10
- package/dist/pages/import.html +7 -7
- package/dist/pages/info.html +16 -16
- package/dist/pages/jdbc-create.html +18 -18
- package/dist/pages/jdbc.html +3 -3
- package/dist/pages/licenseInfo.html +1 -1
- package/dist/pages/login.html +2 -2
- package/dist/pages/monitor/queries.html +5 -5
- package/dist/pages/monitor/resources.html +13 -13
- package/dist/pages/namespaces.html +14 -14
- package/dist/pages/plugins.html +4 -4
- package/dist/pages/rdfClassHierarchyInfo.html +16 -16
- package/dist/pages/rdfrank.html +17 -17
- package/dist/pages/registerLicenseInfo.html +3 -3
- package/dist/pages/repositories.html +20 -20
- package/dist/pages/repository.html +37 -37
- package/dist/pages/similarity-indexes.html +15 -15
- package/dist/pages/sparql-template-create.html +9 -9
- package/dist/pages/sparql-templates.html +3 -3
- package/dist/pages/sparql.html +8 -8
- package/dist/pages/webapi.html +3 -3
- package/dist/res/swagger/index.html +27 -27
- package/package.json +2 -2
- package/dist/10.973caeed3c05ef2cfd1c.bundle.js +0 -2
- package/dist/10.973caeed3c05ef2cfd1c.bundle.js.map +0 -1
- package/dist/102.93af0905ca1ff2be2dbf.bundle.js +0 -2
- package/dist/102.93af0905ca1ff2be2dbf.bundle.js.map +0 -1
- package/dist/104.b82229ea4c12400f6f5d.bundle.js +0 -2
- package/dist/104.b82229ea4c12400f6f5d.bundle.js.map +0 -1
- package/dist/107.37693ea0237c39fda863.bundle.js.map +0 -1
- package/dist/108.3c3f9c242e6a3e18fff5.bundle.js.map +0 -1
- package/dist/11.f4c5533cd200c8568ff6.bundle.js.map +0 -1
- package/dist/124.6a31dfbe4ac2f9064a29.bundle.js.map +0 -1
- package/dist/126.48e00b0525b3ef8efbe8.bundle.js.map +0 -1
- package/dist/140.8f22a20a0689c072368f.bundle.js +0 -2
- package/dist/140.8f22a20a0689c072368f.bundle.js.map +0 -1
- package/dist/141.6ffbf225a69b845e5e07.bundle.js +0 -2
- package/dist/141.6ffbf225a69b845e5e07.bundle.js.map +0 -1
- package/dist/142.355ab1a9716ce7315ad6.bundle.js +0 -2
- package/dist/142.355ab1a9716ce7315ad6.bundle.js.map +0 -1
- package/dist/143.64b1142c8e48b388717f.bundle.js +0 -2
- package/dist/143.64b1142c8e48b388717f.bundle.js.map +0 -1
- package/dist/145.9858a584e01b6c01a57c.bundle.js +0 -2
- package/dist/145.9858a584e01b6c01a57c.bundle.js.map +0 -1
- package/dist/146.15a2396be0b56a454857.bundle.js +0 -2
- package/dist/146.15a2396be0b56a454857.bundle.js.map +0 -1
- package/dist/147.638cfbfdf711a97e19f1.bundle.js +0 -2
- package/dist/147.638cfbfdf711a97e19f1.bundle.js.map +0 -1
- package/dist/154.6dadeaa5b9cdab265cb3.bundle.js +0 -2
- package/dist/154.6dadeaa5b9cdab265cb3.bundle.js.map +0 -1
- package/dist/156.4252f16fc656c91fba0c.bundle.js +0 -2
- package/dist/156.4252f16fc656c91fba0c.bundle.js.map +0 -1
- package/dist/158.13d4aafb2c7f02af028b.bundle.js +0 -2
- package/dist/158.13d4aafb2c7f02af028b.bundle.js.map +0 -1
- package/dist/16.61454b9a7360266e544a.bundle.js +0 -3
- package/dist/16.61454b9a7360266e544a.bundle.js.map +0 -1
- package/dist/160.3b604e0909b8a932d959.bundle.js +0 -2
- package/dist/160.3b604e0909b8a932d959.bundle.js.map +0 -1
- package/dist/161.c72cc3169ea1191e49e8.bundle.js +0 -2
- package/dist/161.c72cc3169ea1191e49e8.bundle.js.map +0 -1
- package/dist/164.a03f4da227b54ad97c18.bundle.js +0 -2
- package/dist/164.a03f4da227b54ad97c18.bundle.js.map +0 -1
- package/dist/166.b4fd0bd3df4985d3e74a.bundle.js +0 -2
- package/dist/166.b4fd0bd3df4985d3e74a.bundle.js.map +0 -1
- package/dist/167.0e3773d3b16936a2a72a.bundle.js +0 -2
- package/dist/167.0e3773d3b16936a2a72a.bundle.js.map +0 -1
- package/dist/169.a43d9e76a361ad2cabb5.bundle.js +0 -2
- package/dist/169.a43d9e76a361ad2cabb5.bundle.js.map +0 -1
- package/dist/17.545bc1027c226502e3b8.bundle.js +0 -2
- package/dist/17.545bc1027c226502e3b8.bundle.js.map +0 -1
- package/dist/171.584fa763e2fe9a4d34f4.bundle.js +0 -2
- package/dist/171.584fa763e2fe9a4d34f4.bundle.js.map +0 -1
- package/dist/172.67ba9379059ac602d509.bundle.js +0 -2
- package/dist/172.67ba9379059ac602d509.bundle.js.map +0 -1
- package/dist/173.fd7ee2abdf75fc0ed3a3.bundle.js +0 -2
- package/dist/173.fd7ee2abdf75fc0ed3a3.bundle.js.map +0 -1
- package/dist/175.341ea8612291026d2630.bundle.js +0 -2
- package/dist/175.341ea8612291026d2630.bundle.js.map +0 -1
- package/dist/176.7cdff30cd9372f424163.bundle.js +0 -2
- package/dist/176.7cdff30cd9372f424163.bundle.js.map +0 -1
- package/dist/177.57ac19484b6430c0f242.bundle.js +0 -2
- package/dist/177.57ac19484b6430c0f242.bundle.js.map +0 -1
- package/dist/180.f19924b6b550773f9163.bundle.js +0 -2
- package/dist/180.f19924b6b550773f9163.bundle.js.map +0 -1
- package/dist/181.db05a22a05f9c928b08c.bundle.js +0 -2
- package/dist/181.db05a22a05f9c928b08c.bundle.js.map +0 -1
- package/dist/182.1b40c7e8a8424e87da32.bundle.js +0 -2
- package/dist/183.1ed57fba52ab51806ec3.bundle.js +0 -2
- package/dist/183.1ed57fba52ab51806ec3.bundle.js.map +0 -1
- package/dist/21.ea150df1291050bc1c4a.bundle.js +0 -2
- package/dist/21.ea150df1291050bc1c4a.bundle.js.map +0 -1
- package/dist/23.b945d0565ded44df49c5.bundle.js.map +0 -1
- package/dist/24.77907cc1d707305663c9.bundle.js +0 -2
- package/dist/24.77907cc1d707305663c9.bundle.js.map +0 -1
- package/dist/25.9d7a3d8f98840b1fc5da.bundle.js.map +0 -1
- package/dist/26.a15a1adb6b30ab849e62.bundle.js.map +0 -1
- package/dist/27.83b24ef9ec0fd6964d92.bundle.js.map +0 -1
- package/dist/3.7f19eec4e1cff6bb8ff2.bundle.js.map +0 -1
- package/dist/30.a2596e679fb09411b854.bundle.js.map +0 -1
- package/dist/31.fbcd8b1840a84a281e47.bundle.js +0 -2
- package/dist/31.fbcd8b1840a84a281e47.bundle.js.map +0 -1
- package/dist/35.8be1042671722a19f3b4.bundle.js.map +0 -1
- package/dist/36.8d7becdfce12d9a0de33.bundle.js +0 -2
- package/dist/36.8d7becdfce12d9a0de33.bundle.js.map +0 -1
- package/dist/38.f4b561d7ee5b236ba481.bundle.js.map +0 -1
- package/dist/39.68f59c2a9aeb4c4100c9.bundle.js +0 -2
- package/dist/39.68f59c2a9aeb4c4100c9.bundle.js.map +0 -1
- package/dist/4.186c084105c931abbe1a.bundle.js.map +0 -1
- package/dist/42.87fe547d27ce0c30deef.bundle.js +0 -2
- package/dist/42.87fe547d27ce0c30deef.bundle.js.map +0 -1
- package/dist/43.34060633fa9548ec3437.bundle.js +0 -2
- package/dist/43.34060633fa9548ec3437.bundle.js.map +0 -1
- package/dist/5.5f48e5c6fc10b52dd415.bundle.js.map +0 -1
- package/dist/53.78084dd64a27f7a6d2e8.bundle.js.map +0 -1
- package/dist/54.fe5e554af6ba2c5778c1.bundle.js.map +0 -1
- package/dist/56.9c6f6ecafc1909c42dda.bundle.js.map +0 -1
- package/dist/61.faf4ab26276a053ccac5.bundle.js +0 -2
- package/dist/61.faf4ab26276a053ccac5.bundle.js.map +0 -1
- package/dist/62.86f5ed4f7b582a8aa17d.bundle.js.map +0 -1
- package/dist/7.c7d8fb1dfdb444052435.bundle.js.map +0 -1
- package/dist/71.4dbbc366049697f736c5.bundle.js.map +0 -1
- package/dist/9.7bdbee8225f687ec81bc.bundle.js +0 -2
- package/dist/9.7bdbee8225f687ec81bc.bundle.js.map +0 -1
- package/dist/97.e88574ad257bd44724c3.bundle.js +0 -2
- package/dist/97.e88574ad257bd44724c3.bundle.js.map +0 -1
- package/dist/bundle.f540ee201846422b1cb9.bundle.js +0 -92
- package/dist/bundle.f540ee201846422b1cb9.bundle.js.map +0 -1
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack:///./src/js/lib/d3-tip/d3-tip-patch.js","webpack:///./src/js/angular/clustermanagement/cluster-drawing.service.js","webpack:///./src/js/angular/clustermanagement/directives.js"],"names":["direction","offset","html","node","initNode","svg","point","target","customPosition","tip","vis","el","tagName","toLowerCase","ownerSVGElement","createSVGPoint","document","body","appendChild","show","args","Array","prototype","slice","call","arguments","length","SVGElement","pop","coords","content","apply","this","poffset","dir","nodel","getNodeEl","i","directions","scrollTop","documentElement","scrollLeft","customPos","style","opacity","classed","direction_callbacks","get","top","left","hide","attr","n","v","d3","selection","functor","destroy","remove","map","bbox","getScreenBBox","y","offsetHeight","x","offsetWidth","s","e","w","nw","ne","sw","se","keys","select","createElement","position","targetel","event","getScreenCTM","parentNode","matrix","tbbox","getBBox","width","height","matrixTransform","clusterColors","ontoOrange","ontoBlue","ontoGreen","ontoGrey","createClusterSvgElement","element","append","createClusterZone","parent","clusterZone","setCreateClusterZone","hasCluster","translationsMap","selectAll","textGroup","text","no_cluster_configured","create_cluster_btn","updateClusterZoneLabels","moveElement","createNodes","nodesDataBinding","nodeRadius","isLegend","nodeGroup","enter","radius","_s32","Math","sqrt","points","data","line","createHexagon","exit","nodeElements","nodeTextHost","addHostnameToNodes","updateNodes","nodes","getNodeIconType","updateNodesIcon","nodeState","LEADER","FOLLOWER","CANDIDATE","updateNodesClasses","each","d","labelNode","hostname","updateNodesHostnameText","NO_CONNECTION","OUT_OF_SYNC","READ_ONLY","RESTRICTED","createLinks","linksDataBinding","updateLinks","setLinkColor","setLinkStyle","link","source","find","address","deltaX","deltaY","dist","normX","normY","sourceX","sourceY","targetX","targetY","getLinkCoordinates","status","IN_SYNC","SYNCING","positionNodesOnClusterZone","clusterZoneX","clusterZoneY","clusterZoneRadius","index","theta","PI","cos","sin","navigationBarWidth","clusterManagementDirectives","angular","module","legend_node_state","legend_link_state","node_state_leader","node_state_follower","node_state_candidate","node_state_no_cluster","node_state_out_of_sync","node_state_no_connection","node_state_read_only","node_state_restricted","link_state_in_sync","link_state_syncing","link_state_out_of_sync","idTranslationKeyMap","node_state","link_state","directive","$window","LocalStorageAdapter","LSKeys","UriUtils","$translate","$rootScope","restrict","scope","updateTranslations","Object","forEach","key","instant","getWindowWidth","collapsed","MENU_STATE","max","floor","innerWidth","getWindowHeight","innerHeight","legendNodesGroup","legendWidth","legendHeight","showLegend","$on","elementId","getLabelFor","createLegendGroup","createClusterLegend","updateLabels","legendTooltip","nodesGroup","linksGroup","tooltipElement","min","getBoundingClientRect","toolTip","showLegendTooltip","hideLegendTooltip","legendNodes","getLegendNodes","legendLinks","getLegendLinks","customText","linkTypeText","linkTypeKey","translateLegendLinksAndNodes","nodeStateLabel","legendPadding","linkStateLabel","nodeStateLabelY","legendNodeData","on","stopPropagation","row","id","linkWidth","endX","linkG","positionLegend","resizeClusterComponent","plot","clusterModel","mouseupCallback","$apply","showCreateClusterDialog","setClusterZoneType","_","cloneDeep","links","shortenIri","endpoint","nodeData","childContext","selectNode","tooltip","windowWidth","$","window","pageX","pageY","linksData","drawLinks","redraw","resize","toggleLegend","config","$tooltipProvider","options","appendToBody","push","NO_CLUSTER"],"mappings":"iFAAA,UAQQ,EAAO,QAAW,0BAAP,EAWX,WAIJ,OAAO,WACH,IAAIA,EAoJJ,WAA8B,MAAO,KAnJjCC,EAoJJ,WAA2B,MAAO,CAAC,EAAG,IAnJlCC,EAoJJ,WAAyB,MAAO,KAnJ5BC,EAAYC,IACZC,EAAY,KACZC,EAAY,KACZC,EAAY,KACZC,EAAiB,KAErB,SAASC,EAAIC,GAyOb,IAAoBC,EAxOhBN,EA0OgC,SADhCM,GADgBA,EAxOCD,GAyOTP,QACFS,QAAQC,cACHF,EAEJA,EAAGG,gBA5OVR,EAAQD,EAAIU,iBACZC,SAASC,KAAKC,YAAYf,GAM9BM,EAAIU,KAAO,WACP,IAAIC,EAAOC,MAAMC,UAAUC,MAAMC,KAAKC,WACnCL,EAAKA,EAAKM,OAAS,aAAcC,aAAYpB,EAASa,EAAKQ,OAE9D,IAKIC,EALAC,EAAU5B,EAAK6B,MAAMC,KAAMZ,GAC3Ba,EAAUhC,EAAO8B,MAAMC,KAAMZ,GAC7Bc,EAAUlC,EAAU+B,MAAMC,KAAMZ,GAChCe,EAAUC,IACVC,EAAUC,EAAWZ,OAErBa,EAAavB,SAASwB,gBAAgBD,WAAavB,SAASC,KAAKsB,UACjEE,EAAazB,SAASwB,gBAAgBC,YAAczB,SAASC,KAAK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5D,QAAQ,CAACzD,EAAMqB,IAAUrB,EAAKuG,GAAKlF,GAClCgG","file":"30.a2596e679fb09411b854.bundle.js","sourcesContent":["// d3.tip\n// Copyright (c) 2013 Justin Palmer\n//\n// Tooltips for d3.js SVG visualizations\n\n(function (root, factory) {\n if (typeof define === 'function' && define.amd) {\n // AMD. Register as an anonymous module with d3 as a dependency.\n define([], factory)\n } else if (typeof module === 'object' && module.exports) {\n // CommonJS\n module.exports = function(d3) {\n d3.tip = factory(d3)\n return d3.tip\n }\n } else {\n // Browser global.\n root.d3.tip = factory(root.d3)\n }\n}(this, function () {\n // Public - contructs a new tooltip\n //\n // Returns a tip\n return function() {\n var direction = d3_tip_direction,\n offset = d3_tip_offset,\n html = d3_tip_html,\n node = initNode(),\n svg = null,\n point = null,\n target = null,\n customPosition = null\n\n function tip(vis) {\n svg = getSVGNode(vis)\n point = svg.createSVGPoint()\n document.body.appendChild(node)\n }\n\n // Public - show the tooltip on the screen\n //\n // Returns a tip\n tip.show = function() {\n var args = Array.prototype.slice.call(arguments)\n if(args[args.length - 1] instanceof SVGElement) target = args.pop()\n\n var content = html.apply(this, args),\n poffset = offset.apply(this, args),\n dir = direction.apply(this, args),\n nodel = getNodeEl(),\n i = directions.length,\n coords,\n scrollTop = document.documentElement.scrollTop || document.body.scrollTop,\n scrollLeft = document.documentElement.scrollLeft || document.body.scrollLeft,\n customPos = customPosition.apply(this, args)\n\n nodel.html(content)\n .style({ opacity: 1, 'pointer-events': 'all' })\n\n while(i--) nodel.classed(directions[i], false)\n coords = direction_callbacks.get(dir).apply(this)\n\n if (customPos) {\n nodel.style(customPos)\n } else {\n nodel.classed(dir, true).style({\n top: (coords.top + poffset[0]) + scrollTop + 'px',\n left: (coords.left + poffset[1]) + scrollLeft + 'px'\n })\n }\n\n return tip\n }\n\n // Public - hide the tooltip\n //\n // Returns a tip\n tip.hide = function() {\n var nodel = getNodeEl()\n nodel.style({ opacity: 0, 'pointer-events': 'none' })\n return tip\n }\n\n // Public: Proxy attr calls to the d3 tip container. Sets or gets attribute value.\n //\n // n - name of the attribute\n // v - value of the attribute\n //\n // Returns tip or attribute value\n tip.attr = function(n, v) {\n if (arguments.length < 2 && typeof n === 'string') {\n return getNodeEl().attr(n)\n } else {\n var args = Array.prototype.slice.call(arguments)\n d3.selection.prototype.attr.apply(getNodeEl(), args)\n }\n\n return tip\n }\n\n // Public: Proxy style calls to the d3 tip container. Sets or gets a style value.\n //\n // n - name of the property\n // v - value of the property\n //\n // Returns tip or style property value\n tip.style = function(n, v) {\n if (arguments.length < 2 && typeof n === 'string') {\n return getNodeEl().style(n)\n } else {\n var args = Array.prototype.slice.call(arguments)\n d3.selection.prototype.style.apply(getNodeEl(), args)\n }\n\n return tip\n }\n\n // Public: Set or get the direction of the tooltip\n //\n // v - One of n(north), s(south), e(east), or w(west), nw(northwest),\n // sw(southwest), ne(northeast) or se(southeast)\n //\n // Returns tip or direction\n tip.direction = function(v) {\n if (!arguments.length) return direction\n direction = v == null ? v : d3.functor(v)\n\n return tip\n }\n\n // Public: Sets or gets the offset of the tip\n //\n // v - Array of [x, y] offset\n //\n // Returns offset or\n tip.offset = function(v) {\n if (!arguments.length) return offset\n offset = v == null ? v : d3.functor(v)\n\n return tip\n }\n\n // Public: sets or gets the html value of the tooltip\n //\n // v - String value of the tip\n //\n // Returns html value or tip\n tip.html = function(v) {\n if (!arguments.length) return html\n html = v == null ? v : d3.functor(v)\n\n return tip\n }\n\n tip.customPosition = function(v) {\n if (!arguments.length) return customPosition\n customPosition = v == null ? v : d3.functor(v)\n\n return tip\n }\n\n // Public: destroys the tooltip and removes it from the DOM\n //\n // Returns a tip\n tip.destroy = function() {\n if(node) {\n getNodeEl().remove();\n node = null;\n }\n return tip;\n }\n\n function d3_tip_direction() { return 'n' }\n function d3_tip_offset() { return [0, 0] }\n function d3_tip_html() { return ' ' }\n\n var direction_callbacks = d3.map({\n n: direction_n,\n s: direction_s,\n e: direction_e,\n w: direction_w,\n nw: direction_nw,\n ne: direction_ne,\n sw: direction_sw,\n se: direction_se\n }),\n\n directions = direction_callbacks.keys()\n\n function direction_n() {\n var bbox = getScreenBBox()\n return {\n top: bbox.n.y - node.offsetHeight,\n left: bbox.n.x - node.offsetWidth / 2\n }\n }\n\n function direction_s() {\n var bbox = getScreenBBox()\n return {\n top: bbox.s.y,\n left: bbox.s.x - node.offsetWidth / 2\n }\n }\n\n function direction_e() {\n var bbox = getScreenBBox()\n return {\n top: bbox.e.y - node.offsetHeight / 2,\n left: bbox.e.x\n }\n }\n\n function direction_w() {\n var bbox = getScreenBBox()\n return {\n top: bbox.w.y - node.offsetHeight / 2,\n left: bbox.w.x - node.offsetWidth\n }\n }\n\n function direction_nw() {\n var bbox = getScreenBBox()\n return {\n top: bbox.nw.y - node.offsetHeight,\n left: bbox.nw.x - node.offsetWidth\n }\n }\n\n function direction_ne() {\n var bbox = getScreenBBox()\n return {\n top: bbox.ne.y - node.offsetHeight,\n left: bbox.ne.x\n }\n }\n\n function direction_sw() {\n var bbox = getScreenBBox()\n return {\n top: bbox.sw.y,\n left: bbox.sw.x - node.offsetWidth\n }\n }\n\n function direction_se() {\n var bbox = getScreenBBox()\n return {\n top: bbox.se.y,\n left: bbox.e.x\n }\n }\n\n function initNode() {\n var node = d3.select(document.createElement('div'))\n node.style({\n position: 'absolute',\n top: 0,\n opacity: 0,\n 'pointer-events': 'none',\n 'box-sizing': 'border-box'\n })\n\n return node.node()\n }\n\n function getSVGNode(el) {\n el = el.node()\n if(el.tagName.toLowerCase() === 'svg')\n return el\n\n return el.ownerSVGElement\n }\n\n function getNodeEl() {\n if(node === null) {\n node = initNode();\n // re-add node to DOM\n document.body.appendChild(node);\n };\n return d3.select(node);\n }\n\n // Private - gets the screen coordinates of a shape\n //\n // Given a shape on the screen, will return an SVGPoint for the directions\n // n(north), s(south), e(east), w(west), ne(northeast), se(southeast), nw(northwest),\n // sw(southwest).\n //\n // +-+-+\n // | |\n // + +\n // | |\n // +-+-+\n //\n // Returns an Object {n, s, e, w, nw, sw, ne, se}\n function getScreenBBox() {\n var targetel = target || d3.event.target;\n\n while ('undefined' === typeof targetel.getScreenCTM && 'undefined' === targetel.parentNode) {\n targetel = targetel.parentNode;\n }\n\n var bbox = {},\n matrix = targetel.getScreenCTM(),\n tbbox = targetel.getBBox(),\n width = tbbox.width,\n height = tbbox.height,\n x = tbbox.x,\n y = tbbox.y\n\n point.x = x\n point.y = y\n bbox.nw = point.matrixTransform(matrix)\n point.x += width\n bbox.ne = point.matrixTransform(matrix)\n point.y += height\n bbox.se = point.matrixTransform(matrix)\n point.x -= width\n bbox.sw = point.matrixTransform(matrix)\n point.y -= height / 2\n bbox.w = point.matrixTransform(matrix)\n point.x += width\n bbox.e = point.matrixTransform(matrix)\n point.x -= width / 2\n point.y -= height / 2\n bbox.n = point.matrixTransform(matrix)\n point.y += height\n bbox.s = point.matrixTransform(matrix)\n\n return bbox\n }\n\n return tip\n };\n\n}));","import {LinkState, NodeState} from \"./controllers\";\n\nexport const clusterColors = {\n ontoOrange: 'var(--onto-orange)',\n ontoBlue: 'var(--onto-blue)',\n ontoGreen: 'var(--onto-green)',\n ontoGrey: 'var(--onto-grey)'\n};\n\nexport function createClusterSvgElement(element) {\n return d3.select(element)\n .append('svg');\n}\n\nexport function createClusterZone(parent) {\n const clusterZone = parent.append('g');\n clusterZone\n .append(\"circle\")\n .classed('cluster-zone', true)\n .style('fill', 'transparent')\n .style('stroke-width', '2');\n return clusterZone;\n}\n\nexport function setCreateClusterZone(hasCluster, clusterZone, translationsMap) {\n clusterZone\n .select('.cluster-zone')\n .classed('no-cluster', !hasCluster);\n\n if (hasCluster) {\n clusterZone.selectAll('#no-cluster-zone').remove();\n } else {\n const textGroup = clusterZone\n .append('g')\n .attr(\"id\", \"no-cluster-zone\");\n textGroup\n .append('text')\n .attr('id', 'no-cluster-label')\n .text(translationsMap.no_cluster_configured || 'No cluster group configured')\n .attr('y', -50)\n .classed('h2', true)\n .style('text-anchor', \"middle\");\n textGroup.append('text')\n .attr('id', 'create-cluster-label')\n .classed('h3', true)\n .text(translationsMap.create_cluster_btn || 'Click here to create a cluster')\n .style('text-anchor', \"middle\");\n textGroup.append('text')\n .attr('y', 130)\n .attr('class', 'icon-any repo')\n .attr('fill', clusterColors.ontoOrange)\n .style('text-anchor', \"middle\")\n .classed('settings-icon', true)\n .text(\"\\ue92b\");\n }\n}\n\nexport function updateClusterZoneLabels(hasCluster, clusterZone, translationsMap) {\n if (hasCluster) {\n return;\n }\n clusterZone.select('#no-cluster-zone #no-cluster-label')\n .text(translationsMap.no_cluster_configured);\n clusterZone.select('#no-cluster-zone #create-cluster-label')\n .text(translationsMap.create_cluster_btn);\n}\n\nexport function moveElement(element, x, y) {\n element.attr('transform', () => {\n return `translate(${x}, ${y})`;\n });\n}\n\nexport function createNodes(nodesDataBinding, nodeRadius, isLegend) {\n const nodeGroup = nodesDataBinding.enter()\n .append('g')\n .attr('id', 'node-group')\n .classed('legend', isLegend);\n\n createHexagon(nodeGroup, nodeRadius);\n nodesDataBinding.exit().remove();\n\n nodeGroup\n .append('text')\n .attr('class', 'icon-any node-icon');\n\n addHostnameToNodes(nodeGroup, nodeRadius, isLegend);\n}\n\nfunction addHostnameToNodes(nodeElements, nodeRadius, isLegend) {\n const nodeTextHost = nodeElements.append('g');\n\n if (isLegend) {\n nodeTextHost.append('foreignObject')\n .attr('y', nodeRadius)\n .attr('x', -nodeRadius)\n .attr('width', nodeRadius * 2)\n .attr('height', 10)\n .attr('class', 'label-wrapper')\n .append('xhtml:div')\n .attr('class', 'id id-host');\n } else {\n nodeTextHost\n .append('rect')\n .attr('class', 'id-host-background')\n .attr('rx', 6);\n\n nodeTextHost\n .append('text')\n .attr('y', nodeRadius + 10)\n .attr('class', 'id id-host')\n .style('text-anchor', 'middle');\n }\n}\n\nexport function updateNodes(nodes) {\n updateNodesIcon(nodes);\n updateNodesClasses(nodes);\n updateNodesHostnameText(nodes);\n}\n\nfunction updateNodesClasses(nodes) {\n nodes\n .select('.node.member')\n .classed('leader', (node) => node.nodeState === NodeState.LEADER)\n .classed('follower', (node) => node.nodeState === NodeState.FOLLOWER)\n .classed('candidate', (node) => node.nodeState === NodeState.CANDIDATE)\n .classed('other', (node) => {\n return node.nodeState !== NodeState.LEADER &&\n node.nodeState !== NodeState.FOLLOWER &&\n node.nodeState !== NodeState.CANDIDATE;\n });\n}\n\nfunction updateNodesIcon(nodes) {\n nodes\n .select('.icon-any.node-icon')\n .text(getNodeIconType);\n}\n\nfunction getNodeIconType(node) {\n if (node.nodeState === NodeState.LEADER) {\n return '\\ue935';\n } else if (node.nodeState === NodeState.FOLLOWER) {\n return '\\ue963';\n } else if (node.nodeState === NodeState.CANDIDATE) {\n return '\\ue914';\n } else if (node.nodeState === NodeState.NO_CONNECTION) {\n return '\\ue931';\n } else if (node.nodeState === NodeState.OUT_OF_SYNC) {\n return '\\ue920';\n } else if (node.nodeState === NodeState.READ_ONLY) {\n return '\\ue95c';\n } else if (node.nodeState === NodeState.RESTRICTED) {\n return '\\ue933';\n }\n return '';\n}\n\nfunction updateNodesHostnameText(nodes) {\n nodes\n .select('.id.id-host')\n .each(function (d) {\n d.labelNode = this;\n })\n .text(function (d) {\n return d.hostname;\n });\n\n // Add padding styling to text background. left/right +5. top/bottom +1\n nodes\n .select('.id-host-background')\n .attr('width', function (d) {\n return d3.select(d.labelNode).node().getBBox().width + 10;\n })\n .attr('height', function (d) {\n return d3.select(d.labelNode).node().getBBox().height + 2;\n })\n .attr('x', function (d) {\n return d3.select(d.labelNode).node().getBBox().x - 5;\n })\n .attr('y', function (d) {\n return d3.select(d.labelNode).node().getBBox().y - 1;\n })\n .attr('fill', '#EEEEEE');\n}\n\nexport function createLinks(linksDataBinding) {\n linksDataBinding.enter()\n .append('path')\n .classed('link', true);\n\n linksDataBinding.exit().remove();\n}\n\nexport function updateLinks(linksDataBinding, nodes) {\n linksDataBinding\n .attr('stroke', setLinkColor)\n .style('stroke-dasharray', setLinkStyle)\n .attr('d', (link) => getLinkCoordinates(link, nodes));\n}\n\nexport function setLinkColor(link) {\n if (link.status === LinkState.IN_SYNC || link.status === LinkState.SYNCING) {\n return clusterColors.ontoGreen;\n } else if (link.status === LinkState.OUT_OF_SYNC) {\n return clusterColors.ontoGrey;\n }\n return 'none';\n}\n\nexport function setLinkStyle(link) {\n if (link.status === LinkState.OUT_OF_SYNC || link.status === LinkState.SYNCING) {\n return '10 10';\n }\n return 'none';\n}\n\nfunction getLinkCoordinates(link, nodes) {\n const source = nodes.find((node) => node.address === link.source);\n const target = nodes.find((node) => node.address === link.target);\n\n const deltaX = target.x - source.x;\n const deltaY = target.y - source.y;\n const dist = Math.sqrt(deltaX * deltaX + deltaY * deltaY);\n const normX = deltaX / dist;\n const normY = deltaY / dist;\n\n // Padding from node center point\n const sourcePadding = 55;\n const targetPadding = 55;\n const sourceX = source.x + (sourcePadding * normX);\n const sourceY = source.y + (sourcePadding * normY);\n const targetX = target.x - (targetPadding * normX);\n const targetY = target.y - (targetPadding * normY);\n return 'M' + sourceX + ',' + sourceY + 'L' + targetX + ',' + targetY;\n}\n\nexport function positionNodesOnClusterZone(nodes, clusterZoneX, clusterZoneY, clusterZoneRadius) {\n nodes\n .attr('transform', (node, index) => {\n // Calculate initial positions for the new nodes based on\n // spreading them evenly on a circle around the center of the page.\n const theta = 2 * Math.PI * index / nodes[0].length;\n var x = clusterZoneX + Math.cos(theta) * clusterZoneRadius;\n var y = clusterZoneY + Math.sin(theta) * clusterZoneRadius;\n node.x = x;\n node.y = y;\n return `translate(${x}, ${y})`;\n });\n}\n\nfunction createHexagon(nodeGroup, radius) {\n const _s32 = (Math.sqrt(3) / 2);\n const xDiff = 0;\n const yDiff = 0;\n const points = [[radius + xDiff, yDiff], [radius / 2 + xDiff, radius * _s32 + yDiff], [-radius / 2 + xDiff, radius * _s32 + yDiff],\n [-radius + xDiff, yDiff],\n [-radius / 2 + xDiff, -radius * _s32 + yDiff], [radius / 2 + xDiff, -radius * _s32 + yDiff], [radius + xDiff, yDiff],\n [radius / 2 + xDiff, radius * _s32 + yDiff]];\n return nodeGroup\n .selectAll(\"path.area\")\n .data([points])\n .enter()\n .append(\"path\")\n .attr('class', 'node member')\n .attr(\"d\", d3.svg.line());\n}\n","import 'angular/utils/local-storage-adapter';\nimport * as CDS from \"./cluster-drawing.service\";\nimport {LinkState, NodeState} from \"./controllers\";\nimport d3tip from 'lib/d3-tip/d3-tip-patch';\n\n\nconst navigationBarWidthFull = 240;\nconst navigationBarWidthCollapsed = 70;\nlet navigationBarWidth = navigationBarWidthFull;\n\nconst nodeRadius = 50;\nconst legendNodeRadius = 25;\n\nconst clusterManagementDirectives = angular.module('graphdb.framework.clustermanagement.directives', [\n 'graphdb.framework.utils.localstorageadapter'\n]);\n\nconst translationsMap = {\n no_cluster_configured: '',\n create_cluster_btn: '',\n legend_node_state: '',\n legend_link_state: '',\n node_state_leader: \"Leader\",\n node_state_follower: \"Follower\",\n node_state_candidate: \"Candidate\",\n node_state_no_cluster: \"No cluster\",\n node_state_out_of_sync: \"Out of sync\",\n node_state_no_connection: \"No connection\",\n node_state_read_only: \"Read only\",\n node_state_restricted: \"Restricted\",\n link_state_in_sync: \"In sync\",\n link_state_syncing: \"Syncing\",\n link_state_out_of_sync: \"Out of sync\"\n};\n\nconst idTranslationKeyMap = {\n node_state: 'legend_node_state',\n link_state: 'legend_link_state'\n};\n\nclusterManagementDirectives.directive('clusterGraphicalView', ['$window', 'LocalStorageAdapter', 'LSKeys', 'UriUtils', '$translate', '$rootScope',\n function ($window, LocalStorageAdapter, LSKeys, UriUtils, $translate, $rootScope) {\n return {\n restrict: 'A',\n link: function (scope, element) {\n scope.showLegend = false;\n $rootScope.$on('$translateChangeSuccess', function () {\n updateTranslations();\n updateLabels();\n });\n scope.$on(\"$destroy\", function () {\n legendTooltip.destroy();\n });\n function updateTranslations() {\n Object.keys(translationsMap).forEach((key) => {\n translationsMap[key] = $translate.instant('cluster_management.cluster_graphical_view.' + key);\n });\n }\n\n function getWindowWidth() {\n const collapsed = LocalStorageAdapter.get(LSKeys.MENU_STATE) === 'collapsedMenu';\n navigationBarWidth = collapsed ? navigationBarWidthCollapsed : navigationBarWidthFull;\n // 95% avoids horizontal scrollbars and adds some margin\n return Math.max(Math.floor(($window.innerWidth - navigationBarWidth) * 0.95), 600);\n }\n\n function getWindowHeight() {\n // 95% avoids horizontal scrollbars and adds some margin\n return Math.max((($window.innerHeight - 250) * 0.95), 600);\n }\n\n let legendNodesGroup;\n let legendWidth;\n let legendHeight;\n const legendPadding = 10;\n\n let width = getWindowWidth();\n let height = getWindowHeight();\n let clusterZoneRadius = Math.min(width, height) / 2 - 100;\n let clusterZoneX = width / 2;\n let clusterZoneY = height / 2;\n let hasCluster;\n\n scope.width = function () {\n return width;\n };\n\n scope.height = function () {\n return height;\n };\n\n // SVG components\n let svg;\n let clusterZone;\n let nodesGroup;\n let linksGroup;\n\n function updateLabels() {\n CDS.updateClusterZoneLabels(hasCluster, clusterZone, translationsMap);\n Object.keys(idTranslationKeyMap).forEach((elementId) => {\n d3.select(`#${elementId}`).text(getLabelFor(elementId));\n });\n if (legendNodesGroup) {\n legendNodesGroup.remove();\n }\n createLegendGroup();\n createClusterLegend();\n }\n\n function translateLegendLinksAndNodes(legendNodes, legendLinks) {\n legendNodes.forEach((node) => {\n node.toolTip = node.hostname = translationsMap[node.customText];\n });\n legendLinks.forEach((link) => {\n link.toolTip = link.linkTypeText = translationsMap[link.linkTypeKey];\n });\n }\n\n function getLabelFor(elementId) {\n const labelKey = idTranslationKeyMap[elementId];\n return translationsMap[labelKey];\n }\n\n function initialize() {\n updateTranslations();\n const hasCluster = !!(scope.clusterModel.nodes && scope.clusterModel.nodes.length);\n createClusterZone(hasCluster);\n createClusterLegend();\n plot();\n }\n\n function createClusterZone(hasCluster) {\n svg = CDS.createClusterSvgElement(element[0])\n .attr('width', width)\n .attr('height', height);\n svg.call(legendTooltip);\n\n clusterZone = CDS.createClusterZone(svg, hasCluster);\n\n linksGroup = svg.append('g').attr('id', 'links-group');\n nodesGroup = svg.append('g').attr('id', 'nodes-group');\n createLegendGroup();\n }\n\n function createLegendGroup() {\n legendNodesGroup = svg.append('g').attr('id', 'legend-group')\n .classed('hidden', !scope.showLegend)\n .classed('legend-group', true);\n }\n\n let tooltipElement;\n const legendTooltip = d3tip()\n .attr('class', 'd3-tip')\n .customPosition(function () {\n const bbox = tooltipElement.getBoundingClientRect();\n const scrollTop = document.documentElement.scrollTop || document.body.scrollTop;\n const scrollLeft = document.documentElement.scrollLeft || document.body.scrollLeft;\n\n return {\n left: bbox.left + scrollLeft + 'px',\n top: (bbox.top - 30) + scrollTop + 'px'\n };\n })\n .html(function (d) {\n return d.toolTip;\n });\n\n // Shows tooltip with legend node or link state\n const showLegendTooltip = function (d, element) {\n tooltipElement = element;\n legendTooltip.show(d, tooltipElement);\n };\n\n // Hides the tooltip with legend node or link state\n const hideLegendTooltip = function () {\n tooltipElement = null;\n legendTooltip.hide();\n };\n\n function createClusterLegend() {\n const nodeLinkStateTextHeight = 14;\n\n const nodeStateLabelY = legendPadding + nodeLinkStateTextHeight;\n const linkStateLabelY = nodeStateLabelY + legendPadding * 3 + legendNodeRadius * 5;\n\n const legendColumns = 4;\n const nodesXPadding = 15;\n const nodesYPadding = 15;\n\n const legendNodes = getLegendNodes();\n const legendLinks = getLegendLinks();\n translateLegendLinksAndNodes(legendNodes, legendLinks);\n\n legendNodesGroup.append('rect')\n .attr('id', 'legend-background')\n .attr('class', 'legend-background')\n .attr('fill', '#EEEEEE');\n\n const nodeStateLabel = legendNodesGroup\n .append('text')\n .attr('id', 'node_state')\n .attr('class', 'id id-host')\n .attr('x', nodeRadius * 4)\n .attr('y', nodeStateLabelY)\n .text(getLabelFor('node_state'));\n\n const linkStateLabel = legendNodesGroup\n .append('text')\n .attr('id', 'link_state')\n .attr('class', 'id id-host')\n .attr('x', nodeRadius * 4)\n .attr('y', linkStateLabelY)\n .text(getLabelFor('link_state'));\n\n const legendNodeData = legendNodesGroup.selectAll('#node-group').data(legendNodes);\n CDS.createNodes(legendNodeData, legendNodeRadius, true);\n CDS.updateNodes(legendNodeData);\n\n legendNodeData.select('.node.member')\n .on(\"mouseover\", function (d) {\n d3.event.stopPropagation();\n showLegendTooltip(d, this);\n })\n .on('mouseout', hideLegendTooltip);\n\n legendNodeData\n .attr('transform', function (d) {\n const row = Math.floor(d.id / legendColumns);\n const column = d.id % legendColumns;\n const x = legendPadding + legendNodeRadius + (nodesXPadding + legendNodeRadius * 2) * column;\n const y = legendPadding * 2 + nodeLinkStateTextHeight + legendNodeRadius + (nodesYPadding + legendNodeRadius\n * 2) * row;\n return `translate(${x}, ${y})`;\n });\n\n legendNodesGroup\n .call(function () {\n legendWidth = this.node().getBBox().width;\n });\n\n // Position node/link state labels\n nodeStateLabel.attr('x', legendPadding + legendWidth / 2);\n linkStateLabel.attr('x', legendPadding + legendWidth / 2);\n\n\n const linkWidth = legendWidth / 3;\n\n const linksGroup = legendNodesGroup.append('g').attr('id', 'links-group');\n const linksGroupY = linkStateLabelY + legendPadding;\n linksGroup.attr('transform', `translate(${legendPadding}, ${linksGroupY})`);\n\n legendLinks.forEach((link, index) => {\n const linkPadding = 5;\n const startX = linkPadding;\n const endX = linkWidth - linkPadding;\n\n const linkG = linksGroup\n .append('g')\n .classed('link', true)\n .classed('legend', true)\n .attr('transform', () => {\n const x = index * linkWidth;\n return `translate(${x}, 0)`;\n });\n\n linkG\n .append('path')\n .classed('link', true)\n .attr('stroke-dasharray', () => CDS.setLinkStyle(link))\n .attr('stroke', () => CDS.setLinkColor(link))\n .attr('d', () => {\n return `M${startX},0,${endX},0`;\n });\n\n linkG.append('foreignObject')\n .attr('y', 10)\n .attr('x', 5)\n .attr('width', linkWidth - 10)\n .attr('height', 10)\n .attr('class', 'label-wrapper')\n .append('xhtml:div')\n .attr('class', 'id id-host')\n .style(\"font-size\", \"9px\")\n .html(link.linkTypeText);\n\n linkG\n .on('mouseover', function () {\n d3.event.stopPropagation();\n showLegendTooltip(link, this);\n })\n .on('mouseout', hideLegendTooltip);\n });\n\n\n legendNodesGroup\n .call(function (d) {\n legendHeight = this.node().getBBox().height;\n legendWidth = this.node().getBBox().width;\n });\n\n legendNodesGroup.select('.legend-background')\n .attr('height', legendHeight + legendPadding * 4)\n .attr('width', legendWidth + legendPadding * 2)\n .attr('rx', '6');\n\n positionLegend();\n }\n\n function positionLegend() {\n const y = height - (legendHeight + legendPadding * 3 + 50);\n CDS.moveElement(legendNodesGroup, 0, y);\n }\n\n function createNodes(nodes) {\n nodes.forEach((node) => node.hostname = UriUtils.shortenIri(node.endpoint));\n const nodeData = nodesGroup.selectAll('#node-group').data(nodes, (node) => node.address);\n nodeData\n .on('click', (d) => {\n scope.childContext.selectNode(d);\n\n // position the tooltip according to the node!\n const tooltip = d3.select('.nodetooltip');\n const windowWidth = $(window).width();\n if (d3.event.pageX < windowWidth / 2) {\n // left\n tooltip.style(\"left\", d3.event.pageX + \"px\");\n tooltip.style(\"right\", \"\");\n } else {\n // right\n tooltip.style(\"left\", \"\");\n tooltip.style(\"right\", (windowWidth - d3.event.pageX) + \"px\");\n }\n tooltip.style(\"top\", (d3.event.pageY - 28) + \"px\");\n });\n CDS.createNodes(nodeData, nodeRadius);\n CDS.updateNodes(nodeData);\n CDS.positionNodesOnClusterZone(nodeData, clusterZoneX, clusterZoneY, clusterZoneRadius);\n }\n\n function drawLinks(links, nodes) {\n const linksData = linksGroup.selectAll('.link').data(links, (link) => link.id);\n CDS.createLinks(linksData);\n CDS.updateLinks(linksData, nodes);\n }\n\n // Properties and functions that can be used by parent\n scope.childContext.redraw = plot;\n scope.childContext.resize = function () {\n // recalculates with new screen width\n width = getWindowWidth();\n height = getWindowHeight();\n svg.attr(\"width\", width);\n svg.attr(\"height\", height);\n plot();\n positionLegend();\n };\n scope.childContext.toggleLegend = () => {\n scope.showLegend = !scope.showLegend;\n legendNodesGroup.classed('hidden', !scope.showLegend);\n };\n\n function resizeClusterComponent() {\n calculateClusterZoneProperties();\n CDS.moveElement(clusterZone, clusterZoneX, clusterZoneY);\n clusterZone\n .select('.cluster-zone')\n .attr('r', clusterZoneRadius);\n }\n\n function calculateClusterZoneProperties() {\n clusterZoneRadius = Math.min(width, height) / 2 - 100;\n clusterZoneX = width / 2;\n clusterZoneY = height / 2;\n }\n\n function setClusterZoneType(hasCluster) {\n CDS.setCreateClusterZone(hasCluster, clusterZone, translationsMap);\n let mouseupCallback;\n if (!hasCluster) {\n mouseupCallback = () => {\n scope.$apply(function () {\n scope.showCreateClusterDialog();\n });\n };\n }\n clusterZone\n .on('mouseup', mouseupCallback);\n }\n\n function plot() {\n resizeClusterComponent();\n if (hasCluster !== scope.clusterModel.hasCluster) {\n hasCluster = !!scope.clusterModel.hasCluster;\n setClusterZoneType(hasCluster);\n }\n const nodes = _.cloneDeep(scope.clusterModel.nodes) || [];\n const links = _.cloneDeep(scope.clusterModel.links) || [];\n createNodes(nodes);\n drawLinks(links, nodes);\n }\n\n initialize();\n }\n };\n }\n])\n .config(['$tooltipProvider', function ($tooltipProvider) {\n $tooltipProvider.options({appendToBody: true});\n}]);\n\n\nconst getLegendNodes = function () {\n const legendNodes = [];\n legendNodes.push({nodeState: NodeState.LEADER, customText: 'node_state_leader'});\n legendNodes.push({nodeState: NodeState.FOLLOWER, customText: 'node_state_follower'});\n legendNodes.push({nodeState: NodeState.CANDIDATE, customText: 'node_state_candidate'});\n legendNodes.push({nodeState: NodeState.NO_CLUSTER, customText: 'node_state_no_cluster'});\n legendNodes.push({nodeState: NodeState.OUT_OF_SYNC, customText: 'node_state_out_of_sync'});\n legendNodes.push({nodeState: NodeState.NO_CONNECTION, customText: 'node_state_no_connection'});\n legendNodes.push({nodeState: NodeState.READ_ONLY, customText: 'node_state_read_only'});\n legendNodes.push({nodeState: NodeState.RESTRICTED, customText: 'node_state_restricted'});\n legendNodes.forEach((node, index) => node.id = index);\n return legendNodes;\n};\n\nconst getLegendLinks = function () {\n const links = [];\n links.push({status: LinkState.IN_SYNC, linkTypeKey: 'link_state_in_sync'});\n links.push({status: LinkState.SYNCING, linkTypeKey: 'link_state_syncing'});\n links.push({status: LinkState.OUT_OF_SYNC, linkTypeKey: 'link_state_out_of_sync'});\n links.forEach((link, index) => link.id = index);\n return links;\n};\n"],"sourceRoot":""}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp=window.webpackJsonp||[]).push([[31,36,61],{122:function(e,i,a){"use strict";a.r(i);a(89);angular.module("graphdb.framework.guides",["ui.bootstrap","graphdb.framework.guides.controllers"])},43:function(e,i){angular.module("graphdb.framework.core.directives.paginations",[]).directive("paginations",(function(){return{template:'<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"></pagination>'}}))},89:function(e,i,a){"use strict";a.r(i);a(20),a(43);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"]}}]);
|
|
2
|
-
//# sourceMappingURL=31.fbcd8b1840a84a281e47.bundle.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack:///./src/js/angular/guides/app.js","webpack:///./src/js/angular/core/directives/paginations.js","webpack:///./src/js/angular/guides/controllers.js"],"names":["angular","module","directive","template","GuidesCtrl","$scope","$rootScope","GuidesService","$filter","$translate","$interpolate","guides","pageSizeOptions","page","pageSize","translationSubscription","undefined","init","getGuides","then","forEach","guide","translatedGuideName","translateLocalMessage","guideName","translatedGuideDescription","guideDescription","guideLevel","guideLevelLabel","matchedElements","changePagination","startGuide","this","$on","isDefined","displayedGuides","slice","changePageSize","size","controller","$inject"],"mappings":"iGAAA,aAOAA,QAAQC,OAAO,2BALC,CACZ,eACA,0C,iBCJJD,QAAQC,OAAO,gDAAiD,IAC3DC,UAAU,eAAe,WACtB,MAAO,CACHC,SAAU,iP,gCCHtB,8BAgBA,SAASC,EAAWC,EAAQC,EAAYC,EAAeC,EAASC,EAAYC,GAExEL,EAAOM,OAAS,GAChBN,EAAOO,gBAAkB,CAAC,GAAI,GAAI,GAAI,KACtCP,EAAOQ,KAAO,EACdR,EAAOS,SAAWT,EAAOO,gBAAgB,GACzCP,EAAOU,6BAA0BC,EAEjCX,EAAOY,KAAO,WACVV,EAAcW,YACTC,KAAKR,IACFN,EAAOM,OAASH,EAAQ,UAARA,CAAmBG,EAAQ,cAC3CN,EAAOM,OAAOS,QAAQC,IAGlB,OAFAA,EAAMC,oBAAsB,aAAWC,sBAAsBd,EAAYC,EAAcW,EAAMG,WAC7FH,EAAMI,2BAA6B,aAAWF,sBAAsBd,EAAYC,EAAcW,EAAMK,kBAC5FL,EAAMM,YACV,UAAKX,EACL,KAAK,EACDK,EAAMO,gBAAkB,6BACxB,MACJ,KAAK,EACDP,EAAMO,gBAAkB,iCACxB,MACJ,QACIP,EAAMO,gBAAkB,gCAGpCvB,EAAOwB,gBAAkBxB,EAAOM,OAChCN,EAAOyB,sBAInBzB,EAAO0B,WAAa,SAAUV,GAC1Bd,EAAcwB,WAAWV,IAGxBW,KAAKjB,0BACNiB,KAAKjB,wBAA0BT,EAAW2B,IAAI,0BAA2B,KACrE5B,EAAOY,UAIfZ,EAAOyB,iBAAmB,WAClB9B,QAAQkC,UAAU7B,EAAOM,UACzBN,EAAO8B,gBAAkB9B,EAAOM,OAAOyB,MAAM/B,EAAOS,UAAYT,EAAOQ,KAAO,GAAIR,EAAOS,SAAWT,EAAOQ,QAInHR,EAAOgC,eAAiB,SAAUC,GAC9BjC,EAAOQ,KAAO,EAEVR,EAAOS,SADPwB,GAGkBjC,EAAOO,gBAAgB,GAE7CP,EAAOyB,oBAGXzB,EAAOY,OAhEXjB,QACKC,OAAO,uCAPI,CACZ,eACA,oCACA,kDAKCsC,WAAW,aAAcnC,GAE9BA,EAAWoC,QAAU,CAAC,SAAU,aAAc,gBAAiB,UAAW,aAAc","file":"31.fbcd8b1840a84a281e47.bundle.js","sourcesContent":["import 'angular/guides/controllers';\n\nconst modules = [\n 'ui.bootstrap',\n 'graphdb.framework.guides.controllers'\n];\n\nangular.module('graphdb.framework.guides', modules);\n","angular.module('graphdb.framework.core.directives.paginations', [])\n .directive('paginations', function () {\n return {\n template: '<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\"></pagination>',\n };\n });\n","import 'angular/guides/guides.service';\nimport 'angular/core/directives/paginations';\nimport {GuideUtils} from \"./guide-utils\";\n\nconst modules = [\n 'ui.bootstrap',\n 'graphdb.framework.guides.services',\n 'graphdb.framework.core.directives.paginations'\n];\n\nangular\n .module('graphdb.framework.guides.controllers', modules)\n .controller('GuidesCtrl', GuidesCtrl);\n\nGuidesCtrl.$inject = ['$scope', '$rootScope', 'GuidesService', '$filter', '$translate', '$interpolate'];\n\nfunction GuidesCtrl($scope, $rootScope, GuidesService, $filter, $translate, $interpolate) {\n\n $scope.guides = [];\n $scope.pageSizeOptions = [10, 20, 50, 100];\n $scope.page = 1;\n $scope.pageSize = $scope.pageSizeOptions[0];\n $scope.translationSubscription = undefined;\n\n $scope.init = function () {\n GuidesService.getGuides()\n .then(guides => {\n $scope.guides = $filter('orderBy')(guides, 'guideOrder');\n $scope.guides.forEach(guide => {\n guide.translatedGuideName = GuideUtils.translateLocalMessage($translate, $interpolate, guide.guideName);\n guide.translatedGuideDescription = GuideUtils.translateLocalMessage($translate, $interpolate, guide.guideDescription);\n switch (guide.guideLevel) {\n case undefined:\n case 0:\n guide.guideLevelLabel = 'view.guides.level.beginner';\n break;\n case 1:\n guide.guideLevelLabel = 'view.guides.level.intermediate';\n break;\n default: // 2 and above\n guide.guideLevelLabel = 'view.guides.level.advanced';\n }\n });\n $scope.matchedElements = $scope.guides;\n $scope.changePagination();\n });\n };\n\n $scope.startGuide = function (guide) {\n GuidesService.startGuide(guide);\n };\n\n if (!this.translationSubscription) {\n this.translationSubscription = $rootScope.$on('$translateChangeSuccess', () => {\n $scope.init();\n });\n }\n\n $scope.changePagination = function () {\n if (angular.isDefined($scope.guides)) {\n $scope.displayedGuides = $scope.guides.slice($scope.pageSize * ($scope.page - 1), $scope.pageSize * $scope.page);\n }\n };\n\n $scope.changePageSize = function (size) {\n $scope.page = 1;\n if (size) {\n $scope.pageSize = size;\n } else {\n $scope.pageSize = $scope.pageSizeOptions[0];\n }\n $scope.changePagination();\n };\n\n $scope.init();\n}\n"],"sourceRoot":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack:///./src/js/angular/autocomplete/app.js","webpack:///./src/js/angular/autocomplete/controllers.js"],"names":["angular","module","AutocompleteCtrl","$scope","$interval","toastr","$repositories","$licenseService","$modal","$timeout","AutocompleteRestService","$autocompleteStatus","$translate","timer","cancelTimer","cancel","pluginName","setPluginIsActive","isPluginActive","pluginIsActive","refreshEnabledStatus","checkAutocompleteStatus","success","data","autocompleteEnabled","setAutocompleteStatus","error","getError","refreshIndexIRIs","shouldIndexIRIs","refreshIndexStatus","indexStatus","refreshLabelConfig","labelConfig","checkForPlugin","pluginFound","setLoader","loading","finally","pullStatus","$broadcast","$on","loader","message","loaderTimeout","loaderMessage","getLoaderMessage","instant","toggleAutocomplete","newValue","toggleIndexIRIs","buildIndex","interruptIndexing","getDegradedReason","addLabel","editLabel","labelIri","languages","label","isNew","open","templateUrl","controller","resolve","result","then","addLabelConfig","removeLabel","removeLabelConfig","isLicenseValid","getActiveRepository","isActiveRepoOntopType","isActiveRepoFedXType","AddLabelCtrl","$modalInstance","copy","ok","form","$valid","close","dismiss","setTemplate","iri","$","focus","$inject"],"mappings":"8FAAA,aAOAA,QAAQC,OAAO,iCALC,CACZ,UACA,gD,gCCJJ,aAcA,SAASC,EAAiBC,EAAQC,EAAWC,EAAQC,EAAeC,EAAiBC,EAAQC,EAAUC,EAAyBC,EAAqBC,GAEjJ,IAAIC,EAEJ,SAASC,IACDD,GACAT,EAAUW,OAAOF,GAIzBV,EAAOa,WAAa,eAEpBb,EAAOc,kBAAoB,SAAUC,GACjCf,EAAOgB,eAAiBD,GAG5B,MAAME,EAAuB,WACzBV,EAAwBW,0BACnBC,SAAQ,SAAUC,GACfpB,EAAOqB,oBAAsBD,EAC7BZ,EAAoBc,sBAAsBF,MAC3CG,OAAM,SAAUH,GACnBlB,EAAOqB,MAAMC,SAASJ,QAIxBK,EAAmB,WACrBlB,EAAwBkB,mBACnBN,SAAQ,SAAUC,GACfpB,EAAO0B,gBAAkBN,KAC1BG,OAAM,SAAUH,GACnBlB,EAAOqB,MAAMC,SAASJ,QAIxBO,EAAqB,WACvBpB,EAAwBoB,qBACnBR,SAAQ,SAAUC,GACfpB,EAAO4B,YAAcR,KAExBG,OAAM,SAAUH,GACblB,EAAOqB,MAAMC,SAASJ,QAI5BS,EAAqB,WACvBtB,EAAwBsB,qBACnBV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SAASJ,OACvBe,SAAQ,WACPnC,EAAOiC,WAAU,MAuJrBgC,CAAkBV,IAGtBvD,EAAOsC,IAAI,mBAAmB,WAC1B3B,IACKP,EAAgB8D,kBAChB/D,EAAcgE,wBACfhE,EAAciE,0BACdjE,EAAckE,yBAGlBrE,EAAO+B,iBACPK,QAzHKhC,EAAgB8D,kBAChB/D,EAAcgE,wBACfhE,EAAciE,0BACdjE,EAAckE,yBAGlBrE,EAAO+B,iBACPK,KA0HR,SAASkC,EAAatE,EAAQuE,EAAgBjE,EAAUc,GACpDpB,EAAOuD,MAAQ1D,QAAQ2E,KAAKpD,EAAKmC,OACjCvD,EAAOwD,MAAQpC,EAAKoC,MAEpBxD,EAAOyE,GAAK,WACJzE,EAAO0E,KAAKC,QACZJ,EAAeK,MAAM5E,EAAOuD,QAIpCvD,EAAOY,OAAS,WACZ2D,EAAeM,QAAQ,WAG3B7E,EAAO8E,YAAc,SAAUC,GAC3B/E,EAAOuD,MAAMF,SAAW0B,EACxBzE,GAAS,WACL0E,EAAE,8BAA8BC,UACjC,IAnRXpF,QACKC,OAAO,6CANI,CACZ,SACA,gDAKC6D,WAAW,mBAAoB5D,GAC/B4D,WAAW,eAAgBW,GAEhCvE,EAAiBmF,QAAU,CAAC,SAAU,YAAa,SAAU,gBAAiB,kBAAmB,SAAU,WAAY,0BAA2B,sBAAuB,cA0PzKZ,EAAaY,QAAU,CAAC,SAAU,iBAAkB,WAAY","file":"35.8be1042671722a19f3b4.bundle.js","sourcesContent":["import 'angular/autocomplete/controllers';\n\nconst modules = [\n 'ngRoute',\n 'graphdb.framework.autocomplete.controllers'\n];\n\nangular.module('graphdb.framework.autocomplete', modules);\n","import 'angular/rest/autocomplete.rest.service';\n\nconst modules = [\n 'toastr',\n 'graphdb.framework.rest.autocomplete.service'\n];\n\nangular\n .module('graphdb.framework.autocomplete.controllers', modules)\n .controller('AutocompleteCtrl', AutocompleteCtrl)\n .controller('AddLabelCtrl', AddLabelCtrl);\n\nAutocompleteCtrl.$inject = ['$scope', '$interval', 'toastr', '$repositories', '$licenseService', '$modal', '$timeout', 'AutocompleteRestService', '$autocompleteStatus', '$translate'];\n\nfunction AutocompleteCtrl($scope, $interval, toastr, $repositories, $licenseService, $modal, $timeout, AutocompleteRestService, $autocompleteStatus, $translate) {\n\n let timer;\n\n function cancelTimer() {\n if (timer) {\n $interval.cancel(timer);\n }\n }\n\n $scope.pluginName = 'autocomplete';\n\n $scope.setPluginIsActive = function (isPluginActive) {\n $scope.pluginIsActive = isPluginActive;\n };\n\n const refreshEnabledStatus = function () {\n AutocompleteRestService.checkAutocompleteStatus()\n .success(function (data) {\n $scope.autocompleteEnabled = data;\n $autocompleteStatus.setAutocompleteStatus(data);\n }).error(function (data) {\n toastr.error(getError(data));\n });\n };\n\n const refreshIndexIRIs = function () {\n AutocompleteRestService.refreshIndexIRIs()\n .success(function (data) {\n $scope.shouldIndexIRIs = data;\n }).error(function (data) {\n toastr.error(getError(data));\n });\n };\n\n const refreshIndexStatus = function () {\n AutocompleteRestService.refreshIndexStatus()\n .success(function (data) {\n $scope.indexStatus = data;\n })\n .error(function (data) {\n toastr.error(getError(data));\n });\n };\n\n const refreshLabelConfig = function () {\n AutocompleteRestService.refreshLabelConfig()\n .success(function (data) {\n $scope.labelConfig = data;\n }).error(function (data) {\n toastr.error(getError(data));\n });\n };\n\n const addLabelConfig = function (label) {\n $scope.setLoader(true, $translate.instant('autocomplete.update'));\n\n\n AutocompleteRestService.addLabelConfig(label)\n .success(function () {\n refreshLabelConfig();\n refreshIndexStatus();\n }).error(function (data) {\n toastr.error(getError(data));\n }).finally(function () {\n $scope.setLoader(false);\n });\n };\n\n const removeLabelConfig = function (label) {\n $scope.setLoader(true, $translate.instant('autocomplete.update'));\n\n AutocompleteRestService.removeLabelConfig(label)\n .success(function () {\n refreshLabelConfig();\n refreshIndexStatus();\n }).error(function (data) {\n toastr.error(getError(data));\n }).finally(function () {\n $scope.setLoader(false);\n });\n };\n\n $scope.checkForPlugin = function () {\n $scope.pluginFound = false;\n\n $scope.setLoader(true);\n\n AutocompleteRestService.checkForPlugin()\n .success(function (data) {\n $scope.pluginFound = data === true;\n if ($scope.pluginFound) {\n refreshEnabledStatus();\n refreshIndexIRIs();\n refreshIndexStatus();\n refreshLabelConfig();\n } else {\n $scope.autocompleteEnabled = false;\n $scope.loading = false;\n }\n }).error(function (data) {\n toastr.error(getError(data));\n }).finally(function () {\n $scope.setLoader(false);\n });\n };\n\n const pullStatus = function () {\n timer = $interval(function () {\n $scope.$broadcast('checkIsActive');\n if ($scope.autocompleteEnabled) {\n refreshIndexStatus();\n }\n }, 5000);\n };\n\n $scope.$on(\"$destroy\", function () {\n cancelTimer();\n });\n\n const init = function() {\n if (!$licenseService.isLicenseValid() ||\n !$repositories.getActiveRepository() ||\n $repositories.isActiveRepoOntopType() ||\n $repositories.isActiveRepoFedXType()) {\n return;\n }\n $scope.checkForPlugin();\n pullStatus();\n };\n\n $scope.setLoader = function (loader, message) {\n $timeout.cancel($scope.loaderTimeout);\n if (loader) {\n $scope.loaderTimeout = $timeout(function () {\n $scope.loader = loader;\n $scope.loaderMessage = message;\n }, 300);\n } else {\n $scope.loader = false;\n }\n };\n\n $scope.getLoaderMessage = function () {\n return $scope.loaderMessage || $translate.instant('common.loading');\n };\n\n $scope.toggleAutocomplete = function () {\n const newValue = !$scope.autocompleteEnabled;\n $scope.setLoader(true, newValue ? $translate.instant('autocomplete.enabling') : $translate.instant('autocomplete.disabling'));\n\n AutocompleteRestService.toggleAutocomplete(newValue)\n .success(function () {\n refreshEnabledStatus();\n refreshIndexStatus();\n }).error(function (data) {\n toastr.error(getError(data));\n }).finally(function () {\n $scope.setLoader(false);\n });\n };\n\n $scope.toggleIndexIRIs = function () {\n $scope.setLoader(true, ($translate.instant('autocomplete.index.iri')));\n\n AutocompleteRestService.toggleIndexIRIs(!$scope.shouldIndexIRIs)\n .success(function () {\n refreshIndexIRIs();\n refreshIndexStatus();\n }).error(function (data) {\n toastr.error(getError(data));\n }).finally(function () {\n $scope.setLoader(false);\n });\n };\n\n $scope.buildIndex = function () {\n $scope.setLoader(true, $translate.instant('autocomplete.index.build'));\n\n AutocompleteRestService.buildIndex()\n .success(function () {\n $scope.indexStatus = 'BUILDING';\n }).error(function (data) {\n toastr.error(getError(data));\n }).finally(function () {\n $scope.setLoader(false);\n });\n };\n\n $scope.interruptIndexing = function () {\n $scope.setLoader(true, $translate.instant('index.interrupt'));\n\n AutocompleteRestService.interruptIndexing()\n .success(function () {\n refreshIndexStatus();\n }).error(function (data) {\n toastr.error(getError(data));\n }).finally(function () {\n $scope.setLoader(false);\n });\n };\n\n $scope.getDegradedReason = function () {\n return $repositories.getDegradedReason();\n };\n\n $scope.addLabel = function () {\n $scope.editLabel({labelIri: '', languages: ''}, true);\n };\n\n $scope.editLabel = function (label, isNew) {\n const modalInstance = $modal.open({\n templateUrl: 'js/angular/autocomplete/templates/modal/add-label.html',\n controller: 'AddLabelCtrl',\n resolve: {\n data: function () {\n return {\n label: label,\n isNew: isNew\n };\n }\n }\n });\n\n modalInstance.result.then(function (label) {\n addLabelConfig(label);\n });\n };\n\n $scope.removeLabel = function (label) {\n removeLabelConfig(label);\n };\n\n $scope.$on('repositoryIsSet', function () {\n cancelTimer();\n if (!$licenseService.isLicenseValid() ||\n !$repositories.getActiveRepository() ||\n $repositories.isActiveRepoOntopType() ||\n $repositories.isActiveRepoFedXType()) {\n return;\n }\n $scope.checkForPlugin();\n pullStatus();\n });\n\n init();\n}\n\nAddLabelCtrl.$inject = ['$scope', '$modalInstance', '$timeout', 'data'];\n\nfunction AddLabelCtrl($scope, $modalInstance, $timeout, data) {\n $scope.label = angular.copy(data.label);\n $scope.isNew = data.isNew;\n\n $scope.ok = function () {\n if ($scope.form.$valid) {\n $modalInstance.close($scope.label);\n }\n };\n\n $scope.cancel = function () {\n $modalInstance.dismiss('cancel');\n };\n\n $scope.setTemplate = function (iri) {\n $scope.label.labelIri = iri;\n $timeout(function () {\n $('#wb-autocomplete-languages').focus();\n }, 0);\n };\n}\n"],"sourceRoot":""}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp=window.webpackJsonp||[]).push([[36,61],{43:function(e,i){angular.module("graphdb.framework.core.directives.paginations",[]).directive("paginations",(function(){return{template:'<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"></pagination>'}}))},89:function(e,i,a){"use strict";a.r(i);a(20),a(43);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"]}}]);
|
|
2
|
-
//# sourceMappingURL=36.8d7becdfce12d9a0de33.bundle.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack:///./src/js/angular/core/directives/paginations.js","webpack:///./src/js/angular/guides/controllers.js"],"names":["angular","module","directive","template","GuidesCtrl","$scope","$rootScope","GuidesService","$filter","$translate","$interpolate","guides","pageSizeOptions","page","pageSize","translationSubscription","undefined","init","getGuides","then","forEach","guide","translatedGuideName","translateLocalMessage","guideName","translatedGuideDescription","guideDescription","guideLevel","guideLevelLabel","matchedElements","changePagination","startGuide","this","$on","isDefined","displayedGuides","slice","changePageSize","size","controller","$inject"],"mappings":"8EAAAA,QAAQC,OAAO,gDAAiD,IAC3DC,UAAU,eAAe,WACtB,MAAO,CACHC,SAAU,iP,gCCHtB,8BAgBA,SAASC,EAAWC,EAAQC,EAAYC,EAAeC,EAASC,EAAYC,GAExEL,EAAOM,OAAS,GAChBN,EAAOO,gBAAkB,CAAC,GAAI,GAAI,GAAI,KACtCP,EAAOQ,KAAO,EACdR,EAAOS,SAAWT,EAAOO,gBAAgB,GACzCP,EAAOU,6BAA0BC,EAEjCX,EAAOY,KAAO,WACVV,EAAcW,YACTC,KAAKR,IACFN,EAAOM,OAASH,EAAQ,UAARA,CAAmBG,EAAQ,cAC3CN,EAAOM,OAAOS,QAAQC,IAGlB,OAFAA,EAAMC,oBAAsB,aAAWC,sBAAsBd,EAAYC,EAAcW,EAAMG,WAC7FH,EAAMI,2BAA6B,aAAWF,sBAAsBd,EAAYC,EAAcW,EAAMK,kBAC5FL,EAAMM,YACV,UAAKX,EACL,KAAK,EACDK,EAAMO,gBAAkB,6BACxB,MACJ,KAAK,EACDP,EAAMO,gBAAkB,iCACxB,MACJ,QACIP,EAAMO,gBAAkB,gCAGpCvB,EAAOwB,gBAAkBxB,EAAOM,OAChCN,EAAOyB,sBAInBzB,EAAO0B,WAAa,SAAUV,GAC1Bd,EAAcwB,WAAWV,IAGxBW,KAAKjB,0BACNiB,KAAKjB,wBAA0BT,EAAW2B,IAAI,0BAA2B,KACrE5B,EAAOY,UAIfZ,EAAOyB,iBAAmB,WAClB9B,QAAQkC,UAAU7B,EAAOM,UACzBN,EAAO8B,gBAAkB9B,EAAOM,OAAOyB,MAAM/B,EAAOS,UAAYT,EAAOQ,KAAO,GAAIR,EAAOS,SAAWT,EAAOQ,QAInHR,EAAOgC,eAAiB,SAAUC,GAC9BjC,EAAOQ,KAAO,EAEVR,EAAOS,SADPwB,GAGkBjC,EAAOO,gBAAgB,GAE7CP,EAAOyB,oBAGXzB,EAAOY,OAhEXjB,QACKC,OAAO,uCAPI,CACZ,eACA,oCACA,kDAKCsC,WAAW,aAAcnC,GAE9BA,EAAWoC,QAAU,CAAC,SAAU,aAAc,gBAAiB,UAAW,aAAc","file":"36.8d7becdfce12d9a0de33.bundle.js","sourcesContent":["angular.module('graphdb.framework.core.directives.paginations', [])\n .directive('paginations', function () {\n return {\n template: '<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\"></pagination>',\n };\n });\n","import 'angular/guides/guides.service';\nimport 'angular/core/directives/paginations';\nimport {GuideUtils} from \"./guide-utils\";\n\nconst modules = [\n 'ui.bootstrap',\n 'graphdb.framework.guides.services',\n 'graphdb.framework.core.directives.paginations'\n];\n\nangular\n .module('graphdb.framework.guides.controllers', modules)\n .controller('GuidesCtrl', GuidesCtrl);\n\nGuidesCtrl.$inject = ['$scope', '$rootScope', 'GuidesService', '$filter', '$translate', '$interpolate'];\n\nfunction GuidesCtrl($scope, $rootScope, GuidesService, $filter, $translate, $interpolate) {\n\n $scope.guides = [];\n $scope.pageSizeOptions = [10, 20, 50, 100];\n $scope.page = 1;\n $scope.pageSize = $scope.pageSizeOptions[0];\n $scope.translationSubscription = undefined;\n\n $scope.init = function () {\n GuidesService.getGuides()\n .then(guides => {\n $scope.guides = $filter('orderBy')(guides, 'guideOrder');\n $scope.guides.forEach(guide => {\n guide.translatedGuideName = GuideUtils.translateLocalMessage($translate, $interpolate, guide.guideName);\n guide.translatedGuideDescription = GuideUtils.translateLocalMessage($translate, $interpolate, guide.guideDescription);\n switch (guide.guideLevel) {\n case undefined:\n case 0:\n guide.guideLevelLabel = 'view.guides.level.beginner';\n break;\n case 1:\n guide.guideLevelLabel = 'view.guides.level.intermediate';\n break;\n default: // 2 and above\n guide.guideLevelLabel = 'view.guides.level.advanced';\n }\n });\n $scope.matchedElements = $scope.guides;\n $scope.changePagination();\n });\n };\n\n $scope.startGuide = function (guide) {\n GuidesService.startGuide(guide);\n };\n\n if (!this.translationSubscription) {\n this.translationSubscription = $rootScope.$on('$translateChangeSuccess', () => {\n $scope.init();\n });\n }\n\n $scope.changePagination = function () {\n if (angular.isDefined($scope.guides)) {\n $scope.displayedGuides = $scope.guides.slice($scope.pageSize * ($scope.page - 1), $scope.pageSize * $scope.page);\n }\n };\n\n $scope.changePageSize = function (size) {\n $scope.page = 1;\n if (size) {\n $scope.pageSize = size;\n } else {\n $scope.pageSize = $scope.pageSizeOptions[0];\n }\n $scope.changePagination();\n };\n\n $scope.init();\n}\n"],"sourceRoot":""}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack:///./src/js/angular/rest/connectors.rest.service.js","webpack:///./src/js/angular/externalsync/controllers.js"],"names":["angular","module","factory","ConnectorsRestService","$inject","$http","getConnectors","get","initConnector","prefix","hasConnector","checkConnector","data","post","headers","jsonToFormData","str","Object","keys","forEach","key","push","encodeURIComponent","join","fromArrayMap","arrayMap","$translate","_","reduce","acc","value","Error","instant","hasOwnProperty","mapCreateValuesToUiValues","values","options","i","length","option","__type","__name","j","__childOptions","child","k","valueK","isDefined","__defaultValue","optionEl","isUndefined","map","String","toJson","_evaluateSparqlQuery","http","repository","query","buildNamePrefix","substring","createConnectorQuery","name","fields","reportError","fcopy","sortObject","obj","newObject","each","childOption","copy","fromJson","e","__label","message","removeEmptyValues","Array","isArray","filter","item","trim","finalString","replace","ConnectorsCtrl","$scope","$repositories","$modal","toastr","ModalService","$q","RDF4JRepositoriesRestService","resetProgress","repair","beingBuiltConnector","percentDone","status","processedEntities","estimatedEntities","indexedEntities","entitiesPerSecond","actionName","waitOnRepairStartOnce","eta","inline","iri","openProgressModal","$","extend","doneCallback","modalInstance","dismiss","open","templateUrl","controller","size","backdrop","scope","executeCreate","connector","errorCallback","modal","addStatements","getActiveRepository","update","then","res","existing","success","err","error","getError","finally","loader","controllers","definitions","getLoaderMessage","timeSeconds","Date","now","loaderStartTime","timeHuman","getHumanReadableSeconds","progressMessage","extraMessage","setLoader","isRunning","isLicenseValid","canWriteActiveRepo","connectors","all","connectorIris","createStatusQueryForAny","evaluateSparqlQuery","results","bindings","statusObject","JSON","parse","console","parseFirstBuildingResult","d","split","catch","getOptions","isEmpty","isObject","toPrettyJson","$watch","getActiveLocation","copyConnector","newValues","resolve","result","skipConversion","newConnector","inst","type","openSimpleModal","title","warning","delete","isExternal","indexOf","popoverMsg","force","namePrefix","deleteConnectorQuery","viewQuery","DeleteConnectorCtrl","$modalInstance","ok","close","cancel","ExtendNewConnectorCtrl","toQuery","label","addField","index","optionName","newField","defaultValues","splice","addOption","array","deleteOption","addMapOption","deleteMapOption","form","$valid","CreateConnectorCtrl","$controller","this","CreateProgressCtrl","$interval","initProgress","statusIri","createStatusQueryForIri","progressInterval","getFirstStatusFromResult","toFixed","etaSeconds","$on","input","Math","ceil"],"mappings":"+EAAAA,QACKC,OAAO,4CAA6C,IACpDC,QAAQ,wBAAyBC,GAEtCA,EAAsBC,QAAU,CAAC,SAIjC,SAASD,EAAsBE,GAE3B,MAAO,CACHC,cAMJ,WACI,OAAOD,EAAME,IAZO,oBAMpBC,cASJ,SAAuBC,GACnB,OAAOJ,EAAME,IAAI,kCAAyCE,IAT1DC,aAYJ,SAAsBD,GAClB,OAAOJ,EAAME,IAAI,mCAA0CE,IAZ3DE,eAeJ,SAAwBC,GACpB,OAAOP,EAAMQ,KAAK,wBAAgCD,EAAM,CACpDE,QAAS,CACL,eAAgB,oB,gCChChC,mBAiBA,SAASC,EAAeH,GACpB,MAAMI,EAA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AAMlB,EAAOyD,wBAAwB9C,EAAO6H,YACvExI,EAAOS,oBAAoBO,WAAaL,EAAOH,OAASlE,EAAWM,QAAQ,0BAA4BN,EAAWM,QAAQ,yBAC1HoD,EAAOS,oBAAoBQ,uBAAwB,GAC1B,UAAlBN,EAAOA,QAAuBX,EAAOS,oBAAoBQ,wBAEhEgH,EAAUrB,OAAO5G,EAAOqI,kBACpBrI,EAAOS,oBAAoBe,cAC3BxB,EAAOS,oBAAoBe,qBAI5C,KAEHxB,EAAOyI,IAAI,YAAY,WACnBR,EAAUrB,OAAO5G,EAAOqI,qBAIhCrI,EAAOS,oBAAsBT,EAAOS,qBAAuB,IAGtDT,EAAOS,oBAAoBU,QAAUnB,EAAOS,oBAAoBW,KACjE8G,IAIJlI,EAAOmF,OAAO,2BAA2B,SAAUzI,GAC3CsD,EAAOS,oBAAoBU,QAAUzE,GACrCwL,OA1tBZtN,QACKC,OAAO,6CANI,CACZ,oDACA,8CAKCgH,WAAW,iBAAkB9B,GAC7B8B,WAAW,yBAA0BgF,GACrChF,WAAW,sBAAuBgG,GAClChG,WAAW,qBAAsBmG,GACjCnG,WAAW,sBAAuB2E,GAClC9G,OAAO,QAwtBZ,WACI,OAAO,SAAUgJ,GACb,OAAOC,KAAKC,KAAKF,OA1fzB3I,EAAe/E,QAAU,CAAC,SAAU,QAAS,gBAAiB,SAAU,SAAU,eAAgB,KAAM,+BAAgC,wBAAyB,cAkVjKwL,EAAoBxL,QAAU,CAAC,SAAU,iBAAkB,cAc3D6L,EAAuB7L,QAAU,CAAC,SAAU,iBAAkB,YAAa,SAAU,UAgErF6M,EAAoB7M,QAAU,CAAC,SAAU,cAAe,QAAS,iBAAkB,YAAa,SAAU,SAAU,WAqBpHgN,EAAmBhN,QAAU,CAAC,SAAU,YAAa,QAAS,gBAAiB","file":"38.f4b561d7ee5b236ba481.bundle.js","sourcesContent":["angular\n .module('graphdb.framework.rest.connectors.service', [])\n .factory('ConnectorsRestService', ConnectorsRestService);\n\nConnectorsRestService.$inject = ['$http'];\n\nconst CONNECTORS_ENDPOINT = 'rest/connectors';\n\nfunction ConnectorsRestService($http) {\n\n return {\n getConnectors,\n initConnector,\n hasConnector,\n checkConnector\n };\n\n function getConnectors() {\n return $http.get(CONNECTORS_ENDPOINT);\n }\n\n function initConnector(prefix) {\n return $http.get(`${CONNECTORS_ENDPOINT}/options?prefix=${prefix}`);\n }\n\n function hasConnector(prefix) {\n return $http.get(`${CONNECTORS_ENDPOINT}/existing?prefix=${prefix}`);\n }\n\n function checkConnector(data) {\n return $http.post(`${CONNECTORS_ENDPOINT}/check`, data, {\n headers: {\n 'Content-Type': 'text/plain'\n }\n });\n }\n}\n","import 'angular/rest/rdf4j.repositories.rest.service';\nimport 'angular/rest/connectors.rest.service';\n\nconst modules = [\n 'graphdb.framework.rest.rdf4j.repositories.service',\n 'graphdb.framework.rest.connectors.service'\n];\n\nangular\n .module('graphdb.framework.externalsync.controllers', modules)\n .controller('ConnectorsCtrl', ConnectorsCtrl)\n .controller('ExtendNewConnectorCtrl', ExtendNewConnectorCtrl)\n .controller('CreateConnectorCtrl', CreateConnectorCtrl)\n .controller('CreateProgressCtrl', CreateProgressCtrl)\n .controller('DeleteConnectorCtrl', DeleteConnectorCtrl)\n .filter('ceil', ceil);\n\nfunction jsonToFormData(data) {\n const str = [];\n Object.keys(data).forEach(function (key) {\n str.push(encodeURIComponent(key) + '=' + encodeURIComponent(data[key]));\n });\n return str.join('&');\n}\n\nfunction toArrayMap(map) {\n return _.map(map, function (value, key) {\n return {key: key, value: value};\n });\n}\n\nfunction fromArrayMap(arrayMap, $translate) {\n return _.reduce(arrayMap, function (acc, value) {\n if (value.key === '' && value.value === '') {\n // empty pair, skip it\n } else if (value.key === '') {\n throw new Error($translate.instant('externalsync.empty.value.key.error', {value: value.value}));\n } else if (acc.hasOwnProperty(value.key)) {\n throw new Error($translate.instant('externalsync.duplicate.key.error', {key: value.key}));\n } else {\n acc[value.key] = value.value;\n }\n return acc;\n }, {});\n}\n\nfunction mapCreateValuesToUiValues(values, options) {\n for (let i = 0; i < options.length; i++) {\n const option = options[i];\n if (option.__type === 'StringArray') {\n if (!values[option.__name]) {\n values[option.__name] = [''];\n }\n } else if (option.__type === 'OptionArray') {\n if (!values[option.__name]) { // values has no entry for this option\n values[option.__name] = [];\n const optionEl = {};\n for (let j = 0; j < option.__childOptions.length; j++) {\n const child = option.__childOptions[j];\n if (child.__type === 'StringArray') {\n optionEl[child.__name] = [''];\n } else {\n optionEl[child.__name] = (!angular.isUndefined(child.__defaultValue) ? child.__defaultValue : '');\n }\n }\n values[option.__name].push(optionEl);\n } else { // values already has en entry for this option\n // Copies the default value for Boolean child options if no explicit value is set\n for (let j = 0; j < option.__childOptions.length; j++) {\n const child = option.__childOptions[j];\n if (child.__type === 'Boolean') {\n for (let k = 0; k < values[option.__name].length; k++) {\n const valueK = values[option.__name][k];\n if (!valueK.hasOwnProperty([child.__name]) && angular.isDefined(child.__defaultValue)) {\n valueK[child.__name] = child.__defaultValue;\n }\n }\n }\n }\n }\n } else if (option.__type === 'Map') {\n if (!values[option.__name]) {\n values[option.__name] = [];\n } else {\n values[option.__name] = toArrayMap(values[option.__name]);\n }\n } else if (option.__type === 'JsonString') {\n if (values[option.__name] && !(values[option.__name] instanceof String) && typeof values[option.__name] !== 'string') {\n values[option.__name] = angular.toJson(values[option.__name], 2);\n }\n } else {\n if (angular.isUndefined(values[option.__name])) {\n values[option.__name] = (!angular.isUndefined(option.__defaultValue) ? option.__defaultValue : '');\n }\n }\n }\n\n return values;\n}\n\nfunction _evaluateSparqlQuery(http, repository, query) {\n return http.post('repositories/' + repository, jsonToFormData({query: query}),\n {\n headers: {\n 'Content-Type': 'application/x-www-form-urlencoded',\n 'Accept': 'application/sparql-results+json',\n 'X-GraphDB-Local-Consistency': 'updating'\n }\n });\n}\n\nfunction buildNamePrefix(prefix) {\n return prefix.substring(0, prefix.length - 1) + '/instance#';\n}\n\nfunction createConnectorQuery(name, prefix, fields, options, reportError) {\n // Returns a copy of the parameter obj sorted according to the order in options\n function sortObject(obj, options) {\n const newObject = {};\n _.each(options, function (option) {\n if (angular.isDefined(obj[option.__name])) {\n if (option.__type === 'OptionArray') {\n newObject[option.__name] = [];\n _.each(obj[option.__name], function (childOption) {\n newObject[option.__name].push(sortObject(childOption, option.__childOptions));\n });\n } else {\n newObject[option.__name] = angular.copy(obj[option.__name]);\n }\n }\n });\n return newObject;\n }\n\n const fcopy = sortObject(fields, options);\n\n for (let i = 0; i < options.length; i++) {\n try {\n if (options[i].__type === 'Map') {\n fcopy[options[i].__name] = fromArrayMap(fcopy[options[i].__name], $translate);\n } else if (options[i].__type === 'JsonString') {\n fcopy[options[i].__name] = angular.fromJson(fcopy[options[i].__name]);\n }\n } catch (e) {\n reportError(options[i].__label, e.message);\n return null;\n }\n }\n\n removeEmptyValues(fcopy);\n //escapeValues(fields);\n let finalString = '';\n finalString += 'PREFIX :<' + prefix + '>\\n';\n const namePrefix = buildNamePrefix(prefix);\n finalString += 'PREFIX inst:<' + namePrefix + '>\\n';\n finalString += 'INSERT DATA {\\n';\n finalString += \"\\tinst:\" + name + \" :createConnector '''\\n\"; // eslint-disable-line quotes\n finalString += angular.toJson(fcopy, 2);\n finalString += \"\\n''' .\\n}\\n\"; // eslint-disable-line quotes\n finalString = finalString.replace(/\\\\/g, '\\\\\\\\\\\\');\n return finalString;\n}\n\nfunction createStatusQueryForIri(iri) {\n const statusIri = iri.replace(/\\/instance#.+$/, '#connectorStatus');\n let finalString = '';\n finalString += 'SELECT ?status {\\n';\n finalString += '\\t<' + iri + '> <' + statusIri + '> ?status';\n finalString += '\\n}';\n return finalString;\n}\n\nfunction createStatusQueryForAny(connectors) {\n const connectorIris = _.map(connectors,\n function (k) {\n return '<' + k.value + 'connectorStatus' + '>';\n }).join('|');\n\n if (connectorIris) {\n return 'SELECT ?connector ?status { ?connector ' + connectorIris + ' ?status }';\n }\n\n return null;\n}\n\nfunction repairConnectorQuery(name, prefix) {\n const namePrefix = buildNamePrefix(prefix);\n return 'PREFIX prefix:<' + prefix + '>\\n' +\n 'INSERT DATA {\\n' +\n '\\t<' + namePrefix + name + '> prefix:repairConnector \"\"\\n' +\n '}';\n}\n\nfunction deleteConnectorQuery(name, prefix, force) {\n const namePrefix = prefix.substring(0, prefix.length - 1) + \"/instance#\";\n return 'PREFIX prefix:<' + prefix + '>\\n' +\n 'INSERT DATA {\\n' +\n '\\t<' + namePrefix + name + '> prefix:dropConnector \"' + (force ? \"force\" : \"\") + '\"\\n' +\n '}';\n}\n\nfunction removeEmptyValues(data) {\n // remove empty values from array\n if (Array.isArray(data)) {\n data = _.filter(data, function (item) {\n return item !== null && (!item.trim || item.trim() !== '');\n });\n }\n // remove empty values from object values\n Object.keys(data).forEach(function (key) {\n if ((data[key] === '' || data[key] == null) && data[key] !== false) {\n delete data[key];\n } else if (typeof data[key] === 'object') {\n data[key] = removeEmptyValues(data[key]);\n }\n });\n return data;\n}\n\nfunction parseFirstBuildingResult(results) {\n if (results.bindings) {\n for (let i = 0; i < results.bindings.length; i++) {\n try {\n const statusObject = JSON.parse(results.bindings[i].status.value);\n if (statusObject.status === 'BUILDING') {\n return {\n connector: results.bindings[i].connector.value,\n status: statusObject\n };\n }\n } catch (e) {\n console.error(e); // eslint-disable-line no-console\n }\n }\n }\n\n return {};\n}\n\nConnectorsCtrl.$inject = ['$scope', '$http', '$repositories', '$modal', 'toastr', 'ModalService', '$q', 'RDF4JRepositoriesRestService', 'ConnectorsRestService', '$translate'];\n\nfunction ConnectorsCtrl($scope, $http, $repositories, $modal, toastr, ModalService, $q, RDF4JRepositoriesRestService, ConnectorsRestService, $translate) {\n $scope.loader = false;\n\n $scope.controllers = [];\n\n $scope.existing = {};\n\n $scope.definitions = {};\n\n $scope.getLoaderMessage = function () {\n const timeSeconds = (Date.now() - $scope.loaderStartTime) / 1000;\n const timeHuman = $scope.getHumanReadableSeconds(timeSeconds);\n let message = '';\n if ($scope.progressMessage) {\n message = $scope.progressMessage + '... ' + timeHuman;\n } else {\n message = $translate.instant('common.running.operation', {timeHuman: timeHuman});\n }\n if ($scope.extraMessage && timeSeconds > 10) {\n message += '\\n' + $scope.extraMessage;\n }\n\n return message;\n };\n\n $scope.setLoader = function (isRunning, progressMessage, extraMessage) {\n if (isRunning) {\n $scope.loader = true;\n $scope.loaderStartTime = Date.now();\n $scope.progressMessage = progressMessage;\n $scope.extraMessage = extraMessage;\n } else {\n $scope.loader = false;\n $scope.progressMessage = '';\n $scope.extraMessage = '';\n }\n };\n\n $scope.initConnector = function (connector) {\n return ConnectorsRestService.initConnector(encodeURIComponent(connector.value))\n .then(function (res) {\n $scope.definitions[connector.key] = res.data;\n\n return ConnectorsRestService.hasConnector(encodeURIComponent(connector.value))\n .then(function (res) {\n $scope.existing[connector.key] = res.data;\n\n });\n });\n };\n\n $scope.getConnectors = function () {\n if (!$scope.isLicenseValid()) {\n return;\n }\n if (!$scope.canWriteActiveRepo()) {\n return;\n }\n\n $scope.setLoader(true, $translate.instant('externalsync.fetching.connectors'), $translate.instant('common.extra.message'));\n\n ConnectorsRestService.getConnectors()\n .then(function (res) {\n $scope.connectors = Object.keys(res.data).map(function (key) {\n return {key: key, value: res.data[key]};\n });\n\n $q.all(_.map($scope.connectors, function (connector) {\n return $scope.initConnector(connector);\n })).finally(function () {\n resetProgress();\n\n const query = createStatusQueryForAny($scope.connectors);\n\n if (query) {\n evaluateSparqlQuery(query)\n .then(function (res) {\n const status = parseFirstBuildingResult(res.data.results);\n if (status.connector) {\n // has a building connector, open progress indicator\n const d = status.connector.split(/#/);\n d[0] = d[0].replace(/\\/instance$/, '#');\n showProgress(d[0], d[1]);\n }\n })\n .finally(function () {\n $scope.setLoader(false);\n });\n } else {\n $scope.setLoader(false);\n }\n });\n }).catch(function (e) {\n $scope.setLoader(false);\n toastr.error(getError(e), $translate.instant('externalsync.could.not.get.connectors.error'));\n });\n\n $scope.existing = {};\n };\n\n $scope.getOptions = function (connector) {\n return $scope.definitions[connector.key];\n };\n\n $scope.isEmpty = function (value) {\n return angular.isObject(value) && Object.keys(value).length === 0;\n };\n\n $scope.toPrettyJson = function (value) {\n return angular.toJson(value, 2);\n };\n\n $scope.$watch(function () {\n return $repositories.getActiveRepository();\n }, $scope.getConnectors);\n\n $scope.$watch(function () {\n return $repositories.getActiveLocation();\n }, $scope.getConnectors);\n\n function evaluateSparqlQuery(query) {\n return _evaluateSparqlQuery($http, $repositories.getActiveRepository(), query);\n }\n\n function resetProgress(repair) {\n $scope.beingBuiltConnector = {\n percentDone: 0,\n status: {\n processedEntities: 0,\n estimatedEntities: 0,\n indexedEntities: 0,\n entitiesPerSecond: 0\n },\n actionName: repair ? $translate.instant('externalsync.repairing') : $translate.instant('externalsync.creating'),\n waitOnRepairStartOnce: !!repair,\n eta: '-',\n inline: false,\n iri: null\n };\n }\n\n function openProgressModal(prefix, name, repair) {\n resetProgress(repair);\n\n $.extend($scope.beingBuiltConnector, {\n iri: buildNamePrefix(prefix) + name,\n name: name,\n inline: false,\n doneCallback: function () {\n $scope.beingBuiltConnector.modalInstance.dismiss('cancel');\n }\n });\n\n $scope.beingBuiltConnector.modalInstance = $modal.open({\n templateUrl: 'pages/connectorProgress.html',\n controller: 'CreateProgressCtrl',\n size: 'lg',\n backdrop: 'static',\n scope: $scope\n });\n\n return $scope.beingBuiltConnector.modalInstance;\n }\n\n function showProgress(prefix, name) {\n resetProgress();\n\n $.extend($scope.beingBuiltConnector, {\n iri: buildNamePrefix(prefix) + name,\n name: name,\n inline: true,\n doneCallback: function () {\n $scope.beingBuiltConnector.inline = false;\n }\n });\n }\n\n function executeCreate(connector, obj, errorCallback) {\n const modal = openProgressModal(connector.value, obj.name, false);\n RDF4JRepositoriesRestService.addStatements($repositories.getActiveRepository(), jsonToFormData({update: obj.query}))\n .then(function () {\n ConnectorsRestService.getConnectors().then(function () {\n ConnectorsRestService.hasConnector(encodeURIComponent(connector.value)).then(function (res) {\n $scope.existing[connector.key] = res.data;\n });\n });\n toastr.success($translate.instant('created.connector', {name: obj.name}));\n }, function (err) {\n toastr.error(getError(err));\n errorCallback();\n }).finally(function () {\n modal.dismiss('cancel');\n });\n }\n\n $scope.copyConnector = function (connector, values) {\n let newValues;\n if (!angular.isUndefined(values)) {\n newValues = angular.copy(values);\n newValues.name = newValues.name + '-copy';\n }\n const modal = $modal.open({\n templateUrl: 'pages/createConnector.html',\n controller: 'CreateConnectorCtrl',\n size: 'lg',\n backdrop: 'static',\n resolve: {\n connector: function () {\n return connector;\n },\n values: function () {\n return angular.isUndefined(newValues) ? {name: '', values: {}} : newValues;\n },\n options: function () {\n return $scope.getOptions(connector);\n }\n }\n });\n\n modal.result.then(function (obj) {\n executeCreate(connector, obj, function () {\n obj.skipConversion = true;\n $scope.newConnector(connector, obj);\n });\n });\n };\n\n $scope.newConnector = function (connector, values) {\n const modal = $modal.open({\n templateUrl: 'pages/createConnector.html',\n controller: 'CreateConnectorCtrl',\n size: 'lg',\n backdrop: 'static',\n resolve: {\n connector: function () {\n return connector;\n },\n values: function () {\n return angular.isUndefined(values) ? {name: '', values: {}} : values;\n },\n options: function () {\n return $scope.getOptions(connector);\n }\n }\n });\n\n modal.result.then(function (obj) {\n executeCreate(connector, obj, function () {\n obj.skipConversion = true;\n $scope.newConnector(connector, obj);\n });\n });\n };\n\n $scope.repair = function (inst, type) {\n ModalService.openSimpleModal({\n title: $translate.instant('externalsync.confirm.repair'),\n message: $translate.instant('externalsync.repair.warning.msg'),\n warning: true\n }).result\n .then(function () {\n const modal = openProgressModal(type.value, inst.name, true);\n\n const query = repairConnectorQuery(inst.name, type.value);\n\n RDF4JRepositoriesRestService.addStatements($repositories.getActiveRepository(), jsonToFormData({update: query}))\n .then(function () {\n ConnectorsRestService.getConnectors().then(function () {\n ConnectorsRestService.hasConnector(encodeURIComponent(type.value)).then(function (res) {\n $scope.existing[type.key] = res.data;\n });\n });\n toastr.success($translate.instant('externalsync.repair.success.msg', {name: inst.name}));\n }, function (err) {\n toastr.error(getError(err));\n }).finally(function () {\n modal.dismiss('cancel');\n });\n });\n };\n\n $scope.delete = function (inst, type) {\n const isExternal = type.key.indexOf(\"Elastic\") >= 0 || type.key.indexOf(\"Solr\") >= 0;\n\n $modal.open({\n templateUrl: 'js/angular/externalsync/templates/deleteConnector.html',\n controller: 'DeleteConnectorCtrl',\n resolve: {\n popoverMsg: function () {\n return isExternal ? $translate.instant('delete.connector.conditional', {type: type.key}) : '';\n }\n }\n }).result\n .then(function(force) {\n $scope.setLoader(true, $translate.instant('externalsync.delete.progress.msg', {name: inst.name}),\n $translate.instant('externalsync.extra.message.warning'));\n\n const query = deleteConnectorQuery(inst.name, type.value, force);\n RDF4JRepositoriesRestService.addStatements($repositories.getActiveRepository(), jsonToFormData({update: query}))\n .then(function () {\n ConnectorsRestService.getConnectors().then(function () {\n ConnectorsRestService.hasConnector(encodeURIComponent(type.value)).then(function (res) {\n $scope.existing[type.key] = res.data;\n });\n });\n if (force) {\n toastr.success($translate.instant('externalsync.delete.force.success.msg', {name: inst.name}));\n if (isExternal) {\n toastr.warning($translate.instant('externalsync.delete.remote.warning', {key: type.key}));\n }\n } else {\n toastr.success($translate.instant('externalsync.delete.success.msg', {name: inst.name}));\n }\n }, function (err) {\n toastr.error(getError(err));\n }).finally(function() {\n $scope.setLoader(false);\n });\n });\n };\n\n $scope.viewQuery = function (connector, inst) {\n $modal.open({\n templateUrl: 'pages/viewQuery.html',\n controller: 'ViewQueryCtrl',\n resolve: {\n query: function () {\n const options = $scope.getOptions(connector);\n return createConnectorQuery(inst.name, connector.value,\n mapCreateValuesToUiValues(inst.values, options), options);\n }\n }\n });\n };\n}\n\nDeleteConnectorCtrl.$inject = ['$scope', '$modalInstance', 'popoverMsg'];\nfunction DeleteConnectorCtrl($scope, $modalInstance, popoverMsg) {\n $scope.force = false;\n $scope.popoverMsg = popoverMsg;\n\n $scope.ok = function () {\n $modalInstance.close($scope.force);\n };\n\n $scope.cancel = function () {\n $modalInstance.dismiss();\n };\n}\n\nExtendNewConnectorCtrl.$inject = ['$scope', '$modalInstance', 'connector', '$modal', 'toastr'];\nfunction ExtendNewConnectorCtrl($scope, $modalInstance, connector, $modal, toastr) {\n\n $scope.connector = connector;\n\n $scope.addField = function (index, optionName) {\n const newField = angular.copy($scope.defaultValues[optionName][0]);\n $scope.values[optionName].splice(index + 1, 0, newField);\n };\n\n $scope.addOption = function (index, array) {\n array.splice(index + 1, 0, '');\n };\n\n $scope.deleteOption = function (index, array) {\n array.splice(index, 1);\n };\n\n $scope.addMapOption = function (index, array) {\n array.splice(index + 1, 0, {key: '', value: ''});\n };\n\n $scope.deleteMapOption = function (index, array) {\n array.splice(index, 1);\n };\n\n function toQuery() {\n return createConnectorQuery($scope.name, connector.value, $scope.values, $scope.options,\n function (label, error) {\n toastr.error(error, label);\n });\n }\n\n $scope.ok = function () {\n if ($scope.form.$valid) {\n const query = toQuery();\n\n if (query) {\n $modalInstance.close({name: $scope.name, values: $scope.values, options: $scope.options, query: query});\n }\n }\n };\n\n $scope.viewQuery = function () {\n const query = toQuery();\n\n if (query) {\n $modal.open({\n templateUrl: 'pages/viewQuery.html',\n controller: 'ViewQueryCtrl',\n resolve: {\n query: function () {\n return query;\n }\n }\n });\n }\n };\n\n $scope.cancel = function () {\n $modalInstance.dismiss('cancel');\n };\n}\n\nCreateConnectorCtrl.$inject = ['$scope', '$controller', '$http', '$modalInstance', 'connector', '$modal', 'values', 'options'];\n\nfunction CreateConnectorCtrl($scope, $controller, $http, $modalInstance, connector, $modal, values, options) {\n angular.extend(this, $controller('ExtendNewConnectorCtrl', {\n $scope: $scope,\n $modalInstance: $modalInstance,\n connector: connector,\n $modal: $modal\n }));\n $scope.values = values.values;\n $scope.options = options;\n $scope.name = values.name;\n if (!values.skipConversion) {\n $scope.values = mapCreateValuesToUiValues($scope.values, $scope.options);\n }\n $scope.defaultValues = angular.copy($scope.values);\n}\n\n// Note that this is a fancy controller: it's used both for a modal and for a directive.\n// This means you can't rely on custom injection through resolve in the modal and the scope\n// must be shared with the main connectors controller.\nCreateProgressCtrl.$inject = ['$scope', '$interval', '$http', '$repositories', '$translate'];\n\nfunction CreateProgressCtrl($scope, $interval, $http, $repositories, $translate) {\n function evaluateSparqlQuery(query) {\n return _evaluateSparqlQuery($http, $repositories.getActiveRepository(), query);\n }\n\n function initProgress() {\n const query = createStatusQueryForIri($scope.beingBuiltConnector.iri);\n\n // reset iri value so that watch will fire again when we do something with the same connector\n $scope.beingBuiltConnector.iri = null;\n\n $scope.progressInterval = $interval(function () {\n function getFirstStatusFromResult(results) {\n if (results.bindings) {\n if (results.bindings.length > 0) {\n try {\n return JSON.parse(results.bindings[0].status.value);\n } catch (e) {\n console.error(e); // eslint-disable-line no-console\n }\n }\n }\n\n return {};\n }\n\n evaluateSparqlQuery(query)\n .then(function (res) {\n const status = getFirstStatusFromResult(res.data.results);\n if (status.status === 'BUILDING') {\n $scope.beingBuiltConnector.status = status;\n $scope.beingBuiltConnector.percentDone = (100 * status.processedEntities / status.estimatedEntities).toFixed(0);\n $scope.beingBuiltConnector.eta = $scope.getHumanReadableSeconds(status.etaSeconds);\n $scope.beingBuiltConnector.actionName = status.repair ? $translate.instant('externalsync.repairing') : $translate.instant('externalsync.creating');\n $scope.beingBuiltConnector.waitOnRepairStartOnce = false;\n } else if (status.status === 'BUILT' && !$scope.beingBuiltConnector.waitOnRepairStartOnce) {\n // done\n $interval.cancel($scope.progressInterval);\n if ($scope.beingBuiltConnector.doneCallback) {\n $scope.beingBuiltConnector.doneCallback();\n }\n }\n });\n }, 1000);\n\n $scope.$on('$destroy', function () {\n $interval.cancel($scope.progressInterval);\n });\n }\n\n $scope.beingBuiltConnector = $scope.beingBuiltConnector || {};\n\n // for modal instance we get the iri before hand and can start progress now\n if (!$scope.beingBuiltConnector.inline && $scope.beingBuiltConnector.iri) {\n initProgress();\n }\n\n // for inline progress we need to watch for the iri value\n $scope.$watch('beingBuiltConnector.iri', function (value) {\n if ($scope.beingBuiltConnector.inline && value) {\n initProgress();\n }\n });\n}\n\nfunction ceil() {\n return function (input) {\n return Math.ceil(input);\n };\n}\n"],"sourceRoot":""}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
(window.webpackJsonp=window.webpackJsonp||[]).push([[39,134],{39:function(e,n){function t(e,n){return{showToastMessageWithDelay:function(t){return new Promise(r=>{e.success(n.instant(t)),setTimeout(r,200)})}}}angular.module("graphdb.framework.utils.notifications",[]).factory("Notifications",t),t.$inject=["toastr","$translate"]},81:function(e,n,t){"use strict";t.r(n);t(39),t(5);function r(e,n,t,r,o,i,a,u,s,c,d,g,f,l,p,w,y){var m;e.page=1,e.totalPages=5,e.helpHidden=1===p.get(w.HIDE_GRAPH_CONFIG_HELP),e.toggleHelp=function(n){void 0===n&&(n=p.get(w.HIDE_GRAPH_CONFIG_HELP)),1!==n?(p.set(w.HIDE_GRAPH_CONFIG_HELP,1),e.helpHidden=!0):(p.set(w.HIDE_GRAPH_CONFIG_HELP,0),e.helpHidden=!1)},e.fixedVisualCallback=function(n,t){e.newConfig.startIRI=n,e.newConfig.startIRILabel=t,m=!0},e.isDefaultGraph=function(e){return"Minimal"===e.name||"Advanced"===e.name},e.isUserGraph=function(n){return!e.isDefaultGraph(n)},e.getSampleName=function(e,n){const t=e[n+"Description"];return t||(e.id?"Copy of "+e.name:e.name)};const C=g.configName;function h(e){r.warning(e)}function b(n){let t;return"query"===n.startMode&&1===e.page?t=n.startGraphQuery:2===e.page?t=n.expandQuery:3===e.page?t=n.resourceQuery:4===e.page?t=n.predicateLabelQuery:5===e.page&&(t=n.resourcePropertiesQuery),angular.isDefined(t)?t:""}function Q(){function i(){e.getAutocompletePromise=d.checkAutocompleteStatus()}c.getGraphConfigSamples().success((function(n){e.samples=_.filter(n,(function(n){return!n.id||e.newConfig.id!==n.id||(e.revertConfig=n,!1)}))})).error((function(e){r.error(getError(e),y.instant("graphexplore.error.graph.configs"))})),e.createGraphConfig=function(){c.createGraphConfig(e.newConfig).success((async function(){await f.showToastMessageWithDelay("graphexplore.saved.new.config"),t.url("graphs-visualizations")})).error((function(e){r.error(getError(e),y.instant("graphexplore.error.could.not.create"))}))},e.updateGraphConfig=function(){c.updateGraphConfig(e.newConfig).success((async function(){await f.showToastMessageWithDelay("graphexplore.saved.config"),t.url("graphs-visualizations")})).error((function(e){r.error(getError(e),y.instant("graphexplore.error.could.not.save"))}))},e.$on("autocompleteStatus",(function(){i()})),i(),e.getNamespacesPromise=l.getNamespaces(e.getActiveRepository());const a=function(e,n,t,r,o,i){n?c.validateQuery(n,t,r,o,i).success((function(){e()})).error((function(e){h(getError(e))})):e()};function u(){s()&&e.$broadcast("addStartFixedNodeAutomatically",{startIRI:e.newConfig.startIRI})}function s(){return 1===e.page&&"node"===e.newConfig.startMode}e.validateCurrentPage=function(n){e.updateModel(),1===e.page?"node"!==e.newConfig.startMode||e.newConfig.startIRI?"query"!==e.newConfig.startMode||e.newConfig.startGraphQuery?"query"===e.newConfig.startMode?a(n,e.newConfig.startGraphQuery,"graph"):n():h(y.instant("graphexplore.provide.query")):h(y.instant("graphexplore.select.start.node")):2===e.page?a(n,e.newConfig.expandQuery,"construct",["node"]):3===e.page?a(n,e.newConfig.resourceQuery,"tuple",["node"],[],["type","label","comment","rank"]):4===e.page?a(n,e.newConfig.predicateLabelQuery,"tuple",["edge"],["label"]):5===e.page&&a(n,e.newConfig.resourcePropertiesQuery,"tuple",["node"],["property","value"])},e.goToPage=function(n){e.page!==n&&e.validateCurrentPage((function(){e.showEditor(),e.page=n,e.notoolbar=1!==e.page}))},e.goToPreviousPage=function(){e.page>1&&e.goToPage(e.page-1),s()&&(m=!1)},e.goToNextPage=function(){u(),("node"!==e.newConfig.startMode||m)&&e.goToPage(e.page+1)},e.saveGraphConfig=function(){u(),s()&&!m||(e.newConfig.startQueryIncludeInferred=e.currentQuery.inference,e.newConfig.startQuerySameAs=e.currentQuery.sameAs,e.validateCurrentPage((function(){e.newConfig.name?e.isUpdate?e.updateGraphConfig(e.newConfig):e.createGraphConfig(e.newConfig):h(y.instant("graphexplore.provide.config.name"))})))},e.updateModel=function(){const n=window.editor.getValue().trim();"query"===e.newConfig.startMode&&1===e.page?e.newConfig.startGraphQuery=n:2===e.page?e.newConfig.expandQuery=n:3===e.page?e.newConfig.resourceQuery=n:4===e.page?e.newConfig.predicateLabelQuery=n:5===e.page&&(e.newConfig.resourcePropertiesQuery=n)},e.setQuery=function(e){window.editor.setValue(e||" ")},e.updateDirty=function(){if(e.revertConfig){const n=b(e.revertConfig),t=window.editor.getValue().trim();e.queryEditorIsDirty=n!==t}},e.updateEditor=function(){n((function(){e.currentQuery.query=b(e.newConfig),o.isActiveRepoOntopType()&&(e.nocount=!0),e.currentQuery.inference=e.newConfig.startQueryIncludeInferred,e.currentQuery.sameAs=e.newConfig.startQuerySameAs,D(),E(e.currentQuery.id)}),100)},e.showEditor=function(){window.editor&&window.editor.xhr&&window.editor.xhr.abort(),e.viewMode="yasr"},e.showPreview=function(){e.currentQuery.outputType="table",e.runQuery()},e.revertEditor=function(){e.setQuery(b(e.revertConfig))},e.$watch("newConfig.startMode",(function(t){"query"===t&&n((function(){e.updateEditor()}),0)})),e.$watch("page",(function(t){("query"===e.newConfig.startMode||t>1)&&n((function(){e.showEditor(),e.updateEditor()}),0)}))}e.newConfig={startQueryIncludeInferred:!0,startQuerySameAs:!0},e.newConfig.startMode="search",e.isUpdate=!1,e.shared=!1,e.encodeQuery=function(e){return encodeURIComponent(e)},C?(e.isUpdate=!0,c.getConfig(C).success((function(n){e.newConfig=n,Q()})).error((function(e){r.error(getError(e),y.instant("created.connector",{name:C}))}))):(e.isUpdate=!1,Q());const T={id:"1",name:"",query:"select * where { \n\t?s ?p ?o .\n} limit 100 \n",inference:e.newConfig.startQueryIncludeInferred,sameAs:e.newConfig.startQuerySameAs};function M(e){}function v(n,t,r){const o=angular.element(document.getElementById("yasr-inner"));e.queryIsRunning=n,n?(e.queryStartTime=Date.now(),e.countTimeouted=!1,e.progressMessage=t,e.extraMessage=r,o.addClass("hide")):(e.progressMessage="",e.extraMessage="",o.removeClass("hide")),null===e.$$phase&&e.$apply()}function S(t){function r(){return window.innerHeight||document.documentElement.clientHeight||document.body.clientHeight||0}const o=t;if(e.orientationViewMode){if("yasr"===e.viewMode){let e=r()-document.querySelector(".CodeMirror-wrap").getBoundingClientRect().top;e-=40,document.querySelector(".CodeMirror-wrap").style.height=e+"px"}else e.noPadding={},document.querySelector(".CodeMirror-wrap").style.height="";document.getElementById("yasr").style.minHeight=""}else if(e.noPadding={paddingRight:15,paddingLeft:0},window.editor&&document.querySelector(".CodeMirror-wrap")){let e=r()-document.querySelector(".CodeMirror-wrap").getBoundingClientRect().top;e-=40,document.querySelector(".CodeMirror-wrap").style.height=e+"px",document.getElementById("yasr").style.minHeight=e+"px"}else{let t;t=n(o?function(){e.fixSizesOnHorizontalViewModeSwitch(o)}:e.fixSizesOnHorizontalViewModeSwitch,100),e.$on("$destroy",(function(){n.cancel(t)}))}window.yasr&&window.yasr.container&&n((function(){window.yasr.container.resize()}),100)}function x(){S(!0)}function E(e){n((function(){$('a[data-id = "'+e+'"]').tab("show")}),0)}function q(n,t){e.executedQueryTab=e.currentQuery,t&&"SELECT"!==window.editor.getQueryType()&&"CONSTRUCT"!==window.editor.getQueryType()?r.warning(y.instant("query.editor.warning.msg")):"update"!==window.editor.getQueryMode()?(e.explainRequested=t,e.queryIsRunning||(n?e.currentTabConfig.resultsCount=0:e.resetCurrentTabConfig(),e.viewMode="editor",e.orientationViewMode&&e.fixSizesOnHorizontalViewModeSwitch(),v(!0,y.instant("evaluating.query.msg")),window.editor.query())):r.warning(y.instant("cannot.execute.update.error"))}function I(){v(!0,y.instant("common.refreshing.namespaces"),y.instant("common.extra.message")),l.getRepositoryNamespaces().success((function(n){const t={};n.results.bindings.forEach((function(e){t[e.prefix.value]=e.namespace.value})),e.namespaces=t})).error((function(n){e.repositoryError=getError(n)})).finally((function(){v(!1)}))}function R(){u.addKnownPrefixes(JSON.stringify(window.editor.getValue())).success((function(e){angular.isDefined(window.editor)&&angular.isDefined(e)&&e!==window.editor.getValue()&&window.editor.setValue(e)})).error((function(e){let n=getError(e);return r.error(n,y.instant("common.add.known.prefixes.error")),!0}))}function P(n){let t=void 0;return angular.forEach(e.tabsData,(function(e){if(e.name===n.name&&e.query===n.body)return t=e.id,e})),t}function D(){e.tabsData=[e.currentQuery];let t=e.currentQuery;null==e.currentQuery.query||""===e.currentQuery.query?window.editor.setValue(" "):window.editor.setValue(e.currentQuery.query),n((function(){e.currentTabConfig={},e.currentTabConfig.queryType=t.queryType,e.currentTabConfig.resultsCount=t.resultsCount,e.currentTabConfig.offset=t.offset,e.currentTabConfig.allResultsCount=t.allResultsCount,e.currentTabConfig.page=t.page,e.currentTabConfig.pageSize=t.pageSize,e.currentTabConfig.timeFinished=t.timeFinished,e.currentTabConfig.timeTook=t.timeTook,e.currentTabConfig.sizeDelta=t.sizeDelta,e.$apply()}),0),$("#yasr").css("padding","0")}function H(e){return $(e).attr("data-id")}e.resetCurrentTabConfig=function(){e.currentTabConfig={pageSize:100,page:1,allResultsCount:0,resultsCount:0}},e.queryExists=!1,e.resetCurrentTabConfig(),e.tabsData=e.tabs=[T],e.saveTab=function(n){const t=function(n){for(let t=0;t<e.tabsData.length;t++){if(e.tabsData[t].id===n)return t}}(n);if(void 0===t)return{};const r=e.tabsData[t];return e.saveQueryToLocal(r),r},e.loadTab=D,e.addNewTab=function(e,n,t){},e.runQuery=q,e.getNamespaces=I,e.changePagination=function(){q(!0,e.explainRequested)},e.toggleSampleQueries=function(){},e.addKnownPrefixes=R,e.getExistingTabId=P,e.querySelected=function(n){const t=P(n);e.toggleSampleQueries(),angular.isDefined(t)?E(t):e.addNewTab(null,n.name,n.body)},e.saveQueryToLocal=M,e.setLoader=v,e.getLoaderMessage=function(){const n=(Date.now()-e.queryStartTime)/1e3,t=e.getHumanReadableSeconds(n);let r;r=e.progressMessage?e.progressMessage+"... "+t:y.instant("common.running.operation",{timeHuman:t});e.extraMessage&&n>10&&(r+="\n"+e.extraMessage);return r},e.fixSizesOnHorizontalViewModeSwitch=S,e.changeViewMode=function(t){e.viewMode="none",e.orientationViewMode=!e.orientationViewMode,S(),$(".dataTables_filter").remove(),$(".resultsTable").remove(),n((function(){D(),E(t)}),100)},e.showHideEditor=x,e.focusQueryEditor=function(){angular.element(document).find(".editable-input").is(":focus")||angular.element(document).find(".CodeMirror textarea:first-child").focus()},e.orientationViewMode=!0,e.orientationViewMode||x(),e.getActiveRepository()&&I(),e.$on("$destroy",(function(){window.editor=null,window.yasr=null})),$("textarea").on("paste",(function(){n((function(){R()}),0)})),e.$watchCollection("[currentQuery.inference, currentQuery.sameAs]",(function(){e.currentQuery})),e.$on("tabAction",(function(n,t){t.relatedTarget&&e.saveTab(H(t.relatedTarget)),e.loadTab(H(t.target))})),e.$on("deleteAllexeptSelected",(function(n,t){e.tabsData=t,e.tabs=t})),e.currentQuery=angular.copy(T),e.showSampleQueries=!1,e.savedQuery={},e.sampleQueries={},e.getResultsDescription=function(){},e.getUpdateDescription=function(){},e.getStaleWarningMessage=function(){}}angular.module("graphdb.framework.graphexplore.controllers.graphviz.config",["graphdb.framework.utils.notifications","graphdb.framework.utils.localstorageadapter"]).controller("GraphConfigCtrl",r),r.$inject=["$scope","$timeout","$location","toastr","$repositories","$modal","ModalService","SparqlRestService","$filter","GraphConfigRestService","AutocompleteRestService","$routeParams","Notifications","RDF4JRepositoriesRestService","LocalStorageAdapter","LSKeys","$translate"]}}]);
|
|
2
|
-
//# sourceMappingURL=39.68f59c2a9aeb4c4100c9.bundle.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"sources":["webpack:///./src/js/angular/utils/notifications.js","webpack:///./src/js/angular/graphexplore/controllers/graphs-config.controller.js"],"names":["Notifications","toastr","$translate","showToastMessageWithDelay","message","Promise","r","success","instant","setTimeout","angular","module","factory","$inject","GraphConfigCtrl","$scope","$timeout","$location","$repositories","$modal","ModalService","SparqlRestService","$filter","GraphConfigRestService","AutocompleteRestService","$routeParams","RDF4JRepositoriesRestService","LocalStorageAdapter","LSKeys","selectedFixedNodeChanged","page","totalPages","helpHidden","get","HIDE_GRAPH_CONFIG_HELP","toggleHelp","value","undefined","set","fixedVisualCallback","uri","label","newConfig","startIRI","startIRILabel","isDefaultGraph","sample","name","isUserGraph","getSampleName","property","extra","id","configName","showInvalidMsg","warning","getQueryForCurrentPage","config","query","startMode","startGraphQuery","expandQuery","resourceQuery","predicateLabelQuery","resourcePropertiesQuery","isDefined","initForConfig","checkAutocompleteStatus","getAutocompletePromise","getGraphConfigSamples","data","samples","_","filter","s","revertConfig","error","getError","createGraphConfig","async","url","updateGraphConfig","$on","getNamespacesPromise","getNamespaces","getActiveRepository","validateQueryWithCallback","successCallback","queryType","params","all","oneOf","validateQuery","broadcastAddStartFixedNodeEvent","checkPageAndMode","$broadcast","validateCurrentPage","updateModel","goToPage","nextPage","showEditor","notoolbar","goToPreviousPage","goToNextPage","saveGraphConfig","startQueryIncludeInferred","currentQuery","inference","startQuerySameAs","sameAs","isUpdate","window","editor","getValue","trim","setQuery","setValue","updateDirty","q1","q2","queryEditorIsDirty","updateEditor","isActiveRepoOntopType","nocount","loadTab","selectTab","xhr","abort","viewMode","showPreview","outputType","runQuery","revertEditor","$watch","shared","encodeQuery","encodeURIComponent","getConfig","defaultTabConfig","saveQueryToLocal","currentQueryTab","setLoader","isRunning","progressMessage","extraMessage","yasrInnerContainer","element","document","getElementById","queryIsRunning","queryStartTime","Date","now","countTimeouted","addClass","removeClass","$$phase","$apply","fixSizesOnHorizontalViewModeSwitch","verticalViewParam","visibleWindowHeight","innerHeight","documentElement","clientHeight","body","verticalView","orientationViewMode","newHeight","querySelector","getBoundingClientRect","style","height","noPadding","minHeight","paddingRight","paddingLeft","timer","cancel","yasr","container","resize","showHideEditor","$","tab","changePage","explain","executedQueryTab","getQueryType","getQueryMode","explainRequested","currentTabConfig","resultsCount","resetCurrentTabConfig","getRepositoryNamespaces","usedPrefixes","results","bindings","forEach","e","prefix","namespace","namespaces","repositoryError","finally","addKnownPrefixes","JSON","stringify","msg","getExistingTabId","existingTabId","tabsData","item","offset","allResultsCount","pageSize","timeFinished","timeTook","sizeDelta","css","getQueryID","attr","queryExists","tabs","saveTab","idx","i","length","findTabIndexByID","addNewTab","callback","tabName","savedQuery","changePagination","toggleSampleQueries","querySelected","tabId","getLoaderMessage","timeSeconds","timeHuman","getHumanReadableSeconds","changeViewMode","tabID","remove","focusQueryEditor","find","is","focus","on","$watchCollection","tabEvent","relatedTarget","target","copy","showSampleQueries","sampleQueries","getResultsDescription","getUpdateDescription","getStaleWarningMessage","controller"],"mappings":"+EAMA,SAASA,EAAcC,EAAQC,GAC3B,MAAO,CACHC,0BASJ,SAAmCC,GAC/B,OAAO,IAAIC,QAASC,IAChBL,EAAOM,QAAQL,EAAWM,QAAQJ,IAClCK,WAAWH,EAAG,SApB1BI,QACKC,OAAO,wCAAyC,IAChDC,QAAQ,gBAAiBZ,GAE9BA,EAAca,QAAU,CAAC,SAAU,e,gCCJnC,kBAYA,SAASC,EAAgBC,EAAQC,EAAUC,EAAWhB,EAAQiB,EAAeC,EAAQC,EAAcC,EAAmBC,EAASC,EAAwBC,EAAyBC,EAAczB,EAAe0B,EAA8BC,EAAqBC,EAAQ1B,GAoBpQ,IAAI2B,EAlBJd,EAAOe,KAAO,EACdf,EAAOgB,WAAa,EAEpBhB,EAAOiB,WAAwE,IAA3DL,EAAoBM,IAAIL,EAAOM,wBAEnDnB,EAAOoB,WAAa,SAAUC,QACZC,IAAVD,IACAA,EAAQT,EAAoBM,IAAIL,EAAOM,yBAE7B,IAAVE,GACAT,EAAoBW,IAAIV,EAAOM,uBAAwB,GACvDnB,EAAOiB,YAAa,IAEpBL,EAAoBW,IAAIV,EAAOM,uBAAwB,GACvDnB,EAAOiB,YAAa,IAK5BjB,EAAOwB,oBAAsB,SAAUC,EAAKC,GACxC1B,EAAO2B,UAAUC,SAAWH,EAC5BzB,EAAO2B,UAAUE,cAAgBH,EACjCZ,GAA2B,GAG/Bd,EAAO8B,eAAiB,SAAUC,GAC9B,MA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KAIlB/M,EAAO2F,aAAehG,QAAQkP,KAAKlH,GAEnC3H,EAAO8O,mBAAoB,EAC3B9O,EAAOwN,WAAa,GACpBxN,EAAO+O,cAAgB,GAEvB/O,EAAOgP,sBAAwB,aAG/BhP,EAAOiP,qBAAuB,aAG9BjP,EAAOkP,uBAAyB,aAvsBpCvP,QACKC,OAAO,6DAA8D,CAClE,wCACA,gDAEHuP,WAAW,kBAAmBpP,GAEnCA,EAAgBD,QAAU,CAAC,SAAU,WAAY,YAAa,SAAU,gBAAiB,SAAU,eAAgB,oBAAqB,UAAW,yBAA0B,0BAA2B,eAAgB,gBAAiB,+BAAgC,sBAAuB,SAAU","file":"39.68f59c2a9aeb4c4100c9.bundle.js","sourcesContent":["angular\n .module('graphdb.framework.utils.notifications', [])\n .factory('Notifications', Notifications);\n\nNotifications.$inject = ['toastr', '$translate'];\n\nfunction Notifications(toastr, $translate) {\n return {\n showToastMessageWithDelay\n };\n\n /**\n * This method will show message with tiny delay and only after completion\n * of latter redirection to \"graphs-visualizations\" page will happen.\n * @param {string} message The message to be displayed.\n * @return {Promise<any>}\n */\n function showToastMessageWithDelay(message) {\n return new Promise((r) => {\n toastr.success($translate.instant(message));\n setTimeout(r, 200);\n });\n }\n}\n","import 'angular/utils/notifications';\nimport 'angular/utils/local-storage-adapter';\n\nangular\n .module('graphdb.framework.graphexplore.controllers.graphviz.config', [\n 'graphdb.framework.utils.notifications',\n 'graphdb.framework.utils.localstorageadapter'\n ])\n .controller('GraphConfigCtrl', GraphConfigCtrl);\n\nGraphConfigCtrl.$inject = ['$scope', '$timeout', '$location', 'toastr', '$repositories', '$modal', 'ModalService', 'SparqlRestService', '$filter', 'GraphConfigRestService', 'AutocompleteRestService', '$routeParams', 'Notifications', 'RDF4JRepositoriesRestService', 'LocalStorageAdapter', 'LSKeys', '$translate'];\n\nfunction GraphConfigCtrl($scope, $timeout, $location, toastr, $repositories, $modal, ModalService, SparqlRestService, $filter, GraphConfigRestService, AutocompleteRestService, $routeParams, Notifications, RDF4JRepositoriesRestService, LocalStorageAdapter, LSKeys, $translate) {\n\n $scope.page = 1;\n $scope.totalPages = 5;\n\n $scope.helpHidden = LocalStorageAdapter.get(LSKeys.HIDE_GRAPH_CONFIG_HELP) === 1;\n\n $scope.toggleHelp = function (value) {\n if (value === undefined) {\n value = LocalStorageAdapter.get(LSKeys.HIDE_GRAPH_CONFIG_HELP);\n }\n if (value !== 1) {\n LocalStorageAdapter.set(LSKeys.HIDE_GRAPH_CONFIG_HELP, 1);\n $scope.helpHidden = true;\n } else {\n LocalStorageAdapter.set(LSKeys.HIDE_GRAPH_CONFIG_HELP, 0);\n $scope.helpHidden = false;\n }\n };\n\n var selectedFixedNodeChanged;\n $scope.fixedVisualCallback = function (uri, label) {\n $scope.newConfig.startIRI = uri;\n $scope.newConfig.startIRILabel = label;\n selectedFixedNodeChanged = true;\n };\n\n $scope.isDefaultGraph = function (sample) {\n return (sample.name === 'Minimal' || sample.name === 'Advanced');\n };\n\n $scope.isUserGraph = function (sample) {\n return !$scope.isDefaultGraph(sample);\n };\n\n $scope.getSampleName = function (sample, property) {\n const extra = sample[property + 'Description'];\n if (extra) {\n // Sample has description, use it\n return extra;\n } else {\n // Sample is a copy of existing config, prepend Copy of to name\n return sample.id ? 'Copy of ' + sample.name : sample.name;\n }\n };\n\n const getGraphConfigSamples = function () {\n GraphConfigRestService.getGraphConfigSamples()\n .success(function (data) {\n $scope.samples = _.filter(data, function (s) {\n // Skip the currently edited config from samples and store it into a revert variable\n if (!s.id || $scope.newConfig.id !== s.id) {\n return true;\n } else {\n $scope.revertConfig = s;\n return false;\n }\n });\n }).error(function (data) {\n toastr.error(getError(data), $translate.instant('graphexplore.error.graph.configs'));\n });\n };\n\n const configName = $routeParams.configName;\n $scope.newConfig = {startQueryIncludeInferred: true, startQuerySameAs: true};\n $scope.newConfig.startMode = 'search';\n $scope.isUpdate = false;\n $scope.shared = false;\n\n $scope.encodeQuery = function (query) {\n return encodeURIComponent(query);\n };\n\n function showInvalidMsg(message) {\n toastr.warning(message);\n }\n\n if (configName) {\n $scope.isUpdate = true;\n GraphConfigRestService.getConfig(configName)\n .success(function (data) {\n $scope.newConfig = data;\n initForConfig();\n })\n .error(function (data) {\n toastr.error(getError(data), $translate.instant('created.connector', {name: configName}));\n });\n } else {\n $scope.isUpdate = false;\n initForConfig();\n }\n\n function getQueryForCurrentPage(config) {\n let query;\n\n if (config.startMode === 'query' && $scope.page === 1) {\n query = config.startGraphQuery;\n } else if ($scope.page === 2) {\n query = config.expandQuery;\n } else if ($scope.page === 3) {\n query = config.resourceQuery;\n } else if ($scope.page === 4) {\n query = config.predicateLabelQuery;\n } else if ($scope.page === 5) {\n query = config.resourcePropertiesQuery;\n }\n\n return angular.isDefined(query) ? query : '';\n }\n\n function initForConfig() {\n getGraphConfigSamples();\n $scope.createGraphConfig = function () {\n GraphConfigRestService.createGraphConfig($scope.newConfig)\n .success(async function () {\n await Notifications.showToastMessageWithDelay('graphexplore.saved.new.config');\n $location.url('graphs-visualizations');\n }).error(function (data) {\n toastr.error(getError(data), $translate.instant('graphexplore.error.could.not.create'));\n });\n };\n\n $scope.updateGraphConfig = function () {\n GraphConfigRestService.updateGraphConfig($scope.newConfig)\n .success(async function () {\n await Notifications.showToastMessageWithDelay('graphexplore.saved.config');\n $location.url('graphs-visualizations');\n }).error(function (data) {\n toastr.error(getError(data), $translate.instant('graphexplore.error.could.not.save'));\n });\n };\n\n function checkAutocompleteStatus() {\n $scope.getAutocompletePromise = AutocompleteRestService.checkAutocompleteStatus();\n }\n\n $scope.$on('autocompleteStatus', function() {\n checkAutocompleteStatus();\n });\n\n checkAutocompleteStatus();\n $scope.getNamespacesPromise = RDF4JRepositoriesRestService.getNamespaces($scope.getActiveRepository());\n\n const validateQueryWithCallback = function (successCallback, query, queryType, params, all, oneOf) {\n if (!query) {\n successCallback();\n } else {\n GraphConfigRestService.validateQuery(query, queryType, params, all, oneOf)\n .success(function () {\n successCallback();\n }).error(function (data) {\n showInvalidMsg(getError(data));\n });\n }\n };\n\n $scope.validateCurrentPage = function (successCallback) {\n $scope.updateModel();\n\n if ($scope.page === 1) {\n if ($scope.newConfig.startMode === 'node' && !$scope.newConfig.startIRI) {\n showInvalidMsg($translate.instant('graphexplore.select.start.node'));\n } else if ($scope.newConfig.startMode === 'query' && !$scope.newConfig.startGraphQuery) {\n showInvalidMsg($translate.instant('graphexplore.provide.query'));\n } else if ($scope.newConfig.startMode === 'query') {\n validateQueryWithCallback(successCallback, $scope.newConfig.startGraphQuery, 'graph')\n } else {\n successCallback();\n }\n } else if ($scope.page === 2) {\n validateQueryWithCallback(successCallback, $scope.newConfig.expandQuery, 'construct', ['node'])\n } else if ($scope.page === 3) {\n validateQueryWithCallback(successCallback, $scope.newConfig.resourceQuery, 'tuple', ['node'], [], ['type', 'label', 'comment', 'rank']);\n } else if ($scope.page === 4) {\n validateQueryWithCallback(successCallback, $scope.newConfig.predicateLabelQuery, 'tuple', ['edge'], ['label']);\n } else if ($scope.page === 5) {\n validateQueryWithCallback(successCallback, $scope.newConfig.resourcePropertiesQuery, 'tuple', ['node'], ['property', 'value']);\n }\n };\n\n $scope.goToPage = function (nextPage) {\n if ($scope.page === nextPage) {\n // already there\n return;\n }\n\n $scope.validateCurrentPage(function () {\n $scope.showEditor();\n $scope.page = nextPage;\n $scope.notoolbar = $scope.page !== 1;\n });\n };\n\n $scope.goToPreviousPage = function () {\n if ($scope.page > 1) {\n $scope.goToPage($scope.page - 1);\n }\n\n if (checkPageAndMode()) {\n selectedFixedNodeChanged = false;\n }\n };\n\n $scope.goToNextPage = function () {\n broadcastAddStartFixedNodeEvent();\n if ($scope.newConfig.startMode !== 'node' || selectedFixedNodeChanged) {\n $scope.goToPage($scope.page + 1);\n }\n };\n\n function broadcastAddStartFixedNodeEvent() {\n if (checkPageAndMode()) {\n $scope.$broadcast('addStartFixedNodeAutomatically', {startIRI: $scope.newConfig.startIRI});\n }\n }\n\n function checkPageAndMode() {\n return $scope.page === 1 && $scope.newConfig.startMode === 'node';\n }\n\n $scope.saveGraphConfig = function () {\n broadcastAddStartFixedNodeEvent();\n\n if (checkPageAndMode() && !selectedFixedNodeChanged) {\n return;\n }\n\n $scope.newConfig.startQueryIncludeInferred = $scope.currentQuery.inference;\n $scope.newConfig.startQuerySameAs = $scope.currentQuery.sameAs;\n\n $scope.validateCurrentPage(function () {\n if (!$scope.newConfig.name) {\n showInvalidMsg($translate.instant('graphexplore.provide.config.name'));\n return;\n }\n $scope.isUpdate ? $scope.updateGraphConfig($scope.newConfig) : $scope.createGraphConfig($scope.newConfig);\n });\n };\n\n $scope.updateModel = function () {\n const query = window.editor.getValue().trim();\n if ($scope.newConfig.startMode === 'query' && $scope.page === 1) {\n $scope.newConfig.startGraphQuery = query;\n } else if ($scope.page === 2) {\n $scope.newConfig.expandQuery = query;\n } else if ($scope.page === 3) {\n $scope.newConfig.resourceQuery = query;\n } else if ($scope.page === 4) {\n $scope.newConfig.predicateLabelQuery = query;\n } else if ($scope.page === 5) {\n $scope.newConfig.resourcePropertiesQuery = query;\n }\n };\n\n // Called when user clicks on a sample query\n $scope.setQuery = function (query) {\n // Hack for YASQE bug\n window.editor.setValue(query ? query : ' ');\n };\n\n $scope.updateDirty = function () {\n if ($scope.revertConfig) {\n const q1 = getQueryForCurrentPage($scope.revertConfig);\n const q2 = window.editor.getValue().trim();\n $scope.queryEditorIsDirty = q1 !== q2;\n }\n };\n\n // Updates the position of the query editor to match the current div placeholder\n // and sets the editor's query to the relevant query from the model.\n $scope.updateEditor = function () {\n $timeout(function () {\n $scope.currentQuery.query = getQueryForCurrentPage($scope.newConfig);\n // // Check for ontop repository and override nocount property (it's default value is false)\n if ($repositories.isActiveRepoOntopType()) {\n $scope.nocount = true;\n }\n $scope.currentQuery.inference = $scope.newConfig.startQueryIncludeInferred;\n $scope.currentQuery.sameAs = $scope.newConfig.startQuerySameAs;\n loadTab();\n selectTab($scope.currentQuery.id);\n }, 100);\n\n };\n\n $scope.showEditor = function () {\n if (window.editor && window.editor.xhr) {\n window.editor.xhr.abort();\n }\n $scope.viewMode = 'yasr';\n };\n\n $scope.showPreview = function () {\n // For some reason YASR gets confused and sets this to rawResponse\n // if we execute a CONSTRUCT and then a SELECT. This makes sure it's always table.\n $scope.currentQuery.outputType = 'table';\n $scope.runQuery();\n };\n\n $scope.revertEditor = function () {\n $scope.setQuery(getQueryForCurrentPage($scope.revertConfig));\n };\n\n // Trigger for showing the editor and moving it to the right position\n $scope.$watch('newConfig.startMode', function (value) {\n if (value === 'query') {\n $timeout(function () {\n $scope.updateEditor();\n }, 0);\n }\n });\n\n // Trigger for showing the editor and moving it to the right position\n $scope.$watch('page', function (value) {\n if ($scope.newConfig.startMode === 'query' || value > 1) {\n $timeout(function () {\n $scope.showEditor();\n $scope.updateEditor();\n }, 0);\n }\n });\n }\n\n // DOWN HERE WE KEEP EVERYTHING PURELY QUERY EDITOR (MOSTLY BORROWED FROM query-editor.controller.js)\n // But Why? Can't we reuse it instead of borrow?\n\n const defaultTabConfig = {\n id: '1',\n name: '',\n query: 'select * where { \\n' +\n '\\t?s ?p ?o .\\n' +\n '} limit 100 \\n',\n inference: $scope.newConfig.startQueryIncludeInferred,\n sameAs: $scope.newConfig.startQuerySameAs\n };\n\n $scope.resetCurrentTabConfig = function () {\n $scope.currentTabConfig = {\n pageSize: 100, // page limit 100 as this is only used for preview\n page: 1,\n allResultsCount: 0,\n resultsCount: 0\n };\n };\n\n $scope.queryExists = false;\n\n $scope.resetCurrentTabConfig();\n\n $scope.tabsData = $scope.tabs = [defaultTabConfig];\n\n // query tab operations\n $scope.saveTab = saveTab;\n $scope.loadTab = loadTab;\n $scope.addNewTab = addNewTab;\n\n // query operations\n $scope.runQuery = runQuery;\n $scope.getNamespaces = getNamespaces;\n $scope.changePagination = changePagination;\n $scope.toggleSampleQueries = toggleSampleQueries;\n $scope.addKnownPrefixes = addKnownPrefixes;\n $scope.getExistingTabId = getExistingTabId;\n $scope.querySelected = querySelected;\n $scope.saveQueryToLocal = saveQueryToLocal;\n\n $scope.setLoader = setLoader;\n $scope.getLoaderMessage = getLoaderMessage;\n\n // query editor and results orientation\n $scope.fixSizesOnHorizontalViewModeSwitch = fixSizesOnHorizontalViewModeSwitch;\n $scope.changeViewMode = changeViewMode;\n $scope.showHideEditor = showHideEditor;\n $scope.focusQueryEditor = focusQueryEditor;\n $scope.orientationViewMode = true;\n\n // start of repository actions\n\n function saveQueryToLocal(currentQueryTab) {\n }\n\n function setLoader(isRunning, progressMessage, extraMessage) {\n const yasrInnerContainer = angular.element(document.getElementById('yasr-inner'));\n $scope.queryIsRunning = isRunning;\n if (isRunning) {\n $scope.queryStartTime = Date.now();\n $scope.countTimeouted = false;\n $scope.progressMessage = progressMessage;\n $scope.extraMessage = extraMessage;\n yasrInnerContainer.addClass('hide');\n } else {\n $scope.progressMessage = '';\n $scope.extraMessage = '';\n yasrInnerContainer.removeClass('hide');\n }\n // We might call this from angular or outside angular so take care of applying the scope.\n if ($scope.$$phase === null) {\n $scope.$apply();\n }\n }\n\n function getLoaderMessage() {\n const timeSeconds = (Date.now() - $scope.queryStartTime) / 1000;\n const timeHuman = $scope.getHumanReadableSeconds(timeSeconds);\n let message;\n\n if ($scope.progressMessage) {\n message = $scope.progressMessage + '... ' + timeHuman;\n } else {\n message = $translate.instant('common.running.operation', {timeHuman: timeHuman});\n }\n if ($scope.extraMessage && timeSeconds > 10) {\n message += '\\n' + $scope.extraMessage;\n }\n\n return message;\n }\n\n\n // start of query editor results orientation operations\n function fixSizesOnHorizontalViewModeSwitch(verticalViewParam) {\n function visibleWindowHeight() {\n return window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight || 0;\n }\n\n const codemirrorWrapperSelector = '.CodeMirror-wrap';\n const verticalView = verticalViewParam;\n if (!$scope.orientationViewMode) {\n $scope.noPadding = {paddingRight: 15, paddingLeft: 0};\n\n // window.editor is undefined if no repo is selected\n if (window.editor && document.querySelector(codemirrorWrapperSelector)) {\n let newHeight = visibleWindowHeight() - (document.querySelector(codemirrorWrapperSelector).getBoundingClientRect().top);\n newHeight -= 40;\n document.querySelector(codemirrorWrapperSelector).style.height = newHeight + 'px';\n document.getElementById('yasr').style.minHeight = newHeight + 'px';\n } else {\n let timer;\n if (verticalView) {\n timer = $timeout(function () {\n $scope.fixSizesOnHorizontalViewModeSwitch(verticalView)\n }, 100);\n } else {\n timer = $timeout($scope.fixSizesOnHorizontalViewModeSwitch, 100);\n }\n\n $scope.$on('$destroy', function () {\n $timeout.cancel(timer);\n });\n }\n } else {\n if ($scope.viewMode === 'yasr') {\n let newHeight = visibleWindowHeight() - (document.querySelector(codemirrorWrapperSelector).getBoundingClientRect().top);\n newHeight -= 40;\n document.querySelector(codemirrorWrapperSelector).style.height = newHeight + 'px';\n } else {\n $scope.noPadding = {};\n document.querySelector(codemirrorWrapperSelector).style.height = '';\n }\n document.getElementById('yasr').style.minHeight = '';\n }\n if (window.yasr && window.yasr.container) {\n $timeout(function () {\n window.yasr.container.resize();\n }, 100);\n }\n }\n\n if (!$scope.orientationViewMode) {\n showHideEditor();\n }\n\n function changeViewMode(tabID) {\n $scope.viewMode = 'none';\n $scope.orientationViewMode = !$scope.orientationViewMode;\n fixSizesOnHorizontalViewModeSwitch();\n $('.dataTables_filter').remove();\n $('.resultsTable').remove();\n $timeout(function () {\n loadTab();\n selectTab(tabID);\n }, 100);\n }\n\n function showHideEditor() {\n fixSizesOnHorizontalViewModeSwitch(true);\n }\n\n function focusQueryEditor() {\n if (!angular.element(document).find('.editable-input').is(':focus')) {\n angular.element(document).find('.CodeMirror textarea:first-child').focus();\n }\n }\n\n function selectTab(id) {\n $timeout(function () {\n $('a[data-id = \"' + id + '\"]').tab('show');\n }, 0);\n }\n\n // start of query operations\n function runQuery(changePage, explain) {\n $scope.executedQueryTab = $scope.currentQuery;\n if (explain && !(window.editor.getQueryType() === 'SELECT' || window.editor.getQueryType() === 'CONSTRUCT')) {\n toastr.warning($translate.instant('query.editor.warning.msg'));\n return;\n }\n\n if (window.editor.getQueryMode() === 'update') {\n toastr.warning($translate.instant('cannot.execute.update.error'));\n return;\n }\n\n $scope.explainRequested = explain;\n if (!$scope.queryIsRunning) {\n if (changePage) {\n $scope.currentTabConfig.resultsCount = 0;\n } else {\n $scope.resetCurrentTabConfig();\n }\n\n // Hides the editor and shows the yasr results\n $scope.viewMode = 'editor';\n if ($scope.orientationViewMode) {\n $scope.fixSizesOnHorizontalViewModeSwitch()\n }\n\n setLoader(true, $translate.instant('evaluating.query.msg'));\n window.editor.query();\n }\n }\n\n function getNamespaces() {\n // Signals the namespaces are to be fetched => loader will be shown\n setLoader(true, $translate.instant('common.refreshing.namespaces'), $translate.instant('common.extra.message'));\n RDF4JRepositoriesRestService.getRepositoryNamespaces()\n .success(function (data) {\n const usedPrefixes = {};\n data.results.bindings.forEach(function (e) {\n usedPrefixes[e.prefix.value] = e.namespace.value;\n });\n $scope.namespaces = usedPrefixes;\n })\n .error(function (data) {\n $scope.repositoryError = getError(data);\n })\n .finally(function () {\n // Signals namespaces were fetched => loader will be hidden\n setLoader(false);\n });\n }\n\n function changePagination() {\n runQuery(true, $scope.explainRequested);\n }\n\n if ($scope.getActiveRepository()) {\n getNamespaces();\n }\n\n $scope.$on('$destroy', function () {\n window.editor = null;\n window.yasr = null;\n });\n\n function toggleSampleQueries() {\n }\n\n // Add known prefixes\n function addKnownPrefixes() {\n SparqlRestService.addKnownPrefixes(JSON.stringify(window.editor.getValue()))\n .success(function (data) {\n if (angular.isDefined(window.editor) && angular.isDefined(data) && data !== window.editor.getValue()) {\n window.editor.setValue(data);\n }\n })\n .error(function (data) {\n let msg = getError(data);\n toastr.error(msg, $translate.instant('common.add.known.prefixes.error'));\n return true;\n });\n }\n\n $('textarea').on('paste', function () {\n $timeout(function () {\n addKnownPrefixes();\n }, 0);\n });\n\n function querySelected(query) {\n const tabId = getExistingTabId(query);\n $scope.toggleSampleQueries();\n if (!angular.isDefined(tabId)) {\n $scope.addNewTab(null, query.name, query.body);\n } else {\n selectTab(tabId);\n }\n }\n\n function getExistingTabId(query) {\n let existingTabId = undefined;\n angular.forEach($scope.tabsData, function (item) {\n if (item.name === query.name && item.query === query.body) {\n existingTabId = item.id;\n return item;\n }\n });\n\n return existingTabId;\n }\n\n // end of query operations\n\n // start of query tab operations\n function findTabIndexByID(id) {\n for (let i = 0; i < $scope.tabsData.length; i++) {\n const tab = $scope.tabsData[i];\n if (tab.id === id) {\n return i;\n }\n }\n }\n\n $scope.$watchCollection('[currentQuery.inference, currentQuery.sameAs]', function () {\n saveQueryToLocal($scope.currentQuery);\n });\n\n function saveTab(id) {\n const idx = findTabIndexByID(id);\n // Tab was deleted, don't try to save it's state\n if (idx === undefined) {\n return {};\n }\n const tab = $scope.tabsData[idx];\n $scope.saveQueryToLocal(tab);\n return tab;\n }\n\n function addNewTab(callback, tabName, savedQuery) {\n }\n\n function loadTab() {\n $scope.tabsData = [$scope.currentQuery];\n\n let tab = $scope.currentQuery;\n\n if ($scope.currentQuery.query == null || $scope.currentQuery.query === '') {\n // hack for YASQE bug\n window.editor.setValue(' ');\n } else {\n window.editor.setValue($scope.currentQuery.query);\n }\n\n $timeout(function () {\n $scope.currentTabConfig = {};\n $scope.currentTabConfig.queryType = tab.queryType;\n $scope.currentTabConfig.resultsCount = tab.resultsCount;\n\n $scope.currentTabConfig.offset = tab.offset;\n $scope.currentTabConfig.allResultsCount = tab.allResultsCount;\n $scope.currentTabConfig.page = tab.page;\n $scope.currentTabConfig.pageSize = tab.pageSize;\n\n $scope.currentTabConfig.timeFinished = tab.timeFinished;\n $scope.currentTabConfig.timeTook = tab.timeTook;\n $scope.currentTabConfig.sizeDelta = tab.sizeDelta;\n $scope.$apply();\n }, 0);\n\n //Remove padding of yasr so it will be aligned with sparql editor\n $('#yasr').css('padding', '0');\n }\n\n function getQueryID(element) {\n return $(element).attr('data-id');\n }\n\n $scope.$on('tabAction', function (e, tabEvent) {\n if (tabEvent.relatedTarget) {\n $scope.saveTab(getQueryID(tabEvent.relatedTarget));\n }\n $scope.loadTab(getQueryID(tabEvent.target));\n });\n\n $scope.$on('deleteAllexeptSelected', function (e, tabs) {\n $scope.tabsData = tabs;\n $scope.tabs = tabs;\n });\n // end of query tab operations\n\n $scope.currentQuery = angular.copy(defaultTabConfig);\n // $scope.state = {};\n $scope.showSampleQueries = false;\n $scope.savedQuery = {};\n $scope.sampleQueries = {};\n\n $scope.getResultsDescription = function () {\n };\n\n $scope.getUpdateDescription = function () {\n };\n\n $scope.getStaleWarningMessage = function () {\n }\n\n}\n"],"sourceRoot":""}
|