mirror of
https://github.com/ant-design/ant-design.git
synced 2024-12-03 00:09:39 +08:00
de555912c9
* feat: anchor ink ball style * chore: code clean * chore: code clean * chore: code clean * chore: update snapshot * chore: change cover
22 lines
574 B
TypeScript
22 lines
574 B
TypeScript
import React from 'react';
|
|
import { Anchor } from 'antd';
|
|
|
|
const { Link } = Anchor;
|
|
|
|
const onChange = (link: string) => {
|
|
console.log('Anchor:OnChange', link);
|
|
};
|
|
|
|
const App: React.FC = () => (
|
|
<Anchor affix={false} onChange={onChange}>
|
|
<Link href="#components-anchor-demo-basic" title="Basic demo" />
|
|
<Link href="#components-anchor-demo-static" title="Static demo" />
|
|
<Link href="#api" title="API">
|
|
<Link href="#anchor-props" title="Anchor Props" />
|
|
<Link href="#link-props" title="Link Props" />
|
|
</Link>
|
|
</Anchor>
|
|
);
|
|
|
|
export default App;
|