mirror of
https://github.com/ant-design/ant-design.git
synced 2026-02-09 02:49:18 +08:00
* docs(replace): replace sandpack demos with code blocks in customize-theme.en-US.md Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * docs: update demo paths in theme customization docs * docs: add first example demo and update documentation * docs(demo): add Radio component to disable-motion example Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * fix(demo): initialize timerRef with null for proper typing Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
49 lines
1.1 KiB
TypeScript
49 lines
1.1 KiB
TypeScript
import React from 'react';
|
|
import { Button, ConfigProvider, Divider, Input, Space } from 'antd';
|
|
|
|
const App: React.FC = () => (
|
|
<>
|
|
<ConfigProvider
|
|
theme={{
|
|
components: {
|
|
Button: {
|
|
colorPrimary: '#00b96b',
|
|
algorithm: true, // Enable algorithm
|
|
},
|
|
Input: {
|
|
colorPrimary: '#eb2f96',
|
|
algorithm: true, // Enable algorithm
|
|
},
|
|
},
|
|
}}
|
|
>
|
|
<Space>
|
|
<div style={{ fontSize: 14 }}>Algorithm Enabled:</div>
|
|
<Input placeholder="Please Input" />
|
|
<Button type="primary">Submit</Button>
|
|
</Space>
|
|
</ConfigProvider>
|
|
<Divider />
|
|
<ConfigProvider
|
|
theme={{
|
|
components: {
|
|
Button: {
|
|
colorPrimary: '#00b96b',
|
|
},
|
|
Input: {
|
|
colorPrimary: '#eb2f96',
|
|
},
|
|
},
|
|
}}
|
|
>
|
|
<Space>
|
|
<div style={{ fontSize: 14 }}>Algorithm Disabled:</div>
|
|
<Input placeholder="Please Input" />
|
|
<Button type="primary">Submit</Button>
|
|
</Space>
|
|
</ConfigProvider>
|
|
</>
|
|
);
|
|
|
|
export default App;
|