浏览代码

HUE-6077 [frontend] Improve hover effects for the result table

Johan Ahlen 8 年之前
父节点
当前提交
19d9597

文件差异内容过多而无法显示
+ 0 - 0
desktop/core/src/desktop/static/desktop/css/hue.css


文件差异内容过多而无法显示
+ 0 - 0
desktop/core/src/desktop/static/desktop/css/hue3-extra.css


+ 4 - 10
desktop/core/src/desktop/static/desktop/js/jquery.tableextender2.js

@@ -170,17 +170,11 @@
     };
 
     var overHandler = function () {
-      self.$parent.find('.fixed-first-column table tbody tr:eq(' + $(this).index() + ') td').css({
-        'border-left': '2px solid #CCC',
-        'background-color': '#EEE'
-      });
+      self.$parent.find('.fixed-first-column table tbody tr:eq(' + $(this).index() + ') td').addClass('fixed-first-col-hover');
     };
 
     var outHandler = function () {
-      self.$parent.find('.fixed-first-column table tbody tr td').css({
-        'border-left': '2px solid #FFF',
-        'background-color': '#F9F9F9'
-      });
+      self.$parent.find('.fixed-first-column table tbody tr td').removeClass('fixed-first-col-hover');
     };
 
     self.$parent.children('table').on('click dblclick', 'tbody tr', clickHandler);
@@ -408,7 +402,7 @@
       if ($(this).html() === '') {
         foundEmptyTh = true;
       }
-      h+= '<tr><td style="border-left: 2px solid #FFF">' + $(this).html() +'</td></tr>';
+      h+= '<tr><td>' + $(this).html() +'</td></tr>';
     });
     if (foundEmptyTh) {
       // In IE it's sometimes empty so we'll redraw in a bit
@@ -433,7 +427,7 @@
     var firstColumnInner = $("<div>").css("background-color", "#FFFFFF").width(originalTh.outerWidth()).height(self.$parent.get(0).scrollHeight);
     clonedTable.appendTo(firstColumnInner);
 
-    var firstColumn = $("<div>").attr("id", self.$element.attr("id") + "jHueTableExtenderClonedContainerColumn").addClass("fixed-first-column").width(originalTh.outerWidth()).height(self.$parent.height()).css("marginLeft", "-2px").css("overflow", "hidden").css("top", topPosition + "px");
+    var firstColumn = $("<div>").attr("id", self.$element.attr("id") + "jHueTableExtenderClonedContainerColumn").addClass("fixed-first-column").width(originalTh.outerWidth()).height(self.$parent.height()).css("overflow", "hidden").css("top", topPosition + "px");
     firstColumn.css("position", self.options.clonedContainerPosition || "fixed");
 
     firstColumnInner.appendTo(firstColumn);

+ 6 - 0
desktop/core/src/desktop/static/desktop/less/components/hue-tables.less

@@ -471,4 +471,10 @@ div.box {
 .table tr.locked td.unlockable:hover .fa-unlock, .table tr td.lockable:hover .fa-lock {
   color: @cui-gray-800;
   display: block;
+}
+
+.fixed-first-col-hover {
+  background-color: #EEE !important;
+  border-left: 2px solid @hue-primary-color-light !important;
+  padding-left: 14px !important;
 }

+ 1 - 1
desktop/core/src/desktop/static/desktop/less/hue-cross-version.less

@@ -258,7 +258,7 @@ input[type='password']::-ms-reveal {
 }
 
 .actionbar-actions {
-  margin: 0px 0px 10px 0px;
+  margin: 0 0 10px 0;
 }
 
 .status-circle {

文件差异内容过多而无法显示
+ 0 - 0
desktop/libs/notebook/src/notebook/static/notebook/css/notebook.css


+ 4 - 4
desktop/libs/notebook/src/notebook/static/notebook/less/notebook.less

@@ -921,8 +921,8 @@
   }
 
   .history-table tbody tr:hover {
-    border-left: 2px solid @cui-default-border-color;
-    border-right: 2px solid @cui-default-border-color;
+    border-left: 2px solid @hue-primary-color-light;
+    border-right: 2px solid @hue-primary-color-light;
   }
 
   .history-table tbody tr:hover td, .history-table tbody tr:hover th {
@@ -931,8 +931,8 @@
 
   .history-table tbody tr.highlight {
     background-color: #f7f7f9;
-    border-left: 2px solid @cui-default-border-color;
-    border-right: 2px solid @cui-default-border-color;
+    border-left: 2px solid @hue-primary-color-light;
+    border-right: 2px solid @hue-primary-color-light;
   }
 
   .ace-highlight .ace-hue {

部分文件因为文件数量过多而无法显示