-
+
-
diff --git a/src/app/features/dashboard/shareSnapshotCtrl.js b/src/app/features/dashboard/shareSnapshotCtrl.js
index fc7973a676c..c9a71f4230b 100644
--- a/src/app/features/dashboard/shareSnapshotCtrl.js
+++ b/src/app/features/dashboard/shareSnapshotCtrl.js
@@ -6,7 +6,7 @@ function (angular) {
var module = angular.module('grafana.controllers');
- module.controller('ShareSnapshotCtrl', function($scope, $rootScope, $location, backendSrv, $timeout) {
+ module.controller('ShareSnapshotCtrl', function($scope, $rootScope, $location, backendSrv, $timeout, timeSrv) {
$scope.snapshot = {
name: $scope.dashboard.title
@@ -24,8 +24,11 @@ function (angular) {
$scope.saveSnapshot = function(makePublic) {
var dash = angular.copy($scope.dashboard);
+ // change title
dash.title = $scope.snapshot.name;
-
+ // make relative times absolute
+ dash.time = timeSrv.timeRange();
+ // remove panel queries & links
dash.forEachPanel(function(panel) {
panel.targets = [];
panel.links = [];
diff --git a/src/css/less/gfbox.less b/src/css/less/gfbox.less
index 995ccb5b435..50401e21c50 100644
--- a/src/css/less/gfbox.less
+++ b/src/css/less/gfbox.less
@@ -97,20 +97,4 @@
}
}
-.share-snapshot {
- text-align: center;
- .share-snapshot-header {
- .fa {
- position: absolute;
- font-size: 600%;
- left: 41%;
- color: @grafanaTargetFuncBackground;
- z-index: -1;
- }
-
- position: relative;
- z-index: 1000;
- line-height: 106px;
- }
-}
diff --git a/src/css/less/grafana.less b/src/css/less/grafana.less
index 579415f17f8..6b6e17ce834 100644
--- a/src/css/less/grafana.less
+++ b/src/css/less/grafana.less
@@ -294,3 +294,30 @@
}
}
}
+
+.share-snapshot {
+ text-align: center;
+
+ .share-snapshot-header {
+ .fa {
+ position: absolute;
+ font-size: 600%;
+ left: 42%;
+ color: @grafanaTargetFuncBackground;
+ z-index: -1;
+ }
+
+ position: relative;
+ z-index: 1000;
+ line-height: 106px;
+ margin: 45px 0 22px 0;
+ }
+
+ .share-snapshot-link {
+ max-width: 716px;
+ white-space: nowrap;
+ overflow: hidden;
+ display: block;
+ text-overflow: ellipsis;
+ }
+}