doc: update
parent
25b1e5a473
commit
3f01f1430c
|
@ -15,7 +15,7 @@ module.exports = {
|
|||
plugins: ['markdown', 'jest', '@typescript-eslint'],
|
||||
overrides: [
|
||||
{
|
||||
files: ['**/demo/*.md'],
|
||||
files: ['*.md'],
|
||||
processor: 'markdown/markdown',
|
||||
rules: {
|
||||
'no-console': 'off',
|
||||
|
|
|
@ -75,3 +75,5 @@ site/dev.js
|
|||
vetur/
|
||||
|
||||
report.html
|
||||
|
||||
site/src/router/demoRoutes.js
|
||||
|
|
|
@ -552,6 +552,7 @@ Involving changes:
|
|||
|
||||
```js
|
||||
// v1
|
||||
// eslint-disable-next-line no-undef,no-unused-vars
|
||||
validateFields((err, value) => {
|
||||
if (!err) {
|
||||
// Do something with value
|
||||
|
@ -563,6 +564,7 @@ Change to
|
|||
|
||||
```js
|
||||
// v2
|
||||
// eslint-disable-next-line no-undef,no-unused-vars
|
||||
validateFields().then(values => {
|
||||
// Do something with value
|
||||
});
|
||||
|
|
|
@ -555,6 +555,7 @@ export default {
|
|||
|
||||
```js
|
||||
// v1
|
||||
// eslint-disable-next-line no-undef,no-unused-vars
|
||||
validateFields((err, value) => {
|
||||
if (!err) {
|
||||
// Do something with value
|
||||
|
@ -566,6 +567,7 @@ validateFields((err, value) => {
|
|||
|
||||
```js
|
||||
// v2
|
||||
// eslint-disable-next-line no-undef,no-unused-vars
|
||||
validateFields().then(values => {
|
||||
// Do something with value
|
||||
});
|
||||
|
|
|
@ -28,8 +28,9 @@
|
|||
"vetur"
|
||||
],
|
||||
"scripts": {
|
||||
"debugger": "vite serve examples",
|
||||
"dev": "yarn routes && vite serve site",
|
||||
"predev": "node node_modules/esbuild/install.js",
|
||||
"debugger": "yarn predev && vite serve examples",
|
||||
"dev": "yarn predev && yarn routes && vite serve site",
|
||||
"test": "cross-env NODE_ENV=test WORKFLOW=true jest --config .jest.js",
|
||||
"test:dev": "cross-env NODE_ENV=test jest --config .jest.js",
|
||||
"compile": "node antd-tools/cli/run.js compile",
|
||||
|
|
|
@ -73,6 +73,7 @@ export const createMarkdownRenderer = (options: MarkdownOptions = {}): MarkdownR
|
|||
permalinkBefore: true,
|
||||
permalinkSymbol: '#',
|
||||
permalinkAttrs: () => ({ 'aria-hidden': true }),
|
||||
tabIndex: false,
|
||||
...options.anchor,
|
||||
})
|
||||
.use(toc, {
|
||||
|
|
|
@ -85,7 +85,7 @@ import type { GlobalConfig } from '../App.vue';
|
|||
import { GLOBAL_CONFIG } from '../SymbolKey';
|
||||
import { computed, defineComponent, inject, onMounted, ref } from 'vue';
|
||||
import { CheckOutlined, SnippetsOutlined } from '@ant-design/icons-vue';
|
||||
import { Modal } from 'ant-design-vue';
|
||||
// import { Modal } from 'ant-design-vue';
|
||||
export default defineComponent({
|
||||
name: 'DemoBox',
|
||||
components: {
|
||||
|
@ -117,11 +117,11 @@ export default defineComponent({
|
|||
props.jsfiddle?.title[globalConfig.isZhCN.value ? 'zh-CN' : 'en-US'],
|
||||
);
|
||||
const warning = () => {
|
||||
Modal.warning({
|
||||
content: globalConfig.isZhCN
|
||||
? '我们检测到你可能使用了 AdBlock 或 Adblock Plus,它会影响到复制、展开代码等功能。 你可以将 Ant Design Vue 加入白名单,以便我们更好地提供服务。'
|
||||
: 'We have detected that you may have used AdBlock or Adblock Plus, which will affect functions such as copying and expanding code. You can add Ant Design Vue to the whitelist so that we can provide better services.',
|
||||
});
|
||||
// Modal.warning({
|
||||
// content: globalConfig.isZhCN
|
||||
// ? '我们检测到你可能使用了 AdBlock 或 Adblock Plus,它会影响到复制、展开代码等功能。 你可以将 Ant Design Vue 加入白名单,以便我们更好地提供服务。'
|
||||
// : 'We have detected that you may have used AdBlock or Adblock Plus, which will affect functions such as copying and expanding code. You can add Ant Design Vue to the whitelist so that we can provide better services.',
|
||||
// });
|
||||
};
|
||||
const iframeDemoKey = computed(() => {
|
||||
return (
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
<template>
|
||||
<article>
|
||||
hello
|
||||
<section class="markdown">
|
||||
<h1>
|
||||
{{ frontmatter.title }}
|
||||
|
|
|
@ -12,9 +12,9 @@ export default [
|
|||
component: () => import('../../../components/alert/demo/index.vue'),
|
||||
},
|
||||
{
|
||||
path: 'anchor:lang(-cn)?',
|
||||
meta: {"category":"Components","type":"其他","cols":2,"title":"Anchor","cover":"https://gw.alipayobjects.com/zos/alicdn/_1-C1JwsC/Anchor.svg","subtitle":"锚点"},
|
||||
component: () => import('../../../components/anchor/demo/index.vue'),
|
||||
path: 'auto-complete:lang(-cn)?',
|
||||
meta: {"category":"Components","type":"数据录入","cols":2,"title":"AutoComplete","cover":"https://gw.alipayobjects.com/zos/alicdn/qtJm4yt45/AutoComplete.svg","subtitle":"自动完成"},
|
||||
component: () => import('../../../components/auto-complete/demo/index.vue'),
|
||||
},
|
||||
{
|
||||
path: 'avatar:lang(-cn)?',
|
||||
|
@ -22,9 +22,9 @@ export default [
|
|||
component: () => import('../../../components/avatar/demo/index.vue'),
|
||||
},
|
||||
{
|
||||
path: 'auto-complete:lang(-cn)?',
|
||||
meta: {"category":"Components","type":"数据录入","cols":2,"title":"AutoComplete","cover":"https://gw.alipayobjects.com/zos/alicdn/qtJm4yt45/AutoComplete.svg","subtitle":"自动完成"},
|
||||
component: () => import('../../../components/auto-complete/demo/index.vue'),
|
||||
path: 'back-top:lang(-cn)?',
|
||||
meta: {"category":"Components","type":"其他","title":"BackTop","cover":"https://gw.alipayobjects.com/zos/alicdn/tJZ5jbTwX/BackTop.svg","subtitle":"回到顶部"},
|
||||
component: () => import('../../../components/back-top/demo/index.vue'),
|
||||
},
|
||||
{
|
||||
path: 'badge:lang(-cn)?',
|
||||
|
@ -32,9 +32,9 @@ export default [
|
|||
component: () => import('../../../components/badge/demo/index.vue'),
|
||||
},
|
||||
{
|
||||
path: 'back-top:lang(-cn)?',
|
||||
meta: {"category":"Components","type":"其他","title":"BackTop","cover":"https://gw.alipayobjects.com/zos/alicdn/tJZ5jbTwX/BackTop.svg","subtitle":"回到顶部"},
|
||||
component: () => import('../../../components/back-top/demo/index.vue'),
|
||||
path: 'breadcrumb:lang(-cn)?',
|
||||
meta: {"category":"Components","type":"导航","title":"Breadcrumb","cover":"https://gw.alipayobjects.com/zos/alicdn/9Ltop8JwH/Breadcrumb.svg","subtitle":"面包屑"},
|
||||
component: () => import('../../../components/breadcrumb/demo/index.vue'),
|
||||
},
|
||||
{
|
||||
path: 'button:lang(-cn)?',
|
||||
|
@ -42,9 +42,9 @@ export default [
|
|||
component: () => import('../../../components/button/demo/index.vue'),
|
||||
},
|
||||
{
|
||||
path: 'breadcrumb:lang(-cn)?',
|
||||
meta: {"category":"Components","type":"导航","title":"Breadcrumb","cover":"https://gw.alipayobjects.com/zos/alicdn/9Ltop8JwH/Breadcrumb.svg","subtitle":"面包屑"},
|
||||
component: () => import('../../../components/breadcrumb/demo/index.vue'),
|
||||
path: 'anchor:lang(-cn)?',
|
||||
meta: {"category":"Components","type":"其他","cols":2,"title":"Anchor","cover":"https://gw.alipayobjects.com/zos/alicdn/_1-C1JwsC/Anchor.svg","subtitle":"锚点"},
|
||||
component: () => import('../../../components/anchor/demo/index.vue'),
|
||||
},
|
||||
{
|
||||
path: 'calendar:lang(-cn)?',
|
||||
|
|
Loading…
Reference in New Issue