tg-ganttchart 0.0.7 → 0.0.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/babel.config.js +5 -0
- package/package.json +1 -4
- package/src/.eslintrc.js +18 -0
- package/src/App.vue +780 -0
- package/src/GanttElastic.standalone.vue +48 -0
- package/src/GanttElastic.vue +2305 -0
- package/src/assets/logo.png +0 -0
- package/src/components/Calendar/Calendar.vue +559 -0
- package/src/components/Calendar/CalendarRow.vue +112 -0
- package/src/components/Chart/Chart.vue +117 -0
- package/src/components/Chart/DaysHighlight.vue +60 -0
- package/src/components/Chart/DependencyLines.vue +112 -0
- package/src/components/Chart/Grid.vue +205 -0
- package/src/components/Chart/ProgressBar.vue +110 -0
- package/src/components/Chart/Row/Epic.vue +131 -0
- package/src/components/Chart/Row/Milestone.vue +117 -0
- package/src/components/Chart/Row/Project.vue +132 -0
- package/src/components/Chart/Row/Story.vue +127 -0
- package/src/components/Chart/Row/Subtask.vue +117 -0
- package/src/components/Chart/Row/Task.mixin.js +47 -0
- package/src/components/Chart/Row/Task.vue +82 -0
- package/src/components/Chart/Text.vue +105 -0
- package/src/components/Expander.vue +114 -0
- package/src/components/GanttElastic.standalone.vue +48 -0
- package/src/components/GanttElastic.vue +1646 -0
- package/src/components/Header/GanttViewFilter.vue +154 -0
- package/src/components/Header/Header.vue +266 -0
- package/src/components/MainView.vue +283 -0
- package/src/components/TaskList/ItemColumn.vue +212 -0
- package/src/components/TaskList/TaskList.vue +45 -0
- package/src/components/TaskList/TaskListHeader.vue +143 -0
- package/src/components/TaskList/TaskListItem.vue +35 -0
- package/src/components/bundle.js +28 -0
- package/src/components/components/Calendar/Calendar.vue +332 -0
- package/src/components/components/Calendar/CalendarRow.vue +96 -0
- package/src/components/components/Chart/Chart.vue +111 -0
- package/src/components/components/Chart/DaysHighlight.vue +71 -0
- package/src/components/components/Chart/DependencyLines.vue +112 -0
- package/src/components/components/Chart/Grid.vue +164 -0
- package/src/components/components/Chart/ProgressBar.vue +110 -0
- package/src/components/components/Chart/Row/Milestone.vue +117 -0
- package/src/components/components/Chart/Row/Project.vue +131 -0
- package/src/components/components/Chart/Row/Task.mixin.js +46 -0
- package/src/components/components/Chart/Row/Task.vue +107 -0
- package/src/components/components/Chart/Text.vue +105 -0
- package/src/components/components/Expander.vue +126 -0
- package/src/components/components/Header/Header.vue +265 -0
- package/src/components/components/MainView.vue +282 -0
- package/src/components/components/TaskList/ItemColumn.vue +121 -0
- package/src/components/components/TaskList/TaskList.vue +45 -0
- package/src/components/components/TaskList/TaskListHeader.vue +143 -0
- package/src/components/components/TaskList/TaskListItem.vue +35 -0
- package/src/components/components/bundle.js +28 -0
- package/src/components/style.js +308 -0
- package/src/index.js +12 -0
- package/src/main.js +6 -0
- package/src/style.js +398 -0
- package/vue.config.js +42 -0
- package/dist/demo.html +0 -1
- package/dist/tgganttchart.common.js +0 -9232
- package/dist/tgganttchart.common.js.map +0 -1
- package/dist/tgganttchart.css +0 -1
- package/dist/tgganttchart.umd.js +0 -9243
- package/dist/tgganttchart.umd.js.map +0 -1
- package/dist/tgganttchart.umd.min.js +0 -7
- package/dist/tgganttchart.umd.min.js.map +0 -1
|
@@ -0,0 +1,308 @@
|
|
|
1
|
+
|
|
2
|
+
export default function getStyle(fontSize = '12px', fontFamily = 'Arial, sans-serif') {
|
|
3
|
+
return {
|
|
4
|
+
fontSize,
|
|
5
|
+
fontFamily,
|
|
6
|
+
'main-view': {
|
|
7
|
+
background: '#FFFFFF'
|
|
8
|
+
},
|
|
9
|
+
'main-container-wrapper': {
|
|
10
|
+
overflow: 'hidden',
|
|
11
|
+
'border-top': '1px solid #eee',
|
|
12
|
+
'border-bottom': '1px solid #eee'
|
|
13
|
+
},
|
|
14
|
+
'main-container': {
|
|
15
|
+
float: 'left',
|
|
16
|
+
'max-width': '100%'
|
|
17
|
+
},
|
|
18
|
+
'main-view-container': {},
|
|
19
|
+
container: {
|
|
20
|
+
display: 'flex',
|
|
21
|
+
'max-width': '100%',
|
|
22
|
+
height: '100%'
|
|
23
|
+
},
|
|
24
|
+
'calendar-wrapper': {
|
|
25
|
+
'user-select': 'none'
|
|
26
|
+
},
|
|
27
|
+
calendar: {
|
|
28
|
+
width: '100%',
|
|
29
|
+
background: '#f3f5f7',
|
|
30
|
+
display: 'block'
|
|
31
|
+
},
|
|
32
|
+
'calendar-row': {
|
|
33
|
+
display: 'flex',
|
|
34
|
+
'justify-content': 'space-evenly'
|
|
35
|
+
},
|
|
36
|
+
'calendar-row--month': {},
|
|
37
|
+
'calendar-row--day': {},
|
|
38
|
+
'calendar-row--hour': {
|
|
39
|
+
'border-bottom': '1px solid #eee'
|
|
40
|
+
},
|
|
41
|
+
'calendar-row-rect': {
|
|
42
|
+
background: 'transparent',
|
|
43
|
+
display: 'flex'
|
|
44
|
+
},
|
|
45
|
+
'calendar-row-rect--month': {},
|
|
46
|
+
'calendar-row-rect--day': {},
|
|
47
|
+
'calendar-row-rect--hour': {},
|
|
48
|
+
'calendar-row-rect-child': {
|
|
49
|
+
display: 'block',
|
|
50
|
+
'border-right-width': '1px', // Calendar
|
|
51
|
+
'border-right-color': '#dadada',
|
|
52
|
+
'border-right-style': 'solid',
|
|
53
|
+
position: 'relative'
|
|
54
|
+
},
|
|
55
|
+
'calendar-row-rect-child--month': {},
|
|
56
|
+
'calendar-row-rect-child--day': { 'text-align': 'center' },
|
|
57
|
+
'calendar-row-rect-child--hour': { 'text-align': 'center' },
|
|
58
|
+
'calendar-row-text': {
|
|
59
|
+
'font-family': fontFamily, // GanttElastic
|
|
60
|
+
'font-size': fontSize, //GanttElastic
|
|
61
|
+
color: '#606060',
|
|
62
|
+
display: 'inline-block',
|
|
63
|
+
position: 'relative'
|
|
64
|
+
},
|
|
65
|
+
'calendar-row-text--month': {},
|
|
66
|
+
'calendar-row-text--day': {},
|
|
67
|
+
'calendar-row-text--hour': {},
|
|
68
|
+
'task-list-wrapper': {},
|
|
69
|
+
'task-list': { background: 'transparent', 'border-color': '#eee' },
|
|
70
|
+
'task-list-header': {
|
|
71
|
+
display: 'flex',
|
|
72
|
+
'user-select': 'none',
|
|
73
|
+
'vertical-align': 'middle',
|
|
74
|
+
'border-bottom': '1px solid #eee',
|
|
75
|
+
'border-left': '1px solid #eee'
|
|
76
|
+
},
|
|
77
|
+
'task-list-header-column': {
|
|
78
|
+
'border-left': '1px solid #00000050',
|
|
79
|
+
'box-sizing': 'border-box',
|
|
80
|
+
display: 'flex',
|
|
81
|
+
background: '#f3f5f7',
|
|
82
|
+
'border-color': 'transparent'
|
|
83
|
+
},
|
|
84
|
+
'task-list-expander-wrapper': {
|
|
85
|
+
display: 'inline-flex',
|
|
86
|
+
'flex-shrink': '0',
|
|
87
|
+
'box-sizing': 'border-box',
|
|
88
|
+
margin: '0 0 0 10px'
|
|
89
|
+
},
|
|
90
|
+
'task-list-expander-content': {
|
|
91
|
+
display: 'inline-flex',
|
|
92
|
+
cursor: 'pointer',
|
|
93
|
+
margin: 'auto 0px',
|
|
94
|
+
'box-sizing': 'border-box',
|
|
95
|
+
'user-select': 'none'
|
|
96
|
+
},
|
|
97
|
+
'task-list-expander-line': {
|
|
98
|
+
fill: 'transparent',
|
|
99
|
+
stroke: '#000000',
|
|
100
|
+
'stroke-width': '1',
|
|
101
|
+
'stroke-linecap': 'round'
|
|
102
|
+
},
|
|
103
|
+
'task-list-expander-border': {
|
|
104
|
+
fill: '#ffffffa0',
|
|
105
|
+
stroke: '#000000A0'
|
|
106
|
+
},
|
|
107
|
+
'chart-expander-wrapper': {
|
|
108
|
+
display: 'block',
|
|
109
|
+
'line-height': '1',
|
|
110
|
+
'box-sizing': 'border-box',
|
|
111
|
+
margin: '0'
|
|
112
|
+
},
|
|
113
|
+
'chart-expander-content': {
|
|
114
|
+
display: 'inline-flex',
|
|
115
|
+
cursor: 'pointer',
|
|
116
|
+
margin: 'auto 0px',
|
|
117
|
+
'box-sizing': 'border-box',
|
|
118
|
+
'user-select': 'none'
|
|
119
|
+
},
|
|
120
|
+
'chart-expander-line': {
|
|
121
|
+
fill: 'transparent',
|
|
122
|
+
stroke: '#000000',
|
|
123
|
+
'stroke-width': '1',
|
|
124
|
+
'stroke-linecap': 'round'
|
|
125
|
+
},
|
|
126
|
+
'chart-expander-border': {
|
|
127
|
+
fill: '#ffffffa0',
|
|
128
|
+
stroke: '#000000A0'
|
|
129
|
+
},
|
|
130
|
+
'task-list-container': {},
|
|
131
|
+
'task-list-header-label': {
|
|
132
|
+
overflow: 'hidden',
|
|
133
|
+
'text-overflow': 'ellipsis',
|
|
134
|
+
'font-family': fontFamily,
|
|
135
|
+
'font-size': fontSize,
|
|
136
|
+
'box-sizing': 'border-box',
|
|
137
|
+
margin: 'auto 6px',
|
|
138
|
+
'flex-grow': '1',
|
|
139
|
+
'vertical-align': 'middle'
|
|
140
|
+
},
|
|
141
|
+
'task-list-header-resizer-wrapper': {
|
|
142
|
+
background: 'transparent',
|
|
143
|
+
height: '100%',
|
|
144
|
+
width: '6px',
|
|
145
|
+
cursor: 'col-resize',
|
|
146
|
+
display: 'inline-flex',
|
|
147
|
+
'vertical-align': 'center'
|
|
148
|
+
},
|
|
149
|
+
'task-list-header-resizer': { margin: 'auto 0px' },
|
|
150
|
+
'task-list-header-resizer-dot': {
|
|
151
|
+
width: '3px',
|
|
152
|
+
height: '3px',
|
|
153
|
+
background: '#ddd',
|
|
154
|
+
'border-radius': '100%',
|
|
155
|
+
margin: '4px 0px'
|
|
156
|
+
},
|
|
157
|
+
'task-list-items': {
|
|
158
|
+
overflow: 'hidden'
|
|
159
|
+
},
|
|
160
|
+
'task-list-item': {
|
|
161
|
+
'border-top': '1px solid #eee',
|
|
162
|
+
'border-right': '1px solid #eee',
|
|
163
|
+
'box-sizing': 'border-box',
|
|
164
|
+
display: 'flex',
|
|
165
|
+
background: 'transparent'
|
|
166
|
+
},
|
|
167
|
+
'task-list-item-column': {
|
|
168
|
+
display: 'inline-flex',
|
|
169
|
+
'flex-shrink': '0',
|
|
170
|
+
'border-left': '1px solid #00000050',
|
|
171
|
+
'box-sizing': 'border-box',
|
|
172
|
+
'border-color': '#eee'
|
|
173
|
+
},
|
|
174
|
+
'task-list-item-value-wrapper': {
|
|
175
|
+
overflow: 'hidden',
|
|
176
|
+
display: 'flex',
|
|
177
|
+
width: '100%'
|
|
178
|
+
},
|
|
179
|
+
'task-list-item-value-container': {
|
|
180
|
+
margin: 'auto 0px',
|
|
181
|
+
overflow: 'hidden'
|
|
182
|
+
},
|
|
183
|
+
'task-list-item-value': {
|
|
184
|
+
display: 'block',
|
|
185
|
+
'flex-shrink': '100',
|
|
186
|
+
'font-family': fontFamily,
|
|
187
|
+
'font-size': fontSize,
|
|
188
|
+
'margin-top': 'auto',
|
|
189
|
+
'margin-bottom': 'auto',
|
|
190
|
+
'margin-left': '6px', // TaskList
|
|
191
|
+
'margin-right': '6px',
|
|
192
|
+
overflow: 'hidden',
|
|
193
|
+
'text-overflow': 'ellipsis',
|
|
194
|
+
'line-height': '1.5em',
|
|
195
|
+
'word-break': 'keep-all',
|
|
196
|
+
'white-space': 'nowrap',
|
|
197
|
+
color: '#606060',
|
|
198
|
+
background: '#FFFFFF'
|
|
199
|
+
},
|
|
200
|
+
'grid-lines': {},
|
|
201
|
+
'grid-line-horizontal': {
|
|
202
|
+
stroke: '#00000010',
|
|
203
|
+
'stroke-width': 1
|
|
204
|
+
},
|
|
205
|
+
'grid-line-vertical': {
|
|
206
|
+
stroke: '#00000010',
|
|
207
|
+
'stroke-width': 1
|
|
208
|
+
},
|
|
209
|
+
'grid-line-time': {
|
|
210
|
+
stroke: '#FF000080',
|
|
211
|
+
'stroke-width': 1
|
|
212
|
+
},
|
|
213
|
+
chart: {
|
|
214
|
+
'user-select': 'none',
|
|
215
|
+
overflow: 'hidden'
|
|
216
|
+
},
|
|
217
|
+
'chart-calendar-container': {
|
|
218
|
+
'user-select': 'none',
|
|
219
|
+
overflow: 'hidden',
|
|
220
|
+
'max-width': '100%',
|
|
221
|
+
'border-right': '1px solid #eee'
|
|
222
|
+
},
|
|
223
|
+
'chart-graph-container': {
|
|
224
|
+
'user-select': 'none',
|
|
225
|
+
overflow: 'hidden',
|
|
226
|
+
'max-width': '100%',
|
|
227
|
+
'border-right': '1px solid #eee'
|
|
228
|
+
},
|
|
229
|
+
'chart-area': {},
|
|
230
|
+
'chart-graph': {
|
|
231
|
+
overflow: 'hidden'
|
|
232
|
+
},
|
|
233
|
+
'chart-row-text-wrapper': {},
|
|
234
|
+
'chart-row-text': {
|
|
235
|
+
background: '#ffffffa0',
|
|
236
|
+
'border-radius': '10px',
|
|
237
|
+
'font-family': fontFamily,
|
|
238
|
+
'font-size': fontSize,
|
|
239
|
+
'font-weight': 'normal',
|
|
240
|
+
color: '#000000a0',
|
|
241
|
+
height: '100%',
|
|
242
|
+
display: 'inline-block'
|
|
243
|
+
},
|
|
244
|
+
'chart-row-text-content': {
|
|
245
|
+
padding: '0px 6px'
|
|
246
|
+
},
|
|
247
|
+
'chart-row-text-content--text': {},
|
|
248
|
+
'chart-row-text-content--html': {},
|
|
249
|
+
'chart-row-wrapper': {},
|
|
250
|
+
'chart-row-bar-wrapper': {},
|
|
251
|
+
'chart-row-bar': {},
|
|
252
|
+
'chart-row-bar-polygon': {
|
|
253
|
+
stroke: '#E74C3C',
|
|
254
|
+
'stroke-width': 1,
|
|
255
|
+
fill: '#F75C4C'
|
|
256
|
+
},
|
|
257
|
+
'chart-row-project-wrapper': {},
|
|
258
|
+
'chart-row-project': {},
|
|
259
|
+
'chart-row-project-polygon': {},
|
|
260
|
+
'chart-row-milestone-wrapper': {},
|
|
261
|
+
'chart-row-milestone': {},
|
|
262
|
+
'chart-row-milestone-polygon': {},
|
|
263
|
+
'chart-row-task-wrapper': {},
|
|
264
|
+
'chart-row-task': {},
|
|
265
|
+
'chart-row-task-polygon': {},
|
|
266
|
+
'chart-row-progress-bar-wrapper': {},
|
|
267
|
+
'chart-row-progress-bar': {},
|
|
268
|
+
'chart-row-progress-bar-line': {
|
|
269
|
+
stroke: '#ffffff25',
|
|
270
|
+
'stroke-width': 20
|
|
271
|
+
},
|
|
272
|
+
'chart-row-progress-bar-solid': {
|
|
273
|
+
fill: '#0EAC51',
|
|
274
|
+
height: '20%'
|
|
275
|
+
},
|
|
276
|
+
'chart-row-progress-bar-pattern': {
|
|
277
|
+
fill: 'url(#diagonalHatch)',
|
|
278
|
+
transform: 'translateY(0.1) scaleY(0.8)'
|
|
279
|
+
},
|
|
280
|
+
'chart-row-progress-bar-outline': {
|
|
281
|
+
stroke: '#E74C3C',
|
|
282
|
+
'stroke-width': 1
|
|
283
|
+
},
|
|
284
|
+
'chart-dependency-lines-wrapper': {},
|
|
285
|
+
'chart-dependency-lines-path': {
|
|
286
|
+
fill: 'transparent',
|
|
287
|
+
stroke: '#FFa00090',
|
|
288
|
+
'stroke-width': 2
|
|
289
|
+
},
|
|
290
|
+
'chart-scroll-container': {},
|
|
291
|
+
'chart-scroll-container--horizontal': {
|
|
292
|
+
overflow: 'auto',
|
|
293
|
+
'max-width': '100%'
|
|
294
|
+
},
|
|
295
|
+
'chart-scroll-container--vertical': {
|
|
296
|
+
'overflow-y': 'auto',
|
|
297
|
+
'overflow-x': 'hidden',
|
|
298
|
+
'max-height': '100%',
|
|
299
|
+
float: 'right'
|
|
300
|
+
},
|
|
301
|
+
'chart-days-highlight-rect': {
|
|
302
|
+
fill: '#f3f5f780'
|
|
303
|
+
},
|
|
304
|
+
'slot-header-beforeOptions': {
|
|
305
|
+
display: 'inline-block'
|
|
306
|
+
}
|
|
307
|
+
};
|
|
308
|
+
}
|
package/src/index.js
ADDED
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
|
|
2
|
+
import ganttChart from './components/GanttElastic.vue';
|
|
3
|
+
export default {
|
|
4
|
+
install(app, options = {}) {
|
|
5
|
+
app.component('tg-ganttchart', ganttChart);
|
|
6
|
+
},
|
|
7
|
+
};
|
|
8
|
+
// if (typeof window !== 'undefined' && window.Vue) {
|
|
9
|
+
// window.Vue.use(TgList);
|
|
10
|
+
// }
|
|
11
|
+
|
|
12
|
+
export { ganttChart };
|