RichEntryTile class
Renders a RichDocument (P6e Task 5's parse of Filament's ProseMirror
tree) with RichText/TextSpan for inline runs and Column for blocks —
the two runtime dependencies this package already has, no more (design
spec, "Flutter"). Registered under EntryKind.rich in EntryRegistry.
Links. Opening a URL needs a platform launcher, a dependency this
package will not take, so tapping is host-wired exactly like
RelationSectionWidget.onSeeAllTap: the host passes its own
EntryRegistry.defaults(onLinkTap: ...) to ResourceViewScreen.registry.
onLinkTap null — the default, no host wired — renders a link as plain,
unstyled text. That is deliberate: this project's own "absence means
unavailable" rule caught two dead-affordance bugs in P6d, and a blue
underlined span that does nothing when tapped is exactly the disabled
corpse that rule exists to prevent.
Unknown nodes. A node type outside the closed vocabulary — a future Filament addition — renders its descendant text as a paragraph rather than vanishing. Silent content loss is the one outcome worse than ugly rendering.
Images. attrs.src null (Filament's state cast nulls it for
private-visibility attachments) skips the node instead of rendering a
broken image.
- Inheritance
-
- Object
- DiagnosticableTree
- Widget
- StatefulWidget
- RichEntryTile
Constructors
- RichEntryTile({required RichDocument document, String? label, void onLinkTap(String href)?, Key? key})
-
const
Properties
- document → RichDocument
-
final
- hashCode → int
-
The hash code for this object.
no setterinherited
- key → Key?
-
Controls how one widget replaces another widget in the tree.
finalinherited
- label → String?
-
final
- onLinkTap → void Function(String href)?
-
Called with a link mark's
hrefwhen its span is tapped. Null means no host has wired link handling — see the class doc.final - runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
Methods
-
createElement(
) → StatefulElement -
Creates a StatefulElement to manage this widget's location in the tree.
inherited
-
createState(
) → State< RichEntryTile> -
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