Store and Initialization
#
BuerliData#
initDoneThis will be set after buerliApi.init was called once. If the user code tries to access data/api of buerli and it is not inizialized, an ERROR will be thrown.
#
optionsThe buerli options.
#
drawingThe drawing management data structure.
#
drawing.idsThe ids of all drawings as array. For easy iteration.
#
drawing.refsThe drawing instances hold by a <ID, Instance> record.
#
drawing.activeStores the id of the current drawing.
#
message#
BuerliOptions#
urlThe url used by buerli-classcad to get a connection to the backend CAD.
#
elements#
plugins#
globalPlugins#
themeThe theme settings for the buerli-react components. The theme settings are stored in the buerli state, even they are only needed for UI components.
Parts of this data will be removed in a future release. Should not be used in user code, except in initialization.
#
theme.primaryThe primary color.
#
theme.secondaryThe secondary color.
#
theme.darkThe dark color.
#
theme.highlightedGeomThe color used for highlighted geometry.
#
theme.hoveredGeomThe color used for hovered geometry.
#
configSpecial configuration. gaga
#
config.geometryCan be used to apply special behaviour for the rendering of geometry.
Since
geometry
config is experimental, it will be changed, removed or replaced in future releases. It should not be used in user code, except in initialization.
#
BuerliApiThe buerli api.
#
initThis api method initializes state. Considering user can accidentally ommit some important like elements, there is a warning disaplying for these cases.
Params
Name | Type | Default | Description |
---|---|---|---|
options | Partial<BuerliOptions> | options which will be set into state.options |
#
createDrawingParams
Name | Type | Default | Description |
---|---|---|---|
name | string |
#
removeDrawingParams
Name | Type | Default | Description |
---|---|---|---|
id | DrawingID |
#
setActiveDrawingParams
Name | Type | Default | Description |
---|---|---|---|
id | DrawingID |