mirror of
https://github.com/ant-design/ant-design.git
synced 2024-11-24 19:19:57 +08:00
ba999de764
* format: site code format * Conflicting * lint * rename
20 lines
507 B
TypeScript
20 lines
507 B
TypeScript
import * as React from 'react';
|
|
import type { DirectionType } from 'antd/es/config-provider';
|
|
import type { ThemeName } from '../common/ThemeSwitch';
|
|
|
|
export interface SiteContextProps {
|
|
isMobile: boolean;
|
|
direction: DirectionType;
|
|
theme: ThemeName[];
|
|
updateSiteConfig: (props: Partial<SiteContextProps>) => void;
|
|
}
|
|
|
|
const SiteContext = React.createContext<SiteContextProps>({
|
|
isMobile: false,
|
|
direction: 'ltr',
|
|
theme: ['light'],
|
|
updateSiteConfig: () => {},
|
|
});
|
|
|
|
export default SiteContext;
|