feat: update form demo

pull/165/head
tjz 7 years ago
parent 787d51f375
commit 37c0ab2a1a

@ -1,6 +1,6 @@
<script> <script>
import AdvancedSearch from './advanced-search' // import AdvancedSearch from './advanced-search'
// import Coordinated from './coordinated' // import Coordinated from './coordinated'
// import CustomizedFormControls from './customized-form-controls' // import CustomizedFormControls from './customized-form-controls'
// import DynamicFormItem from './dynamic-form-item' // import DynamicFormItem from './dynamic-form-item'
@ -15,6 +15,8 @@ import AdvancedSearch from './advanced-search'
// import ValidateOther from './validate-other' // import ValidateOther from './validate-other'
// import ValidateStatic from './validate-static' // import ValidateStatic from './validate-static'
// import WithoutFormCreate from './without-form-create' // import WithoutFormCreate from './without-form-create'
import Test from './test'
import TestString from '!raw-loader!./test'
import CN from './../index.zh-CN' import CN from './../index.zh-CN'
import US from './../index.en-US' import US from './../index.en-US'
@ -68,11 +70,13 @@ export default {
cols: 1, cols: 1,
title: 'Form', title: 'Form',
render () { render () {
console.log(TestString)
return ( return (
<div> <div>
<md cn={md.cn} us={md.us} /> <md cn={md.cn} us={md.us} />
<AdvancedSearch /> <Test />
{/* <Coordinated /> {/* <AdvancedSearch />
<Coordinated />
<CustomizedFormControls /> <CustomizedFormControls />
<DynamicFormItem /> <DynamicFormItem />
<DynamicRule /> <DynamicRule />

6
package-lock.json generated

@ -13313,6 +13313,12 @@
} }
} }
}, },
"raw-loader": {
"version": "1.0.0-beta.0",
"resolved": "http://registry.npm.taobao.org/raw-loader/download/raw-loader-1.0.0-beta.0.tgz",
"integrity": "sha1-YXhTzoMU0RZsBnWNkwLST68I1Ew=",
"dev": true
},
"read-file-stdin": { "read-file-stdin": {
"version": "0.2.1", "version": "0.2.1",
"resolved": "https://registry.npmjs.org/read-file-stdin/-/read-file-stdin-0.2.1.tgz", "resolved": "https://registry.npmjs.org/read-file-stdin/-/read-file-stdin-0.2.1.tgz",

@ -119,6 +119,7 @@
"postcss-loader": "^2.1.2", "postcss-loader": "^2.1.2",
"pre-commit": "^1.2.2", "pre-commit": "^1.2.2",
"querystring": "^0.2.0", "querystring": "^0.2.0",
"raw-loader": "^1.0.0-beta.0",
"reqwest": "^2.0.5", "reqwest": "^2.0.5",
"rimraf": "^2.6.2", "rimraf": "^2.6.2",
"rucksack-css": "^1.0.2", "rucksack-css": "^1.0.2",

@ -1,76 +1,76 @@
import Layout from './components/layout.vue' // import Layout from './components/layout.vue'
import Iframe from './components/iframe.vue' // import Iframe from './components/iframe.vue'
const AsyncTestComp = () => { const AsyncTestComp = () => {
const d = window.location.hash.replace('#', '') const d = window.location.hash.replace('#', '')
return { return {
component: import(`../components/form/demo/test.vue`), component: import(`../components/form/demo/index.vue`),
} }
} }
export default [ export default [
{ path: '/ant-design/components/:name/', component: Layout, props: true }, // { path: '/ant-design/components/:name/', component: Layout, props: true },
{ path: '/ant-design/iframe/:name/', component: Iframe, props: true }, // { path: '/ant-design/iframe/:name/', component: Iframe, props: true },
{ // {
path: '/ant-design', // path: '/ant-design',
component: Layout, // component: Layout,
props: (route) => { // props: (route) => {
const name = route.path.split('/docs/vue/')[1].split('/')[0] // const name = route.path.split('/docs/vue/')[1].split('/')[0]
return { name } // return { name }
}, // },
children: [ // children: [
{ // {
path: 'docs/vue/customize-theme', // path: 'docs/vue/customize-theme',
component: () => import('../docs/vue/customize-theme.en-US.md'), // component: () => import('../docs/vue/customize-theme.en-US.md'),
}, // },
{ // {
path: 'docs/vue/customize-theme-cn', // path: 'docs/vue/customize-theme-cn',
component: () => import('../docs/vue/customize-theme.zh-CN.md'), // component: () => import('../docs/vue/customize-theme.zh-CN.md'),
}, // },
{ // {
path: 'docs/vue/getting-started', // path: 'docs/vue/getting-started',
component: () => import('../docs/vue/getting-started.en-US.md'), // component: () => import('../docs/vue/getting-started.en-US.md'),
}, // },
{ // {
path: 'docs/vue/getting-started-cn', // path: 'docs/vue/getting-started-cn',
component: () => import('../docs/vue/getting-started.zh-CN.md'), // component: () => import('../docs/vue/getting-started.zh-CN.md'),
}, // },
{ // {
path: 'docs/vue/i18n', // path: 'docs/vue/i18n',
component: () => import('../docs/vue/i18n.en-US.md'), // component: () => import('../docs/vue/i18n.en-US.md'),
}, // },
{ // {
path: 'docs/vue/i18n-cn', // path: 'docs/vue/i18n-cn',
component: () => import('../docs/vue/i18n.zh-CN.md'), // component: () => import('../docs/vue/i18n.zh-CN.md'),
}, // },
{ // {
path: 'docs/vue/introduce', // path: 'docs/vue/introduce',
component: () => import('../docs/vue/introduce.en-US.md'), // component: () => import('../docs/vue/introduce.en-US.md'),
}, // },
{ // {
path: 'docs/vue/introduce-cn', // path: 'docs/vue/introduce-cn',
component: () => import('../docs/vue/introduce.zh-CN.md'), // component: () => import('../docs/vue/introduce.zh-CN.md'),
}, // },
{ // {
path: 'docs/vue/use-with-vue-cli', // path: 'docs/vue/use-with-vue-cli',
component: () => import('../docs/vue/use-with-vue-cli.en-US.md'), // component: () => import('../docs/vue/use-with-vue-cli.en-US.md'),
}, // },
{ // {
path: 'docs/vue/use-with-vue-cli-cn', // path: 'docs/vue/use-with-vue-cli-cn',
component: () => import('../docs/vue/use-with-vue-cli.zh-CN.md'), // component: () => import('../docs/vue/use-with-vue-cli.zh-CN.md'),
}, // },
{ // {
path: 'docs/vue/changelog', // path: 'docs/vue/changelog',
component: () => import('../CHANGELOG.en-US.md'), // component: () => import('../CHANGELOG.en-US.md'),
}, // },
{ // {
path: 'docs/vue/changelog-cn', // path: 'docs/vue/changelog-cn',
component: () => import('../CHANGELOG.zh-CN.md'), // component: () => import('../CHANGELOG.zh-CN.md'),
}, // },
{ path: '', redirect: '/ant-design/vue/docs/introduce/' }, // { path: '', redirect: '/ant-design/vue/docs/introduce/' },
], // ],
}, // },
{ path: '/:prefix?/test/:demo?/', component: AsyncTestComp }, { path: '/:prefix?/test/:demo?/', component: AsyncTestComp },
{ path: '/*', redirect: '/ant-design/docs/vue/introduce/' }, // { path: '/*', redirect: '/ant-design/docs/vue/introduce/' },
] ]

Loading…
Cancel
Save