Skip to content

Commit 26a93f8

Browse files
authored
Merge pull request #28 from oslabs-beta/search-metrics
Search metrics
2 parents 2d8b048 + 322d335 commit 26a93f8

File tree

4 files changed

+50
-8
lines changed

4 files changed

+50
-8
lines changed

app/components/GraphNavBar/GraphNavBar.tsx

+2-2
Original file line numberDiff line numberDiff line change
@@ -110,8 +110,8 @@ const GraphNavBar = (props) => {
110110
}}
111111
/>
112112
 Inspect
113-
</Link> */}
114-
<button onClick={() => { setInspect(!inspect) }}>Inspect</button>
113+
</Link>
114+
<button onClick={() => { setInspect(!inspect) }}>Inspect</button> */}
115115
</nav>
116116
)
117117
}

app/components/TransferColumns.tsx

+13-5
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,13 @@ import { useParams } from 'react-router-dom';
33
import { QueryContext } from '../context/QueryContext';
44
import { HealthContext } from '../context/HealthContext';
55
import { EventContext } from '../context/EventContext';
6-
import { DataGrid } from '@material-ui/data-grid';
6+
import { DataGrid } from '@mui/x-data-grid';
7+
import { GridToolbar } from '@mui/x-data-grid/components';
78
import * as DashboardContext from '../context/DashboardContext';
89
import lightAndDark from './Styling';
910

1011
import { Button, TextField } from '@mui/material';
11-
import SearchBar from './SearchBar/SearchBar';
12+
1213

1314
interface Params {
1415
service: string;
@@ -205,16 +206,23 @@ const TransferColumns = React.memo(() => {
205206
style={currentMode}
206207
rows={rows}
207208
columns={columns}
208-
pageSize={10}
209+
slots={{ toolbar: GridToolbar }}
210+
slotProps={{
211+
toolbar: {
212+
showQuickFilter: true,
213+
},
214+
}}
215+
pageSizeOptions ={[10]}
209216
checkboxSelection
210-
disableSelectionOnClick
211-
onSelectionModelChange={metricIndeces => {
217+
disableRowSelectionOnClick
218+
onRowSelectionModelChange={metricIndeces => {
212219
const metrics: any[] = [];
213220
metricIndeces.forEach(el => {
214221
metrics.push(metricsPool[el].key);
215222
});
216223
setTargetKeys(metrics);
217224
}}
225+
218226
/>
219227

220228
</div>

package-lock.json

+34
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,10 +12,10 @@
1212
"@emotion/react": "^11.11.4",
1313
"@emotion/styled": "^11.11.5",
1414
"@jest/types": "^29.6.1",
15-
"@material-ui/data-grid": "^4.0.0-alpha.37",
1615
"@mui/icons-material": "^5.15.16",
1716
"@mui/material": "^5.15.16",
1817
"@mui/styles": "^5.15.16",
18+
"@mui/x-data-grid": "^7.4.0",
1919
"@types/node": "^18.17.1",
2020
"3d-force-graph": "^1.72.2",
2121
"aws-sdk": "^2.1317.0",

0 commit comments

Comments
 (0)