Auto Fit Container Styling

All containers in Titan enable you to insert multiple elements into one holder. When this container is moved all the elements inside of it move along a unit, keeping their position in the container.

The Auto Fit might look like a regular container, where you can place elements freely but it is in fact a stack element built of rows that expands and contracts automatically based on the content inside of it and allows you to insert only one element per row. Each time you drag in an element, a new row opens and the element is placed inside below the previous row. The Auto Fit stacks the elements vertically by default, but it may also be changed to fit elements in a horizontal stack.

The Auto Fit’s main purpose is to display dynamic data. It expands to fit larger content and contracts when the content is smaller or hidden, without leaving any unwanted spaces. The Auto Fit can be made to look interactive using three states: Default, Hover and Clicked. Styling the states differently will create a desired effect.

This element can be broken down into two parts, which can be styled individually, for example, the Root fill color and size or the Overlay border. This element can be edited on both the Element Style Level and the Project Style Level.

The Three Auto Fit Container States

#OptionFunctionAvailable in Project or Element
1DefaultThe Default option refers to the basic state of a Link element. This state is when it is not hovered or clicked on, but simply visible.
2HoverThis option refers to the state of the Link once the user hovers over it with the mouse.
3ClickedThis refers to the state of the Link when the user clicks it.
Autofit Container styling options
Autofit Container styling options
#OptionFunctionAvailable in Project or Element
1RootThis option enables you to set general properties that affect the Auto Fit Container as a whole.
2OverlayThe Overlay option allows you to create a filter or effect above the Auto Fit container by setting a partially transparent color, image or border on top of it.

1. Root

The Root option enables you to set general properties that affect the Auto Fit Container as a whole, such as fill, spacing, position, size, padding, and so much more.

You can also give end users an indication of when they are hovering or clicking on the Auto Fit Container. For this reason, Titan provides three states for the Root styling options: Default, Hover, and Clicked. You can set different fill or border values in each state, for example, to create the desired effect.

Root styling options
Root styling options
#OptionFunctionAvailable in Project or Element
1FillThe Fill option allows you to set the background color of the Auto Fit Container. The color can be set by selecting from a color pallet or by providing a HEX color code.

An image may also be uploaded as a background.

Set your selected fill of choice (color or image) to also have opacity.
2SpacingThe Spacing property enables you to set the vertical spacing in pixels between the Auto Fit rows or the horizontal space when the autofit is used horizontally.
3PositionYou can use this option to change the Auto Fit Container’s location in the content area, on the x and y-axis (left/right/top/bottom).

Position also allows you to make the Auto Fit Container float over its parent container or over the entire page.

“Float over Parent” allows you to set the location of the Auto Fit Container within the box containing it, e.g. strip.

“Float over Page” allows you to set the location of the Auto Fit Container inside of the entire page (and have it stay in the same location even when the user is scrolling in it).
4SizeThis option allows you to change the width and height of the Auto Fit Container.
5PaddingThis option allows you to set a space inside of the Auto Fit container border so that the content does not reach the edges. The padding could be set for the Top, Bottom, Left and Right sides.
6AlignmentYou can set the Auto Fit Container to a vertical or horizontal position in relation to its strip (left/center/right/top/middle/bottom).

The Alignment option also allows you to set the position of a few elements in relation to each other.
7BorderThe Border option allows you to style the contour of the Auto Fit Container: make the border visible or invisible, change its width, color, corner radius, and more.

The border can be styled as a whole or separated into top, bottom, left, and right border lines.
8ShadowYou can add single or multiple shadow layers to the inner and outer contours of the Auto Fit Container with the Shadow option.
9User CSSCascading Style Sheets (CSS) allow a user to apply styles on the Auto Fit Container with CSS code.

Note: For Project styling, CSS is accessed via the Tools menu, which you can read about in our Style Elements Using User CSS article.

2. Overlay

The Overlay option allows you to create a filter or effect above the Auto Fit container by setting a partially transparent color, image or border on top of it.

Overlay styling options
Overlay styling options
#OptionFunctionAvailable in Project or Element
1FillThe Fill option allows you to set a color for an overlay in the Auto Fit Container. The color can be set by selecting from a color pallet or by providing a HEX color code.

An image may also be uploaded as a background.

Set your selected fill of choice (color or image) to also have opacity.
2BorderThe Border option allows you to style the contour of the overlay: make the border visible or invisible, change its width, color, corner radius, and more.

The border can be styled as a whole or separated into top, bottom, left, and right border lines.

Hidden Title

Need more help?