You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@superset.apache.org by GitBox <gi...@apache.org> on 2022/04/06 09:53:51 UTC

[GitHub] [superset] geido commented on a diff in pull request #19539: refactor: Removes the CSS files from the Parallel Coordinates plugin

geido commented on code in PR #19539:
URL: https://github.com/apache/superset/pull/19539#discussion_r843739398


##########
superset-frontend/plugins/legacy-plugin-chart-parallel-coordinates/src/ReactParallelCoordinates.jsx:
##########
@@ -34,14 +34,93 @@ ParallelCoordianes.propTypes = {
 };
 
 export default styled(ParallelCoordianes)`
-  .superset-legacy-chart-parallel-coordinates {
-    div.grid {
-      overflow: auto;
-      div.row {
-        &:hover {
-          background-color: ${({ theme }) => theme.colors.grayscale.light2};
+  ${({ theme }) => `
+    .superset-legacy-chart-parallel-coordinates {
+      div.grid {
+        overflow: auto;
+        div.row {
+          &:hover {
+            background-color: ${theme.colors.grayscale.light2};
+          }
         }
       }
     }
-  }
+    .parcoords svg,
+    .parcoords canvas {
+      font-size: ${theme.typography.sizes.s}px;
+      position: absolute;
+    }
+    .parcoords > canvas {
+      pointer-events: none;
+    }
+
+    .parcoords text.label {
+      font: 100%;
+      font-size: ${theme.typography.sizes.s}px;
+      cursor: drag;
+    }
+    .parcoords rect.background {
+      fill: transparent;
+    }
+    .parcoords rect.background:hover {
+      fill: ${addAlpha(theme.colors.grayscale.base, 0.2)};
+    }
+    .parcoords .resize rect {
+      fill: ${addAlpha(theme.colors.grayscale.dark2, 0.1)};
+    }
+    .parcoords rect.extent {
+      fill: ${addAlpha(theme.colors.grayscale.light5, 0.25)};
+      stroke: ${addAlpha(theme.colors.grayscale.dark2, 0.6)};
+    }
+    .parcoords .axis line,
+    .parcoords .axis path {
+      fill: none;
+      stroke: ${theme.colors.grayscale.dark1};
+      shape-rendering: crispEdges;
+    }
+    .parcoords canvas {
+      opacity: 1;
+      -moz-transition: opacity 0.3s;
+      -webkit-transition: opacity 0.3s;
+      -o-transition: opacity 0.3s;
+    }
+    .parcoords canvas.faded {
+      opacity: ${theme.opacity.mediumLight};
+    }
+    .parcoords {
+      -webkit-touch-callout: none;
+      -webkit-user-select: none;
+      -khtml-user-select: none;
+      -moz-user-select: none;
+      -ms-user-select: none;
+      user-select: none;
+      background-color: ${theme.colors.grayscale.light5};
+    }
+
+    /* data table styles */
+    .parcoords .row,
+    .parcoords .header {
+      clear: left;
+      font-size: ${theme.typography.sizes.s}px;
+      line-height: 18px;

Review Comment:
   @michael-s-molina do you think it makes sense to use grid units for line heights?



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@superset.apache.org
For additional commands, e-mail: notifications-help@superset.apache.org