Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Integrated Week 2 #599

Draft
wants to merge 72 commits into
base: tp
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
72 commits
Select commit Hold shift + click to select a range
45cae80
Rename check to grouping in dashboard UI
MichaelBurgess Nov 5, 2024
7c3eb12
WIP for making detections a supported resource
MichaelBurgess Nov 6, 2024
f50fb38
Add DateTimeRange Picker for Detetction Benchmark
Darkness4ever Nov 6, 2024
c685edc
Show root detection dashboards in dashboard list
MichaelBurgess Nov 6, 2024
4966a5b
Working detection benchmark with table results
MichaelBurgess Nov 6, 2024
01a911a
Add severity support
MichaelBurgess Nov 7, 2024
d74e647
dashboard input values now passed using InputValues struct
kaidaguerre Nov 8, 2024
feb7450
Add DetectionChart to panel
Darkness4ever Nov 8, 2024
da00438
dashboard inputs are now passed using InputValues struct, which also …
kaidaguerre Nov 8, 2024
f0c5587
Add execution flow
MichaelBurgess Nov 8, 2024
be87996
Fix UI crash
MichaelBurgess Nov 8, 2024
1609518
GetConnectionString returns error
kaidaguerre Nov 8, 2024
7becf6b
Add table scroll and panel alligment and sapce
Darkness4ever Nov 8, 2024
207b0ea
Add Loading Indicator for Panel Status
Darkness4ever Nov 8, 2024
767fe11
Moved summary chart
MichaelBurgess Nov 8, 2024
867bbbd
Init date range to 1d
MichaelBurgess Nov 8, 2024
66641fb
Fix date range init bug
MichaelBurgess Nov 8, 2024
8cd3c32
Fix relative time bug
MichaelBurgess Nov 8, 2024
3854249
Add tailwind css styling to DateRangePicker
Darkness4ever Nov 8, 2024
3167930
Close custom pop up when clicked outside
Darkness4ever Nov 8, 2024
cce4b7f
More filtering tweaks
MichaelBurgess Nov 8, 2024
31818ec
Add hover to preset dates and Date Picker
Darkness4ever Nov 9, 2024
4ab84bf
Highlight custom when non-preset relative unit selected
MichaelBurgess Nov 9, 2024
2204a1d
Remove animation on date button hover
Darkness4ever Nov 9, 2024
a938e71
Tweaks
MichaelBurgess Nov 9, 2024
7acc367
Show all severity cards
MichaelBurgess Nov 9, 2024
66ff891
delete test mod
kaidaguerre Nov 11, 2024
ebfc67b
fix dashboard test
pskrbasu Nov 11, 2024
5bf94f6
Add CheckGrouping story
MichaelBurgess Nov 11, 2024
5643215
Add CheckGrouping story
MichaelBurgess Nov 11, 2024
0928f96
Fix bug
MichaelBurgess Nov 11, 2024
36eaec9
Add panel type
MichaelBurgess Nov 11, 2024
57b0d33
Add Diff to Cards
Darkness4ever Nov 11, 2024
24b0fab
Diff charts
MichaelBurgess Nov 11, 2024
b7c2ffb
Fix dashboard crash in card
MichaelBurgess Nov 12, 2024
39462b9
Fix dashboard crash in card
MichaelBurgess Nov 12, 2024
0c99142
wip: snapshot diff - checkpoint initial wiring
graza-io Nov 12, 2024
238234b
Add diff to result set
Darkness4ever Nov 12, 2024
8ac0fee
Add support for chart diffing
MichaelBurgess Nov 12, 2024
0516cfd
Add diff for SingleSeries Line Chart
Darkness4ever Nov 12, 2024
82c7082
wip: snapshot diff - checkpoint
graza-io Nov 12, 2024
94963f5
wip: snapshot diff - checkpoint
graza-io Nov 12, 2024
87eefc6
Add table diffing
MichaelBurgess Nov 12, 2024
a618d3a
wip: loading snapshot changes
graza-io Nov 13, 2024
7426d76
Initial sending of diff request via web socket
MichaelBurgess Nov 13, 2024
1d4ad33
Add Diff Changes for column, area and pie
Darkness4ever Nov 13, 2024
980aec4
Increase max socket message size
MichaelBurgess Nov 13, 2024
cef8810
wip: snapshot diff - checkpoint(inserting)
graza-io Nov 13, 2024
7cd15bb
wip: started parsing diffs
graza-io Nov 13, 2024
64cca05
wip: started parsing diffs - updated to get new values in correct place
graza-io Nov 13, 2024
e5991dd
Fix card diffs to work with new format
MichaelBurgess Nov 13, 2024
f6d9c38
snapshot diffs - wip
graza-io Nov 13, 2024
a6b2ce7
Fix cards to work in new format
MichaelBurgess Nov 13, 2024
6c432eb
Add diif to CheckSummary and CheckNode
Darkness4ever Nov 13, 2024
4dfcf94
Fix aggregation logic for summary
MichaelBurgess Nov 13, 2024
2dcddc0
Logging
MichaelBurgess Nov 13, 2024
5495004
Fix benchmark summary cards
MichaelBurgess Nov 13, 2024
73c12af
Add Diff to CheckSummary
Darkness4ever Nov 13, 2024
3a3fafa
Add __diff to CheckResult
MichaelBurgess Nov 13, 2024
8922eaf
Load diff'd snapshot into UI
MichaelBurgess Nov 13, 2024
55211b7
added 'attribute' to dashboard table column
graza-io Nov 14, 2024
1773cd9
Fix bug showing dashboard list when we should not
MichaelBurgess Nov 14, 2024
3569019
Fix down to zero bug
MichaelBurgess Nov 14, 2024
1535b62
Redirect to correct path
MichaelBurgess Nov 14, 2024
41002fe
Diff for CheckPanel
Darkness4ever Nov 14, 2024
be2ffdc
Fix up number change when not in diff mode
MichaelBurgess Nov 14, 2024
fc1a682
Add SpiltSnapButton
Darkness4ever Nov 14, 2024
8a89191
Remove Diff from Snapshot header
Darkness4ever Nov 14, 2024
79fb8ef
Fixes for charts
MichaelBurgess Nov 14, 2024
1c7bc02
Fix card
MichaelBurgess Nov 14, 2024
dea0925
Styling
MichaelBurgess Nov 14, 2024
da85762
Fixes after rebase
MichaelBurgess Nov 28, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Redirect to correct path
  • Loading branch information
