Skip to content

Commit 29db71c

Browse files
committed
fix(docs): persistent error toasts with dismiss button
UX review: 3-second auto-dismiss is too short to read a JSON error message. Errors now stay until the user dismisses them; success toasts auto-dismiss as before. - showToast: skip the auto-removal timer for type='error'. - dismissToast: explicit removal handler invoked from a per-toast close button. - Template: error toasts render an aria-labeled dismiss button. - Stylesheet: .toast-message flexes, .toast-dismiss is a 24×24 icon button matching the existing modal-close pattern. Mobile + canvas-touch handlers + inline-line-number JSON errors deferred to component refactor task. Source: 4-expert website review — UX dimension top-3 friction.
1 parent f1d9fbe commit 29db71c

7 files changed

Lines changed: 54 additions & 8 deletions

File tree

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/dist/_astro/Visualizer.CcpkQXaA.js

Lines changed: 0 additions & 1 deletion
This file was deleted.

docs/dist/_astro/Visualizer.DaxdaO-Q.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

docs/dist/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!DOCTYPE html><html lang="en"> <head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>Statekit — Statecharts for Go</title><meta name="description" content="Type-safe statecharts for Go. Hierarchical states, parallel regions, history, delayed transitions, with built-in visualization, lint, and a deterministic test clock."><link rel="canonical" href="https://felixgeelhaar.github.io/statekit/"><link rel="icon" type="image/svg+xml" href="/statekit/favicon.svg"><!-- Open Graph --><meta property="og:type" content="website"><meta property="og:url" content="https://felixgeelhaar.github.io/statekit/"><meta property="og:title" content="Statekit — Statecharts for Go"><meta property="og:description" content="Type-safe statecharts for Go. Hierarchical states, parallel regions, history, delayed transitions, with built-in visualization, lint, and a deterministic test clock."><meta property="og:image" content="https://felixgeelhaar.github.io/statekit/og-card.svg"><meta property="og:site_name" content="Statekit"><!-- Twitter --><meta name="twitter:card" content="summary_large_image"><meta name="twitter:title" content="Statekit — Statecharts for Go"><meta name="twitter:description" content="Type-safe statecharts for Go. Hierarchical states, parallel regions, history, delayed transitions, with built-in visualization, lint, and a deterministic test clock."><meta name="twitter:image" content="https://felixgeelhaar.github.io/statekit/og-card.svg"><!-- Structured Data --><script type="application/ld+json">{"@context":"https://schema.org","@type":"SoftwareSourceCode","name":"Statekit","description":"Type-safe statecharts for Go. Hierarchical states, parallel regions, history, delayed transitions, with built-in visualization, lint, and a deterministic test clock.","codeRepository":"https://github.com/felixgeelhaar/statekit","programmingLanguage":"Go","license":"https://opensource.org/licenses/MIT","url":"https://felixgeelhaar.github.io/statekit"}</script><!-- Fonts --><link rel="preconnect" href="https://fonts.googleapis.com"><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin><link href="https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600;700&family=Space+Grotesk:wght@400;500;600;700&display=swap" rel="stylesheet"><link rel="stylesheet" href="/statekit/_astro/Header.Dxm1kJqy.css">
1+
<!DOCTYPE html><html lang="en"> <head><meta charset="UTF-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><title>Statekit — Statecharts for Go</title><meta name="description" content="Type-safe statecharts for Go. Hierarchical states, parallel regions, history, delayed transitions, with built-in visualization, lint, and a deterministic test clock."><link rel="canonical" href="https://felixgeelhaar.github.io/statekit/"><link rel="icon" type="image/svg+xml" href="/statekit/favicon.svg"><!-- Open Graph --><meta property="og:type" content="website"><meta property="og:url" content="https://felixgeelhaar.github.io/statekit/"><meta property="og:title" content="Statekit — Statecharts for Go"><meta property="og:description" content="Type-safe statecharts for Go. Hierarchical states, parallel regions, history, delayed transitions, with built-in visualization, lint, and a deterministic test clock."><meta property="og:image" content="https://felixgeelhaar.github.io/statekit/og-card.svg"><meta property="og:site_name" content="Statekit"><!-- Twitter --><meta name="twitter:card" content="summary_large_image"><meta name="twitter:title" content="Statekit — Statecharts for Go"><meta name="twitter:description" content="Type-safe statecharts for Go. Hierarchical states, parallel regions, history, delayed transitions, with built-in visualization, lint, and a deterministic test clock."><meta name="twitter:image" content="https://felixgeelhaar.github.io/statekit/og-card.svg"><!-- Structured Data --><script type="application/ld+json">{"@context":"https://schema.org","@type":"SoftwareSourceCode","name":"Statekit","description":"Type-safe statecharts for Go. Hierarchical states, parallel regions, history, delayed transitions, with built-in visualization, lint, and a deterministic test clock.","codeRepository":"https://github.com/felixgeelhaar/statekit","programmingLanguage":"Go","license":"https://opensource.org/licenses/MIT","url":"https://felixgeelhaar.github.io/statekit"}</script><!-- Fonts --><link rel="preconnect" href="https://fonts.googleapis.com"><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin><link href="https://fonts.googleapis.com/css2?family=JetBrains+Mono:wght@400;500;600;700&family=Space+Grotesk:wght@400;500;600;700&display=swap" rel="stylesheet"><link rel="stylesheet" href="/statekit/_astro/Header.FCQJRL0B.css">
22
<link rel="stylesheet" href="/statekit/_astro/index.DMVUSLg_.css"></head> <body> <div class="landing" data-astro-cid-j7pv25f6> <header class="header"> <a href="/statekit/" class="logo" aria-label="Statekit home"> <div class="logo-icon"> <svg viewBox="0 0 36 36" fill="none" xmlns="http://www.w3.org/2000/svg" role="img" aria-label="Statekit logo"> <rect x="2" y="2" width="32" height="32" rx="6" stroke="currentColor" stroke-width="2" fill="none"></rect> <circle cx="12" cy="12" r="4" fill="#00d4ff"></circle> <circle cx="24" cy="12" r="4" fill="#a855f7"></circle> <circle cx="18" cy="24" r="4" fill="#00ff88"></circle> <path d="M15 12 L21 12" stroke="#00d4ff" stroke-width="2"></path> <path d="M12 15 L18 21" stroke="#00d4ff" stroke-width="2"></path> <path d="M24 15 L18 21" stroke="#a855f7" stroke-width="2"></path> </svg> </div> <span class="logo-text">State<span>kit</span></span> </a> <nav class="header-nav" aria-label="Primary"> <a href="/statekit/" class="header-nav-link is-active" aria-current="page">Home</a> <a href="/statekit/play" class="header-nav-link">Play</a> <a href="https://pkg.go.dev/github.com/felixgeelhaar/statekit" class="header-nav-link" target="_blank" rel="noopener">Docs</a> </nav> <div class="header-actions"> <a href="https://github.com/felixgeelhaar/statekit/tree/main/mcp" class="header-link" target="_blank" rel="noopener" aria-label="MCP Server for AI-assisted state machine development"> <svg viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" aria-hidden="true"> <path d="M12 2L2 7l10 5 10-5-10-5z"></path> <path d="M2 17l10 5 10-5"></path> <path d="M2 12l10 5 10-5"></path> </svg>
33
MCP
44
</a> <a href="https://github.com/felixgeelhaar/statekit" class="header-link" target="_blank" rel="noopener" aria-label="View Statekit on GitHub"> <svg viewBox="0 0 24 24" fill="currentColor" aria-hidden="true"> <path d="M12 0c-6.626 0-12 5.373-12 12 0 5.302 3.438 9.8 8.207 11.387.599.111.793-.261.793-.577v-2.234c-3.338.726-4.033-1.416-4.033-1.416-.546-1.387-1.333-1.756-1.333-1.756-1.089-.745.083-.729.083-.729 1.205.084 1.839 1.237 1.839 1.237 1.07 1.834 2.807 1.304 3.492.997.107-.775.418-1.305.762-1.604-2.665-.305-5.467-1.334-5.467-5.931 0-1.311.469-2.381 1.236-3.221-.124-.303-.535-1.524.117-3.176 0 0 1.008-.322 3.301 1.23.957-.266 1.983-.399 3.003-.404 1.02.005 2.047.138 3.006.404 2.291-1.552 3.297-1.23 3.297-1.23.653 1.653.242 2.874.118 3.176.77.84 1.235 1.911 1.235 3.221 0 4.609-2.807 5.624-5.479 5.921.43.372.823 1.102.823 2.222v3.293c0 .319.192.694.801.576 4.765-1.589 8.199-6.086 8.199-11.386 0-6.627-5.373-12-12-12z"></path> </svg>

0 commit comments

Comments
 (0)