Skip to content

Commit

Permalink
Merge pull request #2680 from GreenAsJade/move_to_latest_nivo
Browse files Browse the repository at this point in the history
Move to latest nivo, now they fixed their warnings
  • Loading branch information
anoek authored May 13, 2024
2 parents 29b86cd + fe067ba commit 613bc9e
Show file tree
Hide file tree
Showing 5 changed files with 123 additions and 241 deletions.
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -93,9 +93,9 @@
"@dnd-kit/core": "^6.0.3",
"@dnd-kit/sortable": "^7.0.0",
"@hapi/joi": "^17.1.1",
"@nivo/core": "=0.84.0",
"@nivo/line": "=0.84.0",
"@nivo/pie": "=0.84.0",
"@nivo/core": "^0.87.0",
"@nivo/line": "^0.87.0",
"@nivo/pie": "^0.87.0",
"@sentry/browser": "^7.92.0",
"@types/d3": "^7.4.0",
"@types/howler": "^2.2.2",
Expand Down
1 change: 1 addition & 0 deletions src/views/ReportsCenter/ModerationActionSelector.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,7 @@ export function ModerationActionSelector({
const { ref: voting_pane } = registerTargetItem("voting-pane");
const { ref: escalate_option } = registerTargetItem("escalate-option");

// If for some reason we didn't get any actions to offer, we'll just offer "escalate"
const action_choices = available_actions ? available_actions : ["escalate"];

return (
Expand Down
6 changes: 5 additions & 1 deletion src/views/ReportsCenter/ReportsCenterCMInfo.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,11 @@ export function ReportsCenterCMInfo(): JSX.Element {
{["overall", "escaping", "stalling", "score_cheating"].map((report_type) => (
<div key={report_type}>
<h3>{report_type}</h3>
<CMVoteActivityGraph vote_data={vote_data[report_type]} />
{vote_data[report_type] ? (
<CMVoteActivityGraph vote_data={vote_data[report_type]} />
) : (
"no data"
)}
</div>
))}
</div>
Expand Down
1 change: 0 additions & 1 deletion src/views/User/VoteActivityGraph.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,6 @@ const UserVoteActivityGraph = ({ user_id }: UserVoteActivityGraphProps) => {
if (!vote_data) {
return <div>Loading...</div>;
}
console.log("graph render", vote_data);
return <VoteActivityGraph vote_data={vote_data} />;
};

Expand Down
Loading

0 comments on commit 613bc9e

Please sign in to comment.