API Reference
MarkdownRendererOptions
Options controlling how Markdown is parsed and rendered to HTML for a WebView/browser host.
Inheritance
- Object
- MarkdownRendererOptions
Usage
This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.
Returned or exposed by
- Method MarkdownRendererPresets.CreateIntelligenceXTranscript
- Method MarkdownRendererPresets.CreateIntelligenceXTranscript
- Method MarkdownRendererPresets.CreateIntelligenceXTranscriptDesktopShell
- Method MarkdownRendererPresets.CreateIntelligenceXTranscriptDesktopShell
- Method MarkdownRendererPresets.CreateIntelligenceXTranscriptMinimal
- Method MarkdownRendererPresets.CreateIntelligenceXTranscriptMinimal
- Method MarkdownRendererPresets.CreateIntelligenceXTranscriptMinimalPortable
- Method MarkdownRendererPresets.CreateIntelligenceXTranscriptPortable
- Method MarkdownRendererPresets.CreateIntelligenceXTranscriptRelaxed
- Method MarkdownRendererPresets.CreateIntelligenceXTranscriptRelaxed
- Method MarkdownRendererPresets.CreateRelaxed
- Method MarkdownRendererPresets.CreateRelaxed
- Method MarkdownRendererPresets.CreateStrict
- Method MarkdownRendererPresets.CreateStrict
- Method MarkdownRendererPresets.CreateStrictMinimal
- Method MarkdownRendererPresets.CreateStrictMinimal
- Method MarkdownRendererPresets.CreateStrictMinimalPortable
- Method MarkdownRendererPresets.CreateStrictPortable
Accepted by parameters
- Method MarkdownFencedCodeBlockHtmlRenderer.BeginInvoke
- Method MarkdownFencedCodeBlockHtmlRenderer.Invoke
- Method MarkdownHtmlPostProcessor.BeginInvoke
- Method MarkdownHtmlPostProcessor.Invoke
- Method MarkdownRenderer.BuildShellHtml
- Method MarkdownRenderer.ParseDocument
- Method MarkdownRenderer.ParseDocumentResult
- Method MarkdownRenderer.ParseNativeDocument
- Method MarkdownRenderer.RenderBodyHtml
- Method MarkdownRenderer.RenderChatBubbleBodyHtml
- Method MarkdownRenderer.RenderChatBubbleUpdateScript
- Method MarkdownRenderer.RenderUpdateScript
- Constructor MarkdownRendererFeaturePack.MarkdownRendererFeaturePack
- Constructor MarkdownRendererFeaturePack.MarkdownRendererFeaturePack
- Method MarkdownRendererFeaturePack.Apply
- Method MarkdownRendererFeaturePack.IsApplied
- Method MarkdownRendererIntelligenceXAdapter.Apply
- Method MarkdownRendererIntelligenceXAdapter.IsApplied
- Method MarkdownRendererIntelligenceXLegacyMigration.Apply
- Method MarkdownRendererIntelligenceXLegacyMigration.IsApplied
- Constructor MarkdownRendererPlugin.MarkdownRendererPlugin
- Constructor MarkdownRendererPlugin.MarkdownRendererPlugin
- Method MarkdownRendererPlugin.Apply
- Method MarkdownRendererPlugin.IsApplied
- Method MarkdownRendererPreProcessorPipeline.Apply
- Method MarkdownRendererPresets.ApplyChatPresentation
- Method MarkdownRendererPresets.ApplyPortableHtmlOutputProfile
- Method MarkdownRendererShellHeadBuilder.BeginInvoke
- Method MarkdownRendererShellHeadBuilder.Invoke
- Method MarkdownRendererShellUpdateScriptBuilder.BeginInvoke
- Method MarkdownRendererShellUpdateScriptBuilder.Invoke
- Method MarkdownTextPreProcessor.BeginInvoke
- Method MarkdownTextPreProcessor.Invoke
Constructors
public MarkdownRendererOptions() #Creates a new renderer options instance and seeds generic built-in fenced block renderers.
Methods
public Void ApplyFeaturePack(MarkdownRendererFeaturePack featurePack) #VoidApplies a host-level feature pack once.
Parameters
- featurePack OfficeIMO.MarkdownRenderer.MarkdownRendererFeaturePack
public Void ApplyFenceOptionSchema(MarkdownFenceOptionSchema schema) #VoidRegisters a fence option schema once.
Parameters
- schema OfficeIMO.MarkdownRenderer.MarkdownFenceOptionSchema
public Void ApplyPlugin(MarkdownRendererPlugin plugin) #VoidApplies a fenced-block renderer plugin without duplicating existing language registrations.
Parameters
- plugin OfficeIMO.MarkdownRenderer.MarkdownRendererPlugin
public Boolean HasFeaturePack(MarkdownRendererFeaturePack featurePack) #BooleanReturns true when the supplied host-level feature pack has already been applied.
Parameters
- featurePack OfficeIMO.MarkdownRenderer.MarkdownRendererFeaturePack
public Boolean HasFenceOptionSchema(MarkdownFenceOptionSchema schema) #BooleanReturns true when the supplied fence option schema is already registered.
Parameters
- schema OfficeIMO.MarkdownRenderer.MarkdownFenceOptionSchema
public Boolean HasPlugin(MarkdownRendererPlugin plugin) #BooleanReturns true when the supplied plugin has already registered any of its languages.
Parameters
- plugin OfficeIMO.MarkdownRenderer.MarkdownRendererPlugin
public Boolean TryGetFenceOptionSchema(String language, out MarkdownFenceOptionSchema schema) #BooleanAttempts to resolve the most recently-registered fence option schema for the supplied language.
Parameters
- language System.String
- schema OfficeIMO.MarkdownRenderer.MarkdownFenceOptionSchema@
public Boolean TryParseFenceOptions(String language, MarkdownCodeFenceInfo fenceInfo, out MarkdownFenceOptionSet optionSet) #BooleanAttempts to parse fence metadata using the most recently-registered schema for the supplied language.
Parameters
- language System.String
- fenceInfo OfficeIMO.Markdown.MarkdownCodeFenceInfo
- optionSet OfficeIMO.MarkdownRenderer.MarkdownFenceOptionSet@
Inherited Methods
public override Boolean Equals(Object obj) #BooleanParameters
- obj Object
Properties
public MarkdownReaderOptions ReaderOptions { get; set; } #Markdown reader options used when parsing Markdown into OfficeIMO.Markdown's typed model. Defaults are biased for untrusted input (HTML disabled and file URLs blocked).
public HtmlOptions HtmlOptions { get; set; } #HTML rendering options. These control the CSS preset and optional Prism support.
public String BaseHref { get; set; } #Optional base href inserted into the HTML update payload as a <base> tag. The incremental updater moves it to <head> so relative links/images resolve.
public Boolean NormalizeEscapedNewlines { get; set; } #When true, normalizes escaped newlines ("\\n"/"\\r\\n") into real newlines before parsing. Useful when Markdown arrives as a JSON string literal. Default: true.
public Boolean NormalizeZeroWidthSpacingArtifacts { get; set; } #When true, removes zero-width spacing artifacts such as U+200B/U+2060/U+FEFF before parsing. Default: false.
public Boolean NormalizeEmojiWordJoins { get; set; } #When true, inserts a missing space between common status/emoji markers and following prose (for example, ✅Healthy becomes ✅ Healthy). Default: false.
public Boolean NormalizeCompactNumberedChoiceBoundaries { get; set; } #When true, inserts missing spacing around compact numbered-choice joins (for example, or2) becomes or 2)). Default: false.
public Boolean NormalizeSentenceCollapsedBullets { get; set; } #When true, inserts a missing newline before compact bullet markers emitted directly after sentence punctuation. Default: false.
public Boolean NormalizeSoftWrappedStrongSpans { get; set; } #When true, joins short hard-wrapped bold labels (for example, "**Status\nOK**") into a single bold span. This helps chat-style outputs that wrap short headers mid-token. Default: false.
public Boolean NormalizeInlineCodeSpanLineBreaks { get; set; } #When true, compacts inline code spans containing line breaks into a single line. This preserves strict parser compatibility for malformed model outputs. Default: false.
public Boolean NormalizeEscapedInlineCodeSpans { get; set; } #When true, converts escaped inline code spans (for example, \`code\`) into standard markdown code spans. Useful for chat/model outputs that over-escape backticks. Default: false.
public Boolean NormalizeTightStrongBoundaries { get; set; } #When true, inserts a missing space after a closing strong span followed immediately by a word character (for example, **Healthy**next becomes **Healthy** next). Default: false.
public Boolean NormalizeTightArrowStrongBoundaries { get; set; } #When true, normalizes compact arrow-to-strong boundaries (for example, ->**Why it matters:** becomes -> **Why it matters:**). Default: false.
public Boolean NormalizeBrokenStrongArrowLabels { get; set; } #When true, repairs malformed strong spans that are missing the closing delimiter immediately before an arrow-led strong label (for example, **No current failures -> **Why it matters:** becomes **No current failures** -> **Why it matters:**). Default: false.
public Boolean NormalizeWrappedSignalFlowStrongRuns { get; set; } #When true, repairs malformed signal-flow bullets where an entire arrow chain was accidentally wrapped in one strong span. Default: false.
public Boolean NormalizeSignalFlowLabelSpacing { get; set; } #When true, inserts missing spaces after signal-flow labels inside arrow segments (for example, -> **Why it matters:**coverage becomes -> **Why it matters:** coverage). Default: false.
public Boolean NormalizeCollapsedMetricChains { get; set; } #When true, expands collapsed transcript-style metric chains into real markdown lines and converts legacy bold metric labels into plain labels with bold values. Default: false.
public Boolean NormalizeHostLabelBulletArtifacts { get; set; } #When true, repairs compact host-label bullets and merges simple continuation lines (for example, -AD1 followed by healthy becomes - AD1 healthy). Default: false.
public Boolean NormalizeTightColonSpacing { get; set; } #When true, inserts a missing space after a colon in prose labels (for example, Why it matters:missing coverage becomes Why it matters: missing coverage). Default: false.
public Boolean NormalizeHeadingListBoundaries { get; set; } #When true, inserts a missing newline between an ATX heading and an immediately-following unordered strong-label list marker on the same line (for example, ## Summary- **Item:** value becomes ## Summary\n- **Item:** value). Default: false.
public Boolean NormalizeCompactStrongLabelListBoundaries { get; set; } #When true, inserts a missing newline before compact unordered strong-label list markers that were emitted inline after punctuation or symbol characters (for example, ✅- **FSMO:** ok becomes ✅\n- **FSMO:** ok). Default: false.
public Boolean NormalizeCompactHeadingBoundaries { get; set; } #When true, inserts a missing newline before compact ATX headings emitted directly after prose or symbols on the same line (for example, unexpected### Reason becomes unexpected\n### Reason). Default: false.
public Boolean NormalizeStandaloneHashHeadingSeparators { get; set; } #When true, removes stray standalone # separator lines that appear immediately before a real ATX heading. Default: false.
public Boolean NormalizeBrokenTwoLineStrongLeadIns { get; set; } #When true, repairs broken two-line strong lead-ins such as **Result followed by body text** tail. Default: false.
public Boolean NormalizeColonListBoundaries { get; set; } #When true, inserts a missing newline between a colon and an immediately-following unordered list marker on the same line (for example, Next step:- **Item** becomes Next step:\n- **Item**). Default: false.
public Boolean NormalizeCompactFenceBodyBoundaries { get; set; } #When true, inserts a missing newline between a fenced code block language token and inline body content for compact malformed transcript output (for example, ```json{"x":1} or ```mermaidflowchart LR A-->B). Default: false.
public Boolean NormalizeLooseStrongDelimiters { get; set; } #When true, trims accidental whitespace immediately inside strong delimiters (for example, ** Healthy** or **Healthy ** become **Healthy**). Default: false.
public Boolean NormalizeOrderedListMarkerSpacing { get; set; } #When true, inserts a missing space after ordered list markers when list item content starts immediately with emphasis delimiters (for example, 2.**Task** -> 2. **Task**). Default: false.
public Boolean NormalizeOrderedListParenMarkers { get; set; } #When true, converts ordered list markers in 1) form to 1. with normalized spacing. Default: false.
public Boolean NormalizeOrderedListCaretArtifacts { get; set; } #When true, removes stray caret artifacts after ordered list markers (for example, 2.^ **Task** -> 2. **Task**). Default: false.
public Boolean NormalizeCollapsedOrderedListBoundaries { get; set; } #When true, inserts missing newlines between adjacent ordered list items that were emitted on one line (for example, ...)2.**Task** -> ...)\n2.**Task**). Default: false.
public Boolean NormalizeOrderedListStrongDetailClosures { get; set; } #When true, repairs malformed ordered list items where a bold title is missing its closing strong delimiter before a parenthetical detail section (for example, 1. **Task(detail) -> 1. **Task** (detail)). Default: false.
public Boolean NormalizeTightParentheticalSpacing { get; set; } #When true, inserts a missing space before parenthetical phrases adjacent to prose or strong spans (for example, **Task**(detail) -> **Task** (detail)). Default: false.
public Boolean NormalizeNestedStrongDelimiters { get; set; } #When true, flattens malformed nested strong delimiters emitted by some model outputs (for example, **from **Service Control Manager**.**). Default: false.
public Boolean NormalizeDanglingTrailingStrongListClosers { get; set; } #When true, upgrades trailing list-item strong-close artifacts (for example, - Overall health Healthy**** becomes - Overall health **Healthy**). Default: false.
public Boolean NormalizeMetricValueStrongRuns { get; set; } #When true, repairs malformed strong runs used as metric values (for example, ******healthy**, **✅****Healthy**, or a missing trailing closer). Default: false.
public List<MarkdownTextPreProcessor> MarkdownPreProcessors { get; } #Optional markdown pre-processors applied before parsing. These run after escaped newline normalization and after built-in text normalization. Default: none.
public List<IMarkdownDocumentTransform> DocumentTransforms { get; } #Optional AST-level document transforms applied by MarkdownRendererOptions) after parsing and before HTML generation. Prefer these for structural/content rewrites that should operate on MarkdownDoc instead of raw markdown text or rendered HTML strings. Default: none.
public MermaidOptions Mermaid { get; } #Mermaid support options.
public ChartOptions Chart { get; } #Chart.js support options.
public NetworkOptions Network { get; } #vis-network support options.
public MathOptions Math { get; } #Math (KaTeX) support options.
public List<MarkdownFencedCodeBlockRenderer> FencedCodeBlockRenderers { get; } #Optional custom fenced code block renderers applied before built-in Mermaid/Chart/Math conversions. These can replace rendered <pre><code class="language-..."> blocks with host-specific HTML and optionally contribute shell head/update fragments through BuildShellHeadHtml, BuildBeforeContentReplaceScript, and BuildAfterContentReplaceScript. The default collection is seeded with built-in Chart.js / vis-network renderers, and later additions win when aliases overlap.
public IReadOnlyList<String> AppliedFeaturePackIds { get; } #Stable ids of host-level feature packs already applied to this renderer configuration.
public IReadOnlyList<MarkdownFenceOptionSchema> FenceOptionSchemas { get; } #Registered fence option schemas available to renderer plugins and host integrations.
public List<MarkdownHtmlPostProcessor> HtmlPostProcessors { get; } #Optional post-processors applied to the HTML fragment produced by MarkdownRendererOptions). These run after built-in conversions (Mermaid/Chart/Math) and after BaseHref injection. Prefer DocumentTransforms when the change can be expressed against the AST before HTML is emitted. Default: none.
public String ContentSecurityPolicy { get; set; } #Optional Content-Security-Policy meta tag value for the shell document (inserted as http-equiv). Leave unset unless your host wants to enforce a specific policy. Default: null.
public String ShellCss { get; set; } #Optional additional CSS appended to the shell document after built-in styles and assets. Use this to theme/override the default styles without replacing the full shell HTML. Default: null.
public Boolean EnableCodeCopyButtons { get; set; } #When true, the shell will add "Copy" buttons to fenced code blocks (client-side). Default: false.
public Boolean EnableTableCopyButtons { get; set; } #When true, the shell will add table copy actions (TSV/CSV) above rendered tables (client-side). Default: false.
public Nullable<Int32> MaxMarkdownChars { get; set; } #Optional guardrail limit for Markdown input size (character count). When exceeded, MarkdownOverflowHandling applies. Default: null (no limit).
public Nullable<Int32> MaxBodyHtmlBytes { get; set; } #Optional guardrail limit for the rendered HTML payload size (UTF-8 bytes). When exceeded, BodyHtmlOverflowHandling applies. Default: null (no limit).
public OverflowHandling MarkdownOverflowHandling { get; set; } #Behavior when MaxMarkdownChars is exceeded. Default: Truncate.
public OverflowHandling BodyHtmlOverflowHandling { get; set; } #Behavior when MaxBodyHtmlBytes is exceeded. Default: RenderError.