From b4f64f72a3e4bf590c60b0cbd6cd365aa1a58542 Mon Sep 17 00:00:00 2001 From: Lennart Weller Date: Wed, 25 May 2016 12:36:24 +0200 Subject: Imported Upstream version 1.2.0 --- web/index.html | 376 +++++++++++++++++++++++++++++++++++++++++++++++++++------ 1 file changed, 336 insertions(+), 40 deletions(-) (limited to 'web/index.html') diff --git a/web/index.html b/web/index.html index 6f6013da1..9cc2b4bbe 100644 --- a/web/index.html +++ b/web/index.html @@ -191,6 +191,42 @@ font-weight: 500; } + .dropdown-menu { + min-width: 200px; + } + .dropdown-menu.columns-2 { + margin: 0; + padding: 0; + width: 400px; + } + .dropdown-menu li a { + padding: 5px 15px; + font-weight: 300; + } + .dropdown-menu.multi-column { + overflow-x: hidden; + } + .multi-column-dropdown { + list-style: none; + padding: 0; + } + .multi-column-dropdown li a { + display: block; + clear: both; + line-height: 1.428571429; + white-space: normal; + } + .multi-column-dropdown li a:hover { + text-decoration: none; + color: #f5f5f5; + background-color: #262626; + } + .scrollable-menu { + height: auto; + max-height: 80vh; + overflow-x: hidden; + } + /* Back to top (hidden on mobile) */ .back-to-top, .dashboard-theme-toggle { @@ -320,6 +356,7 @@ else return ret; } + var netdataTheme = getTheme('slate'); function setTheme(theme) { @@ -327,15 +364,94 @@ return saveLocalStorage('netdataTheme', theme); } + + var netdataRegistryCallback = function(urls_array) { + var el = ''; + var a1 = ''; + var found = 0; + + if(urls_array) { + function name_comparator_desc(a, b) { + if (a.name > b.name) return -1; + if (a.name < b.name) return 1; + return 0; + } + + var urls = urls_array.sort(name_comparator_desc); + var len = urls.length; + while(len--) { + var u = urls[len]; + + var status = "enabled"; + found++; + + if(u.guid === NETDATA.registry.machine_guid) + status = "disabled" + + el += '
  • ' + u.name + '
  • '; + a1 += '
  • '; + } + } + + if(!found) { + if(urls) + el += '
  • your netdata server list is empty...
  • '; + else + el += '
  • failed to contact the registry...
  • '; + + a1 += '
  •  
  • '; + + el += '' + + '
  • EU - London (DigitalOcean.com)
  • ' + + '
  • US - Atlanta (CDN77.com)
  • ' + + '
  • EU - Athens
  • '; + a1 += '' + + '
  •  
  • ' + + '
  •  
  • '+ + '
  •  
  • '; + } + + el += ''; + a1 += ''; + + el += '
  • What is this?
  • '; + a1 += '
  • ' + + document.getElementById('mynetdata_servers').innerHTML = el; + document.getElementById('mynetdata_servers2').innerHTML = el; + document.getElementById('mynetdata_actions1').innerHTML = a1; + }; + - + @@ -456,9 +584,6 @@ D3, Copyright 2015, Mike Bostock, BSD License - node-int64, - Copyright 2014, Robert Kieffer, MIT License - @@ -775,16 +900,86 @@ -