Skip to content

Commit

Permalink
Moving styles to another file
Browse files Browse the repository at this point in the history
  • Loading branch information
laisspportugal committed Jan 9, 2025
1 parent c3138b1 commit ff391ec
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 17 deletions.
18 changes: 1 addition & 17 deletions packages/suite-base/src/panels/Plot/VerticalBars.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,29 +7,13 @@

import { useCallback, useEffect, useLayoutEffect, useRef } from "react";
import { useLatest } from "react-use";
import { makeStyles } from "tss-react/mui";

import { toSec } from "@lichtblick/rostime";
import { useMessagePipelineSubscribe } from "@lichtblick/suite-base/components/MessagePipeline";
import { useHoverValue } from "@lichtblick/suite-base/context/TimelineInteractionStateContext";

import type { VerticalBarsProps, Scale } from "./types";

Check failure on line 15 in packages/suite-base/src/panels/Plot/VerticalBars.tsx

View workflow job for this annotation

GitHub Actions / lint (ubuntu-20.04)

There should be at least one empty line between import groups

const useStyles = makeStyles()(() => ({
verticalBar: {
position: "absolute",
top: 0,
bottom: 0,
left: 0,
width: 1,
marginLeft: -1,
display: "block",
pointerEvents: "none",
},
playbackBar: {
backgroundColor: "#aaa",
},
}));
import { useStyles } from "@lichtblick/suite-base/panels/Plot/verticalbars.style";

Check failure on line 16 in packages/suite-base/src/panels/Plot/VerticalBars.tsx

View workflow job for this annotation

GitHub Actions / lint (ubuntu-20.04)

`@lichtblick/suite-base/panels/Plot/verticalbars.style` import should occur before type import of `./types`

/** Get the canvas pixel x location for the plot x value */
function getPixelForXValue(
Expand Down
17 changes: 17 additions & 0 deletions packages/suite-base/src/panels/Plot/verticalbars.style.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
import { makeStyles } from "tss-react/mui";

export const useStyles = makeStyles()(() => ({
verticalBar: {

Check failure on line 4 in packages/suite-base/src/panels/Plot/verticalbars.style.ts

View workflow job for this annotation

GitHub Actions / lint (ubuntu-20.04)

Delete `··`
position: "absolute",

Check failure on line 5 in packages/suite-base/src/panels/Plot/verticalbars.style.ts

View workflow job for this annotation

GitHub Actions / lint (ubuntu-20.04)

Delete `····`
top: 0,

Check failure on line 6 in packages/suite-base/src/panels/Plot/verticalbars.style.ts

View workflow job for this annotation

GitHub Actions / lint (ubuntu-20.04)

Delete `····`
bottom: 0,

Check failure on line 7 in packages/suite-base/src/panels/Plot/verticalbars.style.ts

View workflow job for this annotation

GitHub Actions / lint (ubuntu-20.04)

Replace `········` with `····`
left: 0,

Check failure on line 8 in packages/suite-base/src/panels/Plot/verticalbars.style.ts

View workflow job for this annotation

GitHub Actions / lint (ubuntu-20.04)

Replace `········` with `····`
width: 1,

Check failure on line 9 in packages/suite-base/src/panels/Plot/verticalbars.style.ts

View workflow job for this annotation

GitHub Actions / lint (ubuntu-20.04)

Delete `····`
marginLeft: -1,
display: "block",
pointerEvents: "none",
},
playbackBar: {
backgroundColor: "#aaa",
},
}));

0 comments on commit ff391ec

Please sign in to comment.