Browse Source

fix(dashlist): minor fix to dashlist panel, and some minor html markup fixes

Torkel Ödegaard 10 years ago
parent
commit
89ce1a5159

+ 24 - 22
public/app/features/dashboard/partials/settings.html

@@ -77,28 +77,30 @@
 		<div class="editor-row">
 		<div class="editor-row">
 			<div class="tight-form-section">
 			<div class="tight-form-section">
 				<h5>Rows settings</h5>
 				<h5>Rows settings</h5>
-				<div class="tight-form" ng-repeat="row in dashboard.rows">
-					<ul class="tight-form-list">
-						<li class="tight-form-item">
-							Title
-						</li>
-						<li>
-							<input type="text" class="input tight-form-input" style="width: 400px;" ng-model='row.title'></input>
-						</li>
-						<li class="tight-form-item">
-							<editor-checkbox text="Show title" model="row.showTitle"></editor-checkbox>
-						</li>
-						<li class="tight-form-item last">
-							<i ng-click="_.move(dashboard.rows,$index,$index-1)" ng-class="{'invisible': $first}" class="pointer fa fa-arrow-up"></i>
-						</li>
-						<li class="tight-form-item last">
-							<i ng-click="_.move(dashboard.rows,$index,$index+1)" ng-class="{'invisible': $last}" class="pointer fa fa-fw fa-arrow-down"></i>
-						</li>
-						<li class="tight-form-item last">
-							<i ng-click="dashboard.rows = _.without(dashboard.rows,row)" class="pointer fa fa-remove"></i>
-						</li>
-					</ul>
-					<div class="clearfix"></div>
+				<div class="tight-form-container">
+					<div class="tight-form" ng-repeat="row in dashboard.rows">
+						<ul class="tight-form-list">
+							<li class="tight-form-item">
+								Title
+							</li>
+							<li>
+								<input type="text" class="input tight-form-input" style="width: 400px;" ng-model='row.title'></input>
+							</li>
+							<li class="tight-form-item">
+								<editor-checkbox text="Show title" model="row.showTitle"></editor-checkbox>
+							</li>
+							<li class="tight-form-item last">
+								<i ng-click="_.move(dashboard.rows,$index,$index-1)" ng-class="{'invisible': $first}" class="pointer fa fa-arrow-up"></i>
+							</li>
+							<li class="tight-form-item last">
+								<i ng-click="_.move(dashboard.rows,$index,$index+1)" ng-class="{'invisible': $last}" class="pointer fa fa-fw fa-arrow-down"></i>
+							</li>
+							<li class="tight-form-item last">
+								<i ng-click="dashboard.rows = _.without(dashboard.rows,row)" class="pointer fa fa-remove"></i>
+							</li>
+						</ul>
+						<div class="clearfix"></div>
+					</div>
 				</div>
 				</div>
 			</div>
 			</div>
 		</div>
 		</div>

+ 1 - 1
public/app/features/panel/partials/panelTime.html

@@ -1,5 +1,5 @@
 <div class="editor-row">
 <div class="editor-row">
-	<div class="section" style="margin-bottom: 20px">
+	<div class="section tight-form-container" style="margin-bottom: 20px">
 		<div class="tight-form">
 		<div class="tight-form">
 			<ul class="tight-form-list">
 			<ul class="tight-form-list">
 				<li class="tight-form-item tight-form-item-icon">
 				<li class="tight-form-item tight-form-item-icon">

+ 3 - 3
public/app/panels/dashlist/editor.html

@@ -1,7 +1,7 @@
 
 
 <div class="editor-row">
 <div class="editor-row">
 	<div class="section" style="margin-bottom: 20px">
 	<div class="section" style="margin-bottom: 20px">
-		<div class="tight-form">
+		<div class="tight-form last">
 			<ul class="tight-form-list">
 			<ul class="tight-form-list">
 				<li class="tight-form-item" style="width: 110px">
 				<li class="tight-form-item" style="width: 110px">
 					<strong>Mode</strong>
 					<strong>Mode</strong>
@@ -14,7 +14,7 @@
 		</div>
 		</div>
 	</div>
 	</div>
 	<div class="section" style="margin-bottom: 20px" ng-if="panel.mode === 'search'">
 	<div class="section" style="margin-bottom: 20px" ng-if="panel.mode === 'search'">
-		<div class="tight-form">
+		<div class="tight-form last">
 			<ul class="tight-form-list">
 			<ul class="tight-form-list">
 				<li class="tight-form-item" style="width: 110px">
 				<li class="tight-form-item" style="width: 110px">
 					<strong>Search options</strong>
 					<strong>Search options</strong>
@@ -41,7 +41,7 @@
 
 
 <div class="editor-row">
 <div class="editor-row">
 	<div class="section" style="margin-bottom: 20px">
 	<div class="section" style="margin-bottom: 20px">
-		<div class="tight-form">
+		<div class="tight-form last">
 			<ul class="tight-form-list">
 			<ul class="tight-form-list">
 				<li class="tight-form-item" style="width: 110px">
 				<li class="tight-form-item" style="width: 110px">
 					<strong>Limit number to</strong>
 					<strong>Limit number to</strong>

+ 2 - 0
public/app/panels/dashlist/module.js

@@ -43,8 +43,10 @@ function (angular, app, _, config, PanelMeta) {
 
 
     $scope.init = function() {
     $scope.init = function() {
       panelSrv.init($scope);
       panelSrv.init($scope);
+
       if ($scope.panel.tag) {
       if ($scope.panel.tag) {
         $scope.panel.tags = [$scope.panel.tag];
         $scope.panel.tags = [$scope.panel.tag];
+        delete $scope.panel.tag;
       }
       }
 
 
       if ($scope.isNewPanel()) {
       if ($scope.isNewPanel()) {

+ 7 - 7
public/app/panels/singlestat/editor.html

@@ -1,5 +1,5 @@
 <div class="editor-row">
 <div class="editor-row">
-	<div class="section" style="margin-bottom: 20px">
+	<div class="section tight-form-container" style="margin-bottom: 20px">
 		<div class="tight-form">
 		<div class="tight-form">
 			<ul class="tight-form-list">
 			<ul class="tight-form-list">
 				<li class="tight-form-item" style="width: 80px">
 				<li class="tight-form-item" style="width: 80px">
@@ -68,7 +68,7 @@
 					Decimals
 					Decimals
 				</li>
 				</li>
 				<li>
 				<li>
-					<input type="number" class="input-small tight-form-input" placeholder="auto" bs-tooltip="'Override automatic decimal precision for legend and tooltips'" data-placement="right"
+					<input type="number" class="input-small tight-form-input last" placeholder="auto" bs-tooltip="'Override automatic decimal precision for legend and tooltips'" data-placement="right"
 					ng-model="panel.decimals" ng-change="render()" ng-model-onblur>
 					ng-model="panel.decimals" ng-change="render()" ng-model-onblur>
 				</li>
 				</li>
 			</ul>
 			</ul>
@@ -79,7 +79,7 @@
 
 
 <div class="editor-row">
 <div class="editor-row">
 	<div class="section" style="margin-bottom: 20px">
 	<div class="section" style="margin-bottom: 20px">
-		<div class="tight-form">
+		<div class="tight-form last">
 			<ul class="tight-form-list">
 			<ul class="tight-form-list">
 				<li class="tight-form-item" style="width: 80px">
 				<li class="tight-form-item" style="width: 80px">
 					<strong>Coloring</strong>
 					<strong>Coloring</strong>
@@ -121,7 +121,7 @@
 
 
 <div class="editor-row">
 <div class="editor-row">
 	<div class="section" style="margin-bottom: 20px">
 	<div class="section" style="margin-bottom: 20px">
-		<div class="tight-form">
+		<div class="tight-form last">
 			<ul class="tight-form-list">
 			<ul class="tight-form-list">
 				<li class="tight-form-item" style="width: 80px">
 				<li class="tight-form-item" style="width: 80px">
 					<strong>Spark lines</strong>
 					<strong>Spark lines</strong>
@@ -147,7 +147,7 @@
 				<li class="tight-form-item">
 				<li class="tight-form-item">
 					Fill Color
 					Fill Color
 				</li>
 				</li>
-				<li class="tight-form-item">
+				<li class="tight-form-item last">
 					<spectrum-picker ng-model="panel.sparkline.fillColor" ng-change="render()" ></spectrum-picker>
 					<spectrum-picker ng-model="panel.sparkline.fillColor" ng-change="render()" ></spectrum-picker>
 				</li>
 				</li>
 			</ul>
 			</ul>
@@ -158,7 +158,7 @@
 
 
 <div class="editor-row">
 <div class="editor-row">
 	<div class="section" style="margin-bottom: 20px">
 	<div class="section" style="margin-bottom: 20px">
-		<div class="tight-form">
+		<div class="tight-form last">
 			<ul class="tight-form-list">
 			<ul class="tight-form-list">
 				<li class="tight-form-item">
 				<li class="tight-form-item">
 					<strong>Value to text mapping</strong>
 					<strong>Value to text mapping</strong>
@@ -177,7 +177,7 @@
 				</li>
 				</li>
 
 
 				<li>
 				<li>
-					<a class="pointer tight-form-item" ng-click="addValueMap();">
+					<a class="pointer tight-form-item last" ng-click="addValueMap();">
 						<i class="fa fa-plus"></i>
 						<i class="fa fa-plus"></i>
 					</a>
 					</a>
 				</li>
 				</li>