Skip to content

Commit e9260dd

Browse files
authored
Merge pull request #80 from hbcarlos/rtc
Refactor and improvements
2 parents 4a7753d + 3c0da88 commit e9260dd

File tree

1,855 files changed

+2021
-431283
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,855 files changed

+2021
-431283
lines changed

binder/environment.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,5 +17,6 @@ dependencies:
1717
- nodejs >=14,<15
1818
- pip
1919
- wheel
20+
- jupyterlab-link-share=0.2
2021
# additional packages for demos
2122
# - ipywidgets

package.json

Lines changed: 11 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@
2121
],
2222
"main": "lib/index.js",
2323
"types": "lib/index.d.ts",
24+
"style": "style/index.css",
2425
"repository": {
2526
"type": "git",
2627
"url": "https://github.com/wolfv/jupyterlab-drawio.git"
@@ -29,7 +30,7 @@
2930
"build": "jlpm run build:lib && jlpm run build:labextension:dev",
3031
"build:labextension": "jupyter labextension build .",
3132
"build:labextension:dev": "jupyter labextension build --development True .",
32-
"build:lib": "rimraf lib/mxgraph && mkdir -p lib/mxgraph && cp -R src/mxgraph lib && tsc",
33+
"build:lib": "rimraf lib/drawio && mkdir -p lib/drawio && cp -R src/drawio lib && tsc",
3334
"build:prod": "jlpm run build:lib && jlpm run build:labextension",
3435
"clean": "jlpm run clean:lib",
3536
"clean:all": "jlpm run clean:lib && jlpm run clean:labextension",
@@ -44,18 +45,18 @@
4445
"watch:src": "tsc -w"
4546
},
4647
"dependencies": {
47-
"@jupyterlab/application": "^3.0.2",
48-
"@jupyterlab/apputils": "^3.0.2",
49-
"@jupyterlab/coreutils": "^5.0.1",
50-
"@jupyterlab/docregistry": "^3.0.2",
51-
"@jupyterlab/filebrowser": "^3.0.2",
52-
"@jupyterlab/launcher": "^3.0.2",
53-
"@jupyterlab/mainmenu": "^3.0.2",
48+
"@jupyterlab/application": "^3.0.6",
49+
"@jupyterlab/apputils": "^3.0.5",
50+
"@jupyterlab/coreutils": "^5.0.3",
51+
"@jupyterlab/docregistry": "^3.0.6",
52+
"@jupyterlab/filebrowser": "^3.0.6",
53+
"@jupyterlab/launcher": "^3.0.5",
54+
"@jupyterlab/mainmenu": "^3.0.5",
5455
"@lumino/coreutils": "^1.5.3",
5556
"@lumino/widgets": "^1.18.0"
5657
},
5758
"devDependencies": {
58-
"@jupyterlab/builder": "^3.0.0",
59+
"@jupyterlab/builder": "^3.0.5",
5960
"@lumino/messaging": "^1.4.3",
6061
"@typescript-eslint/eslint-plugin": "^2.27.0",
6162
"@typescript-eslint/parser": "^2.27.0",
@@ -70,6 +71,7 @@
7071
},
7172
"jupyterlab": {
7273
"extension": true,
74+
"schemaDir": "schema",
7375
"outputDir": "jupyterlab-drawio/labextension"
7476
},
7577
"styleModule": "style/index.js"

schema/settings.json

