Implement dimension
This commit is contained in:
parent
be00496581
commit
c54e9ff3cb
3 changed files with 106 additions and 0 deletions
|
@ -1,6 +1,7 @@
|
|||
import * as React from 'react';
|
||||
import { ReactSVGPanZoom, Tool, Value, TOOL_PAN } from 'react-svg-pan-zoom';
|
||||
import { Container } from './Elements/Container';
|
||||
import { DimensionLayer } from './Elements/DimensionLayer';
|
||||
|
||||
interface ISVGProps {
|
||||
children: Container | Container[] | null,
|
||||
|
@ -79,6 +80,7 @@ export class SVG extends React.Component<ISVGProps> {
|
|||
>
|
||||
<svg ref={this.svg} {...properties}>
|
||||
{ children }
|
||||
<DimensionLayer isHidden={false} roots={this.props.children} />
|
||||
</svg>
|
||||
</ReactSVGPanZoom>
|
||||
);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue