初始化项目

This commit is contained in:
zhengw
2023-04-04 10:56:33 +08:00
commit f639dc8284
81 changed files with 24339 additions and 0 deletions

View File

@@ -0,0 +1,23 @@
import { Dropdown } from 'antd';
import type { DropDownProps } from 'antd/es/dropdown';
import React from 'react';
import { useEmotionCss } from '@ant-design/use-emotion-css';
import classNames from 'classnames';
export type HeaderDropdownProps = {
overlayClassName?: string;
placement?: 'bottomLeft' | 'bottomRight' | 'topLeft' | 'topCenter' | 'topRight' | 'bottomCenter';
} & Omit<DropDownProps, 'overlay'>;
const HeaderDropdown: React.FC<HeaderDropdownProps> = ({ overlayClassName: cls, ...restProps }) => {
const className = useEmotionCss(({ token }) => {
return {
[`@media screen and (max-width: ${token.screenXS})`]: {
width: '100%',
},
};
});
return <Dropdown overlayClassName={classNames(className, cls)} {...restProps} />;
};
export default HeaderDropdown;