Skip to content

Help button complete !!! #187

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Sep 26, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
github: visualpython
16 changes: 16 additions & 0 deletions .github/ISSUE_TEMPLATE/content-contribution.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
name: Content contribution
about: Share contents to encourage using visualpython (e.g. gitbook, Youtube, blog,
...)
title: ''
labels: documentation
assignees: ''

---

**Share created contents**
Write and share your contents to encourage using visualpython.
Use external links to share your contents.

**Need help**
If you need help for creating contents, you can request other contributors to join.
18 changes: 18 additions & 0 deletions .github/ISSUE_TEMPLATE/design-fix.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
---
name: Design fix
about: Suggest an idea for design and ui
title: ''
labels: design fix
assignees: ''

---

**Is your suggestion related to a problem? Please describe.**
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]

**Describe the design/style you'd like**
A clear and concise description of what you want to happen.
Design images needed to clearly understand

**Additional context**
Add any other context or screenshots about the design suggestion here.
6 changes: 6 additions & 0 deletions .ipynb_checkpoints/Untitled-checkpoint.ipynb
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"cells": [],
"metadata": {},
"nbformat": 4,
"nbformat_minor": 5
}
32 changes: 32 additions & 0 deletions Untitled.ipynb
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"cells": [
{
"cell_type": "code",
"execution_count": null,
"id": "0da90d57",
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"language": "python",
"name": "python3"
},
"vp": {
"vp_config_version": "1.0.0",
"vp_menu_width": 273,
"vp_note_display": false,
"vp_note_width": 0,
"vp_position": {
"width": 278
},
"vp_section_display": true,
"vp_signature": "VisualPython"
}
},
"nbformat": 4,
"nbformat_minor": 5
}
12 changes: 11 additions & 1 deletion css/component/popupComponent.css
Original file line number Diff line number Diff line change
Expand Up @@ -129,8 +129,11 @@
height: 50px;
border-top: 0.25px solid var(--border-gray-color);
}

/* 220919 */
.vp-popup-codeview-box,
.vp-popup-dataview-box {
.vp-popup-dataview-box,
.vp-popup-helpview-box {
display: none;
width: 100%;
height: 100px;
Expand All @@ -155,6 +158,13 @@
margin-top: 9px;
margin-left: 10px;
}

/* 220919 */
.vp-popup-button[data-type="help"] {
float: left;
margin-top: 9px;
margin-left: 10px;
}
.vp-popup-button[data-type="cancel"] {
float: right;
background-color: #E4E4E4;
Expand Down
7 changes: 7 additions & 0 deletions data/help_data.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"Import" : "this is import help",
"File" : "this is file help",
"Bind" : "this is bind help",
"try" : "this is try help",
"Subset" : "this is subset help"
}
14 changes: 14 additions & 0 deletions data/libraries.json
Original file line number Diff line number Diff line change
Expand Up @@ -3063,6 +3063,20 @@
"color": 4,
"icon": "apps/apps_profiling.svg"
}
},
{
"id" : "apps_sample",
"type" : "function",
"level": 1,
"name" : "Sample App",
"tag" : "SAMPLE,OSSCA,APPS",
"path" : "visualpython - apps - sample",
"desc" : "Sample app for OSSCA",
"file" : "m_apps/SampleApp2.js",
"apps" : {
"color": 4,
"icon": "apps/apps_white.svg"
}
}
]
},
Expand Down
Binary file added html/__pycache__/__init__.cpython-310.pyc
Binary file not shown.
Binary file added html/__pycache__/__init__.cpython-39.pyc
Binary file not shown.
13 changes: 12 additions & 1 deletion html/component/popupComponent.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
Note : popup component
License : GNU GPLv3 with Visual Python special exception
Date : 2021. 12. 01
Change Date :
Change Date : 2021. 09. 25
-->
<!-- use body tag to strip comments out on requirejs/text plugin -->
<body>
Expand Down Expand Up @@ -80,10 +80,21 @@
<div class="vp-popup-codeview-box vp-close-on-blur vp-scrollbar">
<textarea name="code"></textarea>
</div>


<!-- Help view box -->
<div class="vp-popup-helpview-box vp-close-on-blur vp-scrollbar">
<textarea name="help"></textarea>
</div>


<!-- Button box -->
<div class="vp-popup-button-box">
<button type="button" class="vp-button vp-popup-button" data-type="code">Code view</button>
<button type="button" class="vp-button vp-popup-button" data-type="data">Data view</button>
<!-- 220919 -->
<button type="button" class="vp-button vp-popup-button vp-popup-help" data-type="help" title="test">Help</button>


