Skip to content

Commit e0fec5a

Browse files
author
minjk-bl
committed
Apps > Chart - add method to x,y,z data value selection
1 parent fc6d70b commit e0fec5a

File tree

5 files changed

+17
-18
lines changed

5 files changed

+17
-18
lines changed

css/m_apps/chart.css

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -235,8 +235,7 @@
235235
}
236236
.vp-var-view-box table.vp-option-table.vp-var-view-list,
237237
.vp-var-view-box table.vp-option-table.vp-var-view-detail {
238-
margin-left: 10px;
239-
margin-top: 7px;
238+
padding: 5px;
240239
}
241240
.vp-var-view-box .vp-var-view-list tbody tr:hover {
242241
background: #C4C4C4;
@@ -247,19 +246,17 @@
247246
color: var(--font-hightlight);
248247
}
249248
.vp-var-view-box .var-view-footer {
250-
padding-left: 10px;
251-
padding-bottom: 7px;
249+
margin-top: 7px;
252250
}
253251
.vp-var-view-box .var-view-footer input[type="text"] {
254-
width: 200px;
252+
width: 210px;
255253
}
256254

257255
/* Column Selector */
258256
.vp-column-select,
259257
.vp-method-select {
260258
border: 0.25px solid #C4C4C4;
261259
overflow-y: auto;
262-
width: 250px;
263260
height: 100px;
264261
}
265262
.vp-column-select-item,
@@ -278,8 +275,4 @@
278275
.vp-select-data {
279276
width: 80px;
280277
height: 30px;
281-
background: #F5F5F5;
282-
border: 0.25px solid #C4C4C4;
283-
box-sizing: border-box;
284-
border-radius: 2px;
285278
}

css/popupComponent.css

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,6 @@
270270
font-size: 13px;
271271
line-height: 16px;
272272
height: 30px;
273-
margin-bottom: 5px;
274273
padding: 3px 7px;
275274
color: var(--font-primary);
276275
background: #FFFFFF;

css/root.css

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -142,6 +142,7 @@ body {
142142
box-shadow: 0.5px 0.5px 0.5px rgb(0 0 0 / 10%);
143143
border-radius: 2px;
144144
line-height: 30px;
145+
vertical-align: middle;
145146
font-family: 'AppleSDGothicNeo';
146147
font-size: 14px;
147148
text-align: center;

html/m_apps/chart.html

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
<div id="vp_varViewBox" class="vp-var-view-box vp-close-on-blur">
55
<div class="vp-icon-btn vp-close-view"><img src="/nbextensions/visualpython/img/close_big.svg"/></div>
66
<div class="vp-var-view-div">
7-
<table id="vp_varViewList" class="vp-option-table vp-var-view-list no-selection">
7+
<table id="vp_varViewList" class="vp-option-table vp-var-view-list no-selection wp100">
88
<colgroup><col width="40%"/><col width="*"/></colgroup>
99
<thead>
1010
<tr><th>Variable</th><th>Data Type</th></tr>
@@ -17,19 +17,26 @@
1717
</div>
1818
<hr style="margin: 0px;"/>
1919
<div id="vp_varViewDetail">
20-
<table class="vp-option-table vp-var-view-detail no-selection">
20+
<table class="vp-option-table vp-var-view-detail no-selection wp100">
2121
<colgroup>
22-
<col width="*"/>
22+
<col width="50%"/>
23+
<col width="50%"/>
2324
</colgroup>
2425
<thead>
2526
<tr>
2627
<th>Column</th>
28+
<th>Method</th>
2729
</tr>
2830
</thead>
2931
<tbody>
3032
<tr>
3133
<td>
32-
<div id="vp_varDetailColList" class="vp-column-select">
34+
<div id="vp_varDetailColList" class="vp-column-select vp-scrollbar">
35+
36+
</div>
37+
</td>
38+
<td>
39+
<div id="vp_varDetailArray" class="vp-method-select vp-scrollbar">
3340

3441
</div>
3542
</td>
@@ -39,7 +46,7 @@
3946
</div>
4047
<div class="var-view-footer">
4148
<input id="vp_varSelectCode" type="text" class="vp-input" readonly/>
42-
<input id="vp_varSelectBtn" type="button" value="select"/>
49+
<input id="vp_varSelectBtn" type="button" class="vp-button w50" value="select"/>
4350
</div>
4451
</div>
4552
<!-- Import option -->

js/m_apps/Chart.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -485,7 +485,6 @@ define([
485485
if (varType == 'DataFrame') {
486486
if (varResult.length > 0) {
487487
varResult.forEach(v => {
488-
// var option = $(`<option value="${v.colName}" data-dtype="${v.dtype}" data-array="${v.array}">${v.colName}</option>`)
489488
var option = $(`<div class="vp-column-select-item"
490489
data-dtype="${v.dtype}" data-array="${v.array}" data-col="${v.colName}" title="${v.array}">
491490
${v.colName}</div>`);
@@ -551,7 +550,7 @@ define([
551550
// allow multi select
552551
var methodArrayCode = new com_String();
553552
var methodList;
554-
// 선택된 항목들 중 categorical variable 존재하면 categorical로 분류
553+
// if categorical variable exists, set as categorical
555554
var hasObject = false;
556555
var selectedColumnList = $(that.wrapSelector('#vp_varDetailColList .vp-column-select-item.selected'));
557556
if (selectedColumnList.length > 0) {

0 commit comments

Comments
 (0)