summaryrefslogtreecommitdiffstats
path: root/ui-react/src/components/loop_viewer/svg
diff options
context:
space:
mode:
authorTed Humphrey <Thomas.Humphrey@att.com>2020-07-08 16:48:40 -0400
committerChristophe Closset <christophe.closset@intl.att.com>2020-07-15 17:49:00 +0000
commit083e5a2aefd76bb1fc25bcb5528b7288b059c1c2 (patch)
treebc99c546f6397c7bd53feb3c49de3dbb7e21a8b5 /ui-react/src/components/loop_viewer/svg
parentb165eb5507409cd0e63b4d255202f46c059f7e6d (diff)
block re-use of existing loop name; support derivation of SvgGenerator
added changes to LoopUI for global style and support of "delete" CL case Issue-ID: CLAMP-896 Change-Id: I97f603f38c277011835b8e206e5e05226a296606 Signed-off-by: Ted Humphrey <Thomas.Humphrey@att.com>
Diffstat (limited to 'ui-react/src/components/loop_viewer/svg')
-rw-r--r--ui-react/src/components/loop_viewer/svg/SvgGenerator.js10
1 files changed, 7 insertions, 3 deletions
diff --git a/ui-react/src/components/loop_viewer/svg/SvgGenerator.js b/ui-react/src/components/loop_viewer/svg/SvgGenerator.js
index 7070455e7..f5f5047ba 100644
--- a/ui-react/src/components/loop_viewer/svg/SvgGenerator.js
+++ b/ui-react/src/components/loop_viewer/svg/SvgGenerator.js
@@ -28,11 +28,12 @@ import OnapConstant from '../../../utils/OnapConstants';
const DivStyled = styled.div`
overflow-x: scroll;
+ display: flex;
width: 100%;
height: 100%;
`
-const emptySvg = (<svg> <text x="20" y="40">No LOOP (SVG)</text> </svg>);
+const emptySvg = (<svg> <text x="60" y="40">No LOOP (SVG)</text> </svg>);
class SvgGenerator extends React.Component {
boxWidth = 200;
@@ -228,11 +229,14 @@ class SvgGenerator extends React.Component {
render() {
var allTheElements = this.renderSvg();
var svgWidth = this.boxWidth*allTheElements.length;
- var svgHeight = this.boxHeight+100;
+ var svgHeight = this.boxHeight+50;
return (
+
<DivStyled onClick={this.handleSvgClick} >
- <svg height={svgHeight} width={svgWidth} preserveAspectRatio="none">
+ <svg height={svgHeight} width={svgWidth} viewBox="0,0,{svgWidth},{svgHeight}" preserveAspectRatio="none">
+ <svg x="-50" y="25">
{allTheElements}
+ </svg>
</svg>
</DivStyled>
);