Skip to content

Commit

Permalink
Added cursor line rendering to the Build Analyzer chart when a data p…
Browse files Browse the repository at this point in the history
…oint is selected

- Also fixed an "Invalid URL" error when following the README instructions & running the application locally
- Github Issue: Sendouc#1806
  • Loading branch information
ElementUser committed Aug 24, 2024
1 parent 97b0f65 commit c946a06
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ TWITCH_CLIENT_SECRET=
SKALOP_SYSTEM_MESSAGE_URL=http://localhost:5900/system
SKALOP_TOKEN=secret

BASE_URL=https://example.com

VITE_SITE_DOMAIN=http://localhost:5173
VITE_SKALOP_WS_URL=ws://localhost:5900

Expand Down
6 changes: 4 additions & 2 deletions app/components/Chart.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ export default function Chart({
headerSuffix,
valueSuffix,
xAxis,
renderCursorLines = false
}: {
options: [
{ label: string; data: Array<{ primary: Date; secondary: number }> },
Expand All @@ -20,6 +21,7 @@ export default function Chart({
headerSuffix?: string;
valueSuffix?: string;
xAxis: "linear" | "localTime";
renderCursorLines?: boolean;
}) {
const { i18n } = useTranslation();
const theme = useTheme();
Expand Down Expand Up @@ -78,8 +80,8 @@ export default function Chart({
/>
),
},
primaryCursor: false,
secondaryCursor: false,
primaryCursor: renderCursorLines,
secondaryCursor: renderCursorLines,
primaryAxis,
secondaryAxes,
dark: theme.htmlThemeClass === Theme.DARK,
Expand Down
1 change: 1 addition & 0 deletions app/features/build-analyzer/routes/analyzer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -1025,6 +1025,7 @@ function StatChart({
headerSuffix={t("analyzer:abilityPoints.short")}
valueSuffix={valueSuffix}
xAxis="linear"
renderCursorLines
/>
);
}
Expand Down

0 comments on commit c946a06

Please sign in to comment.