WIP: G6 迁移新官网,添加css样式

This commit is contained in:
zhanning.bzn 2019-11-15 15:40:13 +08:00
parent 875ccea8f8
commit e1e8d41c60
7 changed files with 68 additions and 0 deletions

View File

@ -1,4 +1,18 @@
import G6 from '@antv/g6';
import insertCss from 'insert-css';
insertCss(`
.g6-tooltip {
border: 1px solid #e2e2e2;
border-radius: 4px;
font-size: 12px;
color: #545454;
background-color: rgba(255, 255, 255, 0.9);
padding: 10px 8px;
box-shadow: rgb(174, 174, 174) 0px 0px 10px;
}
`);
/**
* 该示例演示 Fruchterman 布局算法的聚类效果以及点击交互进行聚类的聚合和扩散效果
* by 十吾

View File

@ -1,4 +1,17 @@
import G6 from '@antv/g6';
import insertCss from 'insert-css';
insertCss(`
.g6-tooltip {
border: 1px solid #e2e2e2;
border-radius: 4px;
font-size: 12px;
color: #545454;
background-color: rgba(255, 255, 255, 0.9);
padding: 10px 8px;
box-shadow: rgb(174, 174, 174) 0px 0px 10px;
}
`);
const graph = new G6.Graph({
container: 'container',

View File

@ -1,4 +1,17 @@
import G6 from '@antv/g6';
import insertCss from 'insert-css';
insertCss(`
.g6-tooltip {
border: 1px solid #e2e2e2;
border-radius: 4px;
font-size: 12px;
color: #545454;
background-color: rgba(255, 255, 255, 0.9);
padding: 10px 8px;
box-shadow: rgb(174, 174, 174) 0px 0px 10px;
}
`);
const graph = new G6.Graph({
container: 'container',

View File

@ -1,4 +1,17 @@
import G6 from '@antv/g6';
import insertCss from 'insert-css';
insertCss(`
.g6-tooltip {
border: 1px solid #e2e2e2;
border-radius: 4px;
font-size: 12px;
color: #545454;
background-color: rgba(255, 255, 255, 0.9);
padding: 10px 8px;
box-shadow: rgb(174, 174, 174) 0px 0px 10px;
}
`);
const data = {
nodes: [{

View File

@ -1,4 +1,17 @@
import G6 from '@antv/g6';
import insertCss from 'insert-css';
insertCss(`
.g6-tooltip {
border: 1px solid #e2e2e2;
border-radius: 4px;
font-size: 12px;
color: #545454;
background-color: rgba(255, 255, 255, 0.9);
padding: 10px 8px;
box-shadow: rgb(174, 174, 174) 0px 0px 10px;
}
`);
const data = {
nodes: [{

View File

@ -1 +1,2 @@
window.g6 = require('./src/index.js');
window.insertCss = require('insert-css');

View File

@ -68,6 +68,7 @@
"gh-pages": "^2.1.1",
"hard-source-webpack-plugin": "~0.13.1",
"home": "~1.0.1",
"insert-css": "^2.0.0",
"jquery": "^3.3.1",
"jszip": "~3.1.5",
"nightmare": "~2.10.0",