Components
Text
Components
Text
Learn how to use the Text component in your applications
Example Usage
#An Example Input Box:
from zero_true import Text
example = TextInput(id="prompt_inputs", label="Enter your prompt", placeholder="Type something...")
Example Output
Overview
pydantic model zero_true.Text
JSON Schema
{
"title": "Text",
"description": "Text is a read only component that is meant for static text",
"type": "object",
"properties": {
"id": {
"description": "Unique id for a component",
"title": "Id",
"type": "string"
},
"variable_name": {
"default": "",
"description": "Optional variable name associated with a component",
"title": "Variable Name",
"type": "string"
},
"component": {
"default": "v-text",
"description": "Vue component name",
"title": "Component",
"type": "string"
},
"text": {
"default": "",
"description": "The actual text content",
"title": "Text",
"type": "string"
},
"type": {
"default": "text-body-1",
"description": "Text type to display",
"enum": [
"text-h1",
"text-h2",
"text-h3",
"text-h4",
"text-h5",
"text-h6",
"text-subtitle-1",
"text-subtitle-2",
"text-body-1",
"text-body-2",
"text-button",
"text-caption",
"text-overline"
],
"title": "Type",
"type": "string"
},
"color": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"default": null,
"description": "Color of the text",
"title": "Color"
}
},
"required": [
"id"
]
}
Bellow are the various attributes you can assign to the component. Utlizing them can allow for modifications to the pre-created object.
zero_true.Text
Zero True Component
field color: str | None = None Color of the text
field component: str = ‘v-text’ Vue component name
field text: str = ” The actual text content
field type: str = ‘text-body-1’ Text type to display
On this page