Skip to content

Interactive interface for browsing global, full-resolution satellite imagery

Metadata in product picker working

Taylor Gunnoe37dc857cc6ca
diff --git a/deploy/metadata.template.html b/deploy/metadata.template.html
index fa82aa42f..253e4ace6 100644
--- a/deploy/metadata.template.html
+++ b/deploy/metadata.template.html
@@ -1,15 +1,2 @@
-<!doctype html>
-<html>
- <head>
- <title>@OFFICIAL_NAME@ - Layer Information</title>
- <link type="text/css" href="../../../pages/css/wv.document.css?v=@BUILD_NONCE@" rel="Stylesheet" />
- <link type="text/css" href="../../../pages/css/wv.standalone.css?v=@BUILD_NONCE@" rel="Stylesheet" />
- <meta name="viewport" content="width=device-width, initial-scale=1">
- </head>
- <body>
- <div id="page" class="wv-document">
<%=content%>
- </div>
- </body>
-</html>
diff --git a/web/css/wv.layers.modal.css b/web/css/wv.layers.modal.css
index e618fcbe3..ac28f7545 100644
--- a/web/css/wv.layers.modal.css
+++ b/web/css/wv.layers.modal.css
@@ -395,6 +395,9 @@
margin-left:160px;
color:#fff;
}
+#selected-category .ui-tabs-panel .source-metadata{
+ padding:0 20px;
+}
#selected-category .ui-tabs-panel p {
font-style: italics;
margin-bottom: 15px;
diff --git a/web/js/layers/wv.layers.modal.js b/web/js/layers/wv.layers.modal.js
index 4fd61eed8..597241418 100644
--- a/web/js/layers/wv.layers.modal.js
+++ b/web/js/layers/wv.layers.modal.js
@@ -197,11 +197,18 @@ wv.layers.modal = wv.layers.modal || function(models, ui, config) {
.attr( 'id', current.id + '-' + source.id );
//Metadata
- var $sourceMeta = $( '<p></p>' )
- .text(source.description);
-
- //$sourceContent.append( $sourceMeta );
+
+ var $sourceMeta = $( '<div></div>' )
+ .addClass('source-metadata');
+
+ if(source.description !== 'no description' ){
+ $.get('config/metadata/' + source.description + '.html')
+ .success(function(data) {
+ $sourceMeta.html(data);
+ });
+ $sourceContent.append( $sourceMeta );
+ }
var $sourceSettings = $( '<ul></ul>' )
.addClass('source-settings');