-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdnd-colorcoded.html
162 lines (140 loc) · 5.1 KB
/
dnd-colorcoded.html
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
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
<html>
<head>
<meta content="text/html;charset=utf-8" http-equiv="Content-Type">
<meta content="utf-8" http-equiv="encoding">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link rel="stylesheet" type="text/css"
href="https://cdnjs.cloudflare.com/ajax/libs/extjs/6.0.0/classic/theme-crisp/resources/theme-crisp-all.css"/>
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/extjs/6.0.0/ext-all.js"></script>
<link rel="stylesheet" media="screen" href="dnd-colorcoded.css">
</head>
<body>
<div class="barsContainer" style="width:100%">
<div id="ribbonSimple" style="width:100%"></div>
</div>
<hr/>
<!-- All canvas related elements -->
<div style="padding: 10px 15px 0px 15px;">
<div class="start-dd-target" style="width:100%;height:2em; box-sizing: border-box; border: 0.1em dashed black; padding: 3px"><b
style="pointer-events: none;">Drop report here to start...</b>
</div>
<div id="canvas"></div>
</div>
<div class="dd-target-zone"></div>
<div class="dd-target-parent">
<div class="dd-target-underlay"></div>
<div class="dd-target"></div>
</div>
<script type="text/javascript">
/*
const conf = {
type: 'column',
wrap: true,
justify: 'start',
align: 'start',
vgap: 20,
hgap: 20,
grow: true,
shrink: true,
cells: [
{
type: 'row',
// grow: false,
// shrink: false,
cells: [
{
type: 'cell',
id: 'fgrp1-h2-n3',
width: 700,
height: 300,
grow: true,
shrink: true,
fgcolor: 'black',
bgcolor: 'white',
border: '1px solid'
},
{
type: 'column',
// grow: false,
// shrink: false,
cells: [
{
type: 'cell',
// id: 'fgrp1-h2-n4',
width: 700,
height: 100,
grow: true,
shrink: true,
fgcolor: 'white',
bgcolor: 'pink'
},
{
type: 'row',
hgap: 5,
grow: true,
shrink: true,
cells: [
{
type: 'cell',
// id: 'fgrp1-h2-n5',
width: 345,
height: 200,
fgcolor: 'black',
bgcolor: 'yellow'
},
{
type: 'cell',
// id: 'fgrp1-h2-n6',
width: 245,
height: 100,
fgcolor: 'black',
bgcolor: ''
}
]
}
]
}
]
},
{
type: 'row',
wrap: true,
inherit: true,
cells: [
{
type: 'cell',
// id: 'fgrp1-h2-n7',
width: 500,
height: 500,
grow: true,
fgcolor: 'black',
bgcolor: 'yellow',
border: '1px dashed'
},
{
type: 'cell',
// id: 'fgrp1-h2-n8',
width: 500,
height: 300,
grow: false,
fgcolor: 'white',
bgcolor: 'blue'
}
]
}
]
};
const cb = (el) => {
console.log(el);
console.log(el.id);
};
console.log(Ext.clone(conf));
gencanvas('canvas', conf, cb);
//console.log('Reapplying...');
//gencanvas('canvas', conf, cb);
console.log(conf);*/
</script>
<script type="text/javascript" src="canvas.js"></script>
<script type="application/javascript" src="dnd-colorcoded.js"></script>
</body>
</html>