refactor(theme): migrate and refactor type OverrideToken by @ant-design/cssinjs-utils

This commit is contained in:
🏎️ Yumo 2024-07-23 16:53:24 +08:00
parent 64f26bd970
commit c057cb2113
2 changed files with 4 additions and 6 deletions

View File

@ -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>;

View File

@ -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';