Skip to content
This repository was archived by the owner on Nov 7, 2026. It is now read-only.
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ The format is loosely inspired by Keep a Changelog.

### Changed

- **Web 0.14.24, animation: while becomes for in lesson 13:** step 2 „Zählen mit festem Plan“ of the for loop lesson shows an animated structure chart: the while loop's start value (`int i = 1`), condition (`i <= 5`) and step (`i++`) light up one after another in their own colour and then move together into the head of the for loop, labelled Start, Bedingung, Schritt (en Init/Condition/Step, pt Início/Condição/Passo). It plays once when it scrolls into view; „Noch einmal abspielen“ replays it. With reduced motion only the end state is shown. New lesson block `::: grafik datei.svg animiert` (own SVG with CSS animation, no library).
- **Web 0.14.23, compact nested branches:** a two-way branch keeps both columns the same width only when neither column contains another branch or switch. Before, each nesting level doubled the width, so the drinks machine in lesson 10 step 2 (three nested branches) was about 3000 px wide and unreadable in the lesson and in the editor; now it is about half as wide, and 20 other lesson diagrams (e.g. VisuBot solutions, L17 ticket) get narrower too. Columns of a branch or switch inside a loop or another branch now always fill the box; before, the header could stay wider than its columns, so the if in lesson 14 step 3 looked like a loop (37 lesson diagrams affected). Wide diagrams in the lesson text no longer shrink below 60 % of their size; they scroll sideways instead.
- **Web 0.14.22, text case names in quotation marks:** in lesson 10 the traffic light structure chart now uses the case names `"rot"`, `"gelb"`, `"grün"` (en `"red"` …, pt `"vermelho"` …) and the calculator solution `"+"`, `"-"`, `"*"`, so it is clear they are texts and the generated Java (`case "rot" ->`) is valid. Lesson text, hint and quiz say so (de/en/pt). The simulation still accepts case names without quotes.
- **Web 0.14.21, array output like in Java:** `System.out.println(zahlen)` now prints a reference such as `[I@1e3779b1` in Simulation and Programmieren, as real Java does (`[D@`, `[Z@`, `[Ljava.lang.String;@`, `[[I@`; the same array keeps its id). `Arrays.toString(…)` and `Arrays.deepToString(…)` show the content; `Arrays` needs `import java.util.Arrays;` like javac, and the Java export adds it. The variable table still shows the content. Lesson 15 „Jetzt in Java“ explains reference and `Arrays.toString` (de/en/pt).
Expand Down
44 changes: 44 additions & 0 deletions web/lessons/bilder/en/l12-while-zu-for.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
44 changes: 44 additions & 0 deletions web/lessons/bilder/l12-while-zu-for.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
44 changes: 44 additions & 0 deletions web/lessons/bilder/pt/l12-while-zu-for.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions web/lessons/de/13-for-schleife.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ kurz: Mit Start, Bedingung und Schritt eine feste Anzahl von Durchläufen zähle

In der While-Schleife hast du schon mitgezählt: Startwert vor der Schleife, Bedingung im Kopf, Veränderung im Inhalt. Die **For-Schleife** schreibt diese drei Teile zusammen in den Kopf. So siehst du auf einen Blick, wie gezählt wird.

::: grafik l12-while-zu-for.svg animiert
Aus der While-Schleife wird eine For-Schleife: Start, Bedingung und Schritt wandern zusammen in den Kopf.
:::

Wenn du eine For-Schleife anklickst, hat sie rechts drei Felder:

- **Start:** `int i = 1` legt die Zählvariable an.
Expand Down
4 changes: 4 additions & 0 deletions web/lessons/en/13-for-schleife.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ kurz: Count a fixed number of passes with Init, Condition and Step.

In the while loop you already counted along: a start value before the loop, a condition in the head, a change inside. The **for loop** puts these three parts together in the head. That way you see at a glance how it counts.

::: grafik l12-while-zu-for.svg animiert
The while loop becomes a for loop: init, condition and step move together into the head.
:::

When you click a for loop, it has three fields on the right:

- **Init:** `int i = 1` creates the counter variable.
Expand Down
4 changes: 4 additions & 0 deletions web/lessons/pt/13-for-schleife.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ kurz: Contar um número fixo de iterações com Início, Condição e Passo.

No ciclo while já foste contando: um valor inicial antes do ciclo, uma condição na cabeça, uma alteração no interior. O **ciclo for** junta estas três partes na cabeça. Assim vês num relance como ele conta.

::: grafik l12-while-zu-for.svg animiert
O ciclo while torna-se um ciclo for: o início, a condição e o passo juntam-se na cabeça.
:::

Quando clicas num ciclo for, ele tem três campos à direita:

- **Início:** `int i = 1` cria a variável contadora.
Expand Down
4 changes: 2 additions & 2 deletions web/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion web/package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "visustruct-web",
"private": true,
"version": "0.14.23",
"version": "0.14.24",
"type": "module",
"scripts": {
"dev": "vite",
Expand Down
1 change: 1 addition & 0 deletions web/src/i18n/de.strings
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@
"web_learn_solve_in_code" = "Löse diese Übung im %@.";
"web_learn_solve_in_both" = "Löse diese Übung im %1$@ und im %2$@.";
"web_learn_open_in_editor" = "Im Editor öffnen";
"web_learn_replay" = "Noch einmal abspielen";
"web_learn_graphic_labels" = "👆 Klick aufs Bild: Beschriftung ein oder aus";
"web_learn_check" = "Prüfen";
"web_learn_hint" = "Tipp";
Expand Down
1 change: 1 addition & 0 deletions web/src/i18n/en.strings
Original file line number Diff line number Diff line change
Expand Up @@ -72,6 +72,7 @@
"web_learn_solve_in_code" = "Solve this exercise in the %@ area.";
"web_learn_solve_in_both" = "Solve this exercise in the %1$@ and %2$@ areas.";
"web_learn_open_in_editor" = "Open in editor";
"web_learn_replay" = "Play again";
"web_learn_graphic_labels" = "👆 Click the picture to show or hide the labels";
"web_learn_check" = "Check";
"web_learn_hint" = "Hint";
Expand Down
Loading
Loading