Skip to content

part class

Displays its children in a block.

Methods

__init__()

__init__(
    class_name=None,
    render=True,
    page=None,
    height=None,
    content=None,
    partial=None,
    id=None,
    properties=None,
    hover_text=None,
) -> None

Create a new part element.

Parameters:

Name Type Description Default
class_name dynamic(str)

A list of CSS class names, separated by white spaces, that are associated with the generated HTML Element.
These class names are added to the default taipy-part class name.

None
render dynamic(bool)

If True, this part is visible on the page.
If False, the part is hidden and its content is not displayed.

True
page dynamic(str)

The page to show as the content of the block (page name if defined or a URL in an iframe).
This should not be defined if partial is set.

None
height dynamic(str)

The height of the part, in CSS units.

None
content dynamic(Any)

The content provided to the part. See the documentation section on content providers.

None
partial Partial

A Partial object that holds the content of the block.
This should not be defined if page is set.

None
id str

The identifier assigned to the rendered HTML component.
This can be used in callbacks or to target the element for styling.

None
properties dict[str, Any]

A dictionary of additional properties that can be set to the element.

None
hover_text dynamic(str)

The text that is displayed when the user hovers over the element.

None