style: format scripts
parent
547a55b722
commit
b1ae997ee8
|
@ -13,6 +13,7 @@ try {
|
||||||
outputDir: path.resolve(rootPath, './vetur'),
|
outputDir: path.resolve(rootPath, './vetur'),
|
||||||
tagPrefix: 'a-',
|
tagPrefix: 'a-',
|
||||||
});
|
});
|
||||||
|
// eslint-disable-next-line no-console
|
||||||
console.log('generator types success');
|
console.log('generator types success');
|
||||||
} catch (e) {
|
} catch (e) {
|
||||||
console.error('generator types error', e);
|
console.error('generator types error', e);
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
/* eslint-disable no-continue */
|
import type { Articals } from './parser';
|
||||||
import { Artical, Articals } from './parser';
|
|
||||||
import { formatType, removeVersion, toKebabCase } from './utils';
|
import { formatType, removeVersion, toKebabCase } from './utils';
|
||||||
import { VueTag } from './type';
|
import type { VueTag } from './type';
|
||||||
|
|
||||||
function getComponentName(name: string, tagPrefix: string) {
|
function getComponentName(name: string, tagPrefix: string) {
|
||||||
if (name) {
|
if (name) {
|
||||||
|
@ -35,7 +34,7 @@ function parserProps(tag: VueTag, line: any) {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
export function formatter(articals: Articals, componentName: string, tagPrefix: string = '') {
|
export function formatter(articals: Articals, componentName: string, tagPrefix = '') {
|
||||||
if (!articals.length) {
|
if (!articals.length) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
import glob from 'fast-glob';
|
import glob from 'fast-glob';
|
||||||
import { join, dirname, basename } from 'path';
|
import { join, dirname } from 'path';
|
||||||
import { mdParser } from './parser';
|
import { mdParser } from './parser';
|
||||||
import { formatter } from './formatter';
|
import { formatter } from './formatter';
|
||||||
import { genWebTypes } from './web-types';
|
import { genWebTypes } from './web-types';
|
||||||
import { readFileSync, outputFileSync } from 'fs-extra';
|
import { readFileSync, outputFileSync } from 'fs-extra';
|
||||||
import { Options, VueTag } from './type';
|
import type { Options, VueTag } from './type';
|
||||||
import { normalizePath, getComponentName } from './utils';
|
import { normalizePath, getComponentName } from './utils';
|
||||||
import { genVeturTags, genVeturAttributes } from './vetur';
|
import { genVeturTags, genVeturAttributes } from './vetur';
|
||||||
|
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { PathLike } from 'fs';
|
import type { PathLike } from 'fs';
|
||||||
|
|
||||||
export type VueSlot = {
|
export type VueSlot = {
|
||||||
name: string;
|
name: string;
|
||||||
|
|
|
@ -18,7 +18,7 @@ export function formatType(type: string) {
|
||||||
}
|
}
|
||||||
|
|
||||||
export function getComponentName(name: string) {
|
export function getComponentName(name: string) {
|
||||||
let title = name
|
const title = name
|
||||||
.split('-')
|
.split('-')
|
||||||
.map(it => it.substring(0, 1) + it.substring(1))
|
.map(it => it.substring(0, 1) + it.substring(1))
|
||||||
.join('');
|
.join('');
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { VueTag, VeturTags, VeturAttributes } from './type';
|
import type { VueTag, VeturTags, VeturAttributes } from './type';
|
||||||
|
|
||||||
export function genVeturTags(tags: VueTag[]) {
|
export function genVeturTags(tags: VueTag[]) {
|
||||||
const veturTags: VeturTags = {};
|
const veturTags: VeturTags = {};
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { VueTag, Options } from './type';
|
import type { VueTag, Options } from './type';
|
||||||
|
|
||||||
// create web-types.json to provide autocomplete in JetBrains IDEs
|
// create web-types.json to provide autocomplete in JetBrains IDEs
|
||||||
export function genWebTypes(tags: VueTag[], options: Options) {
|
export function genWebTypes(tags: VueTag[], options: Options) {
|
||||||
|
|
10
package.json
10
package.json
|
@ -42,12 +42,16 @@
|
||||||
"prettier": "prettier -c --write '**/*'",
|
"prettier": "prettier -c --write '**/*'",
|
||||||
"pretty-quick": "pretty-quick",
|
"pretty-quick": "pretty-quick",
|
||||||
"dist": "node --max_old_space_size=8192 antd-tools/cli/run.js dist",
|
"dist": "node --max_old_space_size=8192 antd-tools/cli/run.js dist",
|
||||||
"lint": "eslint -c ./.eslintrc.js --fix --ext .jsx,.js,.ts,.tsx ./components",
|
"lint": "npm run tsc && npm run lint:demo && npm run lint:md && npm run lint:script && npm run lint:site",
|
||||||
"lint:demo": "eslint -c ./.eslintrc.js --fix --ext .vue ./components",
|
"lint:components": "eslint --fix --ext .jsx,.js,.ts,.tsx ./components",
|
||||||
|
"lint:demo": "eslint --fix components/*/demo/*.vue",
|
||||||
|
"lint:md": "eslint --fix *.md",
|
||||||
|
"lint:script": "eslint . --ext '.js,.jsx,.ts,.tsx'",
|
||||||
"lint:site": "eslint -c ./.eslintrc.js --fix --ext .jsx,.js,.ts,.tsx,vue ./site",
|
"lint:site": "eslint -c ./.eslintrc.js --fix --ext .jsx,.js,.ts,.tsx,vue ./site",
|
||||||
"lint:style": "stylelint \"{site,components}/**/*.less\" --syntax less",
|
"lint:style": "stylelint \"{site,components}/**/*.less\" --syntax less",
|
||||||
"codecov": "codecov",
|
"codecov": "codecov",
|
||||||
"routes": "node site/scripts/genrateRoutes.js"
|
"routes": "node site/scripts/genrateRoutes.js",
|
||||||
|
"tsc": "tsc --noEmit"
|
||||||
},
|
},
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
|
|
|
@ -4,7 +4,7 @@ import { deeplyParseHeader } from '../../utils/parseHeader';
|
||||||
import { slugify } from './slugify';
|
import { slugify } from './slugify';
|
||||||
|
|
||||||
export const extractHeaderPlugin = (md: MarkdownIt, include = ['h2', 'h3']) => {
|
export const extractHeaderPlugin = (md: MarkdownIt, include = ['h2', 'h3']) => {
|
||||||
md.renderer.rules.heading_open = (tokens, i, options, env, self) => {
|
md.renderer.rules.heading_open = (tokens, i, options, _env, self) => {
|
||||||
const token = tokens[i];
|
const token = tokens[i];
|
||||||
if (include.includes(token.tag)) {
|
if (include.includes(token.tag)) {
|
||||||
const title = tokens[i + 1].content;
|
const title = tokens[i + 1].content;
|
||||||
|
|
|
@ -28,7 +28,7 @@ export const highlightLinePlugin = (md: MarkdownIt) => {
|
||||||
const rawCode = code.replace(wrapperRE, '');
|
const rawCode = code.replace(wrapperRE, '');
|
||||||
const highlightLinesCode = rawCode
|
const highlightLinesCode = rawCode
|
||||||
.split('\n')
|
.split('\n')
|
||||||
.map((split, index) => {
|
.map((_split, index) => {
|
||||||
const lineNumber = index + 1;
|
const lineNumber = index + 1;
|
||||||
const inRange = lineNumbers.some(([start, end]) => {
|
const inRange = lineNumbers.some(([start, end]) => {
|
||||||
if (start && end) {
|
if (start && end) {
|
||||||
|
|
|
@ -11,7 +11,7 @@ export const lineNumberPlugin = (md: MarkdownIt) => {
|
||||||
|
|
||||||
const lines = code.split('\n');
|
const lines = code.split('\n');
|
||||||
const lineNumbersCode = [...Array(lines.length - 1)]
|
const lineNumbersCode = [...Array(lines.length - 1)]
|
||||||
.map((line, index) => `<span class="line-number">${index + 1}</span><br>`)
|
.map((_line, index) => `<span class="line-number">${index + 1}</span><br>`)
|
||||||
.join('');
|
.join('');
|
||||||
|
|
||||||
const lineNumbersWrapperCode = `<div class="line-numbers-wrapper">${lineNumbersCode}</div>`;
|
const lineNumbersWrapperCode = `<div class="line-numbers-wrapper">${lineNumbersCode}</div>`;
|
||||||
|
|
|
@ -9,7 +9,7 @@ import { URL } from 'url';
|
||||||
const indexRE = /(^|.*\/)index.md(#?.*)$/i;
|
const indexRE = /(^|.*\/)index.md(#?.*)$/i;
|
||||||
|
|
||||||
export const linkPlugin = (md: MarkdownIt, externalAttrs: Record<string, string>) => {
|
export const linkPlugin = (md: MarkdownIt, externalAttrs: Record<string, string>) => {
|
||||||
md.renderer.rules.link_open = (tokens, idx, options, env, self) => {
|
md.renderer.rules.link_open = (tokens, idx, options, _env, self) => {
|
||||||
const token = tokens[idx];
|
const token = tokens[idx];
|
||||||
const hrefIndex = token.attrIndex('href');
|
const hrefIndex = token.attrIndex('href');
|
||||||
if (hrefIndex >= 0) {
|
if (hrefIndex >= 0) {
|
||||||
|
|
|
@ -7,8 +7,8 @@
|
||||||
// 3. <!--beforeend-->
|
// 3. <!--beforeend-->
|
||||||
// 4. <!--afterend-->
|
// 4. <!--afterend-->
|
||||||
|
|
||||||
import MarkdownIt from 'markdown-it';
|
import type MarkdownIt from 'markdown-it';
|
||||||
import { MarkdownParsedData } from '../markdown';
|
import type { MarkdownParsedData } from '../markdown';
|
||||||
|
|
||||||
export const preWrapperPlugin = (md: MarkdownIt) => {
|
export const preWrapperPlugin = (md: MarkdownIt) => {
|
||||||
const fence = md.renderer.rules.fence!;
|
const fence = md.renderer.rules.fence!;
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
// string.js slugify drops non ascii chars so we have to
|
// string.js slugify drops non ascii chars so we have to
|
||||||
// use a custom implementation here
|
// use a custom implementation here
|
||||||
const removeDiacritics = require('diacritics').remove;
|
import diacritics from 'diacritics';
|
||||||
|
const removeDiacritics = diacritics.remove;
|
||||||
// eslint-disable-next-line no-control-regex
|
// eslint-disable-next-line no-control-regex
|
||||||
const rControl = /[\u0000-\u001f]/g;
|
const rControl = /[\u0000-\u001f]/g;
|
||||||
const rSpecial = /[\s~`!@#$%^&*()\-_+=[\]{}|\\;:"'<>,.?/]+/g;
|
const rSpecial = /[\s~`!@#$%^&*()\-_+=[\]{}|\\;:"'<>,.?/]+/g;
|
||||||
|
|
|
@ -3,7 +3,7 @@ import type MarkdownIt from 'markdown-it';
|
||||||
import type { RuleBlock } from 'markdown-it/lib/parser_block';
|
import type { RuleBlock } from 'markdown-it/lib/parser_block';
|
||||||
|
|
||||||
export const snippetPlugin = (md: MarkdownIt, root: string) => {
|
export const snippetPlugin = (md: MarkdownIt, root: string) => {
|
||||||
const parser: RuleBlock = (state, startLine, endLine, silent) => {
|
const parser: RuleBlock = (state, startLine, _endLine, silent) => {
|
||||||
const CH = '<'.charCodeAt(0);
|
const CH = '<'.charCodeAt(0);
|
||||||
const pos = state.bMarks[startLine] + state.tShift[startLine];
|
const pos = state.bMarks[startLine] + state.tShift[startLine];
|
||||||
const max = state.eMarks[startLine];
|
const max = state.eMarks[startLine];
|
||||||
|
|
|
@ -8,7 +8,9 @@ const gulp = require('gulp');
|
||||||
const program = require('commander');
|
const program = require('commander');
|
||||||
|
|
||||||
program.on('--help', () => {
|
program.on('--help', () => {
|
||||||
|
// eslint-disable-next-line no-console
|
||||||
console.log(' Usage:'.to.bold.blue.color);
|
console.log(' Usage:'.to.bold.blue.color);
|
||||||
|
// eslint-disable-next-line no-console
|
||||||
console.log();
|
console.log();
|
||||||
});
|
});
|
||||||
|
|
||||||
|
@ -41,6 +43,7 @@ const task = program.args[0];
|
||||||
if (!task) {
|
if (!task) {
|
||||||
program.help();
|
program.help();
|
||||||
} else {
|
} else {
|
||||||
|
// eslint-disable-next-line no-console
|
||||||
console.log('scripts run', task);
|
console.log('scripts run', task);
|
||||||
|
|
||||||
require('./gulpfile');
|
require('./gulpfile');
|
||||||
|
|
|
@ -34,7 +34,7 @@ const useMenus = (): {
|
||||||
const inCategory =
|
const inCategory =
|
||||||
r.meta &&
|
r.meta &&
|
||||||
r.meta.category &&
|
r.meta.category &&
|
||||||
r.meta.category.toLowerCase() === category &&
|
(r.meta.category as string).toLowerCase() === category &&
|
||||||
!pattern.test(r.path);
|
!pattern.test(r.path);
|
||||||
if (inCategory && category === 'docs') {
|
if (inCategory && category === 'docs') {
|
||||||
if (isZhCN) {
|
if (isZhCN) {
|
||||||
|
|
|
@ -1,319 +0,0 @@
|
||||||
|
|
||||||
export default [
|
|
||||||
|
|
||||||
{
|
|
||||||
path: 'affix:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"导航","title":"Affix","cover":"https://gw.alipayobjects.com/zos/alicdn/tX6-md4H6/Affix.svg","subtitle":"固钉"},
|
|
||||||
component: () => import('../../../components/affix/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'alert:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"反馈","title":"Alert","cover":"https://gw.alipayobjects.com/zos/alicdn/8emPa3fjl/Alert.svg","subtitle":"警告提示"},
|
|
||||||
component: () => import('../../../components/alert/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)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Avatar","cover":"https://gw.alipayobjects.com/zos/antfincdn/aBcnbw68hP/Avatar.svg","subtitle":"头像"},
|
|
||||||
component: () => import('../../../components/avatar/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)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Badge","cover":"https://gw.alipayobjects.com/zos/antfincdn/6%26GF9WHwvY/Badge.svg","subtitle":"徽标数"},
|
|
||||||
component: () => import('../../../components/badge/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)?',
|
|
||||||
meta: {"category":"Components","type":"通用","title":"Button","cover":"https://gw.alipayobjects.com/zos/alicdn/fNUKzY1sk/Button.svg","subtitle":"按钮"},
|
|
||||||
component: () => import('../../../components/button/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)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Calendar","cover":"https://gw.alipayobjects.com/zos/antfincdn/dPQmLq08DI/Calendar.svg","subtitle":"日历"},
|
|
||||||
component: () => import('../../../components/calendar/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'card:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Card","cover":"https://gw.alipayobjects.com/zos/antfincdn/NqXt8DJhky/Card.svg","subtitle":"卡片"},
|
|
||||||
component: () => import('../../../components/card/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'carousel:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Carousel","cover":"https://gw.alipayobjects.com/zos/antfincdn/%24C9tmj978R/Carousel.svg","subtitle":"走马灯"},
|
|
||||||
component: () => import('../../../components/carousel/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'cascader:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"Cascader","cover":"https://gw.alipayobjects.com/zos/alicdn/UdS8y8xyZ/Cascader.svg","subtitle":"级联选择"},
|
|
||||||
component: () => import('../../../components/cascader/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'checkbox:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"Checkbox","cover":"https://gw.alipayobjects.com/zos/alicdn/8nbVbHEm_/CheckBox.svg","subtitle":"多选框"},
|
|
||||||
component: () => import('../../../components/checkbox/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'collapse:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Collapse","cover":"https://gw.alipayobjects.com/zos/alicdn/IxH16B9RD/Collapse.svg","subtitle":"折叠面板"},
|
|
||||||
component: () => import('../../../components/collapse/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'comment:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Comment","cover":"https://gw.alipayobjects.com/zos/alicdn/ILhxpGzBO/Comment.svg","subtitle":"评论"},
|
|
||||||
component: () => import('../../../components/comment/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'config-provider:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"其他","cols":1,"title":"ConfigProvider","cover":"https://gw.alipayobjects.com/zos/alicdn/kegYxl1wj/ConfigProvider.svg","subtitle":"全局化配置"},
|
|
||||||
component: () => import('../../../components/config-provider/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'date-picker:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"DatePicker","cover":"https://gw.alipayobjects.com/zos/alicdn/RT_USzA48/DatePicker.svg","subtitle":"日期选择框"},
|
|
||||||
component: () => import('../../../components/date-picker/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'descriptions:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Descriptions","cover":"https://gw.alipayobjects.com/zos/alicdn/MjtG9_FOI/Descriptions.svg","subtitle":"描述列表"},
|
|
||||||
component: () => import('../../../components/descriptions/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'divider:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"布局","title":"Divider","cover":"https://gw.alipayobjects.com/zos/alicdn/5swjECahe/Divider.svg","subtitle":"分割线"},
|
|
||||||
component: () => import('../../../components/divider/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'drawer:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"反馈","title":"Drawer","cover":"https://gw.alipayobjects.com/zos/alicdn/7z8NJQhFb/Drawer.svg","subtitle":"抽屉"},
|
|
||||||
component: () => import('../../../components/drawer/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'dropdown:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"导航","title":"Dropdown","cover":"https://gw.alipayobjects.com/zos/alicdn/eedWN59yJ/Dropdown.svg","subtitle":"下拉菜单"},
|
|
||||||
component: () => import('../../../components/dropdown/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'empty:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Empty","cover":"https://gw.alipayobjects.com/zos/alicdn/MNbKfLBVb/Empty.svg","subtitle":"空状态"},
|
|
||||||
component: () => import('../../../components/empty/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'form:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","cols":1,"title":"Form","cover":"https://gw.alipayobjects.com/zos/alicdn/ORmcdeaoO/Form.svg","subtitle":"表单"},
|
|
||||||
component: () => import('../../../components/form/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'grid:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"布局","cols":1,"title":"Grid","cover":"https://gw.alipayobjects.com/zos/alicdn/5rWLU27so/Grid.svg","subtitle":"栅格"},
|
|
||||||
component: () => import('../../../components/grid/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'icon:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"通用","title":"Icon","cover":"https://gw.alipayobjects.com/zos/alicdn/rrwbSt3FQ/Icon.svg","subtitle":"图标"},
|
|
||||||
component: () => import('../../../components/icon/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'image:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Image","cover":"https://gw.alipayobjects.com/zos/antfincdn/D1dXz9PZqa/image.svg","subtitle":"图片"},
|
|
||||||
component: () => import('../../../components/image/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'input:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"Input","cover":"https://gw.alipayobjects.com/zos/alicdn/xS9YEJhfe/Input.svg","subtitle":"输入框"},
|
|
||||||
component: () => import('../../../components/input/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'input-number:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"InputNumber","cover":"https://gw.alipayobjects.com/zos/alicdn/XOS8qZ0kU/InputNumber.svg","subtitle":"数字输入框"},
|
|
||||||
component: () => import('../../../components/input-number/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'layout:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"布局","cols":1,"title":"Layout","cover":"https://gw.alipayobjects.com/zos/alicdn/hzEndUVEx/Layout.svg","subtitle":"布局"},
|
|
||||||
component: () => import('../../../components/layout/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'list:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"List","cover":"https://gw.alipayobjects.com/zos/alicdn/5FrZKStG_/List.svg","subtitle":"列表"},
|
|
||||||
component: () => import('../../../components/list/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'mentions:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"Mentions","cover":"https://gw.alipayobjects.com/zos/alicdn/jPE-itMFM/Mentions.svg","subtitle":"提及"},
|
|
||||||
component: () => import('../../../components/mentions/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'menu:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","cols":1,"type":"导航","title":"Menu","cover":"https://gw.alipayobjects.com/zos/alicdn/3XZcjGpvK/Menu.svg","subtitle":"导航菜单"},
|
|
||||||
component: () => import('../../../components/menu/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'message:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"反馈","title":"Message","cover":"https://gw.alipayobjects.com/zos/alicdn/hAkKTIW0K/Message.svg","subtitle":"全局提示"},
|
|
||||||
component: () => import('../../../components/message/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'modal:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"反馈","title":"Modal","cover":"https://gw.alipayobjects.com/zos/alicdn/3StSdUlSH/Modal.svg","subtitle":"对话框"},
|
|
||||||
component: () => import('../../../components/modal/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'notification:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"反馈","title":"Notification","cover":"https://gw.alipayobjects.com/zos/alicdn/Jxm5nw61w/Notification.svg","subtitle":"通知提醒框"},
|
|
||||||
component: () => import('../../../components/notification/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'page-header:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"导航","title":"PageHeader","cols":1,"subtitle":"页头","cover":"https://gw.alipayobjects.com/zos/alicdn/6bKE0Cq0R/PageHeader.svg"},
|
|
||||||
component: () => import('../../../components/page-header/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'pagination:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"导航","title":"Pagination","cols":1,"cover":"https://gw.alipayobjects.com/zos/alicdn/1vqv2bj68/Pagination.svg","subtitle":"分页"},
|
|
||||||
component: () => import('../../../components/pagination/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'popconfirm:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"反馈","title":"Popconfirm","cover":"https://gw.alipayobjects.com/zos/alicdn/fjMCD9xRq/Popconfirm.svg","subtitle":"气泡确认框"},
|
|
||||||
component: () => import('../../../components/popconfirm/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'popover:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Popover","cover":"https://gw.alipayobjects.com/zos/alicdn/1PNL1p_cO/Popover.svg","subtitle":"气泡卡片"},
|
|
||||||
component: () => import('../../../components/popover/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'progress:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"反馈","title":"Progress","cover":"https://gw.alipayobjects.com/zos/alicdn/xqsDu4ZyR/Progress.svg","subtitle":"进度条"},
|
|
||||||
component: () => import('../../../components/progress/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'radio:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"Radio","cover":"https://gw.alipayobjects.com/zos/alicdn/8cYb5seNB/Radio.svg","subtitle":"单选框"},
|
|
||||||
component: () => import('../../../components/radio/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'rate:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"Rate","cover":"https://gw.alipayobjects.com/zos/alicdn/R5uiIWmxe/Rate.svg","subtitle":"评分"},
|
|
||||||
component: () => import('../../../components/rate/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'result:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"反馈","title":"Result","cover":"https://gw.alipayobjects.com/zos/alicdn/9nepwjaLa/Result.svg","subtitle":"结果"},
|
|
||||||
component: () => import('../../../components/result/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'select:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"Select","cover":"https://gw.alipayobjects.com/zos/alicdn/_0XzgOis7/Select.svg","subtitle":"选择器"},
|
|
||||||
component: () => import('../../../components/select/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'skeleton:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"反馈","title":"Skeleton","cover":"https://gw.alipayobjects.com/zos/alicdn/KpcciCJgv/Skeleton.svg","subtitle":"骨架屏"},
|
|
||||||
component: () => import('../../../components/skeleton/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'slider:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"Slider","cover":"https://gw.alipayobjects.com/zos/alicdn/HZ3meFc6W/Silder.svg","subtitle":"滑动输入条"},
|
|
||||||
component: () => import('../../../components/slider/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'space:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"布局","title":"Space","cols":1,"cover":"https://gw.alipayobjects.com/zos/antfincdn/wc6%263gJ0Y8/Space.svg","subtitle":"间距"},
|
|
||||||
component: () => import('../../../components/space/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'spin:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"反馈","title":"Spin","cover":"https://gw.alipayobjects.com/zos/alicdn/8emPa3fjl/Alert.svg","subtitle":"加载中"},
|
|
||||||
component: () => import('../../../components/spin/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'statistic:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Statistic","cover":"https://gw.alipayobjects.com/zos/antfincdn/rcBNhLBrKbE/Statistic.svg","subtitle":"统计数值"},
|
|
||||||
component: () => import('../../../components/statistic/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'steps:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"导航","cols":1,"title":"Steps","cover":"https://gw.alipayobjects.com/zos/antfincdn/UZYqMizXHaj/Steps.svg","subtitle":"步骤条"},
|
|
||||||
component: () => import('../../../components/steps/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'switch:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"Switch","cover":"https://gw.alipayobjects.com/zos/alicdn/zNdJQMhfm/Switch.svg","subtitle":"开关"},
|
|
||||||
component: () => import('../../../components/switch/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'table:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","cols":1,"type":"数据展示","title":"Table","cover":"https://gw.alipayobjects.com/zos/alicdn/f-SbcX2Lx/Table.svg","subtitle":"表格"},
|
|
||||||
component: () => import('../../../components/table/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'tabs:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Tabs","cover":"https://gw.alipayobjects.com/zos/antfincdn/lkI2hNEDr2V/Tabs.svg","subtitle":"标签页"},
|
|
||||||
component: () => import('../../../components/tabs/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'tag:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Tag","cover":"https://gw.alipayobjects.com/zos/alicdn/cH1BOLfxC/Tag.svg","subtitle":"标签"},
|
|
||||||
component: () => import('../../../components/tag/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'time-picker:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"TimePicker","cover":"https://gw.alipayobjects.com/zos/alicdn/h04Zsl98I/TimePicker.svg","subtitle":"时间选择框"},
|
|
||||||
component: () => import('../../../components/time-picker/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'timeline:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Timeline","cover":"https://gw.alipayobjects.com/zos/antfincdn/vJmo00mmgR/Timeline.svg","subtitle":"时间轴"},
|
|
||||||
component: () => import('../../../components/timeline/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'tooltip:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Tooltip","cover":"https://gw.alipayobjects.com/zos/alicdn/Vyyeu8jq2/Tooltp.svg","subtitle":"文字提示"},
|
|
||||||
component: () => import('../../../components/tooltip/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'transfer:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"Transfer","cover":"https://gw.alipayobjects.com/zos/alicdn/QAXskNI4G/Transfer.svg","subtitle":"穿梭框"},
|
|
||||||
component: () => import('../../../components/transfer/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'tree:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据展示","title":"Tree","cover":"https://gw.alipayobjects.com/zos/alicdn/Xh-oWqg9k/Tree.svg","subtitle":"树形控件"},
|
|
||||||
component: () => import('../../../components/tree/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'tree-select:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"TreeSelect","cover":"https://gw.alipayobjects.com/zos/alicdn/Ax4DA0njr/TreeSelect.svg","subtitle":"树选择"},
|
|
||||||
component: () => import('../../../components/tree-select/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'typography:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"通用","title":"Typography","cols":1,"cover":"https://gw.alipayobjects.com/zos/alicdn/GOM1KQ24O/Typography.svg","subtitle":"排版"},
|
|
||||||
component: () => import('../../../components/typography/demo/index.vue'),
|
|
||||||
},
|
|
||||||
{
|
|
||||||
path: 'upload:lang(-cn)?',
|
|
||||||
meta: {"category":"Components","type":"数据录入","title":"Upload","cover":"https://gw.alipayobjects.com/zos/alicdn/QaeBt_ZMg/Upload.svg","subtitle":"上传"},
|
|
||||||
component: () => import('../../../components/upload/demo/index.vue'),
|
|
||||||
},
|
|
||||||
];
|
|
|
@ -49,7 +49,7 @@
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
// eslint-disable-next-line no-unused-vars
|
// eslint-disable-next-line no-unused-vars
|
||||||
import { mapActions, mapState, mapMutations } from 'vuex';
|
import { mapActions, mapState } from 'vuex';
|
||||||
import Login from './components';
|
import Login from './components';
|
||||||
|
|
||||||
const { Tab, Email, Password, Submit } = Login;
|
const { Tab, Email, Password, Submit } = Login;
|
||||||
|
|
|
@ -14,14 +14,5 @@
|
||||||
"allowJs": true,
|
"allowJs": true,
|
||||||
"importsNotUsedAsValues": "preserve"
|
"importsNotUsedAsValues": "preserve"
|
||||||
},
|
},
|
||||||
"exclude": [
|
"exclude": ["node_modules", "lib", "es", "dist", "v2-doc", "scripts", "**/__tests__/**/*"]
|
||||||
"node_modules",
|
|
||||||
"lib",
|
|
||||||
"es",
|
|
||||||
"antd-tools",
|
|
||||||
"dist",
|
|
||||||
"v2-doc",
|
|
||||||
"scripts",
|
|
||||||
"**/__tests__/**/*"
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
|
|
1
v2-doc
1
v2-doc
|
@ -1 +0,0 @@
|
||||||
Subproject commit 53e2e630b1d0c666252e9b747690f0e524e5a08b
|
|
Loading…
Reference in New Issue