mirror of
https://github.com/ant-design/ant-design.git
synced 2024-11-24 02:59:58 +08:00
refactor(theme): migrate and refactor type OverrideToken
by @ant-design/cssinjs-utils
This commit is contained in:
parent
64f26bd970
commit
c057cb2113
@ -1,5 +1,6 @@
|
||||
import type {
|
||||
GlobalToken as GlobalTokenTypeUtil,
|
||||
OverrideTokenMap as OverrideTokenTypeUtil,
|
||||
} from '@ant-design/cssinjs-utils';
|
||||
|
||||
import type { AliasToken } from './alias';
|
||||
@ -8,3 +9,5 @@ import type { ComponentTokenMap } from './components';
|
||||
|
||||
/** Final token which contains the components level override */
|
||||
export type GlobalToken = GlobalTokenTypeUtil<ComponentTokenMap, AliasToken>;
|
||||
|
||||
export type OverrideToken = OverrideTokenTypeUtil<ComponentTokenMap, AliasToken>;
|
||||
|
@ -2,17 +2,12 @@ import type { CSSInterpolation, DerivativeFunc } from '@ant-design/cssinjs';
|
||||
|
||||
import type { AnyObject } from '../../_util/type';
|
||||
import type { AliasToken } from './alias';
|
||||
import type { ComponentTokenMap } from './components';
|
||||
import type { MapToken } from './maps';
|
||||
import type { SeedToken } from './seeds';
|
||||
|
||||
export type MappingAlgorithm = DerivativeFunc<SeedToken, MapToken>;
|
||||
|
||||
export type OverrideToken = {
|
||||
[key in keyof ComponentTokenMap]: Partial<ComponentTokenMap[key]> & Partial<AliasToken>;
|
||||
};
|
||||
|
||||
export type { GlobalToken } from './cssinjs-utils';
|
||||
export type { GlobalToken, OverrideToken } from './cssinjs-utils';
|
||||
|
||||
export type { AliasToken } from './alias';
|
||||
export type { ComponentTokenMap } from './components';
|
||||
|
Loading…
Reference in New Issue
Block a user