Merge pull request #3996 from bluewave-labs/fix/dashboard-table-state
fix: add a dashboard table state
This commit is contained in:
2 files changed
+6
-1
No files matched your search
@@ -10,6 +10,7 @@ type ThemeMode = "light" | "dark";
|
|||||||
type ChartType = "histogram" | "line";
|
type ChartType = "histogram" | "line";
|
||||||
|
|
||||||
type TableName =
|
type TableName =
|
||||||
|
| "dashboard"
|
||||||
| "monitors"
|
| "monitors"
|
||||||
| "team"
|
| "team"
|
||||||
| "maintenance"
|
| "maintenance"
|
||||||
@@ -29,6 +30,7 @@ interface SidebarState {
|
|||||||
}
|
}
|
||||||
|
|
||||||
interface UIState {
|
interface UIState {
|
||||||
|
dashboard: TableState;
|
||||||
monitors: TableState;
|
monitors: TableState;
|
||||||
pagespeed: TableState;
|
pagespeed: TableState;
|
||||||
team: TableState;
|
team: TableState;
|
||||||
@@ -54,6 +56,9 @@ const initialMode: ThemeMode = window?.matchMedia?.("(prefers-color-scheme: dark
|
|||||||
: "light";
|
: "light";
|
||||||
|
|
||||||
const initialState: UIState = {
|
const initialState: UIState = {
|
||||||
|
dashboard: {
|
||||||
|
rowsPerPage: 100,
|
||||||
|
},
|
||||||
monitors: {
|
monitors: {
|
||||||
rowsPerPage: 10,
|
rowsPerPage: 10,
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ const Dashboard = () => {
|
|||||||
types: [...MonitorTypes],
|
types: [...MonitorTypes],
|
||||||
checksLimit: 1,
|
checksLimit: 1,
|
||||||
refreshInterval: 30000,
|
refreshInterval: 30000,
|
||||||
rowsPerPageTable: "monitors",
|
rowsPerPageTable: "dashboard",
|
||||||
rowsPerPageDefault: 100,
|
rowsPerPageDefault: 100,
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user