Author SHA1 Message Date
chight b8aa67f64c Fix linux cares about case sensitivity. 2026-10-01 15:20:34 -07:00
chight 79f7e9661c Fix security, we check for broken API calls. 2026-10-01 15:18:08 -07:00
2 changed files with 22 additions and 17 deletions
+17 -17
View File
@@ -50,8 +50,8 @@ export const WIDGET_REGISTRY = {
name: "IVANS",
category: "Communications",
description: "Feed of recent IVANS reports and reviewer statuses.",
component: lazy(() => import('../components/Widgets/IvansAlerts.jsx')),
settingsComponent: lazy(() => import('../components/Widgets/settings/IvansAlertsSettings.jsx')),
component: lazy(() => import('../components/widgets/IvansAlerts.jsx')),
settingsComponent: lazy(() => import('../components/widgets/settings/IvansAlertsSettings.jsx')),
defaultSettings: {
startDate: getStartDate(),
endDate: getEndDate(),
@@ -72,8 +72,8 @@ export const WIDGET_REGISTRY = {
name: "Remote Sensing",
category: "Remote Sensing",
description: "Feed of recent remote sensing reports.",
component: lazy(() => import('../components/Widgets/RemoteSensing.jsx')),
settingsComponent: lazy(() => import('../components/Widgets/Settings/RemoteSensingSettings.jsx')),
component: lazy(() => import('../components/widgets/RemoteSensing.jsx')),
settingsComponent: lazy(() => import('../components/widgets/settings/RemoteSensingSettings.jsx')),
defaultSettings: {
startDate: getStartDate(),
endDate: getEndDate(),
@@ -94,8 +94,8 @@ export const WIDGET_REGISTRY = {
name: "Alert Level Changes",
category: "Daily Alerts",
description: "List of 7-day alert level changes with trend arrows.",
component: lazy(() => import('../components/Widgets/AlertChanges.jsx')),
settingsComponent: lazy(() => import('../components/Widgets/settings/AlertChangeSettings.jsx')),
component: lazy(() => import('../components/widgets/AlertChanges.jsx')),
settingsComponent: lazy(() => import('../components/widgets/settings/AlertChangeSettings.jsx')),
defaultSettings: {
startDate: getStartDate(),
endDate: getEndDate(),
@@ -111,7 +111,7 @@ export const WIDGET_REGISTRY = {
category: "Daily Volcanic Activity",
description: "List of explosion events over a specified time period.",
component: lazy(() => import('../components/Widgets/ExplosionEvents.jsx')),
component: lazy(() => import('../components/widgets/ExplosionEvents.jsx')),
// The specific settings UI for this widget
settingsComponent: lazy(() => import('../components/widgets/settings/ExplosionEventsSettings.jsx')),
@@ -131,8 +131,8 @@ export const WIDGET_REGISTRY = {
name: "Plume Events",
category: "Daily Volcanic Activity",
description: "Plot of explosion heights over a weeks time.",
component: lazy(() => import('../components/Widgets/PlumeEvents.jsx')),
settingsComponent: lazy(() => import('../components/Widgets/settings/PlumeEventsSettings.jsx')),
component: lazy(() => import('../components/widgets/PlumeEvents.jsx')),
settingsComponent: lazy(() => import('../components/widgets/settings/PlumeEventsSettings.jsx')),
defaultSettings: {
startDate: getStartDate(),
endDate: getEndDate(),
@@ -146,8 +146,8 @@ export const WIDGET_REGISTRY = {
name: "Seismic Events",
category: "Daily Volcanic Activity",
description: "Plot of number of seismic events over a weeks time.",
component: lazy(() => import('../components/Widgets/SeismicEvents.jsx')),
settingsComponent: lazy(() => import('../components/Widgets/settings/SeismicEventsSettings.jsx')),
component: lazy(() => import('../components/widgets/SeismicEvents.jsx')),
settingsComponent: lazy(() => import('../components/widgets/settings/SeismicEventsSettings.jsx')),
defaultSettings: {
startDate: getStartDate(),
endDate: getEndDate(),
@@ -161,7 +161,7 @@ export const WIDGET_REGISTRY = {
name: "Alert Level Changes Quad Plot",
category: "Computer Science",
description: "Percentage of TP, TN, FP, and FN changes in viable alert levels.",
component: lazy(() => import('../components/Widgets/LlmAlChangesQuadPlot.jsx')),
component: lazy(() => import('../components/widgets/LlmAlChangesQuadPlot.jsx')),
allowedSizes: {
medium: { w: 3, h: 12 }
}
@@ -171,8 +171,8 @@ export const WIDGET_REGISTRY = {
name: "Communication Coordinator Report",
category: "Daily Volcanic Activity",
description: "Generated Report",
component: lazy(() => import('../components/Widgets/CommCoorReport.jsx')),
settingsComponent: lazy(() => import('../components/Widgets/settings/CommCoorReportSettings.jsx')),
component: lazy(() => import('../components/widgets/CommCoorReport.jsx')),
settingsComponent: lazy(() => import('../components/widgets/settings/CommCoorReportSettings.jsx')),
defaultSettings: {
copyToClipboard: false,
downloadReport: false,
@@ -188,8 +188,8 @@ export const WIDGET_REGISTRY = {
name: "VAA Polygon Projections Map",
category: "Maps",
description: "By selecting a volcano, the map will take you to it and show a polygon of the ash in 8, 12, and 18 hours",
component: lazy(() => import('../components/Widgets/VaaMap.jsx')),
settingsComponent: lazy(() => import('../components/Widgets/settings/VaaMapSettings.jsx')),
component: lazy(() => import('../components/widgets/VaaMap.jsx')),
settingsComponent: lazy(() => import('../components/widgets/settings/VaaMapSettings.jsx')),
defaultSettings: {
position: [45.61142, -122.49630], // CVO's coordinates
startDate: getToday(),
@@ -209,7 +209,7 @@ export const WIDGET_REGISTRY = {
name: "Travel Gantt Chart",
category: "Communications",
description: "View upcoming travels in a gantt chart",
component: lazy(() => import('../components/Widgets/TravelGanttChart.jsx')),
component: lazy(() => import('../components/widgets/TravelGanttChart.jsx')),
allowedSizes: {
medium: { w: 6, h: 12 }
}
+5
View File
@@ -46,6 +46,11 @@ const useAuthStore = create((set) => ({
// Hit the new lightweight endpoint
const res = await api.get('session/');
// 🔨 Security Fix a broken API call, Verify we actually got a user object back, not HTML fallback text
if (typeof res.data === 'string' || !res.data.username) {
throw new Error("Received invalid data format instead of user session");
}
// Rehydrate the store with the user's info!
set({
isAuthenticated: true,