2019-11-04 19:36:02 +08:00
|
|
|
const { repository } = require('./package.json');
|
|
|
|
|
|
|
|
module.exports = {
|
|
|
|
plugins: [
|
|
|
|
{
|
|
|
|
resolve: '@antv/gatsby-theme-antv',
|
|
|
|
options: {
|
|
|
|
GATrackingId: 'UA-148148901-4',
|
2019-11-15 14:59:14 +08:00
|
|
|
pathPrefix: '/g6'
|
2019-11-04 19:36:02 +08:00
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
// Customize your site metadata:
|
|
|
|
siteMetadata: {
|
|
|
|
title: 'G6',
|
|
|
|
description: 'A collection of charts made with the Grammar of Graphics',
|
|
|
|
githubUrl: repository.url,
|
|
|
|
navs: [
|
|
|
|
{
|
|
|
|
slug: 'docs/manual',
|
|
|
|
title: {
|
2019-11-13 15:34:21 +08:00
|
|
|
zh: '文档',
|
|
|
|
en: 'Docs'
|
2019-11-05 15:55:54 +08:00
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
2019-11-15 15:04:15 +08:00
|
|
|
slug: 'docs/api/GlobalAPI',
|
2019-11-05 15:55:54 +08:00
|
|
|
title: {
|
2019-11-13 15:34:21 +08:00
|
|
|
zh: 'API',
|
2019-11-05 15:55:54 +08:00
|
|
|
en: 'API'
|
2019-11-04 19:36:02 +08:00
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
2019-11-15 15:04:15 +08:00
|
|
|
slug: 'examples/tree/compactBox',
|
2019-11-04 19:36:02 +08:00
|
|
|
title: {
|
|
|
|
zh: '图表演示',
|
|
|
|
en: 'Examples'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
],
|
|
|
|
docs: [
|
2019-11-13 15:34:21 +08:00
|
|
|
{
|
|
|
|
slug: 'manual/FAQ',
|
|
|
|
title: {
|
|
|
|
zh: 'FAQ',
|
|
|
|
en: 'FAQ'
|
|
|
|
},
|
|
|
|
order: 2
|
|
|
|
},
|
2019-11-04 19:36:02 +08:00
|
|
|
{
|
|
|
|
slug: 'manual/tutorial',
|
|
|
|
title: {
|
|
|
|
zh: '入门教程',
|
|
|
|
en: 'Tutorial'
|
|
|
|
},
|
2019-11-13 15:34:21 +08:00
|
|
|
order: 3
|
2019-11-04 19:36:02 +08:00
|
|
|
},
|
|
|
|
{
|
2019-11-05 15:55:54 +08:00
|
|
|
slug: 'manual/middle',
|
2019-11-04 19:36:02 +08:00
|
|
|
title: {
|
2019-11-13 15:34:21 +08:00
|
|
|
zh: '核心概念',
|
2019-11-05 15:55:54 +08:00
|
|
|
en: 'Middle'
|
2019-11-04 19:36:02 +08:00
|
|
|
},
|
2019-11-13 15:34:21 +08:00
|
|
|
order: 4
|
2019-11-04 19:36:02 +08:00
|
|
|
},
|
2019-11-06 18:21:43 +08:00
|
|
|
{
|
|
|
|
slug: 'manual/middle/states',
|
|
|
|
title: {
|
|
|
|
zh: '交互与事件',
|
|
|
|
en: 'Behavior & Event'
|
|
|
|
},
|
2019-11-13 15:34:21 +08:00
|
|
|
order: 4
|
2019-11-06 18:21:43 +08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
slug: 'manual/middle/elements',
|
|
|
|
title: {
|
|
|
|
zh: '节点与边',
|
|
|
|
en: 'Graph Element'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
slug: 'manual/middle/elements/nodes',
|
|
|
|
title: {
|
2019-11-16 18:00:49 +08:00
|
|
|
zh: '内置节点',
|
2019-11-06 18:21:43 +08:00
|
|
|
en: 'Default Node'
|
|
|
|
},
|
|
|
|
order: 2
|
|
|
|
},
|
|
|
|
{
|
|
|
|
slug: 'manual/middle/elements/edges',
|
|
|
|
title: {
|
2019-11-16 18:00:49 +08:00
|
|
|
zh: '内置边',
|
2019-11-06 18:21:43 +08:00
|
|
|
en: 'Default Edge'
|
|
|
|
},
|
|
|
|
order: 3
|
|
|
|
},
|
2019-11-04 19:36:02 +08:00
|
|
|
{
|
2019-11-05 15:55:54 +08:00
|
|
|
slug: 'manual/advanced',
|
2019-11-04 19:36:02 +08:00
|
|
|
title: {
|
2019-11-13 15:34:21 +08:00
|
|
|
zh: '高级指引',
|
2019-11-05 15:55:54 +08:00
|
|
|
en: 'Advanced'
|
2019-11-04 19:36:02 +08:00
|
|
|
},
|
2019-11-16 18:23:56 +08:00
|
|
|
order: 5
|
2019-11-05 20:06:36 +08:00
|
|
|
},
|
2019-11-13 15:34:21 +08:00
|
|
|
{
|
|
|
|
slug: 'manual/cases',
|
|
|
|
title: {
|
2019-11-16 16:06:19 +08:00
|
|
|
zh: '综合应用',
|
2019-11-13 15:34:21 +08:00
|
|
|
en: 'Cases'
|
|
|
|
},
|
2019-11-16 18:23:56 +08:00
|
|
|
order: 6
|
2019-11-13 15:34:21 +08:00
|
|
|
},
|
2019-11-05 20:06:36 +08:00
|
|
|
{
|
|
|
|
slug: 'api',
|
|
|
|
title: {
|
|
|
|
zh: 'API 文档',
|
|
|
|
en: 'API Doc'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
slug: 'api/nodeEdge',
|
|
|
|
title: {
|
|
|
|
zh: '节点和边',
|
|
|
|
en: 'Node & Edge'
|
2019-11-07 20:26:07 +08:00
|
|
|
},
|
|
|
|
order: 4
|
2019-11-08 19:43:55 +08:00
|
|
|
},
|
2019-11-16 17:22:09 +08:00
|
|
|
{
|
|
|
|
slug: 'api/layout',
|
|
|
|
title: {
|
|
|
|
zh: 'Layout',
|
|
|
|
en: 'Layout'
|
|
|
|
},
|
|
|
|
order: 4
|
|
|
|
},
|
2019-11-08 19:43:55 +08:00
|
|
|
{
|
|
|
|
slug: 'api/properties',
|
|
|
|
title: {
|
|
|
|
zh: '属性配置项',
|
|
|
|
en: 'Properties'
|
|
|
|
},
|
2019-11-13 15:34:21 +08:00
|
|
|
order: 10
|
2019-11-04 19:36:02 +08:00
|
|
|
}
|
|
|
|
],
|
|
|
|
examples: [
|
|
|
|
{
|
|
|
|
slug: 'tree',
|
|
|
|
icon: 'tree', // 图标名可以去 https://antv.alipay.com/zh-cn/g2/3.x/demo/index.html 打开控制台查看图标类名
|
|
|
|
title: {
|
|
|
|
zh: '树图',
|
2019-11-14 13:37:44 +08:00
|
|
|
en: 'Tree Graph'
|
2019-11-04 19:36:02 +08:00
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
slug: 'net',
|
|
|
|
icon: 'net',
|
|
|
|
title: {
|
|
|
|
zh: '一般图',
|
2019-11-14 13:37:44 +08:00
|
|
|
en: 'General Graph'
|
2019-11-04 19:36:02 +08:00
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
slug: 'graphql',
|
|
|
|
icon: 'graphql',
|
|
|
|
title: {
|
|
|
|
zh: '其他表达形式',
|
|
|
|
en: 'Net Charts'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
slug: 'shape',
|
|
|
|
icon: 'shape',
|
|
|
|
title: {
|
|
|
|
zh: '元素',
|
|
|
|
en: 'Shape'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
slug: 'interaction',
|
|
|
|
icon: 'interaction',
|
|
|
|
title: {
|
|
|
|
zh: '交互',
|
|
|
|
en: 'Interaction'
|
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
slug: 'scatter',
|
|
|
|
icon: 'scatter',
|
|
|
|
title: {
|
|
|
|
zh: '动画',
|
2019-11-14 23:10:02 +08:00
|
|
|
en: 'Animation'
|
2019-11-04 19:36:02 +08:00
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
slug: 'tool',
|
|
|
|
icon: 'tool',
|
|
|
|
title: {
|
2019-11-13 11:30:50 +08:00
|
|
|
zh: '组件',
|
|
|
|
en: 'Component'
|
2019-11-04 19:36:02 +08:00
|
|
|
}
|
|
|
|
},
|
|
|
|
{
|
|
|
|
slug: 'case',
|
|
|
|
icon: 'case',
|
|
|
|
title: {
|
|
|
|
zh: '复杂案例',
|
|
|
|
en: 'Case'
|
|
|
|
}
|
|
|
|
}
|
|
|
|
]
|
|
|
|
}
|
|
|
|
};
|