Commit Graph
24 Commits
Author SHA1 Message Date
Alex 1d90b8d8d9 refactor all call sites 2026-05-07 09:54:58 -07:00
gorkem-bwl 602769b3e7 feat(checks): render status code 5000 as "Down" with subtype tooltip
Status code 5000 is Checkmate's internal sentinel for "no HTTP response
received" (DNS failure, connection refused, timeout, TLS error, etc.).
Showing the raw number to admins is confusing — the value isn't a real
HTTP code and means nothing without context.

This change replaces "5000" with "Down" across all check/incident
surfaces, and adds a hover tooltip that explains the underlying cause
based on the stored error message. Real HTTP codes (2xx/3xx/4xx/5xx)
are unchanged.

## Changes
- Add client/src/Utils/statusCode.ts with formatStatusCode,
  getStatusCodeTooltip, getStatusCodeValueType, extractErrorCode, and a
  message-to-subtype parser (timeout / dns / refused / tls / reset).
- Wire into 6 render sites: Checks table, Uptime details Checks table,
  GeoChecks table + map popup, Incidents table, Incident details dialog.
- Add common.statusCode.* i18n keys in en.json with subtype-specific
  descriptions. Tooltip appends the raw error code (ECONNREFUSED,
  ETIMEDOUT, CERT_HAS_EXPIRED, etc.) when present in the message.

## Tooltip examples
- "queryA ECONNREFUSED www.example.com" →
  "The server refused the connection (port closed or service not listening). (ECONNREFUSED)"
- "connect ETIMEDOUT 1.2.3.4:443" →
  "The server didn't respond in time (request timed out). (ETIMEDOUT)"

## Notes
- No DB or server changes; statusCode field stays 5000 in storage.
- Other locales fall back to English keys until translated.
2026-05-07 01:13:09 -04:00
gorkem-bwl 031a6fdf3c feat(client): unified EmptyState across all pages and table empties
- New EmptyState + EmptyStateIllustration components: stacked-cards SVG
  with grid background, theme-aware light/dark palette.
- Variants: default (centered with title + description), compact
  (horizontal, in-section), fullscreen (vertically centers in viewport).
- Wired into Checks, Incidents, Logs (Logs+Queue tabs), Notifications,
  Maintenance, Status pages, and Team tab — each with i18n title +
  description and a fullscreen layout when truly empty.
- Table.EmptyView now wraps the EmptyState in a divider-bordered card
  so short messages no longer look orphaned.
- Incidents Option-A short-circuit: when summary.total === 0, replace
  the whole page chrome with EmptyState; otherwise keep filters + cards.
- Fallback.tsx (BaseFallback / EmptyFallback / EmptyMonitorFallback /
  ErrorFallback) refactored to delegate to EmptyState.
2026-04-25 23:26:34 -04:00
Alex Holliday e3057ad039 remove unused import 2026-02-26 22:21:19 +00:00
Alex Holliday 32f41a3cc4 remove unused import 2026-02-26 22:11:32 +00:00
Alex Holliday 177d6f80d0 remove on row click 2026-02-26 22:08:14 +00:00
Alex Holliday d45e6ec97c remove v2 dir 2026-02-20 18:13:39 +00:00
Alex Holliday 71cdd05b15 type errors 2026-02-11 20:29:50 +00:00
Alex Holliday bb8cc8b464 cleanup, check fix 2026-01-28 20:00:42 +00:00
Alex Holliday f41f2322cf remove unused import 2026-01-28 19:26:15 +00:00
Alex Holliday 5a468d717a Responsive 2026-01-28 19:00:34 +00:00
Alex Holliday 975d134dd8 extract strings 2026-01-28 18:45:11 +00:00
Alex Holliday fcfad945a0 selects 2026-01-28 17:59:11 +00:00
Alex Holliday 07705e9823 fix recent 2026-01-27 23:21:04 +00:00
Alex Holliday c48049e0af checks table 2026-01-27 23:17:40 +00:00
Alex Holliday f3ba8c9815 monitor select 2026-01-27 23:05:00 +00:00
Alex Holliday f88e4ee6f4 refactor 2026-01-27 22:24:16 +00:00
Alex Holliday 300b1b2238 initial commit 2026-01-27 21:57:09 +00:00
Alex Holliday c1d0cb568d remove console.log, fix docker file 2026-01-27 21:00:28 +00:00
Alex Holliday 63d2bb97ee add dateRange to checks query 2026-01-27 20:46:28 +00:00
Alex Holliday e354fa7ebf response time chart 2026-01-26 02:06:37 +00:00
Alex Holliday c1b2bda623 _id -> id 2026-01-20 19:41:57 +00:00
Alex Holliday cdfc87da09 remove ack 2026-01-20 19:21:03 +00:00
Alex Holliday 427e5a18ea incidents -> checks 2026-01-20 19:12:05 +00:00