14 |
15 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/feature_request.md:
--------------------------------------------------------------------------------
1 | ---
2 | name: Feature request
3 | about: Suggest an idea for this project
4 | title: "[FEATURE REQUEST]"
5 | labels: Feature request
6 | assignees: ''
7 |
8 | ---
9 |
10 | **Is your feature request related to a problem? Please describe.**
11 | A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
12 |
13 | **Describe the solution you'd like**
14 | A clear and concise description of what you want to happen.
15 |
16 | **Describe alternatives you've considered**
17 | A clear and concise description of any alternative solutions or features you've considered.
18 |
19 | **Additional context**
20 | Add any other context or screenshots about the feature request here.
21 |
--------------------------------------------------------------------------------
/Memo/ESP3D [ESP410] format.md:
--------------------------------------------------------------------------------
1 | # ESP3D [ESP410] format
2 |
3 | This command list all AP available, limited to 30 by API, if signal is too low, AP is not listed to avoid connection problems.
4 |
5 | WebUI need use json format to get propelry formated answer
6 | As described in Commands.md:
7 |
8 | Example
9 | `[ESP410]json`
10 | you will get the following if ok
11 |
12 | ```
13 | {
14 | "cmd": "410",
15 | "status": "ok",
16 | "data": [
17 | {
18 | "SSID": "GRBL",
19 | "SIGNAL": "100",
20 | "IS_PROTECTED": "1"
21 | },
22 | {
23 | "SSID": "luc-ext1",
24 | "SIGNAL": "64",
25 | "IS_PROTECTED": "1"
26 | },
27 | {
28 | "SSID": "TP-Link_Luc",
29 | "SIGNAL": "62",
30 | "IS_PROTECTED": "1"
31 | }
32 | ]
33 | }
34 | ```
35 |
--------------------------------------------------------------------------------
/extensions/click2go/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "clicktogo",
3 | "version": "1.0.0",
4 | "description": "ESP3D-WEBUI extension",
5 | "main": "click2go.html",
6 | "scripts": {
7 | "build": "webpack --mode production"
8 | },
9 | "keywords": [],
10 | "author": "Luc LEBOSSE",
11 | "license": "LGPL",
12 | "devDependencies": {
13 | "@babel/core": "^7.24.7",
14 | "@babel/preset-env": "^7.24.7",
15 | "babel-loader": "^9.1.3",
16 | "compression-webpack-plugin": "^11.1.0",
17 | "css-loader": "^7.1.2",
18 | "filemanager-webpack-plugin": "^8.0.0",
19 | "html-loader": "^5.0.0",
20 | "html-webpack-plugin": "^5.6.0",
21 | "style-loader": "^4.0.0",
22 | "webpack": "^5.92.0",
23 | "webpack-cli": "^5.1.4"
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/extensions/gcodeViewer/package.json:
--------------------------------------------------------------------------------
1 | {
2 | "name": "gcodeViewer",
3 | "version": "1.0.1",
4 | "description": "ESP3D-WEBUI extension",
5 | "main": "gcodeViewer.html",
6 | "scripts": {
7 | "build": "webpack --mode production"
8 | },
9 | "keywords": [],
10 | "author": "Luc LEBOSSE",
11 | "license": "LGPL",
12 | "devDependencies": {
13 | "@babel/core": "^7.24.7",
14 | "@babel/preset-env": "^7.24.7",
15 | "babel-loader": "^9.1.3",
16 | "compression-webpack-plugin": "^11.1.0",
17 | "css-loader": "^7.1.2",
18 | "filemanager-webpack-plugin": "^8.0.0",
19 | "html-loader": "^5.0.0",
20 | "html-webpack-plugin": "^5.6.0",
21 | "style-loader": "^4.0.0",
22 | "webpack": "^5.92.0",
23 | "webpack-cli": "^5.1.4"
24 | }
25 | }
26 |
--------------------------------------------------------------------------------
/.github/FUNDING.yml:
--------------------------------------------------------------------------------
1 | # These are supported funding model platforms
2 |
3 | #github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
4 | #patreon: # Replace with a single Patreon username
5 | #open_collective: # Replace with a single Open Collective username
6 | #ko_fi: # Replace with a single Ko-fi username
7 | #tidelift: # Replace with a single Tidelift platform-name/package-name e.g., npm/babel
8 | #community_bridge: # Replace with a single Community Bridge project-name e.g., cloud-foundry
9 | #liberapay: # Replace with a single Liberapay username
10 | #issuehunt: # Replace with a single IssueHunt username
11 | #otechie: # Replace with a single Otechie username
12 | custom: https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=WWLSJZ97FV834
13 |
--------------------------------------------------------------------------------
/server/public/theme-purple:
--------------------------------------------------------------------------------
1 | .feather-icon-container svg,
2 | span.input-group-addon,
3 | span.form-input,
4 | input,
5 | select,
6 | span.text-dark,
7 | label.text-dark,
8 | label.hide-low,
9 | section,
10 | button,
11 | .navbar,
12 | .modal-container,
13 | body,
14 | .empty,
15 | html{
16 | background-color:rgb(200, 200, 233)!important;
17 | color:white!important;
18 |
19 | }
20 |
21 | a svg.esp3dlogo{
22 | color:#c0c0c0!important;
23 | }
24 |
25 | .form-switch input:checked + .form-icon {
26 | background-color:white!important;
27 | }
28 |
29 | a.active svg,
30 | a.active label.hide-low{
31 | color:blue!important;
32 | }
33 |
34 | .navbar{
35 | border-bottom:white solid 0.5px;
36 | }
37 |
38 | span.navbar-section{
39 | background-color:#0e0e6d!important;
40 | color:white!important;
41 | }
42 |
--------------------------------------------------------------------------------
/themes_samples/theme-purple:
--------------------------------------------------------------------------------
1 | .feather-icon-container svg,
2 | span.input-group-addon,
3 | span.form-input,
4 | input,
5 | select,
6 | span.text-dark,
7 | label.text-dark,
8 | label.hide-low,
9 | section,
10 | button,
11 | .navbar,
12 | .modal-container,
13 | body,
14 | .empty,
15 | html{
16 | background-color:rgb(200, 200, 233)!important;
17 | color:white!important;
18 |
19 | }
20 |
21 | a svg.esp3dlogo{
22 | color:#c0c0c0!important;
23 | }
24 |
25 | .form-switch input:checked + .form-icon {
26 | background-color:white!important;
27 | }
28 |
29 | a.active svg,
30 | a.active label.hide-low{
31 | color:blue!important;
32 | }
33 |
34 | .navbar{
35 | border-bottom:white solid 0.5px;
36 | }
37 |
38 | span.navbar-section{
39 | background-color:#0e0e6d!important;
40 | color:white!important;
41 | }
42 |
--------------------------------------------------------------------------------
/.prettierrc:
--------------------------------------------------------------------------------
1 | {
2 | "printWidth": 80,
3 | "tabWidth": 4,
4 | "useTabs": false,
5 | "semi": false,
6 | "singleQuote": false,
7 | "trailingComma": "es5",
8 | "bracketSpacing": true,
9 | "bracketSameLine": false,
10 | "arrowParens": "always",
11 | "requirePragma": false,
12 | "insertPragma": false,
13 | "proseWrap": "preserve",
14 | "overrides": [
15 | {
16 | "files": "*.js",
17 | "options": {
18 | "parser": "babel"
19 | }
20 | },
21 | {"files": "*.css",
22 | "options": {
23 | "parser": "css"
24 | }
25 | },
26 | {"files": "*.scss",
27 | "options": {
28 | "parser": "scss"
29 | }
30 | },
31 | {"files": "*.json",
32 | "options": {
33 | "printWidth": 120,
34 | }
35 | }
36 | ]
37 | }
38 |
--------------------------------------------------------------------------------
/src/style/_spectre-exp.scss:
--------------------------------------------------------------------------------
1 | /*! Spectre.css Experimentals v#{$version} | MIT License | github.com/picturepan2/spectre */
2 | // Experimentals
3 | //@import "node_modules/spectre.css/src/autocomplete";
4 | //@import "node_modules/spectre.css/src/calendars";
5 | //@import "node_modules/spectre.css/src/carousels";
6 | //@import "node_modules/spectre.css/src/comparison-sliders";
7 | //@import "node_modules/spectre.css/src/filters";
8 | //@import "node_modules/spectre.css/src/meters";
9 | //@import "node_modules/spectre.css/src/off-canvas";
10 | //@import "node_modules/spectre.css/src/parallax";
11 | //@import "node_modules/spectre.css/src/progress";
12 | @import "node_modules/spectre.css/src/sliders";
13 | //@import "node_modules/spectre.css/src/timelines";
14 | //@import "node_modules/spectre.css/src/viewer-360";
15 |
--------------------------------------------------------------------------------
/Memo/ESP3D [ESP401] format.md:
--------------------------------------------------------------------------------
1 | # ESP3D [ESP401] format
2 |
3 | WebUI need use json format to get propelry formated answer
4 | As described in Commands.md:
5 |
6 | ## Conventions
7 |
8 | 1 - add space to separate parameters
9 | 2 - if parameter has space add \\ in front of space to not be seen as separator
10 | 3 - json json=YES json=TRUE json=1 are paremeters to switch output to json
11 | By default output is plain text, to get json formated output
12 | add json or json=yes after main parameters
13 | The json format is {
14 | cmd:"<401>", //the id of requested command
15 | status:"" //give if it is success or an failure
16 | data:"the position of setting"
17 | }
18 |
19 | Example
20 | `[ESP401]P=1 T=S V=My\ SSID json`
21 | you will get the following if ok
22 | `{"cmd":"401","status":"ok","data":"1"}`
23 |
--------------------------------------------------------------------------------
/Memo/variablesList.md:
--------------------------------------------------------------------------------
1 | # Variables list
2 |
3 | - From output:
4 |
5 | - [PRB:0.000,0.000,0.000:0]
6 | #prb_x#, #prb_y#,#prb_z#
7 | optional according axis definition #prb_a#,#prb_b#,#prb_c#
8 |
9 | - from ? report MPos:0.000,0.000,0.000,0.000,0.000,0.000
10 | #pos_x#, #pos_y#, #pos_z#, #pos_a#, #pos_b#, #pos_c#,
11 | #pos_wx#, #pos_wy#, #pos_wz#, #pos_wa#, #pos_wb#, #pos_wc#,
12 | optional according axis definition #pos_u#,#pos_v#,#pos_w#, #pos_wu#,#pos_wv#,#pos_ww#
13 |
14 | Note: if variable is unknown, then it is set to `0`
15 |
16 | - From UI
17 |
18 | - Probe Panel
19 | Probe thickness : #probe_thickness#
20 | Selected axis : #selected_axis#
21 |
22 | - Laser CNC Panel
23 | Maximum value of laser: #laser_max#
24 |
--------------------------------------------------------------------------------
/extensions/click2go/.prettierrc:
--------------------------------------------------------------------------------
1 | {
2 | "printWidth": 80,
3 | "tabWidth": 4,
4 | "useTabs": false,
5 | "semi": false,
6 | "singleQuote": false,
7 | "trailingComma": "es5",
8 | "bracketSpacing": true,
9 | "bracketSameLine": false,
10 | "arrowParens": "always",
11 | "requirePragma": false,
12 | "insertPragma": false,
13 | "proseWrap": "preserve",
14 | "overrides": [
15 | {
16 | "files": "*.js",
17 | "options": {
18 | "parser": "babel"
19 | }
20 | },
21 | {"files": "*.css",
22 | "options": {
23 | "parser": "css"
24 | }
25 | },
26 | {"files": "*.scss",
27 | "options": {
28 | "parser": "scss"
29 | }
30 | },
31 | {"files": "*.json",
32 | "options": {
33 | "printWidth": 120,
34 | }
35 | }
36 | ]
37 | }
38 |
--------------------------------------------------------------------------------
/extensions/gcodeViewer/.prettierrc:
--------------------------------------------------------------------------------
1 | {
2 | "printWidth": 80,
3 | "tabWidth": 4,
4 | "useTabs": false,
5 | "semi": false,
6 | "singleQuote": false,
7 | "trailingComma": "es5",
8 | "bracketSpacing": true,
9 | "bracketSameLine": false,
10 | "arrowParens": "always",
11 | "requirePragma": false,
12 | "insertPragma": false,
13 | "proseWrap": "preserve",
14 | "overrides": [
15 | {
16 | "files": "*.js",
17 | "options": {
18 | "parser": "babel"
19 | }
20 | },
21 | {"files": "*.css",
22 | "options": {
23 | "parser": "css"
24 | }
25 | },
26 | {"files": "*.scss",
27 | "options": {
28 | "parser": "scss"
29 | }
30 | },
31 | {"files": "*.json",
32 | "options": {
33 | "printWidth": 120,
34 | }
35 | }
36 | ]
37 | }
38 |
--------------------------------------------------------------------------------
/extensions/gcodeViewer/README.md:
--------------------------------------------------------------------------------
1 | This ESP3D-WebUI extension is a WebGL-based G-code viewer designed to provide an interactive and high-performance visualization of G-code files directly in the web browser.
2 | It offers the following features:
3 |
4 | * Real-time 3D rendering of 3D printing toolpaths.
5 | * Efficient loading and processing of large G-code files.
6 | * Intuitive user interface with visualization controls.
7 | * Dynamic filtering of print layers.
8 | * Customizable viewing options (auto-rotation, axis inversion, etc.).
9 | * Performance optimizations for smooth experience even with complex models.
10 |
11 | > [!INFO]
12 | >### Note
13 | > This extension is for 3D printers only, it will not work with CNC machines, an updated version is planned for the future.
14 |
15 | The package is built in /dist directory
16 |
--------------------------------------------------------------------------------
/.github/stale.yml:
--------------------------------------------------------------------------------
1 | # Number of days of inactivity before an issue becomes stale
2 | daysUntilStale: 21
3 | # Number of days of inactivity before a stale issue is closed
4 | daysUntilClose: 3
5 | # Issues with these labels will never be considered stale
6 | exemptLabels:
7 | - pinned
8 | - security
9 | - Under Investigation
10 | - Work in progress
11 | - Planned
12 | - Feedback Welcome
13 | # Label to use when marking an issue as stale
14 | staleLabel: stale
15 | # Comment to post when marking an issue as stale. Set to `false` to disable
16 | markComment: >
17 | This issue has been automatically marked as stale because it has not had
18 | recent activity. It will be closed if no further activity occurs. Thank you
19 | for your contributions.
20 | # Comment to post when closing a stale issue. Set to `false` to disable
21 | closeComment: false
22 |
--------------------------------------------------------------------------------
/src/adapters/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI adapter file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 |
22 | import { httpAdapter } from "./httpAdapter"
23 |
24 | export { httpAdapter }
25 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Marlin/variablesTable.js:
--------------------------------------------------------------------------------
1 | /*
2 | variablesTable.js - ESP3D WebUI helpers file
3 |
4 | Copyright (c) 2021 Luc LEBOSSE. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 |
20 | const variablesTable = []
21 |
22 | export default variablesTable
23 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Repetier/variablesTable.js:
--------------------------------------------------------------------------------
1 | /*
2 | variablesTable.js - ESP3D WebUI helpers file
3 |
4 | Copyright (c) 2021 Luc LEBOSSE. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 |
20 | const variablesTable = []
21 |
22 | export default variablesTable
23 |
--------------------------------------------------------------------------------
/src/targets/CNC/Controls/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickStopButton } from "./QuickStopButton"
22 |
23 | export { QuickStopButton }
24 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Smoothieware/variablesTable.js:
--------------------------------------------------------------------------------
1 | /*
2 | variablesTable.js - ESP3D WebUI helpers file
3 |
4 | Copyright (c) 2021 Luc LEBOSSE. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 |
20 | const variablesTable = []
21 |
22 | export default variablesTable
23 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Marlin-embedded/variablesTable.js:
--------------------------------------------------------------------------------
1 | /*
2 | variablesTable.js - ESP3D WebUI helpers file
3 |
4 | Copyright (c) 2021 Luc LEBOSSE. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 |
20 | const variablesTable = []
21 |
22 | export default variablesTable
23 |
--------------------------------------------------------------------------------
/src/components/Images/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI helpers file
3 |
4 | Copyright (c) 2021 Alexandre Aussourd. All rights reserved.
5 | Modified by Luc LEBOSSE 2021
6 |
7 | This code is free software; you can redistribute it and/or
8 | modify it under the terms of the GNU Lesser General Public
9 | License as published by the Free Software Foundation; either
10 | version 2.1 of the License, or (at your option) any later version.
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 | You should have received a copy of the GNU Lesser General Public
16 | License along with This code; if not, write to the Free Software
17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18 | */
19 | import { h } from "preact"
20 | import { iconsFeather } from "./icons"
21 |
22 | export { iconsFeather }
23 |
--------------------------------------------------------------------------------
/src/areas/footer.js:
--------------------------------------------------------------------------------
1 | /*
2 | footer.js - ESP3D WebUI footer file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 |
22 | //Nothing for the moment
23 | const FooterContainer = () => {
24 | return
25 | }
26 |
27 | export { FooterContainer }
28 |
--------------------------------------------------------------------------------
/src/hooks/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI hooks file
3 |
4 | Copyright (c) 2020~2024 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { useHttpQueue, useHttpFn } from "./useHttpQueue"
22 | import { useSettings } from "./useSettings"
23 |
24 | export { useHttpQueue, useSettings, useHttpFn}
25 |
--------------------------------------------------------------------------------
/server/public/capabilities.html:
--------------------------------------------------------------------------------
1 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
--------------------------------------------------------------------------------
/src/targets/SandTable/Controls/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickStopButton } from "./QuickStopButton"
22 | import { BackgroundContainer } from "./BackgroundContainer"
23 |
24 | export { QuickStopButton, BackgroundContainer }
25 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Controls/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickStopButton } from "./QuickStopButton"
22 | import { BackgroundContainer } from ".//BackgroundContainer"
23 |
24 | export { QuickStopButton, BackgroundContainer }
25 |
--------------------------------------------------------------------------------
/src/components/App/version.js:
--------------------------------------------------------------------------------
1 | /*
2 | version.js - ESP3D WebUI version file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 | import { webUIbuild } from "../../targets"
20 | export const webUIversion = "3.0.1"
21 | export const Esp3dVersion = () => (
22 |
23 | {webUIversion}.{webUIbuild}
24 |
25 | )
26 |
--------------------------------------------------------------------------------
/src/tabs/machine/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI navigation tab file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { MachineSettings } from "../../targets"
22 |
23 | const MachineTab = () => {
24 | console.log("Machine")
25 | return
26 | }
27 |
28 | export { MachineTab }
29 |
--------------------------------------------------------------------------------
/server/public/dispatch.html:
--------------------------------------------------------------------------------
1 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
--------------------------------------------------------------------------------
/src/areas/menu.js:
--------------------------------------------------------------------------------
1 | /*
2 | menu.js - ESP3D WebUI Menu file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { Navbar } from "../components/Navbar"
22 |
23 | const Menu = () => {
24 | return (
25 |
28 |
29 |
--------------------------------------------------------------------------------
/src/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI App file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | if (process.env.NODE_ENV === "development") {
21 | require("preact/debug")
22 | }
23 | import { h, render } from "preact"
24 | import { App } from "./components/App"
25 | import "./style/index.scss"
26 | import "SubTargetDir/style/index.scss"
27 | render(, document.body)
28 |
--------------------------------------------------------------------------------
/src/targets/CNC/GRBL/Controls/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickButtonsBar } from "./QuickButtonsBar"
22 | import { InformationsControls } from "./InformationsControls"
23 | import { BackgroundContainer } from "./BackgroundContainer"
24 | export { QuickButtonsBar, InformationsControls, BackgroundContainer }
25 |
--------------------------------------------------------------------------------
/src/targets/CNC/grblHAL/Controls/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickButtonsBar } from "./QuickButtonsBar"
22 | import { InformationsControls } from "./InformationsControls"
23 | import { BackgroundContainer } from "./BackgroundContainer"
24 | export { QuickButtonsBar, InformationsControls, BackgroundContainer }
25 |
--------------------------------------------------------------------------------
/.github/workflows/build-ci.yml:
--------------------------------------------------------------------------------
1 | name: build-ci
2 |
3 | on: [pull_request, push]
4 |
5 | jobs:
6 | build:
7 | runs-on: ubuntu-latest
8 | steps:
9 | - uses: actions/checkout@v4
10 | - name: Use Node.js
11 | uses: actions/setup-node@v3
12 | with:
13 | node-version: '16.x'
14 | - name: Install libraries
15 | id: setuptools
16 | run: npm install
17 | continue-on-error: true
18 | - name: Build all files
19 | id: buildall
20 | run: npm run buildall
21 | continue-on-error: true
22 | - name: Failure check
23 | env:
24 | STEPS_CONTEXT: ${{ toJson(steps) }}
25 | DISCORD_WEBHOOK_URL: ${{ secrets.DISCORD_WEBHOOK_URL }}
26 | if: steps.setuptools.outcome == 'failure' || steps.buildall.outcome == 'failure'
27 | run: bash ./.github/ci/final-check.sh "$GITHUB_RUN_ID" "failure"
28 | - name: Success check
29 | env:
30 | DISCORD_WEBHOOK_URL: ${{ secrets.DISCORD_WEBHOOK_URL }}
31 | if: steps.setuptools.outcome == 'success' && steps.buildall.outcome == 'success'
32 | run: bash ./.github/ci/final-check.sh "$GITHUB_RUN_ID" "success"
33 |
--------------------------------------------------------------------------------
/server/public/query.html:
--------------------------------------------------------------------------------
1 |
27 |
28 |
33 |
34 |
--------------------------------------------------------------------------------
/server/public/lang-fr.json:
--------------------------------------------------------------------------------
1 | {
2 | "lang" : "Français",
3 | "S1" : "Chargement...",
4 | "S2" : "Connection websocket...",
5 | "S3" : "Apparement vous êtes connecté depuis une autre page, donc cette page est désormais déconnectée",
6 | "S4" : "Erreur traitement lors du fichier de configuration, le fichier est incorrecte",
7 | "S5" : "Impossible de se connecter au serveur de la carte",
8 | "S6" : "Erreur de connection WebSocket",
9 | "S7" : "Erreur lors du traitement du fichier de préférences, le fichier est incorrecte",
10 | "S8" : "SVP reconnectez-moi",
11 | "S9" : "déconnecté",
12 | "S10" : "Connection with board is lost",
13 | "S11" : "Aidez nous",
14 | "S12" : "A propos d'ESP3D",
15 | "S13" : "Tableau de bord",
16 | "S14" : "Parmètres",
17 | "S15" : "Donation pour ESP3D",
18 | "S16" : "Version micrologiciel",
19 | "S17" : "Version interface",
20 | "S18" : "Version navigateur",
21 | "S19" : "Inconnu",
22 | "S20" : "Go to github",
23 | "S21" : "Parsing data error, data are incorrect",
24 | "S22" : "Erreur",
25 | "S23" : "Refresh information",
26 | "S24" : "Fermer",
27 | "T9" : "Utilisation sytème de fichiers"
28 | }
29 |
--------------------------------------------------------------------------------
/src/components/Controls/Loading.js:
--------------------------------------------------------------------------------
1 | /*
2 | Loading.js - ESP3D WebUI component file
3 |
4 | Copyright (c) 2021 Alexandre Aussourd. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 | import { createComponent } from "../Helpers"
20 |
21 | /*
22 | * Local const
23 | *
24 | */
25 | const modifiers = {
26 | lg: "loading-lg",
27 | large: "loading-lg",
28 | }
29 | const Loading = createComponent("div", "loading", modifiers)
30 |
31 | export default Loading
32 |
--------------------------------------------------------------------------------
/src/targets/CNC/GRBL/Controls/QuickButtonsBar.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickStopButton } from "../../Controls"
22 |
23 | const QuickButtonsBar = () => {
24 | return (
25 |
26 |
27 |
28 | )
29 | }
30 |
31 | export { QuickButtonsBar }
32 |
--------------------------------------------------------------------------------
/src/targets/CNC/grblHAL/Controls/QuickButtonsBar.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickStopButton } from "../../Controls"
22 |
23 | const QuickButtonsBar = () => {
24 | return (
25 |
26 |
27 |
28 | )
29 | }
30 |
31 | export { QuickButtonsBar }
32 |
--------------------------------------------------------------------------------
/src/targets/SandTable/GRBL/Controls/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickButtonsBar } from "./QuickButtonsBar"
22 | import { InformationsControls } from "./InformationsControls"
23 | import { BackgroundContainer } from "../../Controls/BackgroundContainer"
24 | export { QuickButtonsBar, InformationsControls, BackgroundContainer }
25 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Marlin/Controls/QuickButtonsBar.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickStopButton } from "../../Controls"
22 |
23 | const QuickButtonsBar = () => {
24 | return (
25 |
26 |
27 |
28 | )
29 | }
30 |
31 | export { QuickButtonsBar }
32 |
--------------------------------------------------------------------------------
/src/targets/SandTable/GRBL/Controls/QuickButtonsBar.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickStopButton } from "../../Controls"
22 |
23 | const QuickButtonsBar = () => {
24 | return (
25 |
26 |
27 |
28 | )
29 | }
30 |
31 | export { QuickButtonsBar }
32 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Repetier/Controls/QuickButtonsBar.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickStopButton } from "../../Controls"
22 |
23 | const QuickButtonsBar = () => {
24 | return (
25 |
26 |
27 |
28 | )
29 | }
30 |
31 | export { QuickButtonsBar }
32 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Smoothieware/Controls/QuickButtonsBar.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickStopButton } from "../../Controls"
22 |
23 | const QuickButtonsBar = () => {
24 | return (
25 |
26 |
27 |
28 | )
29 | }
30 |
31 | export { QuickButtonsBar }
32 |
--------------------------------------------------------------------------------
/server/CNC/grblHAL/Flash/www/lang-fr.json:
--------------------------------------------------------------------------------
1 | {
2 | "lang" : "Français",
3 | "S1" : "Chargement...",
4 | "S2" : "Connection websocket...",
5 | "S3" : "Apparement vous êtes connecté depuis une autre page, donc cette page est désormais déconnectée",
6 | "S4" : "Erreur traitement lors du fichier de configuration, le fichier est incorrecte",
7 | "S5" : "Impossible de se connecter au serveur de la carte",
8 | "S6" : "Erreur de connection WebSocket",
9 | "S7" : "Erreur lors du traitement du fichier de préférences, le fichier est incorrecte",
10 | "S8" : "SVP reconnectez-moi",
11 | "S9" : "déconnecté",
12 | "S10" : "Connection with board is lost",
13 | "S11" : "Aidez nous",
14 | "S12" : "A propos d'ESP3D",
15 | "S13" : "Tableau de bord",
16 | "S14" : "Parmètres",
17 | "S15" : "Donation pour ESP3D",
18 | "S16" : "Version micrologiciel",
19 | "S17" : "Version interface",
20 | "S18" : "Version navigateur",
21 | "S19" : "Inconnu",
22 | "S20" : "Go to github",
23 | "S21" : "Parsing data error, data are incorrect",
24 | "S22" : "Erreur",
25 | "S23" : "Refresh information",
26 | "S24" : "Fermer",
27 | "T9" : "Utilisation sytème de fichiers"
28 | }
29 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Marlin-embedded/Controls/QuickButtonsBar.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickStopButton } from "../../Controls"
22 |
23 | const QuickButtonsBar = () => {
24 | return (
25 |
26 |
27 |
28 | )
29 | }
30 |
31 | export { QuickButtonsBar }
32 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Smoothieware/Controls/MixedExtrudersControl.js:
--------------------------------------------------------------------------------
1 | /*
2 | MixedExtrudersControl.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { T } from "../../../../components/Translations"
22 |
23 | const MixedExtrudersControl = ({ feedrate }) => {
24 | console.log("feedrate", feedrate)
25 |
26 | return
{T("S199")}
27 | }
28 |
29 | export { MixedExtrudersControl }
30 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Marlin/style/index.scss:
--------------------------------------------------------------------------------
1 | @import "../../style/index";
2 | .mixed-extruders-container {
3 | display: flex;
4 | flex-direction: column;
5 | align-items: center;
6 | justify-content: center;
7 | width: 100%;
8 | height: 100%;
9 | }
10 | .mixed-extruder-control {
11 | display: flex;
12 | width: 100%;
13 | align-items: center;
14 | justify-content: center;
15 | gap: 10px;
16 | }
17 |
18 | .mixed-extruder-control-header {
19 | border: 0.05rem solid #5755d9;
20 | color: #5755d9;
21 | border-radius: 1.1rem 1.1rem;
22 | height: 1.8rem;
23 | line-height: 1.6rem;
24 | padding: 0rem 0rem;
25 | text-align: center;
26 | font-size: 0.8rem;
27 | width: 1.8rem;
28 | height: 1.8rem;
29 | }
30 |
31 | .mixed-extruder-control-header .label {
32 | font-size: 0.7rem;
33 | text-align: center;
34 | color: #5755d9;
35 | margin: 0rem 0rem;
36 | padding: 0px 0px;
37 | background-color: white;
38 | font-weight: bold;
39 | border-radius: 0.9rem 0.9rem;
40 | width: 0.9rem;
41 | height: 0.9rem;
42 | }
43 |
44 | .extruder-extrude-controls-container {
45 | display: flex;
46 | align-items: center;
47 | justify-content: center;
48 | width: 100%;
49 | gap: 10px;
50 | }
51 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Repetier/style/index.scss:
--------------------------------------------------------------------------------
1 | @import "../../style/index";
2 | .mixed-extruders-container {
3 | display: flex;
4 | flex-direction: column;
5 | align-items: center;
6 | justify-content: center;
7 | width: 100%;
8 | height: 100%;
9 | }
10 | .mixed-extruder-control {
11 | display: flex;
12 | width: 100%;
13 | align-items: center;
14 | justify-content: center;
15 | gap: 10px;
16 | }
17 |
18 | .mixed-extruder-control-header {
19 | border: 0.05rem solid #5755d9;
20 | color: #5755d9;
21 | border-radius: 1.1rem 1.1rem;
22 | height: 1.8rem;
23 | line-height: 1.6rem;
24 | padding: 0rem 0rem;
25 | text-align: center;
26 | font-size: 0.8rem;
27 | width: 1.8rem;
28 | height: 1.8rem;
29 | }
30 |
31 | .mixed-extruder-control-header .label {
32 | font-size: 0.7rem;
33 | text-align: center;
34 | color: #5755d9;
35 | margin: 0rem 0rem;
36 | padding: 0px 0px;
37 | background-color: white;
38 | font-weight: bold;
39 | border-radius: 0.9rem 0.9rem;
40 | width: 0.9rem;
41 | height: 0.9rem;
42 | }
43 |
44 | .extruder-extrude-controls-container {
45 | display: flex;
46 | align-items: center;
47 | justify-content: center;
48 | width: 100%;
49 | gap: 10px;
50 | }
51 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Marlin-embedded/style/index.scss:
--------------------------------------------------------------------------------
1 | @import "../../style/index";
2 | .mixed-extruders-container {
3 | display: flex;
4 | flex-direction: column;
5 | align-items: center;
6 | justify-content: center;
7 | width: 100%;
8 | height: 100%;
9 | }
10 | .mixed-extruder-control {
11 | display: flex;
12 | width: 100%;
13 | align-items: center;
14 | justify-content: center;
15 | gap: 10px;
16 | }
17 |
18 | .mixed-extruder-control-header {
19 | border: 0.05rem solid #5755d9;
20 | color: #5755d9;
21 | border-radius: 1.1rem 1.1rem;
22 | height: 1.8rem;
23 | line-height: 1.6rem;
24 | padding: 0rem 0rem;
25 | text-align: center;
26 | font-size: 0.8rem;
27 | width: 1.8rem;
28 | height: 1.8rem;
29 | }
30 |
31 | .mixed-extruder-control-header .label {
32 | font-size: 0.7rem;
33 | text-align: center;
34 | color: #5755d9;
35 | margin: 0rem 0rem;
36 | padding: 0px 0px;
37 | background-color: white;
38 | font-weight: bold;
39 | border-radius: 0.9rem 0.9rem;
40 | width: 0.9rem;
41 | height: 0.9rem;
42 | }
43 |
44 | .extruder-extrude-controls-container {
45 | display: flex;
46 | align-items: center;
47 | justify-content: center;
48 | width: 100%;
49 | gap: 10px;
50 | }
51 |
--------------------------------------------------------------------------------
/src/components/Controls/Toast.js:
--------------------------------------------------------------------------------
1 | /*
2 | Toast.js - ESP3D WebUI component file
3 |
4 | Copyright (c) 2021 Alexandre Aussourd. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 | import { createComponent } from "../Helpers"
20 |
21 | const modifiers = {
22 | primary: "toast-primary",
23 | success: "toast-success",
24 | warning: "toast-warning",
25 | error: "toast-error",
26 | }
27 |
28 | const Toast = createComponent("div", "toast", modifiers)
29 | Toast.Close = createComponent("button", "btn btn-clear float-right")
30 |
31 | export default Toast
32 |
--------------------------------------------------------------------------------
/src/areas/informations.js:
--------------------------------------------------------------------------------
1 | /*
2 | informations.js - ESP3D WebUI Informations file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { InformationsControls, QuickButtonsBar } from "../targets"
22 | const Informations = () => {
23 | return (
24 |
25 |
26 |
27 |
28 |
29 |
30 | )
31 | }
32 |
33 | export { Informations }
34 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Marlin/Controls/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickButtonsBar } from "./QuickButtonsBar"
22 | import { InformationsControls } from "./InformationsControls"
23 | import { MixedExtrudersControl } from "./MixedExtrudersControl"
24 | import { BackgroundContainer } from "../../Controls/BackgroundContainer"
25 | export {
26 | QuickButtonsBar,
27 | InformationsControls,
28 | MixedExtrudersControl,
29 | BackgroundContainer,
30 | }
31 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Repetier/Controls/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickButtonsBar } from "./QuickButtonsBar"
22 | import { InformationsControls } from "./InformationsControls"
23 | import { MixedExtrudersControl } from "./MixedExtrudersControl"
24 | import { BackgroundContainer } from "../../Controls/BackgroundContainer"
25 | export {
26 | QuickButtonsBar,
27 | InformationsControls,
28 | MixedExtrudersControl,
29 | BackgroundContainer,
30 | }
31 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Smoothieware/Controls/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickButtonsBar } from "./QuickButtonsBar"
22 | import { InformationsControls } from "./InformationsControls"
23 | import { MixedExtrudersControl } from "./MixedExtrudersControl"
24 | import { BackgroundContainer } from "../../Controls/BackgroundContainer"
25 | export {
26 | QuickButtonsBar,
27 | InformationsControls,
28 | MixedExtrudersControl,
29 | BackgroundContainer,
30 | }
31 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Marlin-embedded/Controls/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { QuickButtonsBar } from "./QuickButtonsBar"
22 | import { InformationsControls } from "./InformationsControls"
23 | import { MixedExtrudersControl } from "./MixedExtrudersControl"
24 | import { BackgroundContainer } from "../../Controls/BackgroundContainer"
25 | export {
26 | QuickButtonsBar,
27 | InformationsControls,
28 | MixedExtrudersControl,
29 | BackgroundContainer,
30 | }
31 |
--------------------------------------------------------------------------------
/src/targets/SandTable/GRBL/Controls/InformationsControls.js:
--------------------------------------------------------------------------------
1 | /*
2 | Informations.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { Fragment, h } from "preact"
21 | import { PositionsControls } from "../../../../components/Panels/JogCNC"
22 | import { useUiContextFn } from "../../../../contexts"
23 |
24 | const InformationsControls = () => {
25 | return (
26 |
27 | {useUiContextFn.getValue("showjogpanel") && }
28 |
29 | )
30 | }
31 |
32 | export { InformationsControls }
33 |
--------------------------------------------------------------------------------
/src/targets/CNC/GRBL/stream.js:
--------------------------------------------------------------------------------
1 | /*
2 | stream.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 |
22 | const isVerboseOnly = (type, data) => {
23 | const line = data.trim()
24 | if (
25 | line.trim().length == 0 ||
26 | line.startsWith("[") ||
27 | line.startsWith("ok") ||
28 | line.startsWith("<") ||
29 | line.startsWith("SENSOR:") ||
30 | (line.startsWith("{") && line.endsWith("}"))
31 | )
32 | return true
33 | else return false
34 | }
35 |
36 | export { isVerboseOnly }
37 |
--------------------------------------------------------------------------------
/src/targets/CNC/grblHAL/stream.js:
--------------------------------------------------------------------------------
1 | /*
2 | stream.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 |
22 | const isVerboseOnly = (type, data) => {
23 | const line = data.trim()
24 | if (
25 | line.trim().length == 0 ||
26 | line.startsWith("[") ||
27 | line.startsWith("ok") ||
28 | line.startsWith("<") ||
29 | line.startsWith("SENSOR:") ||
30 | (line.startsWith("{") && line.endsWith("}"))
31 | )
32 | return true
33 | else return false
34 | }
35 |
36 | export { isVerboseOnly }
37 |
--------------------------------------------------------------------------------
/src/targets/SandTable/GRBL/stream.js:
--------------------------------------------------------------------------------
1 | /*
2 | stream.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 |
22 | const isVerboseOnly = (type, data) => {
23 | const line = data.trim()
24 | if (
25 | line.trim().length == 0 ||
26 | line.startsWith("[") ||
27 | line.startsWith("ok") ||
28 | line.startsWith("<") ||
29 | line.startsWith("SENSOR:") ||
30 | (line.startsWith("{") && line.endsWith("}"))
31 | )
32 | return true
33 | else return false
34 | }
35 |
36 | export { isVerboseOnly }
37 |
--------------------------------------------------------------------------------
/.github/ISSUE_TEMPLATE/bug_report.md:
--------------------------------------------------------------------------------
1 | ---
2 | name: Bug report
3 | about: Create a report to help us improve
4 | title: "[BUG]"
5 | labels: Bug
6 | assignees: ''
7 |
8 | ---
9 |
10 | **Describe the bug**
11 | A clear and concise description of what the bug is.
12 |
13 | **To Reproduce**
14 | Steps to reproduce the behavior:
15 | 1. Go to '...'
16 | 2. Click on '....'
17 | 3. Scroll down to '....'
18 | 4. See error
19 |
20 | **Expected behavior**
21 | A clear and concise description of what you expected to happen.
22 |
23 | **Screenshots**
24 | If applicable, add screenshots to help explain your problem.
25 |
26 | **ESP3D Firmware: (please complete the following information)**
27 | - Version:[e.g 2.1b4]
28 | - Web UI Version:[e.g 2.1b14]
29 | - Wifi mode:[e.g. STA]
30 | - Any change done in FW
31 |
32 | **Target Firmware: (please complete the following information)**
33 | - Name: [e.g. Marlin]
34 | - Version [e.g. 2.0]
35 |
36 | **Board used (please complete the following information):**
37 | - MCU: [e.g. ESP32]
38 | - Name:[e.g. NodeMCU2s]
39 | - Flash size: [e.g. 4M: 2M/2M]
40 |
41 | **Browser used (please complete the following information):**
42 | - Name: [e.g. Chrome]
43 | - Version [e.g. 2.0]
44 | - Operating system [e.g. Windows 10]
45 |
46 | **Additional context**
47 | Add any other context about the problem here.
48 | Developer tools output, error message, etc...
49 |
--------------------------------------------------------------------------------
/src/components/Controls/Fields/Label.js:
--------------------------------------------------------------------------------
1 | /*
2 | Label.js - ESP3D WebUI component file
3 |
4 | Copyright (c) 2021 Alexandre Aussourd. All rights reserved.
5 | Modified by Luc LEBOSSE 2021
6 |
7 | This code is free software; you can redistribute it and/or
8 | modify it under the terms of the GNU Lesser General Public
9 | License as published by the Free Software Foundation; either
10 | version 2.1 of the License, or (at your option) any later version.
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 | You should have received a copy of the GNU Lesser General Public
16 | License along with This code; if not, write to the Free Software
17 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
18 | */
19 |
20 | import { h } from "preact"
21 | import { useEffect } from "preact/hooks"
22 |
23 | const LabelCtrl = ({ label = "", id = "", value = "", setValue, ...rest }) => {
24 | useEffect(() => {
25 | //to update state when import or show first time as value will never change because it is a label not an input
26 | if (setValue) setValue(null, true)
27 | }, [value])
28 | return null
29 | }
30 |
31 | export default LabelCtrl
32 |
--------------------------------------------------------------------------------
/src/style/components/_menu.scss:
--------------------------------------------------------------------------------
1 | .menu-entry {
2 | }
3 |
4 | .menu-panel-item {
5 | display: flex;
6 | justify-content: space-between;
7 | }
8 | .text-menu-item {
9 | overflow: hidden;
10 | text-overflow: ellipsis;
11 | white-space: nowrap;
12 | margin-right: 5px;
13 | }
14 |
15 | .menu-panel-item .feather-icon-container {
16 | vertical-align: middle;
17 | margin-top: 0.2rem;
18 | }
19 |
20 | .menu-item {
21 | color: #5755d9;
22 | }
23 |
24 | .menu .menu-item > .menu-entry {
25 | border-radius: 0.2rem;
26 | color: inherit;
27 | display: block;
28 | margin: 0 -0.4rem;
29 | padding: 0.2rem 0.4rem;
30 | text-decoration: none;
31 | cursor: pointer;
32 | }
33 |
34 | .menu .menu-item > .menu-entry:focus,
35 | .menu .menu-item > .menu-entry:hover {
36 | background: #f1f1fc;
37 | color: #5755d9;
38 | }
39 |
40 | .menu-container,
41 | .information-container {
42 | flex: 0 1 auto;
43 | z-index: 10000;
44 | border: 0px !important;
45 | }
46 |
47 | .menu-item-panel{
48 | pointer-events: none!important;
49 | }
50 |
51 | .menu .menu-item > .menu-entry:active,
52 | .menu .menu-item > .menu-entry.active {
53 | background: inherit;
54 | color: inherit;
55 | }
56 |
57 | .panel .menu-item:active,
58 | .panel .menu-item.active {
59 | background: #5755d9;
60 | color: #f1f1fc;
61 | border-radius: 0.2rem;
62 | }
63 |
--------------------------------------------------------------------------------
/src/pages/extrapages/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | extrapage.js - ESP3D WebUI navigation page file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import {ExtraContent} from "../../components/ExtraContent"
22 |
23 | const ExtraPage = ({ id, source, refreshtime, label, type }) => {
24 | return (
25 |
34 | )
35 | }
36 |
37 | export default ExtraPage
38 |
--------------------------------------------------------------------------------
/src/style/components/_panel.scss:
--------------------------------------------------------------------------------
1 | .panel-dashboard,
2 | .panel-interface,
3 | .panel-features {
4 | user-select: none;
5 | -moz-user-select: none;
6 | -webkit-user-select: none;
7 | -ms-user-select: none;
8 | }
9 |
10 | .macro-buttons-panel {
11 | display: -ms-flexbox;
12 | display: flex;
13 | flex-flow: row wrap;
14 | justify-content: space-between;
15 | align-content: stretch;
16 | }
17 |
18 | .panel {
19 | display: -ms-flexbox;
20 | display: flex;
21 | flex-flow: column;
22 | height: 550px;
23 | overflow-y: auto !important;
24 | overflow-x: hidden !important;
25 | }
26 |
27 | .panel {
28 | background-color: #fff;
29 | color: #000;
30 | }
31 |
32 | .panel-body-dashboard,
33 | .panel-body-interface,
34 | .panel-body-features {
35 | display: -ms-flexbox;
36 | display: flex;
37 | flex-flow: column;
38 | }
39 | .panel .navbar,
40 | .panel .navbar-section {
41 | background: #f1f1fc;
42 | color: #5755d9;
43 | }
44 |
45 | .panel-item {
46 | flex: 0 1 auto;
47 | }
48 |
49 | .files-list-footer {
50 | padding: 0.2rem 0.8rem !important;
51 | }
52 |
53 | .column {
54 | .panel {
55 | height: 100%;
56 | box-shadow: 0px 0px 14px -5px rgba(0, 0, 0, 0.05);
57 | }
58 | }
59 |
60 | .loading-panel {
61 | display: flex;
62 | justify-content: center;
63 | align-items: center;
64 | height: 100%;
65 | width: 100%;
66 | }
67 |
--------------------------------------------------------------------------------
/extensions/click2go/webpack.config.js:
--------------------------------------------------------------------------------
1 | const path = require('path');
2 | const HtmlWebpackPlugin = require('html-webpack-plugin');
3 | const CompressionPlugin = require('compression-webpack-plugin');
4 | const FileManagerPlugin = require('filemanager-webpack-plugin');
5 |
6 | const htmlFileName = 'click2go.html';
7 |
8 | module.exports = {
9 | entry: `./src/${htmlFileName}`,
10 | output: {
11 | path: path.resolve(__dirname, 'dist'),
12 | },
13 | module: {
14 | rules: [
15 | {
16 | test: /\.html$/,
17 | use: ['html-loader'],
18 | },
19 | {
20 | test: /\.css$/,
21 | use: ['style-loader', 'css-loader'],
22 | },
23 | {
24 | test: /\.js$/,
25 | use: ['babel-loader'],
26 | },
27 | ],
28 | },
29 | plugins: [
30 | new HtmlWebpackPlugin({
31 | template: `./src/${htmlFileName}`,
32 | filename: htmlFileName,
33 | minify: {
34 | collapseWhitespace: true,
35 | removeComments: true,
36 | },
37 | inject: false,
38 | }),
39 | new CompressionPlugin({
40 | filename: '[path][base].gz',
41 | algorithm: 'gzip',
42 | test: /\.html$/,
43 | threshold: 0,
44 | minRatio: 1,
45 | }),
46 | new FileManagerPlugin({
47 | events: {
48 | onEnd: {
49 | delete: [`dist/${htmlFileName}`, 'dist/main.js'],
50 | },
51 | },
52 | }),
53 | ],
54 | };
55 |
--------------------------------------------------------------------------------
/extensions/gcodeViewer/webpack.config.js:
--------------------------------------------------------------------------------
1 | const path = require('path');
2 | const HtmlWebpackPlugin = require('html-webpack-plugin');
3 | const CompressionPlugin = require('compression-webpack-plugin');
4 | const FileManagerPlugin = require('filemanager-webpack-plugin');
5 |
6 | const htmlFileName = 'gcodeViewer.html';
7 |
8 | module.exports = {
9 | entry: `./src/${htmlFileName}`,
10 | output: {
11 | path: path.resolve(__dirname, 'dist'),
12 | },
13 | module: {
14 | rules: [
15 | {
16 | test: /\.html$/,
17 | use: ['html-loader'],
18 | },
19 | {
20 | test: /\.css$/,
21 | use: ['style-loader', 'css-loader'],
22 | },
23 | {
24 | test: /\.js$/,
25 | use: ['babel-loader'],
26 | },
27 | ],
28 | },
29 | plugins: [
30 | new HtmlWebpackPlugin({
31 | template: `./src/${htmlFileName}`,
32 | filename: htmlFileName,
33 | minify: {
34 | collapseWhitespace: true,
35 | removeComments: true,
36 | },
37 | inject: false,
38 | }),
39 | new CompressionPlugin({
40 | filename: '[path][base].gz',
41 | algorithm: 'gzip',
42 | test: /\.html$/,
43 | threshold: 0,
44 | minRatio: 1,
45 | }),
46 | new FileManagerPlugin({
47 | events: {
48 | onEnd: {
49 | delete: [`dist/${htmlFileName}`, 'dist/main.js'],
50 | },
51 | },
52 | }),
53 | ],
54 | };
55 |
--------------------------------------------------------------------------------
/src/components/Modal/confirmModal.js:
--------------------------------------------------------------------------------
1 | /*
2 | confirmationModal.js - ESP3D WebUI component file
3 |
4 | Copyright (c) 2021 Luc LEBOSSE. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 | import { HelpCircle } from "preact-feather"
20 | import { showModal } from "./genericModal"
21 |
22 | const showConfirmationModal = ({
23 | modals,
24 | title,
25 | content,
26 | button1,
27 | button2,
28 | }) => {
29 | showModal({
30 | modals,
31 | title,
32 | content,
33 | button1,
34 | button2,
35 | id: "confirmation",
36 | icon: ,
37 | hideclose: true,
38 | })
39 | }
40 |
41 | export { showConfirmationModal }
42 |
--------------------------------------------------------------------------------
/src/components/Helpers/storedState.js:
--------------------------------------------------------------------------------
1 | /*
2 | time.js - ESP3D WebUI helpers file
3 |
4 | Copyright (c) 2021 Luc LEBOSSE. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 | import { useState, useMemo } from "preact/hooks"
20 |
21 | export const useStoredState = (key, defaultValue) => {
22 | const stored = useMemo(() => {
23 | try {
24 | return JSON.parse(localStorage.getItem(key))
25 | } catch (e) {}
26 | })
27 | const [state, setInternalState] = useState(stored ?? defaultValue)
28 | const setState = (newState) => {
29 | setInternalState(newState)
30 | localStorage.setItem(key, JSON.stringify(newState))
31 | }
32 | return [state, setState]
33 | }
34 |
--------------------------------------------------------------------------------
/src/targets/helpers.js:
--------------------------------------------------------------------------------
1 | /*
2 | files.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { useUiContextFn } from "../contexts"
22 |
23 | //Check if filename is a file to be processed based on extension
24 | const canProcessFile = (filename) => {
25 | const filters = useUiContextFn.getValue("filesfilter").split(";")
26 | for (let index = 0; index < filters.length; index++) {
27 | if (
28 | filters[index] == "*" ||
29 | filename.trim().endsWith("." + filters[index])
30 | ) {
31 | return true
32 | }
33 | }
34 | return false
35 | }
36 |
37 | export { canProcessFile }
38 |
--------------------------------------------------------------------------------
/src/components/Controls/Fields/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI controls file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 |
22 | import Boolean from "./Boolean"
23 | import FormGroup from "./FormGroup"
24 | import Input from "./Input"
25 | import Select from "./Select"
26 | import PickUp from "./PickUp"
27 | import ItemsList from "./ItemsList"
28 | import IconSelect from "./IconSelect"
29 | import LabelCtrl from "./Label"
30 | import Slider from "./Slider"
31 | import Mask from "./Mask"
32 |
33 | export {
34 | Boolean,
35 | FormGroup,
36 | Input,
37 | Select,
38 | PickUp,
39 | ItemsList,
40 | IconSelect,
41 | LabelCtrl,
42 | Slider,
43 | Mask,
44 | }
45 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Smoothieware/stream.js:
--------------------------------------------------------------------------------
1 | /*
2 | stream.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { isTemperatures, isPositions } from "./filters"
22 |
23 | const isVerboseOnly = (type, data) => {
24 | const line = data.trim()
25 | if (
26 | isTemperatures(line) ||
27 | isPositions(line) ||
28 | line.trim().length == 0 ||
29 | line.startsWith("echo:") ||
30 | line.startsWith("ok") ||
31 | line.startsWith("M105") ||
32 | line.startsWith("SENSOR:") ||
33 | (line.startsWith("{") && line.endsWith("}"))
34 | )
35 | return true
36 | else return false
37 | }
38 |
39 | export { isVerboseOnly }
40 |
--------------------------------------------------------------------------------
/src/components/Controls/Modal.js:
--------------------------------------------------------------------------------
1 | /*
2 | Modal.js - ESP3D WebUI component file
3 |
4 | Copyright (c) 2021 Alexandre Aussourd. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 | import { createComponent } from "../Helpers"
20 |
21 | /*
22 | * Local const
23 | *
24 | */
25 | const modifiers = {
26 | lg: "text-lg",
27 | large: "text-lg",
28 | sm: "text-sm",
29 | small: "text-sm",
30 | }
31 | const Modal = createComponent("div", "modal", modifiers)
32 | Modal.Overlay = createComponent("a", "modal-overlay")
33 | Modal.Container = createComponent("div", "modal-container")
34 | Modal.Header = createComponent("div", "modal-header")
35 | Modal.Body = createComponent("div", "modal-body")
36 | Modal.Footer = createComponent("div", "modal-footer")
37 |
38 | export default Modal
39 |
--------------------------------------------------------------------------------
/src/targets/SandTable/GRBL/panels.js:
--------------------------------------------------------------------------------
1 | /*
2 | panels.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { FilesPanelElement } from "../../../components/Panels/Files"
22 | import { MacrosPanelElement } from "../../../components/Panels/Macros"
23 | import { TerminalPanelElement } from "../../../components/Panels/Terminal"
24 | import { JogPanelElement } from "../../../components/Panels/JogCNC"
25 | import { NotificationsPanelElement } from "../../../components/Panels/Notifications"
26 |
27 | const defaultPanelsList = [
28 | FilesPanelElement,
29 | TerminalPanelElement,
30 | MacrosPanelElement,
31 | JogPanelElement,
32 | NotificationsPanelElement,
33 | ]
34 |
35 | export { defaultPanelsList }
36 |
--------------------------------------------------------------------------------
/server/public/translate.html:
--------------------------------------------------------------------------------
1 |
27 |
28 |
34 |
35 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Repetier/stream.js:
--------------------------------------------------------------------------------
1 | /*
2 | stream.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { isTemperatures, isPositions } from "./filters"
22 |
23 | const isVerboseOnly = (type, data) => {
24 | const line = data.trim()
25 | if (
26 | isTemperatures(line) ||
27 | isPositions(line) ||
28 | line.trim().length == 0 ||
29 | line.startsWith("echo:") ||
30 | line.startsWith("ok") ||
31 | line.startsWith("wait") ||
32 | line.startsWith("busy") ||
33 | line.startsWith("M105") ||
34 | line.startsWith("SENSOR:") ||
35 | (line.startsWith("{") && line.endsWith("}"))
36 | )
37 | return true
38 | else return false
39 | }
40 |
41 | export { isVerboseOnly }
42 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Marlin-embedded/stream.js:
--------------------------------------------------------------------------------
1 | /*
2 | stream.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { isTemperatures, isPositions } from "./filters"
22 |
23 | const isVerboseOnly = (type, data) => {
24 | const line = data.trim()
25 | if (
26 | isTemperatures(line) ||
27 | isPositions(line) ||
28 | line.trim().length == 0 ||
29 | line.startsWith("echo:") ||
30 | line.startsWith("ok") ||
31 | line.startsWith("M105") ||
32 | line.startsWith("M114") ||
33 | line.startsWith("FR:") ||
34 | line.startsWith("SENSOR:") ||
35 | (line.startsWith("{") && line.endsWith("}"))
36 | )
37 | return true
38 | else return false
39 | }
40 |
41 | export { isVerboseOnly }
42 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Marlin/stream.js:
--------------------------------------------------------------------------------
1 | /*
2 | stream.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { isTemperatures, isPositions, isPrintStatus } from "./filters"
22 |
23 | const isVerboseOnly = (type, data) => {
24 | const line = data.trim()
25 | return (
26 | isTemperatures(line) ||
27 | isPositions(line) ||
28 | isPrintStatus(line) ||
29 | line.trim().length === 0 ||
30 | line.startsWith("echo:") ||
31 | line.startsWith("ok") ||
32 | line.startsWith("M105") ||
33 | line.startsWith("M106") ||
34 | line.startsWith("M114") ||
35 | line.startsWith("FR:") ||
36 | line.startsWith("SENSOR:") ||
37 | (line.startsWith("{") && line.endsWith("}"))
38 | )
39 | }
40 |
41 | export { isVerboseOnly }
42 |
--------------------------------------------------------------------------------
/src/components/Controls/CenterLeft.js:
--------------------------------------------------------------------------------
1 | /*
2 | Button.js - ESP3D WebUI component file
3 |
4 | Copyright (c) 2021 Luc LEBOSSE. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 |
20 | /*
21 | * Local const
22 | *
23 | */
24 | const CenterLeft = ({ bordered, children }) => {
25 | return (
26 |
27 |
39 | {children}
40 |
41 |
42 | )
43 | }
44 |
45 | export default CenterLeft
46 |
--------------------------------------------------------------------------------
/server/public/preferences.json:
--------------------------------------------------------------------------------
1 | {
2 | "settings": {
3 | "language": "default",
4 | "theme": "default",
5 | "autoload": true,
6 | "mobileview": false,
7 | "audio": false,
8 | "showsensorspanel": false,
9 | "enablepolling": false,
10 | "pollingrefresh": "3000",
11 | "pollingcommands": "M105",
12 | "showterminalpanel": true,
13 | "openterminalonstart": false,
14 | "verbose": true,
15 | "autoscroll": true,
16 | "showfilespanel": true,
17 | "openfilesonstart": false,
18 | "filesfilter": "g;G;gco;GCO;gcode;GCODE",
19 | "tftsd": false,
20 | "tftusb": false,
21 | "sd": false,
22 | "showjogpanel": true,
23 | "openjogonstart": false,
24 | "xyfeedrate": "1000",
25 | "zfeedrate": "1000",
26 | "xpos": "100",
27 | "ypos": "100",
28 | "zpos": "100",
29 | "homecmd": "G28 $",
30 | "motoroff": "M84",
31 | "emergencystop": "M112",
32 | "showmacrospanel": true,
33 | "openmacrosonstart": false,
34 | "macros": [],
35 | "showextracontents": false,
36 | "openextrapanelsonstart": false,
37 | "extracontents": [],
38 | "showtemperaturespanel": true,
39 | "opentemperaturesonstart": true,
40 | "extrudermax": "300",
41 | "extruderpreheat": "190;220;230",
42 | "bedmax": "140",
43 | "bedpreheat": "50;90;110",
44 | "chambermax": "140",
45 | "chamberpreheat": "50;90;110",
46 | "showextruderspanel": true,
47 | "openextrudersonstart": true,
48 | "ismixedextruder": false,
49 | "ecolors": "blue;red;green;#FF00FF",
50 | "efeedrate": "400",
51 | "enumber": "1",
52 | "showfanspanel": true,
53 | "openfansonstart": true,
54 | "showspeedpanel": false,
55 | "openspeedonstart": true,
56 | "showflowratepanel": false,
57 | "openflowrateonstart": true
58 | }
59 | }
--------------------------------------------------------------------------------
/src/components/Controls/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI controls file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 |
22 | import Button from "./Button"
23 | import ButtonImg from "./ButtonImg"
24 | import { Field } from "./Field"
25 | import { ScanApList } from "./ScanAp"
26 | import Loading from "./Loading"
27 | import Modal from "./Modal"
28 | import Toast from "./Toast"
29 | import Progress from "./Progress"
30 | import CenterLeft from "./CenterLeft"
31 | import FieldGroup from "./FieldGroup"
32 | import FullScreenButton from "./FullScreenButton"
33 | import CloseButton from "./CloseButton"
34 | import ContainerHelper from "./ContainerHelper"
35 |
36 | export {
37 | Button,
38 | ButtonImg,
39 | CenterLeft,
40 | CloseButton,
41 | ContainerHelper,
42 | Field,
43 | FieldGroup,
44 | FullScreenButton,
45 | Loading,
46 | Modal,
47 | Progress,
48 | ScanApList,
49 | Toast,
50 | }
51 |
--------------------------------------------------------------------------------
/src/targets/CNC/GRBL/variablesTable.js:
--------------------------------------------------------------------------------
1 | /*
2 | variablesTable.js - ESP3D WebUI helpers file
3 |
4 | Copyright (c) 2021 Luc LEBOSSE. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 |
20 | const variablesTable = [
21 | { name: "#pos_x#", value: 0 },
22 | { name: "#pos_y#", value: 0 },
23 | { name: "#pos_z#", value: 0 },
24 | { name: "#pos_a#", value: 1 },
25 | { name: "#pos_b#", value: 1 },
26 | { name: "#pos_c#", value: 0 },
27 | { name: "#pos_wx#", value: 0 },
28 | { name: "#pos_wy#", value: 0 },
29 | { name: "#pos_wz#", value: 0 },
30 | { name: "#pos_wa#", value: 0 },
31 | { name: "#pos_wb#", value: 0 },
32 | { name: "#pos_wc#", value: 0 },
33 | { name: "#prb_x#", value: 0 },
34 | { name: "#prb_y#", value: 0 },
35 | { name: "#prb_z#", value: 0 },
36 | { name: "#laser_max#", value: 0 },
37 | { name: "#selected_axis#", value: "X" },
38 | { name: "#probe_thickness#", value: 0 },
39 | ]
40 |
41 | export default variablesTable
42 |
--------------------------------------------------------------------------------
/src/targets/SandTable/GRBL/variablesTable.js:
--------------------------------------------------------------------------------
1 | /*
2 | variablesTable.js - ESP3D WebUI helpers file
3 |
4 | Copyright (c) 2021 Luc LEBOSSE. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 |
20 | const variablesTable = [
21 | { name: "#pos_x#", value: 0 },
22 | { name: "#pos_y#", value: 0 },
23 | { name: "#pos_z#", value: 0 },
24 | { name: "#pos_a#", value: 1 },
25 | { name: "#pos_b#", value: 1 },
26 | { name: "#pos_c#", value: 0 },
27 | { name: "#pos_wx#", value: 0 },
28 | { name: "#pos_wy#", value: 0 },
29 | { name: "#pos_wz#", value: 0 },
30 | { name: "#pos_wa#", value: 0 },
31 | { name: "#pos_wb#", value: 0 },
32 | { name: "#pos_wc#", value: 0 },
33 | { name: "#prb_x#", value: 0 },
34 | { name: "#prb_y#", value: 0 },
35 | { name: "#prb_z#", value: 0 },
36 | { name: "#laser_max#", value: 0 },
37 | { name: "#selected_axis#", value: "X" },
38 | { name: "#probe_thickness#", value: 0 },
39 | ]
40 |
41 | export default variablesTable
42 |
--------------------------------------------------------------------------------
/server/public/upload.html:
--------------------------------------------------------------------------------
1 |
38 |
39 |
45 |
46 |
--------------------------------------------------------------------------------
/src/targets/SandTable/Controls/BackgroundContainer.js:
--------------------------------------------------------------------------------
1 | /*
2 | BackgroundContainer.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { Fragment, h } from "preact"
21 | /*import { useEffect } from "preact/hooks"
22 | import { useTargetContext } from "../GRBL/TargetContext"
23 | import { useUiContext } from "../../../contexts"
24 | import { T } from "../../components/Translations"*/
25 |
26 | const BackgroundContainer = () => {
27 | /* const { alarmCode, errorCode } = useTargetContext()
28 | const { toasts } = useUiContext()
29 | useEffect(() => {
30 | if (alarmCode != 0 || errorCode != 0) {
31 | toasts.addToast({
32 | type: "error",
33 | content: T(
34 | alarmCode != 0 ? "ALARM:" + alarmCode : "error:" + errorCode
35 | ),
36 | })
37 | }
38 | }, [alarmCode, errorCode])*/
39 |
40 | return null
41 | }
42 |
43 | export { BackgroundContainer }
44 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Controls/BackgroundContainer.js:
--------------------------------------------------------------------------------
1 | /*
2 | BackgroundContainer.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { Fragment, h } from "preact"
21 | //import { useEffect } from "preact/hooks"
22 | //import { useTargetContext } from "../TargetContext"
23 | //import { useUiContext } from "../../../../contexts"
24 | //import { T } from "../../../../components/Translations"
25 |
26 | const BackgroundContainer = () => {
27 | //const { alarmCode, errorCode } = useTargetContext()
28 | // const { toasts } = useUiContext()
29 | /* useEffect(() => {
30 | if (alarmCode != 0 || errorCode != 0) {
31 | toasts.addToast({
32 | type: "error",
33 | content: T(
34 | alarmCode != 0 ? "ALARM:" + alarmCode : "error:" + errorCode
35 | ),
36 | })
37 | }
38 | }, [alarmCode, errorCode])*/
39 |
40 | return null
41 | }
42 |
43 | export { BackgroundContainer }
44 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Marlin/Controls/InformationsControls.js:
--------------------------------------------------------------------------------
1 | /*
2 | Informations.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { Fragment, h } from "preact"
21 | import { PositionsControls } from "../../../../components/Panels/Jog"
22 | import { TemperaturesControls } from "../../../../components/Panels/Temperatures"
23 | import { ExtraControls } from "../../../../components/Panels/ExtraControls"
24 | import { StatusControls } from "../../../../components/Panels/Status"
25 | import { useUiContextFn } from "../../../../contexts"
26 |
27 | const InformationsControls = () => {
28 | return (
29 |
30 | {useUiContextFn.getValue("showjogpanel") && }
31 | {useUiContextFn.getValue("showtemperaturespanel") && (
32 |
33 | )}
34 |
35 |
36 |
37 | )
38 | }
39 |
40 | export { InformationsControls }
41 |
--------------------------------------------------------------------------------
/extensions_samples/extension_settings.html:
--------------------------------------------------------------------------------
1 |
33 |
34 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Repetier/Controls/InformationsControls.js:
--------------------------------------------------------------------------------
1 | /*
2 | Informations.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { Fragment, h } from "preact"
21 | import { PositionsControls } from "../../../../components/Panels/Jog"
22 | import { TemperaturesControls } from "../../../../components/Panels/Temperatures"
23 | import { ExtraControls } from "../../../../components/Panels/ExtraControls"
24 | import { StatusControls } from "../../../../components/Panels/Status"
25 | import { useUiContextFn } from "../../../../contexts"
26 |
27 | const InformationsControls = () => {
28 | return (
29 |
30 | {useUiContextFn.getValue("showjogpanel") && }
31 | {useUiContextFn.getValue("showtemperaturespanel") && (
32 |
33 | )}
34 |
35 |
36 |
37 | )
38 | }
39 |
40 | export { InformationsControls }
41 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Smoothieware/Controls/InformationsControls.js:
--------------------------------------------------------------------------------
1 | /*
2 | Informations.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { Fragment, h } from "preact"
21 | import { PositionsControls } from "../../../../components/Panels/Jog"
22 | import { TemperaturesControls } from "../../../../components/Panels/Temperatures"
23 | import { ExtraControls } from "../../../../components/Panels/ExtraControls"
24 | import { StatusControls } from "../../../../components/Panels/Status"
25 | import { useUiContextFn } from "../../../../contexts"
26 |
27 | const InformationsControls = () => {
28 | return (
29 |
30 | {useUiContextFn.getValue("showjogpanel") && }
31 | {useUiContextFn.getValue("showtemperaturespanel") && (
32 |
33 | )}
34 |
35 |
36 |
37 | )
38 | }
39 |
40 | export { InformationsControls }
41 |
--------------------------------------------------------------------------------
/src/targets/Printer3D/Marlin-embedded/Controls/InformationsControls.js:
--------------------------------------------------------------------------------
1 | /*
2 | Informations.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { Fragment, h } from "preact"
21 | import { PositionsControls } from "../../../../components/Panels/Jog"
22 | import { TemperaturesControls } from "../../../../components/Panels/Temperatures"
23 | import { ExtraControls } from "../../../../components/Panels/ExtraControls"
24 | import { StatusControls } from "../../../../components/Panels/Status"
25 | import { useUiContextFn } from "../../../../contexts"
26 |
27 | const InformationsControls = () => {
28 | return (
29 |
30 | {useUiContextFn.getValue("showjogpanel") && }
31 | {useUiContextFn.getValue("showtemperaturespanel") && (
32 |
33 | )}
34 |
35 |
36 |
37 | )
38 | }
39 |
40 | export { InformationsControls }
41 |
--------------------------------------------------------------------------------
/src/targets/CNC/GRBL/Controls/BackgroundContainer.js:
--------------------------------------------------------------------------------
1 | /*
2 | BackgroundContainer.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { Fragment, h } from "preact"
21 | import { useEffect } from "preact/hooks"
22 | import { useTargetContext } from "../../.."
23 | import { useUiContext } from "../../../../contexts"
24 | import { T } from "../../../../components/Translations"
25 |
26 | const BackgroundContainer = () => {
27 | const { alarmCode, errorCode, status } = useTargetContext()
28 | const { toasts } = useUiContext()
29 | useEffect(() => {
30 | //console.log(status)
31 |
32 | if (alarmCode != 0 || errorCode != 0) {
33 | toasts.addToast({
34 | type: "error",
35 | content: T(
36 | alarmCode != 0 ? "ALARM:" + alarmCode : "error:" + errorCode
37 | ),
38 | })
39 | }
40 | }, [alarmCode, errorCode, status])
41 |
42 | return null
43 | }
44 |
45 | export { BackgroundContainer }
46 |
--------------------------------------------------------------------------------
/src/targets/CNC/GRBL/Controls/InformationsControls.js:
--------------------------------------------------------------------------------
1 | /*
2 | Informations.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { Fragment, h } from "preact"
21 | import { PositionsControls } from "../../../../components/Panels/JogCNC"
22 | import { StatusControls } from "../../../../components/Panels/StatusCNC"
23 | import { SpindleControls } from "../../../../components/Panels/SpindleCNC"
24 | import { LaserControls } from "../../../../components/Panels/LaserCNC"
25 | import { OverridesControls } from "../../../../components/Panels/OverridesCNC"
26 | import { useUiContextFn } from "../../../../contexts"
27 |
28 | const InformationsControls = () => {
29 | return (
30 |
31 |
32 | {useUiContextFn.getValue("showjogpanel") && }
33 |
34 | {!useUiContextFn.getValue("showspindlepanel") && }
35 |
36 |
37 | )
38 | }
39 |
40 | export { InformationsControls }
41 |
--------------------------------------------------------------------------------
/src/targets/CNC/grblHAL/Controls/InformationsControls.js:
--------------------------------------------------------------------------------
1 | /*
2 | Informations.js - ESP3D WebUI Target file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { Fragment, h } from "preact"
21 | import { PositionsControls } from "../../../../components/Panels/JogCNC"
22 | import { StatusControls } from "../../../../components/Panels/StatusCNC"
23 | import { SpindleControls } from "../../../../components/Panels/SpindleCNC"
24 | import { LaserControls } from "../../../../components/Panels/LaserCNC"
25 | import { OverridesControls } from "../../../../components/Panels/OverridesCNC"
26 | import { useUiContextFn } from "../../../../contexts"
27 |
28 | const InformationsControls = () => {
29 | return (
30 |
31 |
32 | {useUiContextFn.getValue("showjogpanel") && }
33 |
34 | {!useUiContextFn.getValue("showspindlepanel") && }
35 |
36 |
37 | )
38 | }
39 |
40 | export { InformationsControls }
41 |
--------------------------------------------------------------------------------
/src/targets/SandTable/style/_index.scss:
--------------------------------------------------------------------------------
1 | .H-100 {
2 | height: 100%;
3 | }
4 |
5 | .W-100 {
6 | width: 100%;
7 | }
8 |
9 | .jog-container {
10 | display: flex;
11 | height: 100%;
12 | width: 100%;
13 | flex-direction: column;
14 | justify-content: space-evenly;
15 | align-items: center;
16 | }
17 |
18 | .jog-positions-ctrls {
19 | display: flex;
20 | width: 100%;
21 | justify-content: space-evenly;
22 | }
23 |
24 | .jog-position-ctrl {
25 | min-width: 3rem;
26 | border: 0.05rem solid #dadee4;
27 | border-radius: 5px;
28 | }
29 | .jog-position-sub-header,
30 | .jog-position-header {
31 | border-bottom: 0.05rem solid #dadee4;
32 | color: #5755d9;
33 | background-color: #f1f1fc;
34 | display: flex;
35 | justify-content: center;
36 | align-items: center;
37 | font-weight: bold;
38 | font-size: 70%;
39 | }
40 |
41 | .jog-position-header {
42 | border-radius: 5px 5px 0px 0px;
43 | }
44 |
45 | .jog-position-value {
46 | display: flex;
47 | justify-content: center;
48 | align-items: center;
49 | color: #5755d9;
50 | font-size: 80%;
51 | }
52 |
53 | .jog-buttons-container-horizontal,
54 | .jog-buttons-container {
55 | display: flex;
56 | justify-content: space-between;
57 | border: 0.05rem solid #dadee4;
58 | border-radius: 5px;
59 | }
60 |
61 | .jog-buttons-container {
62 | flex-direction: column;
63 | }
64 |
65 | .jog-buttons-main-container {
66 | display: flex;
67 | justify-content: space-between;
68 | }
69 |
70 | .jog-distance-selector-container {
71 | display: flex;
72 | flex-direction: column;
73 | justify-content: center;
74 | }
75 |
76 | .jog-distance-selector-header {
77 | border: 0.05rem solid #5755d9 !important;
78 | border-radius: 5px 5px 0px 0px;
79 | color: #5755d9;
80 | background-color: #f1f1fc;
81 | }
82 |
--------------------------------------------------------------------------------
/src/contexts/index.js:
--------------------------------------------------------------------------------
1 | /*
2 | index.js - ESP3D WebUI context file
3 |
4 | Copyright (c) 2020 Luc Lebosse. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 |
11 | This code is distributed in the hope that it will be useful,
12 | but WITHOUT ANY WARRANTY; without even the implied warranty of
13 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 | Lesser General Public License for more details.
15 |
16 | You should have received a copy of the GNU Lesser General Public
17 | License along with This code; if not, write to the Free Software
18 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
19 | */
20 | import { h } from "preact"
21 | import { RouterContextProvider, useRouterContext } from "./RouterContext"
22 | import {
23 | HttpQueueContextProvider,
24 | useHttpQueueContext,
25 | } from "./HttpQueueContext"
26 | import { UiContextProvider, useUiContext, useUiContextFn } from "./UiContext"
27 | import {
28 | SettingsContextProvider,
29 | useSettingsContext,
30 | useSettingsContextFn,
31 | } from "./SettingsContext"
32 | import { DatasContextProvider, useDatasContext } from "./DatasContext"
33 | import { WsContextProvider, useWsContext } from "./WsContext"
34 |
35 | export {
36 | RouterContextProvider,
37 | useRouterContext,
38 | HttpQueueContextProvider,
39 | useHttpQueueContext,
40 | UiContextProvider,
41 | useUiContext,
42 | useUiContextFn,
43 | SettingsContextProvider,
44 | useSettingsContext,
45 | DatasContextProvider,
46 | useDatasContext,
47 | WsContextProvider,
48 | useWsContext,
49 | useSettingsContextFn,
50 | }
51 |
--------------------------------------------------------------------------------
/src/components/Controls/Button.js:
--------------------------------------------------------------------------------
1 | /*
2 | Button.js - ESP3D WebUI component file
3 |
4 | Copyright (c) 2021 Alexandre Aussourd. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 | import { createComponent } from "../Helpers"
20 |
21 | /*
22 | * Local const
23 | *
24 | */
25 |
26 | const modifiers = {
27 | donotdisable: "do-not-disable",
28 | group: "input-group-btn",
29 | link: "btn-link",
30 | primary: "btn-primary",
31 | error: "btn-error",
32 | success: "btn-success",
33 | lg: "btn-lg",
34 | sm: "btn-sm",
35 | xs: "btn-xs",
36 | block: "btn-block",
37 | action: "btn-action",
38 | circle: "s-circle",
39 | active: "active",
40 | disable: "disable",
41 | loading: "loading",
42 | tooltip: "tooltip",
43 | btooltip: "tooltip-bottom",
44 | ltooltip: "tooltip tooltip-left",
45 | rtooltip: "tooltip tooltip-right",
46 | mx2: "mx-2",
47 | m05: "m-05",
48 | m2: "m-2",
49 | m1: "m-1",
50 | mt1: "mt-1",
51 | min2rem: "min2rem",
52 | min1rem: "min1rem",
53 | }
54 | const Button = createComponent("button", "btn", modifiers)
55 |
56 | export default Button
57 |
--------------------------------------------------------------------------------
/src/components/Helpers/time.js:
--------------------------------------------------------------------------------
1 | /*
2 | time.js - ESP3D WebUI helpers file
3 |
4 | Copyright (c) 2021 Luc LEBOSSE. All rights reserved.
5 |
6 | This code is free software; you can redistribute it and/or
7 | modify it under the terms of the GNU Lesser General Public
8 | License as published by the Free Software Foundation; either
9 | version 2.1 of the License, or (at your option) any later version.
10 | This code is distributed in the hope that it will be useful,
11 | but WITHOUT ANY WARRANTY; without even the implied warranty of
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 | Lesser General Public License for more details.
14 | You should have received a copy of the GNU Lesser General Public
15 | License along with This code; if not, write to the Free Software
16 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
17 | */
18 | import { h } from "preact"
19 |
20 | function getBrowserTimeZone() {
21 | const d = new Date()
22 | const offset = d.getTimezoneOffset()
23 | const sign = offset < 0 ? "+" : "-"
24 | const hours = Math.floor(Math.abs(offset) / 60)
25 | const minutes = Math.abs(offset) % 60
26 | return `${sign}${hours.toString().padStart(2, "0")}:${minutes
27 | .toString()
28 | .padStart(2, "0")}`
29 | }
30 |
31 | function getBrowserTime(time) {
32 | //ISO 8601 format string
33 | function padNumber(num, size) {
34 | const s = num.toString().padStart(size, "0")
35 | return s
36 | }
37 | const d = typeof time != "undefined" ? new Date(time) : new Date()
38 | return `${d.getFullYear()}-${padNumber(d.getMonth() + 1, 2)}-${padNumber(
39 | d.getDate(),
40 | 2
41 | )}T${padNumber(d.getHours(), 2)}:${padNumber(
42 | d.getMinutes(),
43 | 2
44 | )}:${padNumber(d.getSeconds(), 2)}`
45 | }
46 |
47 | export { getBrowserTime, getBrowserTimeZone }
48 |
--------------------------------------------------------------------------------
/src/components/Panels/index.js:
--------------------------------------------------------------------------------
1 | import { h } from "preact"
2 | import { ChevronDown } from "preact-feather"
3 | import { useUiContextFn } from "../../contexts"
4 |
5 | const Menu = ({ items }) => {
6 | return (
7 |