Tagflow class

Main widget for rendering rich content.

Inheritance

Constructors

Tagflow({required String html, TagflowTheme? theme, @Deprecated('Legacy converter API. Use registry: TagflowComponentRegistry(...) ' 'instead. Will be removed in tagflow 2.0.') List<ElementConverter<TagflowNode>> converters = const [], ErrorWidgetBuilder errorBuilder = _defaultErrorWidget, @Deprecated('Has no effect: content is adapted synchronously. ' 'Will be removed before tagflow 1.0.0.') WidgetBuilder loadingBuilder = _defaultLoadingWidget, TagflowViewOptions? viewOptions, @Deprecated('Use viewOptions: TagflowViewOptions(...) instead. ' 'Will be removed in tagflow 2.0.') TagflowOptions? options, TagflowRenderBoundary? renderBoundary, Key? key})
Creates a new legacy HTML Tagflow widget.
const
Tagflow.document(TagflowDocument document, {TagflowTheme? theme, TagflowRenderTheme? renderTheme, TagflowComponentRegistry? registry, @Deprecated('Legacy converter API. Use registry: TagflowComponentRegistry(...) ' 'instead. Will be removed in tagflow 2.0.') List<ElementConverter<TagflowNode>> converters = const [], ErrorWidgetBuilder errorBuilder = _defaultErrorWidget, @Deprecated('Has no effect: content is adapted synchronously. ' 'Will be removed before tagflow 1.0.0.') WidgetBuilder loadingBuilder = _defaultLoadingWidget, TagflowViewOptions? viewOptions, @Deprecated('Use viewOptions: TagflowViewOptions(...) instead. ' 'Will be removed in tagflow 2.0.') TagflowOptions? options, Key? key})
Creates a new Tagflow widget from a native runtime document.
const
Tagflow.html({required String html, TagflowHtmlAdapter? adapter, String? documentId, TagflowTheme? theme, TagflowRenderTheme? renderTheme, TagflowComponentRegistry? registry, @Deprecated('Legacy converter API. Use registry: TagflowComponentRegistry(...) ' 'instead. Will be removed in tagflow 2.0.') List<ElementConverter<TagflowNode>> converters = const [], ErrorWidgetBuilder errorBuilder = _defaultErrorWidget, @Deprecated('Has no effect: content is adapted synchronously. ' 'Will be removed before tagflow 1.0.0.') WidgetBuilder loadingBuilder = _defaultLoadingWidget, TagflowViewOptions? viewOptions, @Deprecated('Use viewOptions: TagflowViewOptions(...) instead. ' 'Will be removed in tagflow 2.0.') TagflowOptions? options, TagflowRenderBoundary? renderBoundary, Key? key})
Creates a new Tagflow widget from HTML.
const
Tagflow.markdown({required String markdown, TagflowMarkdownAdapter? markdownAdapter, String? documentId, TagflowTheme? theme, TagflowRenderTheme? renderTheme, TagflowComponentRegistry? registry, ErrorWidgetBuilder errorBuilder = _defaultErrorWidget, @Deprecated('Has no effect: content is adapted synchronously. ' 'Will be removed before tagflow 1.0.0.') WidgetBuilder loadingBuilder = _defaultLoadingWidget, TagflowViewOptions? viewOptions, Key? key})
Creates a new Tagflow widget from GitHub Flavored Markdown.
const

Properties

adapter → TagflowHtmlAdapter?
Adapter used by Tagflow.html to produce a runtime document.
final
converters → List<ElementConverter<TagflowNode>>
Additional legacy converters to use.
final
document → TagflowDocument?
The canonical runtime document to render.
final
documentId → String?
Id given to the document adapted from html or markdown.
final
errorBuilder → ErrorWidgetBuilder
Error builder for handling parsing/conversion errors
final
hashCode → int
The hash code for this object.
no setterinherited
html → String?
The HTML content to render.
final
key → Key?
Controls how one widget replaces another widget in the tree.
finalinherited
loadingBuilder → WidgetBuilder
Not shown: content is adapted synchronously, before the first frame.
final
markdown → String?
The Markdown content to render.
final
markdownAdapter → TagflowMarkdownAdapter?
Adapter used by Tagflow.markdown to produce a runtime document.
final
options → TagflowOptions
Legacy compatibility access to the old options shape.
no setter
registry → TagflowComponentRegistry?
Semantic component registry used by the runtime entry points.
final
renderBoundary → TagflowRenderBoundary?
HTML-only render boundary used by HTML entry points.
no setter
renderTheme → TagflowRenderTheme?
Typed styling for the built-in components, merged over the enclosing TagflowRenderThemeScope and the defaults from the ambient Theme.
final
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
theme → TagflowTheme?
Legacy theme.
final
viewOptions → TagflowViewOptions
Runtime view options for configuring the Tagflow widget.
no setter

Methods

createElement() → StatefulElement
Creates a StatefulElement to manage this widget's location in the tree.
inherited
createState() → State<Tagflow>
Creates the mutable state for this widget at a given location in the tree.
override
debugDescribeChildren() → List<DiagnosticsNode>
Returns a list of DiagnosticsNode objects describing this node's children.
inherited
debugFillProperties(DiagnosticPropertiesBuilder properties) → void
Add additional properties associated with the node.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toDiagnosticsNode({String? name, DiagnosticsTreeStyle? style}) → DiagnosticsNode
Returns a debug representation of the object that is used by debugging tools and by DiagnosticsNode.toStringDeep.
inherited
toString({DiagnosticLevel minLevel = DiagnosticLevel.info}) → String
A string representation of this object.
inherited
toStringDeep({String prefixLineOne = '', String? prefixOtherLines, DiagnosticLevel minLevel = DiagnosticLevel.debug, int wrapWidth = 65}) → String
Returns a string representation of this node and its descendants.
inherited
toStringShallow({String joiner = ', ', DiagnosticLevel minLevel = DiagnosticLevel.debug}) → String
Returns a one-line detailed description of the object.
inherited
toStringShort() → String
A short, textual description of this widget.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited