# Layout Containers

The Telerik UI TileLayout for ASP.NET Core component tiles are configured by using the [`Containers`](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/tilelayoutbuilder#containerssystemaction) configurator.

## Dimensions

Each tile can span across several rows and columns. The space that the tile takes up is determined by its container [`RowSpan()`](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/tilelayoutcontainerbuilder#rowspansystemdouble) and [`ColSpan()`](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/tilelayoutcontainerbuilder#colspansystemdouble).

## Headers

The tiles can be configured with our without headers.

> Headers are required if using the `Reorderable()` functionality of the widget.

The headers render their content via the [`Header.Text()`](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/tilelayoutcontainerheadersettingsbuilder#textsystemstring) which is plain text or by utilizing a [`Header.Template()`](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/tilelayoutcontainerheadersettingsbuilder#templatesystemstring) or [`Header.TemplateId()`](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/tilelayoutcontainerheadersettingsbuilder#templateidsystemstring).

## Body content

The main tile content is rendered from the [`BodyTemplate()`](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/tilelayoutcontainerbuilder#bodytemplatesystemstring) that can also be plain text or a complex template with widgets in it. for complex widgets, the [`BodyTemplateId()`](https://www.telerik.com/aspnet-core-ui/documentation/api/kendo.mvc.ui.fluent/tilelayoutcontainerbuilder#bodytemplateidsystemstring) might be more suitable.

> When using widgets inside the template, their `ToClientTemplate()` method needs to be called.

## Container Styles

The TileLayout containers do not support a container-level `HtmlAttributes()` method in the HtmlHelper or an `html-attributes` attribute in the TagHelper. The `HtmlAttributes()` configuration applies to the root TileLayout element, not to individual containers.

To customize the class used by all tile items, override the `kendo.ui.TileLayout.styles.item` style before the widget is initialized. To add attributes to content inside a tile, include them in the container body template. Per-container attributes require client-side customization after the TileLayout is initialized.

The TileLayout exposes an object that allows you to override the following styles:

```JS
    var tileLayoutStyles = {
        wrapper: "k-widget k-tilelayout",
        item: "k-tilelayout-item k-card",
        itemHeader: "k-tilelayout-item-header k-card-header",
        itemHeaderTitle: "k-card-title",
        itemBody: "k-tilelayout-item-body k-card-body",
        reorderHint: "k-layout-item-hint k-layout-item-hint-reorder",
        resizeHint: "k-layout-item-hint k-layout-item-hint-resize"
    };
```

To override any of the classes, add your own or remove some, insert the new definition before the widget is initialized:

```JS
    kendo.ui.TileLayout.styles.item = "k-tilelayout-item k-card my-own-class";
```

## See Also

* [Overview of the Tile Layout (Demo)](https://demos.telerik.com/kendo-ui/tilelayout/index)
* [API Reference of the Tile Layout](https://www.telerik.com/aspnet-core-ui/documentation/api/tilelayout)
* [Resizing](https://www.telerik.com/aspnet-core-ui/documentation/html-helpers/layout/tilelayout/resizing)
* [Reordering](https://www.telerik.com/aspnet-core-ui/documentation/html-helpers/layout/tilelayout/reordering)
