Index: components/physical_web/webui/resources/physical_web.js |
diff --git a/components/physical_web/webui/resources/physical_web.js b/components/physical_web/webui/resources/physical_web.js |
index 418dc1d6e90c1b5e8daffb35b8fbd841900eae08..2029936b8da52f242319ca3cf7dad37d11587a38 100644 |
--- a/components/physical_web/webui/resources/physical_web.js |
+++ b/components/physical_web/webui/resources/physical_web.js |
@@ -24,8 +24,12 @@ function physicalWebItemClicked(index) { |
function returnNearbyURLs(nearbyUrlsData) { |
var bodyContainer = $('body-container'); |
renderTemplate(nearbyUrlsData); |
+ bodyContainer.style.display = 'block'; |
- bodyContainer.style.visibility = 'visible'; |
+ if (nearbyUrlsData['metadata'].length == 0) { |
+ var emptyMessage = $('empty-list-container'); |
+ emptyMessage.style.display = 'block'; |
nyquist
2017/03/02 19:01:28
If this page stays open for a bit, does it automat
Ran
2017/03/02 19:36:36
The function only gets called when the page loaded
|
+ } |
} |
document.addEventListener('DOMContentLoaded', requestNearbyURLs); |