Evenfire is an intelligence layer platform for running LLM agents that take real actions, on your infrastructure
TypeScript
docs(markdown): R3-L1 align preview renderer comments
M3850f5b6d52a
diff --git a/control-ui/components/GfsMarkdownPreview/index.tsx b/control-ui/components/GfsMarkdownPreview/index.tsxindex 21f93335b..46eb793fd 100644--- a/control-ui/components/GfsMarkdownPreview/index.tsx+++ b/control-ui/components/GfsMarkdownPreview/index.tsx@@ -2,14 +2,14 @@// Renderer exception recorded in docs/agents/frontend-style-rules.md// ("Markdown rendering and editing"): this read-only GFS markdown preview uses-// ReactMarkdown + remark-gfm instead of the standard @uiw/react-md-editor-// because the preview must render GFM tables inside a labelled, keyboard--// focusable scrollable table region (here through the shared-// TableViewport/DataTable primitives), which `MDEditor.Markdown` cannot-// preserve without regressing that behavior. Guarantees: no rehype-raw, so raw-// HTML stays inert; urlTransform restricts `src` to inline data:image URIs and-// link hrefs to http(s):/mailto:/# fragments; code blocks render as plain-// `pre` > `code`. Covered by components/__tests__/GfsMarkdownPreview.test.tsx.+// ReactMarkdown + remark-gfm as the established, tested preview integration.+// GFM tables use a labelled, keyboard-focusable scroll region through the+// shared TableViewport/DataTable primitives. MDEditor.Markdown supports custom+// table components; switching requires a separate migration that revalidates+// rendering, keyboard operation, and untrusted-content handling. Guarantees:+// no rehype-raw, so raw HTML stays inert; urlTransform restricts `src` to inline+// data:image URIs and links to http(s):/mailto:/# fragments; code blocks render+// as plain `pre` > `code`. Covered by GfsMarkdownPreview.test.tsx.import { useEffect, useId, useRef, useState } from 'react'import { createPortal } from 'react-dom'import ReactMarkdown from 'react-markdown'diff --git a/desktop-app/ui/src/components/GfsMarkdownPreview/Body.tsx b/desktop-app/ui/src/components/GfsMarkdownPreview/Body.tsxindex fb13b8d20..e9e7e8c95 100644--- a/desktop-app/ui/src/components/GfsMarkdownPreview/Body.tsx+++ b/desktop-app/ui/src/components/GfsMarkdownPreview/Body.tsx@@ -1,12 +1,13 @@// Renderer exception recorded in docs/agents/frontend-style-rules.md// ("Markdown rendering and editing"): this read-only GFS markdown preview uses-// ReactMarkdown + remark-gfm instead of the standard @uiw/react-md-editor-// because the preview must render GFM tables inside a labelled, keyboard--// focusable scrollable table region, which `MDEditor.Markdown` cannot preserve-// without regressing that behavior. Guarantees: no rehype-raw, so raw HTML-// stays inert; urlTransform restricts `src` to inline data:image URIs and link-// hrefs to http(s):/mailto:/# fragments; code blocks render as plain `pre` >-// `code`. Covered by the GfsMarkdownPreview and GfsMarkdownPreviewBody suites.+// ReactMarkdown + remark-gfm as the established, tested preview integration.+// GFM tables use a labelled, keyboard-focusable scroll region.+// MDEditor.Markdown supports custom table components; switching requires a+// separate migration that revalidates rendering, keyboard operation, and+// untrusted-content handling. Guarantees: no rehype-raw, so raw HTML stays+// inert; urlTransform restricts `src` to inline data:image URIs and links to+// http(s):/mailto:/# fragments; code blocks render as plain `pre` > `code`.+// Covered by the GfsMarkdownPreview and GfsMarkdownPreviewBody suites.import { useEffect, useId, useRef, useState } from 'react'import ReactMarkdown from 'react-markdown'import type { Components } from 'react-markdown'