Margin

The Telerik and Kendo UI Spacing utilities enable you to apply and control different aspects of an elements layout.

Margin

The Telerik and Kendo UI Margin Utilities are CSS utility classes that enable you to control the margin area of an element.

Utility ClassCSS Property
.k-m-0margin: 0;
.k-m-1pxmargin: 1px;
.k-m-1margin: 0.25rem;
.k-m--1pxmargin: -1px;
.k-m--1margin: -0.25rem;
.k-m-xsmargin: 0.25rem;
.k-m-smmargin: 0.5rem;
.k-m-mdmargin: 0.75rem;
.k-m-lgmargin: 1rem;
.k-m-xlmargin: 1.5rem;
.k-m-thinmargin: 0.125rem;
.k-m-hairmargin: 1px;
.k-m-automargin: auto;
.k-mt-0margin-top: 0;
.k-mt-1pxmargin-top: 1px;
.k-mt-1margin-top: 0.25rem;
.k-mt--1pxmargin-top: -1px;
.k-mt--1margin-top: -0.25rem;
.k-mt-xsmargin-top: 0.25rem;
.k-mt-smmargin-top: 0.5rem;
.k-mt-mdmargin-top: 0.75rem;
.k-mt-lgmargin-top: 1rem;
.k-mt-xlmargin-top: 1.5rem;
.k-mt-thinmargin-top: 0.125rem;
.k-mt-hairmargin-top: 1px;
.k-mt-automargin-top: auto;
.k-mr-0margin-right: 0;
.k-mr-1pxmargin-right: 1px;
.k-mr-1margin-right: 0.25rem;
.k-mr--1pxmargin-right: -1px;
.k-mr--1margin-right: -0.25rem;
.k-mr-xsmargin-right: 0.25rem;
.k-mr-smmargin-right: 0.5rem;
.k-mr-mdmargin-right: 0.75rem;
.k-mr-lgmargin-right: 1rem;
.k-mr-xlmargin-right: 1.5rem;
.k-mr-thinmargin-right: 0.125rem;
.k-mr-hairmargin-right: 1px;
.k-mr-automargin-right: auto;
.k-mb-0margin-bottom: 0;
.k-mb-1pxmargin-bottom: 1px;
.k-mb-1margin-bottom: 0.25rem;
.k-mb--1pxmargin-bottom: -1px;
.k-mb--1margin-bottom: -0.25rem;
.k-mb-xsmargin-bottom: 0.25rem;
.k-mb-smmargin-bottom: 0.5rem;
.k-mb-mdmargin-bottom: 0.75rem;
.k-mb-lgmargin-bottom: 1rem;
.k-mb-xlmargin-bottom: 1.5rem;
.k-mb-thinmargin-bottom: 0.125rem;
.k-mb-hairmargin-bottom: 1px;
.k-mb-automargin-bottom: auto;
.k-ml-0margin-left: 0;
.k-ml-1pxmargin-left: 1px;
.k-ml-1margin-left: 0.25rem;
.k-ml--1pxmargin-left: -1px;
.k-ml--1margin-left: -0.25rem;
.k-ml-xsmargin-left: 0.25rem;
.k-ml-smmargin-left: 0.5rem;
.k-ml-mdmargin-left: 0.75rem;
.k-ml-lgmargin-left: 1rem;
.k-ml-xlmargin-left: 1.5rem;
.k-ml-thinmargin-left: 0.125rem;
.k-ml-hairmargin-left: 1px;
.k-ml-automargin-left: auto;
.k-mx-0margin-inline: 0;
.k-mx-1pxmargin-inline: 1px;
.k-mx-1margin-inline: 0.25rem;
.k-mx--1pxmargin-inline: -1px;
.k-mx--1margin-inline: -0.25rem;
.k-mx-xsmargin-inline: 0.25rem;
.k-mx-smmargin-inline: 0.5rem;
.k-mx-mdmargin-inline: 0.75rem;
.k-mx-lgmargin-inline: 1rem;
.k-mx-xlmargin-inline: 1.5rem;
.k-mx-thinmargin-inline: 0.125rem;
.k-mx-hairmargin-inline: 1px;
.k-mx-automargin-inline: auto;
.k-my-0margin-block: 0;
.k-my-1pxmargin-block: 1px;
.k-my-1margin-block: 0.25rem;
.k-my--1pxmargin-block: -1px;
.k-my--1margin-block: -0.25rem;
.k-my-xsmargin-block: 0.25rem;
.k-my-smmargin-block: 0.5rem;
.k-my-mdmargin-block: 0.75rem;
.k-my-lgmargin-block: 1rem;
.k-my-xlmargin-block: 1.5rem;
.k-my-thinmargin-block: 0.125rem;
.k-my-hairmargin-block: 1px;
.k-my-automargin-block: auto;

Margin for All Sides

Use the k-m-{size} utility to set an equal margin to all four sides of an element.

Inline Margin

Use the k-mx-{size} utility to set a start and end margin of the writing direction. For the left-to-right writing direction, this must be a horizontal margin.

Block Margin

Use the k-my-{size} utility to set a start and end margin of the writing direction. For the left-to-right writing direction this must be a vertical margin.

Margin for One Side

Use the k-m{t|r|b|l}-{size} class to set a margin to the correspondent side of an element. The k-mt-{size} utility sets the top, k-mr-{size} the right, k-mb-{size} the bottom, and k-ml-{size} the left margin.

Feedback