Function: Semantic()
@termwright/ink / Semantic
Function: Semantic()
Section titled “Function: Semantic()”Semantic(
__namedParameters):ReactNode
Defined in: ink/src/semantic.tsx:67
Annotate the element a child renders, declaratively.
Nested <Semantic> elements need no wiring: the probe derives parentId
from the rendered tree, so a listitem inside a list is published under
it because that is where it actually sits.
It works with ordinary ink.render; the optional injected probe reads the
weak registry. The component adds no host node and therefore no layout box.
Parameters
Section titled “Parameters”__namedParameters
Section titled “__namedParameters”Returns
Section titled “Returns”ReactNode
Example
Section titled “Example”<Semantic role="dialog" name="Permission" extended={{environment: "prod"}}> <Box borderStyle="round" flexDirection="column"> <Semantic role="button" name="Approve"> <Box><Text>Approve</Text></Box> </Semantic> </Box></Semantic>