MichaelBurgess committed Nov 28, 2024
commit 1535b62cd1dd8f4d940153ca286570d03b92c653
1 change: 1 addition & 0 deletions ui/dashboard/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ const DashboardApp = ({
<Routes>
<Route path="/" element={dashboards} />
<Route path="/snapshot/:dashboard_name" element={dashboards} />
{/*<Route path="/snapshot_diff/:dashboard_name" element={dashboards} />*/}
<Route path="/:dashboard_name" element={dashboards} />
</Routes>
);
Expand Down
4 changes: 2 additions & 2 deletions ui/dashboard/src/components/DashboardList/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -468,10 +468,10 @@ const DashboardList = () => {

const DashboardListWrapper = ({ wrapperClassName = "" }) => {
const { dashboard_name } = useParams();
const { dataMode, search } = useDashboard();
const { search } = useDashboard();

// If we have a dashboard selected and no search, we don't want to show the list
if ((dataMode === "diff" || dashboard_name) && !search.value) {
if (dashboard_name && !search.value) {
return null;
}

Expand Down
4 changes: 4 additions & 0 deletions ui/dashboard/src/components/SnapshotDiffButton/index.tsx
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
import { DashboardActions } from "../../types";
import { useDashboard } from "../../hooks/useDashboard";
import { useNavigate } from "react-router-dom";
import { useRef } from "react";

const SnapshotDiffButton = () => {
const { dispatch, snapshot } = useDashboard();
const fileInputRef = useRef<HTMLInputElement | null>(null);
const navigate = useNavigate();

if (!snapshot) {
return null;
Expand Down Expand Up @@ -41,12 +43,14 @@ const SnapshotDiffButton = () => {

e.target.value = "";
try {
navigate(`/snapshot/diff`);
const data = JSON.parse(fr.result.toString());
dispatch({
type: DashboardActions.GET_SNAPSHOT_DIFF,
snapshot: data,
});
} catch (err: any) {
console.log(err);
dispatch({
type: DashboardActions.WORKSPACE_ERROR,
error: "Unable to load snapshot:" + err.message,
Expand Down
23 changes: 20 additions & 3 deletions ui/dashboard/src/hooks/useDashboard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import {
DashboardCliMode,
DashboardDataModeCLISnapshot,
DashboardDataModeCloudSnapshot,
DashboardDataModeDiff,
DashboardDataModeLive,
DashboardDataOptions,
DashboardRenderOptions,
Expand Down Expand Up @@ -232,11 +233,25 @@ const DashboardProvider = ({
state.snapshot,
]);

useEffect(() => {
if (
location.pathname === "/" &&
(state.dataMode === DashboardDataModeCLISnapshot ||
state.dataMode === DashboardDataModeDiff)
) {
dispatch({
type: DashboardActions.SET_DATA_MODE,
dataMode: DashboardDataModeLive,
});
}
}, [dispatch, location, state.dataMode]);

useEffect(() => {
if (
!!dashboard_name &&
!location.pathname.startsWith("/snapshot/") &&
state.dataMode === DashboardDataModeCLISnapshot
(state.dataMode === DashboardDataModeCLISnapshot ||
state.dataMode === DashboardDataModeDiff)
) {
dispatch({
type: DashboardActions.SET_DATA_MODE,
Expand Down Expand Up @@ -672,7 +687,8 @@ const DashboardProvider = ({
if (
!state.availableDashboardsLoaded ||
!dashboard_name ||
state.dataMode === DashboardDataModeCLISnapshot
state.dataMode === DashboardDataModeCLISnapshot ||
state.dataMode === DashboardDataModeDiff
) {
return;
}
Expand All @@ -692,7 +708,8 @@ const DashboardProvider = ({
useEffect(() => {
if (
location.pathname.startsWith("/snapshot/") &&
state.dataMode !== DashboardDataModeCLISnapshot
state.dataMode !== DashboardDataModeCLISnapshot &&
state.dataMode !== DashboardDataModeDiff
) {
navigate("/");
}
Expand Down