Commit 9263ad13 authored by Wei Zhu's avatar Wei Zhu Committed by Tim Neutkens

Update Ant Design example (#3485)

parent 57a0fc43
...@@ -4,7 +4,7 @@ export default ({ children }) => ...@@ -4,7 +4,7 @@ export default ({ children }) =>
<Head> <Head>
<meta name='viewport' content='width=device-width, initial-scale=1' /> <meta name='viewport' content='width=device-width, initial-scale=1' />
<meta charSet='utf-8' /> <meta charSet='utf-8' />
<link rel='stylesheet' href='//cdnjs.cloudflare.com/ajax/libs/antd/2.9.3/antd.min.css' /> <link rel='stylesheet' href='https://unpkg.com/antd@3/dist/antd.min.css' />
</Head> </Head>
<style jsx global>{` <style jsx global>{`
body { body {
......
...@@ -7,7 +7,7 @@ ...@@ -7,7 +7,7 @@
"start": "next start" "start": "next start"
}, },
"dependencies": { "dependencies": {
"antd": "^2.10.2", "antd": "^3.0.2",
"babel-plugin-import": "^1.1.1", "babel-plugin-import": "^1.1.1",
"next": "latest", "next": "latest",
"react": "^16.0.0", "react": "^16.0.0",
......
import Layout from '../index.js' import Layout from '../index.js'
import { Form, Select, InputNumber, DatePicker, Switch, Slider, Button, LocaleProvider } from 'antd' import { Form, Select, InputNumber, DatePicker, Switch, Slider, Button } from 'antd'
import enUS from 'antd/lib/locale-provider/en_US'
const FormItem = Form.Item const FormItem = Form.Item
const Option = Select.Option const Option = Select.Option
export default () => ( export default () => (
<Layout> <Layout>
<LocaleProvider locale={enUS}>
<div style={{ marginTop: 100 }}> <div style={{ marginTop: 100 }}>
<Form layout='horizontal'> <Form layout='horizontal'>
<FormItem <FormItem
...@@ -68,6 +66,5 @@ export default () => ( ...@@ -68,6 +66,5 @@ export default () => (
</FormItem> </FormItem>
</Form> </Form>
</div> </div>
</LocaleProvider>
</Layout> </Layout>
) )
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment