Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
62 commits
Select commit Hold shift + click to select a range
35d5764
add: first draft
Nov 4, 2025
c064d42
add: working examples
Nov 4, 2025
9fbb696
Merge pull request #584 from sensebox/main
Thiemann96 Nov 5, 2025
e4e271a
edit: remove unused buttons
Nov 5, 2025
6961557
remove: accordions add: connect wizard as bar
Nov 5, 2025
2966996
update: toolbox
Nov 6, 2025
8bbd391
add: background image
Nov 6, 2025
939fa02
fix: concat blocks
Nov 6, 2025
cea0496
remove:logs
Nov 6, 2025
cdd3ccc
add: new icons and text
Nov 7, 2025
17ea535
change: mcu mini appearance
Nov 6, 2025
6371436
add: more tests
Nov 6, 2025
45d42d2
remove: blocks not supported by esp
Nov 6, 2025
1f7fd1a
fix: mcu mini
Nov 10, 2025
6f86797
add: refresh logic to user management
Nov 12, 2025
1ff31d0
fix:env
Nov 14, 2025
f77f70a
add: env to gitignore
Nov 14, 2025
e136f82
add: navigation in bottom right
Nov 14, 2025
9abece0
add: margin to have navigation always visible
Nov 14, 2025
a551da1
add: border to slides
Nov 14, 2025
6b07a0e
add: tooltips for button in navigation
Nov 14, 2025
8f96102
add: blockquote styling
Nov 14, 2025
2fd39c3
styles: add tutorial table and blockquote styles
Nov 14, 2025
035f6ed
fix: navigation when tutorial is present
Nov 25, 2025
3e5321f
add: h5p to builder and viewer
Nov 25, 2025
326ca38
add: h5p to viewer
Nov 25, 2025
4895011
remove: unused logs
Nov 25, 2025
cb15a89
remove: unused imports
Nov 25, 2025
1504d9a
add: first draft
Nov 4, 2025
f49aaa7
add: navigation in bottom right
Nov 14, 2025
4468095
add: margin to have navigation always visible
Nov 14, 2025
5aad2c7
add: border to slides
Nov 14, 2025
18f0fcc
add: tooltips for button in navigation
Nov 14, 2025
2dc2870
add: blockquote styling
Nov 14, 2025
5aab8e3
fix: navigation when tutorial is present
Nov 25, 2025
9f2a4d2
add: navigation in bottom right
Nov 14, 2025
6fd7a5f
add: margin to have navigation always visible
Nov 14, 2025
103bb29
add: border to slides
Nov 14, 2025
1fb4644
add: tooltips for button in navigation
Nov 14, 2025
d1e295c
add: blockquote styling
Nov 14, 2025
83aa83c
fix: navigation when tutorial is present
Nov 25, 2025
64e8414
add: navigation in bottom right
Nov 14, 2025
43e285f
add: margin to have navigation always visible
Nov 14, 2025
4f2b395
add: border to slides
Nov 14, 2025
02b0831
add: tooltips for button in navigation
Nov 14, 2025
44ae24b
add: blockquote styling
Nov 14, 2025
16e3758
fix: navigation when tutorial is present
Nov 25, 2025
b394d60
fix: logs and device filter
Nov 26, 2025
01c74ac
fix: browser freezing on loop
Nov 26, 2025
e78740a
fix: now sends disconnect flag
Nov 26, 2025
7e11208
fix: display
Nov 26, 2025
84ea723
remove: not working blocks for now
Nov 26, 2025
238674b
add: first tutorial
Nov 26, 2025
88a1986
add: flashtool for sensebox basic
Nov 26, 2025
5e27901
add: better tutorial
Nov 27, 2025
6a4f033
fix: percent number
Nov 27, 2025
f7ab7e6
fix: import error
Nov 27, 2025
59cc499
fix: import errors
Nov 27, 2025
baa9324
fix: copy button in log
Nov 27, 2025
2ff9fbd
add: sensors
Nov 27, 2025
759f1d8
Merge pull request #602 from sensebox/basic_addSensors
Thiemann96 Nov 27, 2025
24a5bbb
add: if-else block and repeat x times block
Thiemann96 Jan 19, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ VITE_INITIAL_COMPILER_URL=https://compiler.sensebox.de

VITE_BOARD=sensebox-mcu
VITE_BLOCKLY_API=https://api.testing.sensebox.de

# VITE_BLOCKLY_API=http://localhost:8080
GENERATE_SOURCEMAP=false

# in days
Expand Down
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
.env.development.local
.env.test.local
.env.production.local

.env
npm-debug.log*
yarn-debug.log*
yarn-error.log*
Expand Down
85 changes: 54 additions & 31 deletions cypress/e2e/blockly.cy.js
Original file line number Diff line number Diff line change
@@ -1,20 +1,41 @@
/// <reference types="cypress" />

