SidebarLayoutV1

toloka.client.project.template_builder.layouts.SidebarLayoutV1 | Source code

SidebarLayoutV1(
self,
content: Optional[BaseComponent] = None,
controls: Optional[BaseComponent] = None,
*,
controls_width: Optional[Union[BaseComponent, float]] = None,
extra_controls: Optional[BaseComponent] = None,
min_width: Optional[Union[BaseComponent, float]] = None,
validation: Optional[BaseComponent] = None,
version: Optional[str] = '1.0.0'
)

A layout with a main content block and a panel with controls.

The component supports modes:

  • Widescreen — The control panel is placed to the right of the main block.
  • Compact — The controls are placed under the main block and stretch to the entire width.

For more information, see layout.sidebar.

Parameters description

ParametersTypeDescription
contentOptional[BaseComponent]

The main block.

controlsOptional[BaseComponent]

The control panel.

controls_widthOptional[Union[BaseComponent, float]]

The width in pixels of the control panel in the widescreen mode.

Default value: 200.

extra_controlsOptional[BaseComponent]

An additional panel with controls. It is placed below the controls.

min_widthOptional[Union[BaseComponent, float]]

The minimum width in pixels of the component in a widescreen mode. If the component width is less than the specified value, the interface switches to the compact mode.

Default value: 400.

validationOptional[BaseComponent]

Validation rules.

Last updated: August 28, 2023

Toloka-Kit
OverviewGetting API keyQuick start
Recipes
Reference
toloka.client
toloka.async_client
toloka.autoquality [autoquality]
toloka.metrics
toloka.streaming