mirror of
https://github.com/ant-design/ant-design.git
synced 2025-01-06 02:38:00 +08:00
c01c1b505b
* demo: update demo * fix: fix test * feat: table snap --------- Co-authored-by: 叶枫 <645381995@qq.com>
23 lines
494 B
TypeScript
23 lines
494 B
TypeScript
import React from 'react';
|
|
import { Flex, Grid, Tag } from 'antd';
|
|
|
|
const { useBreakpoint } = Grid;
|
|
|
|
const App: React.FC = () => {
|
|
const screens = useBreakpoint();
|
|
return (
|
|
<Flex wrap="wrap" gap="small">
|
|
Current break point:
|
|
{Object.entries(screens)
|
|
.filter((screen) => !!screen[1])
|
|
.map<React.ReactNode>((screen) => (
|
|
<Tag color="blue" key={screen[0]}>
|
|
{screen[0]}
|
|
</Tag>
|
|
))}
|
|
</Flex>
|
|
);
|
|
};
|
|
|
|
export default App;
|