Creates a bubble component that can display various types of content.
Either the content to display or the options object. When an object, it can have the following properties:
Configuration object
Width of the bubble (e.g., '200px', 300)
CSS class name for custom styling
Fixed position of the bubble it can be one of the values: 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right'
Enable/disable drag functionality
{React.CSSProperties} - Inline styles object
URL of the image to display
Icon element to display that can be a string or a React node
Header title text
Header description text
The content to display (only used when options are provided or when no options are provided)
A JSX element representing the bubble component
optionsOrContent
content
bubble
Basic usage with just content
bubble('Hello World'); Copy
bubble('Hello World');
Usage with options and other component blocks
bubble({title: 'Header title', description: 'Header description', overlay: true},[ group([ inputField({ name: 'firstName', label: 'First name', defaultValue: 'Mark', }), ]),]); Copy
bubble({title: 'Header title', description: 'Header description', overlay: true},[ group([ inputField({ name: 'firstName', label: 'First name', defaultValue: 'Mark', }), ]),]);
Usage with other component blocks
bubble([ headerBar({title: 'Modular UI form'}), group([ inputField({ name: 'firstName', label: 'First name', defaultValue: 'Mark', }), ]),]); Copy
bubble([ headerBar({title: 'Modular UI form'}), group([ inputField({ name: 'firstName', label: 'First name', defaultValue: 'Mark', }), ]),]);
Creates a bubble component that can display various types of content.
Param: optionsOrContent
Either the content to display or the options object. When an object, it can have the following properties:
Param: options
Configuration object
Param: options.width
Width of the bubble (e.g., '200px', 300)
Param: options.className
CSS class name for custom styling
Param: options.forcePosition
Fixed position of the bubble it can be one of the values: 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right'
Param: options.isDraggable
Enable/disable drag functionality
Param: options.style
{React.CSSProperties} - Inline styles object
Param: options.image
URL of the image to display
Param: options.icon
Icon element to display that can be a string or a React node
Param: options.title
Header title text
Param: options.description
Header description text
Param: content
The content to display (only used when options are provided or when no options are provided)
Returns
A JSX element representing the bubble component
Remarks
optionsOrContentis either the content to display or the options object.contentis the content to display when theoptionsOrContentis an object.bubblefunction can be used to display a bubble with a headerBar and group.Example
Basic usage with just content
Example
Usage with options and other component blocks
Example
Usage with other component blocks