Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Component Palette Icon:



On_this_page



The Breakpoint container consists of a single breakpoint, with two child views. In other words, using a Breakpoint container offers you a layout with the opportunity to create two different views that are shown at two distinct ranges of layout widths. 

This allows for a very simple responsive design that removes one container and replaces it with another when the viewport width is changed. With the Breakpoint container, you can define completely different content to render for each child. This is in contrast to a container such as the column container, where the content for each breakpoint is identical but the layout of it changes according to screen size. 

Breakpoint containers are ideal to use in cases where you want completely different components available between a mobile user or a desktop user, since the components in each breakpoint are completely separate instances. Thus, if you're attempting to make a responsive view, and a Flex container isn't quite giving the desired result, a Breakpoint container can be used to switch to a completely different container or view. 


Properties

Perspective_property


NameDescriptionProperty Type
breakpointWidth (in pixels) breakpoint declarations for child layouts. When the container is sized below minWidth, child position rules will fall back to the next set breakpoint rules. value: numeric
determinant
New_in
Version8.1.32


Choose between the height or width dimension that the Breakpoint container will use to break. Default is width.

value: string
styleUse Style to customize the visual style of the component. The Style menu contains all the tools for modifying text, background, margins, and borders. You can also specify a style class.object
Editor_notes

Make this visible and append to table above under "breakpoint" property upon 8.1.32 release

NameDescriptionProperty Typedeterminant New_in
Version8.1.32

Choose between the height or width dimension that the Breakpoint container will use to break. Default is width.

value: string


Child Component Position Properties

When a component is placed inside of a Breakpoint container, it will inherit the position property listed below. 

PropertyDescriptionData Type
sizeIndicates which child the component located in. Expected values are "small" and "large". value: string


Scripting

See the Perspective - Breakpoint Container Scripting page for the full list of scripting functions available for this component.


Example (Nested Breakpoint Containers)

In this example, we have a Breakpoint container nested inside a root Breakpoint container. The setup is as follows:

Containers

  • The nested Breakpoint container is used when the root Breakpoint container's size is less than 800 pixels.
  • The nested Breakpoint container will change when its size is less than 700 pixels.

Components

  • When the page is greater than 800 pixels, an XY Chart is displayed.
  • When the page is between 700 and 800 pixels, an empty Power Chart is shown.
  • When the page is less than 700 pixels, an Icon is displayed.

The relevant properties for this example are displayed below:

Root Breakpoint Container Properties:

PropertyValue
Breakpoint800px

Nested Breakpoint Container Properties:

PropertyValue
Breakpoint700px