mirror of
https://gitee.com/antv/g6.git
synced 2024-12-02 11:48:29 +08:00
fix: delete unnecessary console
This commit is contained in:
parent
b419ad6c7c
commit
d3da98d5ce
@ -121,7 +121,6 @@ const singleEdge: ShapeOptions = {
|
|||||||
style.y = offsetStyle.y;
|
style.y = offsetStyle.y;
|
||||||
style.rotate = offsetStyle.rotate;
|
style.rotate = offsetStyle.rotate;
|
||||||
style.textAlign = this._getTextAlign(labelPosition, offsetStyle.angle);
|
style.textAlign = this._getTextAlign(labelPosition, offsetStyle.angle);
|
||||||
console.log('get style by position', labelPosition, style);
|
|
||||||
return style;
|
return style;
|
||||||
},
|
},
|
||||||
// 获取文本对齐方式
|
// 获取文本对齐方式
|
||||||
@ -177,7 +176,6 @@ const singleEdge: ShapeOptions = {
|
|||||||
const label = group.addShape('text', {
|
const label = group.addShape('text', {
|
||||||
attrs: labelStyle
|
attrs: labelStyle
|
||||||
});
|
});
|
||||||
console.log('edge draw label', label);
|
|
||||||
return label;
|
return label;
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -53,11 +53,8 @@ describe('shape edge test', () => {
|
|||||||
// label: '这是一条线'
|
// label: '这是一条线'
|
||||||
// }, group);
|
// }, group);
|
||||||
|
|
||||||
// console.log(shape.attr('path').length);
|
|
||||||
// expect(shape.attr('path').length).toEqual(2);
|
// expect(shape.attr('path').length).toEqual(2);
|
||||||
// const label = group.get('children')[1];
|
// const label = group.get('children')[1];;
|
||||||
// console.log(label.attr('x'), label.attr('y'));
|
|
||||||
// console.log(group.getCount());
|
|
||||||
// expect(shape.attr('path').length).toEqual(2);
|
// expect(shape.attr('path').length).toEqual(2);
|
||||||
// expect(label.attr('x')).toEqual((100 + 150) / 2);
|
// expect(label.attr('x')).toEqual((100 + 150) / 2);
|
||||||
// expect(label.attr('y')).toEqual((100 + 50) / 2);
|
// expect(label.attr('y')).toEqual((100 + 50) / 2);
|
||||||
@ -249,7 +246,6 @@ describe('shape edge test', () => {
|
|||||||
// }
|
// }
|
||||||
// }, group);
|
// }, group);
|
||||||
// const label = group.get('children')[1];
|
// const label = group.get('children')[1];
|
||||||
// console.log('labellabellabellabel', label, label.attr('textAlign'));
|
|
||||||
// expect(label.attr('textAlign')).toEqual('center');
|
// expect(label.attr('textAlign')).toEqual('center');
|
||||||
|
|
||||||
// expect(label.attr('stroke')).toEqual('white');
|
// expect(label.attr('stroke')).toEqual('white');
|
||||||
|
Loading…
Reference in New Issue
Block a user