updateLayoutStyle()
Supported from API_LEVEL
4.0. For API compatibility, please refer to API_LEVEL.
Updates the layout style of a widget node. For detailed layout object properties, please refer to layout property configuration.
Type
(style: LayoutStyle) => void
Parameters
| Parameter | Type | Description |
|---|---|---|
| style | LayoutStyle | Object containing layout properties, the layout object |
Example
import { createWidget, widget } from '@zos/ui'
const container = createWidget(widget.VIRTUAL_CONTAINER)
// Update container layout style
container.updateLayoutStyle({
display: 'flex',
'flex-direction': 'row',
'justify-content': 'space-between',
'align-items': 'center',
width: '100%',
height: '200px'
})