aboutsummaryrefslogtreecommitdiff
path: root/content/pages/graph-editor/graph-editor.rst
blob: 34462e4f712f2070f9700711410753db81a9a744 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
Graph editor
============

:status: hidden
:save_as: pages/graph-editor/index.html
:url: pages/graph-editor/

.. raw:: html

 <style>

 #app {
   width: 100%;
   height: 100%;
   overflow: hidden;
 }

 #panes {
   display: flex;
   width: 100%;
 }

 #graph {
   flex: 1;
   width: 50%;
 }


 #editor {
   border-right: 1px solid #ccc;
   flex: 1;
 }

 #output svg { top: 0; left: 0; width: 100%; height: 100%; }

 </style>

 <div id="app">
         <button id="dot_output">Export DOT</button>
         <button id="png_output">Export PNG</button>
         <button id="btn_window">Isoler</button>
   <div id="panes" class="split split-horizontal">
     <textarea id="editor">g1
  Nom
  -
  propriété 1 <-> g2:2
  propriété 2

 g2
  Autre
  -
  propriété 1
  encore une autre <i>entrée</i>
  autre champ -> g1:3 retour

 g3
  Dernier élément
  -
  ligne 2
  ligne 3</textarea>
        <div id="graph" class="split">
          <div id="output">
            <div id="svg"></div>
          </div>
        </div>
      </div>
    </div>

    <script src="{static}/resources/viz.js/convert.js"></script>