Lines changed: 203 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,203 @@
1+
{
2+
"title": "DrawIO",
3+
"description": "DrawIO settings.",
4+
"jupyter.lab.shortcuts": [
5+
{
6+
"command": "drawio:command/print",
7+
"keys": ["Ctrl+P"],
8+
"selector": "body"
9+
},
10+
{
11+
"command": "drawio:command/undo",
12+
"keys": ["Ctrl+Z"],
13+
"selector": "body"
14+
},
15+
{
16+
"command": "drawio:command/redo",
17+
"keys": ["Ctrl+Shift+Z"],
18+
"selector": "body"
19+
},
20+
{
21+
"command": "drawio:command/cut",
22+
"keys": ["Ctrl+X"],
23+
"selector": "body"
24+
},
25+
{
26+
"command": "drawio:command/copy",
27+
"keys": ["Ctrl+C"],
28+
"selector": "body"
29+
},
30+
{
31+
"command": "drawio:command/paste",
32+
"keys": ["Ctrl+V"],
33+
"selector": "body"
34+
},
35+
{
36+
"command": "drawio:command/duplicate",
37+
"keys": ["Ctrl+D"],
38+
"selector": "body"
39+
},
40+
{
41+
"command": "drawio:command/editData",
42+
"keys": ["Ctrl+M"],
43+
"selector": "body"
44+
},
45+
{
46+
"command": "drawio:command/editStyle",
47+
"keys": ["Ctrl+E"],
48+
"selector": "body"
49+
},
50+
{
51+
"command": "drawio:command/edit",
52+
"keys": ["F2/Enter"],
53+
"selector": "body"
54+
},
55+
{
56+
"command": "drawio:command/selectVertices",
57+
"keys": ["Ctrl+Shift+I"],
58+
"selector": "body"
59+
},
60+
{
61+
"command": "drawio:command/selectEdges",
62+
"keys": ["Ctrl+Shift+E"],
63+
"selector": "body"
64+
},
65+
{
66+
"command": "drawio:command/selectAll",
67+
"keys": ["Ctrl+A"],
68+
"selector": "body"
69+
},
70+
{
71+
"command": "drawio:command/selectNone",
72+
"keys": ["Ctrl+Shift+A"],
73+
"selector": "body"
74+
},
75+
{
76+
"command": "drawio:command/lockUnlock",
77+
"keys": ["Ctrl+L"],
78+
"selector": "body"
79+
},
80+
{
81+
"command": "drawio:command/formatPanel",
82+
"keys": ["Ctrl+Shift+P"],
83+
"selector": "body"
84+
},
85+
{
86+
"command": "drawio:command/outline",
87+
"keys": ["Ctrl+Shift+O"],
88+
"selector": "body"
89+
},
90+
{
91+
"command": "drawio:command/layers",
92+
"keys": ["Ctrl+Shift+L"],
93+
"selector": "body"
94+
},
95+
{
96+
"command": "drawio:command/grid",
97+
"keys": ["Ctrl+Shift+G"],
98+
"selector": "body"
99+
},
100+
{
101+
"command": "drawio:command/connectionArrows",
102+
"keys": ["Alt+Shift+A"],
103+
"selector": "body"
104+
},
105+
{
106+
"command": "drawio:command/connectionPoints",
107+
"keys": ["Alt+Shift+P"],
108+
"selector": "body"
109+
},
110+
{
111+
"command": "drawio:command/resetView",
112+
"keys": ["Ctrl+H"],
113+
"selector": "body"
114+
},
115+
{
116+
"command": "drawio:command/zoomIn",
117+
"keys": ["Ctrl+(Numpad)/Alt+Mousewheel"],
118+
"selector": "body"
119+
},
120+
{
121+
"command": "drawio:command/zoomOut",
122+
"keys": ["Ctrl-(Numpad)/Alt+Mousewheel"],
123+
"selector": "body"
124+
},
125+
{
126+
"command": "drawio:command/toFront",
127+
"keys": ["Ctrl+Shift+F"],
128+
"selector": "body"
129+
},
130+
{
131+
"command": "drawio:command/toBack",
132+
"keys": ["Ctrl+Shift+B"],
133+
"selector": "body"
134+
},
135+
{
136+
"command": "drawio:command/turn",
137+
"keys": ["Ctrl+R"],
138+
"selector": "body"
139+
},
140+
{
141+
"command": "drawio:command/exitGroup",
142+
"keys": ["Ctrl+Shift+Home"],
143+
"selector": "body"
144+
},
145+
{
146+
"command": "drawio:command/enterGroup",
147+
"keys": ["Ctrl+Shift+End"],
148+
"selector": "body"
149+
},
150+
{
151+
"command": "drawio:command/expand",
152+
"keys": ["Ctrl+End"],
153+
"selector": "body"
154+
},
155+
{
156+
"command": "drawio:command/collapse",
157+
"keys": ["Ctrl+Home"],
158+
"selector": "body"
159+
},
160+
{
161+
"command": "drawio:command/group",
162+
"keys": ["Ctrl+G"],
163+
"selector": "body"
164+
},
165+
{
166+
"command": "drawio:command/ungroup",
167+
"keys": ["Ctrl+Shift+U"],
168+
"selector": "body"
169+
},
170+
{
171+
"command": "drawio:command/clearWaypoints",
172+
"keys": ["Alt+Shift+C"],
173+
"selector": "body"
174+
},
175+
{
176+
"command": "drawio:command/autosize",
177+
"keys": ["Ctrl+Shift+Y"],
178+
"selector": "body"
179+
},
180+
{
181+
"command": "drawio:command/fitWindow",
182+
"keys": ["Ctrl+Shift+H"],
183+
"selector": "body"
184+
},
185+
{
186+
"command": "drawio:command/fitPage",
187+
"keys": ["Ctrl+J"],
188+
"selector": "body"
189+
},
190+
{
191+
"command": "drawio:command/fitTwoPages",
192+
"keys": ["Ctrl+Shift+J"],
193+
"selector": "body"
194+
},
195+
{
196+
"command": "drawio:command/customZoom",
197+
"keys": ["Ctrl+O"],
198+
"selector": "body"
199+
}
200+
],
201+
"type": "object",
202+
"additionalProperties": false
203+
}

scripts/copyfiles.js

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
11
var fs = require('fs-extra');
22

3-
fs.copySync('src/mxgraph/javascript/src/', 'lib/mxgraph/javascript/src/');
4-
fs.copySync('src/mxgraph/javascript/examples/grapheditor/www/', 'lib/mxgraph/javascript/examples/grapheditor/www/');
3+
//fs.copySync('src/mxgraph/javascript/src/', 'lib/mxgraph/javascript/src/');
4+
//fs.copySync('src/mxgraph/javascript/examples/grapheditor/www/', 'lib/mxgraph/javascript/examples/grapheditor/www/');
55
// fs.copySync('src/mxgraph/javascript/examples/grapheditor/www/resources/grapheditor.txt',
66
// 'lib/mxgraph/javascript/examples/grapheditor/www/resources/grapheditor.md');
77
// fs.copySync('src/mxgraph/javascript/examples/grapheditor/www/resources/grapheditor.txt',
88
// 'src/mxgraph/javascript/examples/grapheditor/www/resources/grapheditor.md');
9+
10+
fs.copySync('src/drawio/', 'lib/drawio/');
11+
//fs.copySync('src/drawio/', 'lib/drawio/');

src/mxgraph/javascript/src/css/common.css renamed to src/drawio/css/common.css

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ div.mxRubberband {
77
background: #0077FF;
88
}
99
.mxCellEditor {
10-
background: url('../images/transparent.gif');
10+
background: url('../img/transparent.gif');
1111
border-color: transparent;
1212
border-style: solid;
1313
position: absolute;
@@ -27,7 +27,7 @@ div.mxWindow {
2727
-webkit-box-shadow: 3px 3px 12px #C0C0C0;
2828
-moz-box-shadow: 3px 3px 12px #C0C0C0;
2929
box-shadow: 3px 3px 12px #C0C0C0;
30-
background: url('../images/window.gif');
30+
background: url('../img/window.gif');
3131
border:1px solid #c3c3c3;
3232
position: absolute;
3333
overflow: hidden;
@@ -40,7 +40,7 @@ table.mxWindow {
4040
font-size: 8pt;
4141
}
4242
td.mxWindowTitle {
43-
background: url('../images/window-title.gif') repeat-x;
43+
background: url('../img/window-title.gif') repeat-x;
4444
text-overflow: ellipsis;
4545
white-space: nowrap;
4646
text-align: center;
@@ -73,7 +73,7 @@ td.mxWindowPane input, td.mxWindowPane select, td.mxWindowPane textarea, td.mxWi
7373
padding: 1px;
7474
}
7575
td.mxWindowPane button {
76-
background: url('../images/button.gif') repeat-x;
76+
background: url('../img/button.gif') repeat-x;
7777
font-family: Arial;
7878
font-size: 8pt;
7979
padding: 2px;
@@ -124,7 +124,7 @@ div.mxPopupMenu {
124124
-webkit-box-shadow: 3px 3px 12px #C0C0C0;
125125
-moz-box-shadow: 3px 3px 12px #C0C0C0;
126126
box-shadow: 3px 3px 12px #C0C0C0;
127-
background: url('../images/window.gif');
127+
background: url('../img/window.gif');
128128
position: absolute;
129129
border-style: solid;
130130
border-width: 1px;

0 commit comments

Comments
 (0)