<div class="vp-popup-runadd-box">
<button type="button" class="vp-button activated vp-popup-button" data-type="run" title="Save to block & Run cell">Run</button>
Expand Down
67 changes: 67 additions & 0 deletions html/m_ml/OrderInfo.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
<body>
<div class="vp-grid-box">
<div class="vp-grid-border-box">
<div class="vp-grid-col-95">
<label for="modelType" class="vp-orange-text">Model Type</label>
<select id="modelType" class="vp-select vp-state">
<option value="rgs">Regression</option>
<option value="clf">Classfication</option>
<option value="cls">Clustering</option>
</select>
</div>
<div class="vp-grid-col-95 vp-upper-box rgs clf">
<label for="targetData" class="vp-orange-text">Target Data</label>
<input type="text" class="vp-input vp-state" id="targetData" placeholder="Input target data" value="y_test"/>
</div>
<div class="vp-grid-col-95 vp-upper-box rgs clf">
<label for="predictData" class="vp-orange-text">Predict Data</label>
<input type="text" class="vp-input vp-state" id="predictData" placeholder="Input predict data" value="pred"/>
</div>
<div class="vp-grid-col-95 vp-upper-box cls">
<label for="clusteredIndex" class="vp-orange-text">Clustered Index</label>
<input type="text" class="vp-input vp-state" id="clusteredIndex" placeholder="Input predict data" value="clusters"/>
</div>
</div>
<div class="vp-grid-border-box">
<label for="featureData">Evaluation Metrics</label>
<div class="vp-grid-box vp-eval-box vp-eval-rgs">
<label><input type="checkbox" id="r_squared" class="vp-state" checked><span>R squared</span></label>
<label><input type="checkbox" id="mae" class="vp-state"><span>Mean Absolute Error</span></label>
<label><input type="checkbox" id="mape" class="vp-state"><span>Mean Absolute Percentage Error</span></label>
<label><input type="checkbox" id="rmse" class="vp-state" checked><span>Root Mean Squared Error</span></label>
<label><input type="checkbox" id="scatter_plot" class="vp-state"><span>Scatter plot</span></label>
</div>
<div class="vp-grid-box vp-eval-box vp-eval-clf">
<label><input type="checkbox" id="confusion_matrix" class="vp-state" checked><span>Confusion Matrix</span></label>
<label><input type="checkbox" id="report" class="vp-state" checked><span>Report (Accuracy/Precision/Recall/F1-score)</span></label>
<label class="vp-gray-text vp-italic">* You can select individually</span></label>
<label><input type="checkbox" id="accuracy" class="vp-state"><span>Accuracy</span></label>
<label><input type="checkbox" id="precision" class="vp-state"><span>Precision</span></label>
<label><input type="checkbox" id="recall" class="vp-state"><span>Recall</span></label>
<label><input type="checkbox" id="f1_score" class="vp-state"><span>F1-scorev</label>
<!-- <hr style="margin: 5px;"/> -->
<!-- <label><input type="checkbox" id="roc_curve" class="vp-eval-check vp-state" data-type="roc-auc"><span>ROC Curve</span></label>
<label><input type="checkbox" id="auc" class="vp-eval-check vp-state" data-type="roc-auc"><span>AUC</span></label> -->
<!-- <div class="vp-grid-col-95">
<label for="model" class="vp-orange-text">Model</label>
<select id="model" class="vp-select vp-state vp-ev-model roc-auc">
</select>
</div> -->
</div>
<div class="vp-grid-box vp-eval-box vp-eval-cls">
<label><input type="checkbox" id="silhouetteScore" class="vp-eval-check vp-state" data-type="silhouette" checked><span>Silhouette score</span></label>
<div class="vp-grid-col-95">
<label for="featureData2" class="vp-orange-text">Feature Data</label>
<input type="text" class="vp-input vp-state vp-ev-model silhouette" id="featureData2" placeholder="Input feature data" value="X"/>
</div>
<hr style="margin: 5px;"/>
<label><input type="checkbox" id="ari" class="vp-eval-check vp-state" data-type="ari-nmi"><span>ARI (Adjusted Random Score)</span></label>
<label><input type="checkbox" id="nmi" class="vp-eval-check vp-state" data-type="ari-nmi"><span>NMI (Normalized Mutual Information)</span></label>
<div class="vp-grid-col-95">
<label for="targetData2" class="vp-orange-text">Target Data</label>
<input type="text" class="vp-input vp-state vp-ev-model ari-nmi" id="targetData2" placeholder="Input target data" value="y"/>
</div>
</div>
</div>
</div>
</body>
46 changes: 46 additions & 0 deletions js/board/HelpView.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
/*
* Project Name : Visual Python
* Description : GUI-based Python code generator
* File Name : HelpView.js
* Author : Black Logic
* Note : Render Help view
* License : GNU GPLv3 with Visual Python special exception
* Date : 2021. 09. 13
* Change Date :
*/

//============================================================================
// [CLASS] HelpView
//============================================================================
define([
'../com/component/PopupComponent'
], function(PopupComponent) {
'use strict';

/**
* @class HelpView
* @constructor
*/
class HelpView extends PopupComponent {
_init() {
super._init();

this.config.footer = false;
this.config.sizeLevel = 1;

this.state = {
helpview: '',
...this.state
}

this._addCodemirror('helpview', this.wrapSelector('#helpview'), "readonly");
}

templateForBody() {
return `<textarea id="helpview">${this.state.helpview}</textarea>`;
}
}

return HelpView;

});
Loading