2022-11-23 20:22:38 +08:00
|
|
|
import type { FullToken, GenerateStyle } from '../../theme/internal';
|
2023-09-04 19:59:02 +08:00
|
|
|
|
2022-10-28 16:09:38 +08:00
|
|
|
/** Component only token. Which will handle additional calculation of alias token */
|
|
|
|
export interface ComponentToken {
|
|
|
|
// Component token here
|
|
|
|
}
|
|
|
|
|
|
|
|
interface SpaceToken extends FullToken<'Space'> {
|
|
|
|
// Custom token here
|
|
|
|
}
|
|
|
|
|
2022-11-19 13:47:33 +08:00
|
|
|
const genSpaceCompactStyle: GenerateStyle<SpaceToken> = (token) => {
|
2022-10-28 16:09:38 +08:00
|
|
|
const { componentCls } = token;
|
|
|
|
|
|
|
|
return {
|
|
|
|
[componentCls]: {
|
|
|
|
'&-block': {
|
|
|
|
display: 'flex',
|
|
|
|
width: '100%',
|
|
|
|
},
|
|
|
|
'&-vertical': {
|
|
|
|
flexDirection: 'column',
|
|
|
|
},
|
|
|
|
},
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
// ============================== Export ==============================
|
|
|
|
export default genSpaceCompactStyle;
|