From 1835e6429dd6820f1af36e295cb1df3780dd2a52 Mon Sep 17 00:00:00 2001 From: mcyph <20507948+mcyph@users.noreply.github.com> Date: Thu, 25 Mar 2021 12:55:45 +1100 Subject: [PATCH] started integrating more examples into the next.js app --- src/pages/JsonData.js | 159 +++++++--------- src/pages/LOD.js | 142 ++++++-------- src/pages/LabelPosition.js | 132 ++++++------- src/pages/Labels.js | 285 ++++++++++++++++------------ src/pages/Layers.js | 181 ++++++++++-------- src/pages/Markers.js | 375 ++++++++++++++++++++----------------- src/pages/Merge.js | 322 +++++++++++++++++++------------ src/pages/Monitor.js | 277 +++++++++++++-------------- src/pages/index.js | 18 +- 9 files changed, 997 insertions(+), 894 deletions(-) diff --git a/src/pages/JsonData.js b/src/pages/JsonData.js index 4770d5de2..38d7fd290 100644 --- a/src/pages/JsonData.js +++ b/src/pages/JsonData.js @@ -1,16 +1,27 @@ /** * Copyright (c) 2006-2013, JGraph Ltd - - JSON data example for mxGraph. This example demonstrates using - JSON to encode/decode parts of the graph model in mxCodec. + + JSON data example for mxGraph. This example demonstrates using + JSON to encode/decode parts of the graph model in mxCodec. */ import React from 'react'; import mxEvent from '../mxgraph/util/mxEvent'; import mxGraph from '../mxgraph/view/mxGraph'; import mxRubberband from '../mxgraph/handler/mxRubberband'; +import mxCodecRegistry from '../mxgraph/io/mxCodecRegistry'; +import mxObjectCodec from '../mxgraph/io/mxObjectCodec'; +import mxUtils from '../mxgraph/util/mxUtils'; +import mxCodec from '../mxgraph/io/mxCodec'; + +class JsonData extends React.Component { + // Adds an option to view the XML of the graph + document; + + body; + + 'View XML'; -class MYNAMEHERE extends React.Component { constructor(props) { super(props); } @@ -20,126 +31,82 @@ class MYNAMEHERE extends React.Component { return ( <>