2023-04-26 21:55:58 +08:00
---
order: 9
2023-05-04 11:31:15 +08:00
title: Migrate Less variables to Component Token
2023-04-26 21:55:58 +08:00
---
This document contains the correspondence between all the less variables related to components in version 4.x and the Component Token in version 5.x. If you are upgrading from version 4.x to version 5.x, you can quickly find the corresponding Component Token through this comparison table.
< Alert message = "Note: There are still some less variables that do not have a corresponding Component Token, and these variables have been deprecated in version 5.x." > < / Alert >
2023-05-04 11:31:15 +08:00
<!-- ## 全局变量 -->
2023-05-09 19:24:50 +08:00
## Component Token
2023-05-04 11:31:15 +08:00
<!-- ### Alert -->
<!-- ### Anchor -->
<!-- ### Avatar -->
<!-- ### Badge -->
<!-- ### BreadCrumb -->
<!-- ### Button -->
<!-- ### Calendar -->
<!-- ### Card -->
<!-- ### Carousel -->
<!-- ### Cascader -->
<!-- ### Checkbox -->
<!-- ### Collapse -->
<!-- ### Descriptions -->
<!-- ### Divider -->
2023-05-09 19:24:50 +08:00
### Drawer
2023-05-04 15:38:07 +08:00
<!-- prettier - ignore -->
| Less variables | Component Token | Note |
| --- | --- | --- |
2023-05-09 19:24:50 +08:00
| `@drawer-bg` | `colorBgElevated` | GlobalToken |
| `@drawer-header-padding` | `padding` 、`paddingLG` | GlobalToken, used as `${padding}px ${paddingLG}px` |
| `@drawer-title-font-size` | `fontSizeLG` | GlobalToken |
| `@drawer-title-line-height` | `lineHeightLG` | GlobalToken |
| `@drawer-body-padding` | `paddingLG` | GlobalToken |
| `@drawer-footer-padding-vertical` | `footerPaddingBlock` | `footerPaddingBlock` is a number without units, `@drawer-footer-padding-vertical` with units |
| `@drawer-footer-padding-horizontal` | `footerPaddingInline` | `footerPaddingInline` is a number without units, `@drawer-footer-padding-horizontal` with units |
2023-05-04 11:31:15 +08:00
<!-- ### Dropdown -->
<!-- ### Empty -->
<!-- ### Form -->
<!-- ### Image -->
<!-- ### Input -->
<!-- ### Layout -->
<!-- ### List -->
<!-- ### Mentions -->
<!-- ### Menu -->
2023-05-09 19:24:50 +08:00
### Message
2023-05-04 15:33:49 +08:00
<!-- prettier - ignore -->
| Less variables | Component Token | Note |
| --- | --- | --- |
| `@zindex-message` | `zIndexPopup` | - |
2023-05-09 19:24:50 +08:00
| `@message-notice-content-padding` | `contentPadding` | - |
| `@message-notice-content-bg` | `contentBg` | - |
2023-05-04 11:31:15 +08:00
2023-05-09 19:24:50 +08:00
### Modal
2023-04-26 21:55:58 +08:00
<!-- prettier - ignore -->
| Less variables | Component Token | Note |
| --- | --- | --- |
| `@modal-header-padding-vertical` | - | Deprecated for style change |
| `@modal-header-padding-horizontal` | - | Deprecated for style change |
| `@modal-body-padding` | - | Deprecated for style change |
2023-05-09 19:24:50 +08:00
| `@modal-header-bg` | `headerBg` | - |
2023-04-26 21:55:58 +08:00
| `@modal-header-padding` | - | Deprecated for style change |
| `@modal-header-border-width` | - | Deprecated for style change |
| `@modal-header-border-style` | - | Deprecated for style change |
2023-05-09 19:24:50 +08:00
| `@modal-header-title-line-height` | `titleLineHeight` | - |
| `@modal-header-title-font-size` | `titleFontSize` | - |
2023-04-26 21:55:58 +08:00
| `@modal-header-border-color-split` | - | Deprecated for style change |
| `@modal-header-close-size` | - | Deprecated for style change |
2023-05-09 19:24:50 +08:00
| `@modal-content-bg` | `contentBg` | - |
| `@modal-heading-color` | `titleColor` | - |
| `@modal-close-color` | `colorIcon` | GlobalToken |
| `@modal-footer-bg` | `footerBg` | - |
2023-04-26 21:55:58 +08:00
| `@modal-footer-border-color-split` | - | Deprecated for style change |
| `@modal-footer-border-style` | - | Deprecated for style change |
| `@modal-footer-padding-vertical` | - | Deprecated for style change |
| `@modal-footer-padding-horizontal` | - | Deprecated for style change |
| `@modal-footer-border-width` | - | Deprecated for style change |
2023-05-09 19:24:50 +08:00
| `@modal-mask-bg` | `colorBgMask` | GlobalToken |
2023-04-26 21:55:58 +08:00
| `@modal-confirm-body-padding` | - | Deprecated for style change |
2023-05-09 19:24:50 +08:00
| `@modal-confirm-title-font-size` | `titleFontSize` | - |
| `@modal-border-radius` | `borderRadiusLG` | GlobalToken |
2023-05-04 15:33:16 +08:00
2023-05-09 19:24:50 +08:00
<!-- ### Notification -->
2023-05-04 11:31:15 +08:00
<!-- ### Pagination -->
<!-- ### Popover -->
<!-- ### Progress -->
<!-- ### Radio -->
<!-- ### Rate -->
2023-05-09 19:24:50 +08:00
### Result
2023-05-04 16:29:50 +08:00
<!-- prettier - ignore -->
| Less variables | Component Token | Note |
| --- | --- | --- |
2023-05-09 19:24:50 +08:00
| `@result-icon-font-size` | `iconFontSize` | - |
| `@result-title-font-size` | `titleFontSize` | - |
| `@result-subtitle-font-size` | `subtitleFontSize` | - |
| `@result-extra-margin` | `extraMargin` | - |
2023-05-04 11:31:15 +08:00
<!-- ### Segment -->
<!-- ### Select -->
<!-- ### Skeleton -->
<!-- ### Slider -->
2023-05-09 19:24:50 +08:00
### Statistic
2023-05-04 15:37:10 +08:00
<!-- prettier - ignore -->
| Less variables | Component Token | Note |
| --- | --- | --- |
2023-05-09 19:24:50 +08:00
| `@statistic-title-font-size` | `titleFontSize` | - |
| `@statistic-content-font-size` | `contentFontSize` | - |
| `@statistic-font-family` | `fontFamily` | GlobalToken |
2023-05-04 11:31:15 +08:00
2023-05-09 19:24:50 +08:00
### Step
2023-05-04 02:09:57 +08:00
<!-- prettier - ignore -->
2023-05-04 15:33:16 +08:00
| Less variables | Component Token | Note |
2023-05-04 02:09:57 +08:00
| --- | --- | --- |
2023-05-09 19:24:50 +08:00
| `@process-tail-color` | `colorSplit` | GlobalToken |
| `@steps-nav-arrow-color` | `navArrowColor` | - |
| `@steps-background` | `colorBgContainer` | - |
| `@steps-icon-size` | `iconSize` | - |
| `@steps-icon-custom-size` | `customIconSize` | - |
| `@steps-icon-custom-top` | `customIconTop` | - |
| `@steps-icon-custom-font-size` | `customIconFontSize` | - |
| `@steps-icon-top` | `iconTop` | - |
| `@steps-icon-font-size` | `iconFontSize` | - |
| `@steps-icon-margin` | - | Deprecated |
| `@steps-title-line-height` | `titleLineHeight` | - |
| `@steps-small-icon-size` | `iconSizeSM` | - |
| `@steps-small-icon-margin` | - | Deprecated |
| `@steps-dot-size` | `dotSize` | - |
| `@steps-dot-top` | - | Deprecated |
| `@steps-current-dot-size` | `dotCurrentSize` | - |
| `@steps-description-max-width` | `descriptionMaxWidth` | - |
| `@steps-nav-content-max-width` | `stepsNavContentMaxWidth` | - |
| `@steps-vertical-icon-width` | `iconSize` | - |
| `@steps-vertical-tail-width` | - | Deprecated |
| `@steps-vertical-tail-width-sm` | - | Deprecated |
2023-05-04 11:31:15 +08:00
<!-- ### Switch -->
<!-- ### Table -->
<!-- ### Tabs -->
<!-- ### Tag -->
<!-- ### Timeline -->
<!-- ### TimePicker -->
<!-- ### Tooltip -->
<!-- ### Transfer -->
<!-- ### Tree -->
<!-- ### Typography -->
<!-- ### Upload -->