describe("Blockly Editor Page Tests", () => {
const boards = [
{ name: "senseBox ESP", alt: "Sensebox ESP", expected: "MCU-S2" },
{ name: "senseBox MCU", alt: "Sensebox MCU", expected: "MCU" },
{ name: "senseBox Mini", alt: "Sensebox Mini", expected: "MCU:MINI" },
];

it("[Blockly] visits the editor page", () => {
cy.visit("/");
});

it("[Blockly] visits the tutorial page", () => {
cy.visit("/tutorial");

cy.get("h1, h2, h3")
.contains(/tutorial/i)
.should("be.visible");
});

it("[Blockly] visits the gallery page", () => {
cy.visit("/gallery");

cy.get("h1, h2, h3, h4")
.contains(/gallery/i)
.should("be.visible");
});

it("[Blockly] visits the faq page", () => {
cy.visit("/faq");

// ✅ Check that a headline exists with the text "FAQ" (non case-sensitive)
cy.get("h1, h2, h3")
.invoke("text")
.then((text) => {
expect(text.toLowerCase()).to.include("faq");
});
});

it("[Blockly] visits the settings page", () => {
Expand All @@ -29,61 +50,69 @@ describe("Blockly Editor Page Tests", () => {
cy.visit("/");
cy.get('img[alt="Sensebox ESP"]').click();

// get a button that has an SVG with the class "fa-bars" inside it
// this is the button that opens the menu
// open the sidebar (button with fa-bars icon)
const menuButton = cy.get("button").find("svg.fa-bars").parents("button");

// click the button
menuButton.click();

// click the a with href "/tutorial"
// navigate to tutorial
cy.get('a[href="/tutorial"]').click();
cy.wait(1000);
cy.url().should("include", "/tutorial");
cy.wait(1000);

// click the button
// navigate back to blockly
menuButton.click();

// click the a with href "/" and deep inside it an span containing "Blockly"
cy.get('a[href="/"]').find("span").contains("Blockly").parents("a").click();
cy.wait(1000);
cy.url().should("include", "/");

// check if compile button exists
cy.get('button[aria-label="Compile code"]').should("exist");
});

it("[Blockly] selects senseBox ESP", () => {
cy.visit("/");
cy.get('img[alt="Sensebox ESP"]', { timeout: 8000 }).click();
});

it("[Blockly] selects senseBox MCU", () => {
cy.visit("/");
cy.get('img[alt="Sensebox MCU"]', { timeout: 8000 }).click();
// ✅ Extended board selection test (case-insensitive)
boards.forEach((board) => {
it(`[Blockly] selects ${board.name}`, () => {
cy.visit("/");

// Click the board image
cy.get(`img[alt="${board.alt}"]`, { timeout: 8000 }).click();

cy.wait(500); // give Redux and UI some time

// ✅ Check sessionStorage (non case-sensitive)
cy.window()
.its("sessionStorage")
.invoke("getItem", "board")
.then((value) => {
expect(value?.toLowerCase()).to.eq(board.expected.toLowerCase());
});

// ✅ Check the navbar text (non case-sensitive)
cy.get("#navbar-selected-board")
.should("be.visible")
.invoke("text")
.then((text) => {
expect(text.trim().toLowerCase()).to.include(
board.expected.toLowerCase(),
);
});
});
});

it("[Blockly] selects senseBox Mini", () => {
cy.visit("/");
cy.get('img[alt="Sensebox Mini"]', { timeout: 8000 }).click();
}); /// <reference types="cypress" />

it("[Blockly] changes the language in settings and verifies via headline", () => {
cy.visit("/settings");

cy.get("#language-selector").click();

cy.get('li[data-value="en_US"]').click();

cy.get("#settingsLanguage")
.should("be.visible")
.and("contain.text", "Language");

// jetzt zurückwechseln auf Deutsch
// switch back to German
cy.get("#language-selector").click();
cy.get('li[data-value="de_DE"]').click();

// prüfen, ob die Überschrift wieder deutsch ist
cy.get("#settingsLanguage")
.should("be.visible")
.and("contain.text", "Sprache");
Expand All @@ -103,7 +132,6 @@ describe("Blockly Editor Page Tests", () => {
cy.get('img[alt="Sensebox ESP"]').click();
cy.get('button[aria-label="Compile code"]').click();

// check if the request was made
cy.wait("@compile", {
responseTimeout: 30000,
requestTimeout: 30000,
Expand All @@ -129,7 +157,6 @@ describe("Blockly Editor Page Tests", () => {
cy.get('img[alt="Sensebox MCU"]').click();
cy.get('button[aria-label="Compile code"]').click();

// check if the request was made
cy.wait("@compile", {
responseTimeout: 30000,
requestTimeout: 30000,
Expand All @@ -142,19 +169,15 @@ describe("Blockly Editor Page Tests", () => {
});

it("[Blockly] compiles code", () => {
// intercept the request to the compiler

cy.intercept({
method: "POST",
pathname: "/compile",
}).as("compile");

cy.visit("/");

cy.get('img[alt="Sensebox ESP"]').click();
cy.get('button[aria-label="Compile code"]').click();

// check if the request was made
cy.wait("@compile", {
responseTimeout: 30000,
requestTimeout: 30000,
Expand Down
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
"@uiw/react-md-editor": "^4.0.8",
"axios": "^1.13.1",
"blockly": "^12.3.0",
"esptool-js": "^0.5.7",
"file-saver": "^2.0.5",
"framer-motion": "^6.5.1",
"markdown-it": "^14.1.0",
Expand Down
Binary file added public/media/basic/tutorial/actionBar.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/media/basic/tutorial/flashtool.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/media/basic/tutorial/resetBtn.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/media/basic/tutorial/selectUSB.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/media/blockly/led_blue.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/media/blockly/led_off.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/media/blockly/led_red.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added public/media/blockly/led_yellow.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
20 changes: 20 additions & 0 deletions public/media/hardware/icons/Icon_BME680.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
32 changes: 32 additions & 0 deletions public/media/hardware/icons/Icon_LED_Blau.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
32 changes: 32 additions & 0 deletions public/media/hardware/icons/Icon_LED_Gelb.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
25 changes: 25 additions & 0 deletions public/media/hardware/icons/Icon_LED_OFF.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
32 changes: 32 additions & 0 deletions public/media/hardware/icons/Icon_LED_Rot.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
23 changes: 23 additions & 0 deletions public/media/hardware/icons/Icon_Luftfeuchtigkeit.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
20 changes: 20 additions & 0 deletions public/media/hardware/icons/Icon_OLED-Display.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading