first commit
This commit is contained in:
5
frontend/node_modules/antd/es/empty/style/index.d.ts
generated
vendored
Normal file
5
frontend/node_modules/antd/es/empty/style/index.d.ts
generated
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
/** Component only token. Which will handle additional calculation of alias token */
|
||||
export interface ComponentToken {
|
||||
}
|
||||
declare const _default: (prefixCls: string, rootCls?: string) => readonly [(node: React.ReactElement) => React.ReactElement, string, string];
|
||||
export default _default;
|
||||
73
frontend/node_modules/antd/es/empty/style/index.js
generated
vendored
Normal file
73
frontend/node_modules/antd/es/empty/style/index.js
generated
vendored
Normal file
@@ -0,0 +1,73 @@
|
||||
import { genStyleHooks, mergeToken } from '../../theme/internal';
|
||||
// ============================== Shared ==============================
|
||||
const genSharedEmptyStyle = token => {
|
||||
const {
|
||||
componentCls,
|
||||
margin,
|
||||
marginXS,
|
||||
marginXL,
|
||||
fontSize,
|
||||
lineHeight
|
||||
} = token;
|
||||
return {
|
||||
[componentCls]: {
|
||||
marginInline: marginXS,
|
||||
fontSize,
|
||||
lineHeight,
|
||||
textAlign: 'center',
|
||||
// 原来 &-image 没有父子结构,现在为了外层承担我们的 hashId,改成父子结构
|
||||
[`${componentCls}-image`]: {
|
||||
height: token.emptyImgHeight,
|
||||
marginBottom: marginXS,
|
||||
opacity: token.opacityImage,
|
||||
img: {
|
||||
height: '100%'
|
||||
},
|
||||
svg: {
|
||||
maxWidth: '100%',
|
||||
height: '100%',
|
||||
margin: 'auto'
|
||||
}
|
||||
},
|
||||
[`${componentCls}-description`]: {
|
||||
color: token.colorTextDescription
|
||||
},
|
||||
// 原来 &-footer 没有父子结构,现在为了外层承担我们的 hashId,改成父子结构
|
||||
[`${componentCls}-footer`]: {
|
||||
marginTop: margin
|
||||
},
|
||||
'&-normal': {
|
||||
marginBlock: marginXL,
|
||||
color: token.colorTextDescription,
|
||||
[`${componentCls}-description`]: {
|
||||
color: token.colorTextDescription
|
||||
},
|
||||
[`${componentCls}-image`]: {
|
||||
height: token.emptyImgHeightMD
|
||||
}
|
||||
},
|
||||
'&-small': {
|
||||
marginBlock: marginXS,
|
||||
color: token.colorTextDescription,
|
||||
[`${componentCls}-image`]: {
|
||||
height: token.emptyImgHeightSM
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
};
|
||||
// ============================== Export ==============================
|
||||
export default genStyleHooks('Empty', token => {
|
||||
const {
|
||||
componentCls,
|
||||
controlHeightLG,
|
||||
calc
|
||||
} = token;
|
||||
const emptyToken = mergeToken(token, {
|
||||
emptyImgCls: `${componentCls}-img`,
|
||||
emptyImgHeight: calc(controlHeightLG).mul(2.5).equal(),
|
||||
emptyImgHeightMD: controlHeightLG,
|
||||
emptyImgHeightSM: calc(controlHeightLG).mul(0.875).equal()
|
||||
});
|
||||
return genSharedEmptyStyle(emptyToken);
|
||||
});
|
||||
Reference in New Issue
Block a user