Commit graph

37 commits

Author SHA1 Message Date
Grovy311
8562d6eb83 cable-sizing: size for the protective device, not just the load; manual entry; icon position
- calculateCableSizing now selects cross-section against
  designCurrentA = max(operatingCurrentA, existingProtectionRatedCurrentA)
  instead of the load current alone. A breaker only trips at its own rated
  current (In), so a cable sized for the actual load could overheat under
  sustained current below that threshold - the standard In <= Iz rule.
  Voltage-drop calculation still uses the real operating current, only the
  capacity check changed. Alerts and the ok-summary now name the breaker as
  the limiting factor when it is one.
- Added a manual cable type/cross-section entry in the modal itself:
  running a calculation pre-fills these fields as a suggestion, but they
  are the single field that actually gets applied, and stay editable -
  this restores the direct manual-entry capability the modal replaced when
  it took over the cableSummary/cableCrossSection cell click.
- Fixed calculator icon position from a trailing ::after (inconsistent
  position depending on cell text length, easy to miss on empty cells) to
  a fixed-position ::before, so it is always in the same place regardless
  of whether cable data is already filled in.
- No new display for the existing protection device - it already has its
  own Schutz column in this app.
2026-08-07 18:02:28 +02:00
Grovy311
d22f150cbe cable-sizing: trigger on both cable columns, calculator icon
Trigger now matches cableSummary OR cableCrossSection so it still
shows up regardless of which cable-related column a user has visible
(column visibility is a per-browser preference in this app, not fixed
- see docs/cable-sizing-module.md coupling note). Icon changed to a
calculator glyph.
2026-08-07 17:50:26 +02:00
Grovy311
068ec72fe2 cable-sizing: fix trigger column and add visible affordance
The trigger was wired to the cableCrossSection column, which is not in
the default visible column set - the actually visible "Kabel" column
is cableSummary (a computed cableType/cableCrossSection/cableLength
join). Editing cableSummary already maps to the remark field rather
than the underlying cable data (see buildCircuitEditPatch), so this
column was effectively a read-only display already; retargeting the
trigger there loses no existing manual-edit capability. Also adds
.cell-cable-sizing-trigger styling (mirrors .cell-protection-trigger)
so the trigger is visually discoverable, which the initial version was
missing entirely.
2026-08-07 17:49:08 +02:00
a17e2e3f4b Merge remote-tracking branch 'origin/feature/amev-picker-and-collapsible-sidebar' 2026-08-06 22:01:54 +02:00
64ccd1f829 Add dark mode toggle in the sidebar
Adds a persistent dark/light theme toggle (localStorage +
data-bs-theme on <html>) so it applies globally, including the
circuit editor route which has no visible sidebar. An inline
beforeInteractive script sets the theme before hydration to avoid a
flash of the wrong theme.

Bootstrap components pick up data-bs-theme automatically; the custom
circuit-grid CSS previously used ~150 hardcoded hex colors, all
converted to semantic tokens in globals.css with light/dark values.

Verified with a headless-browser pass across the project list, project
detail page, circuit editor, project-device drawer and a settings
modal in both themes; no console errors.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-06 21:56:21 +02:00
Grovy311
9bd22dfcb7 Add AMEV Gleichzeitigkeitsfaktor-Auswähler und einklappbare Seitenleiste
- Gzf-Picker-Modal mit AMEV-Tabelle 3 (Planungshilfe für elektrische
  Leistungsbilanzen) im Projektgerät-Modal und im globalen Geräteformular
- Docker-Deploy-Tooling (docker-start.sh, run-migrations.js) für den
  produktiven Container
- Seitenleiste ist jetzt einklappbar (Icon-only, Zustand in localStorage)
2026-08-03 17:07:14 +02:00
facf788ce8 Remove circuit structure preview 2026-07-31 14:52:37 +02:00
bd8dd09f79 Open circuit protection from grid cell 2026-07-31 10:02:11 +02:00
f4bfef9071 Merge branch 'main' into feature/multiplesections 2026-07-31 09:00:39 +02:00
756e307bd8 Manage distribution board components 2026-07-31 07:29:25 +02:00
31589875b5 Render protected circuit structure 2026-07-31 07:22:26 +02:00
Grovy311
704f4df2a8 Apply Petrol/Volt/Kupfer design system and project sidebar
Bring the Econsult-family design tokens (see design-system-econsult.md)
into leistungsbilanz-ts and add a persistent sidebar for the projects
area, mirroring elt-planung-suite / Einsatz-Orga. The sidebar lists all
projects and, inside a project, jumps to its sections; the tree editor
stays sidebar-free since it needs the full width. The projects overview
page is decluttered to a single stacked column (create/import/global
devices) now that the project list lives in the sidebar.
2026-07-30 17:40:11 +02:00
9ea081179d Add distribution power summaries 2026-07-29 19:02:18 +02:00
602ae6da0b Compact circuit grid columns 2026-07-29 11:12:24 +02:00
096ba8aa1c Standardize phase type labels 2026-07-29 10:46:00 +02:00
0180f768ac Improve editor totals and formatting 2026-07-29 08:26:03 +02:00
edf245a21c Use full-width editor device drawer 2026-07-28 20:43:08 +02:00
7257deacdc Redesign and translate grid controls 2026-07-22 23:19:21 +02:00
fafccca50f Redesign grid filter menu 2026-07-22 23:04:03 +02:00
d1615bcfee Clarify active grid filters 2026-07-22 22:57:25 +02:00
d0b8239085 Contain circuit editor scrolling 2026-07-22 22:44:49 +02:00
b3a7ff79da Confirm cross-section device moves 2026-07-22 20:31:55 +02:00
f8802fecdb Harden grid deletion and BMK validation 2026-07-22 20:27:01 +02:00
b1e19a88d5 Started multiline manipulations 2026-05-05 21:20:09 +02:00
47dec0df39 Added column sorting 2026-05-05 20:48:54 +02:00
1aace105c7 Filter/Sort working with renumbering afterwards 2026-05-05 18:50:59 +02:00
9b9e67bf0c Undo Redo working 2026-05-05 09:55:08 +02:00
75435475fc Drag and drop working 2026-05-04 23:27:13 +02:00
897e506b74 Drag and drop working 2026-05-04 23:00:22 +02:00
efbb81c13d Project devices sidebar working 2026-05-04 19:00:21 +02:00
48b4dd0fc0 Editor fully working as expected 2026-05-04 18:42:20 +02:00
ad498f2bb5 New usable editor 2026-05-03 23:00:46 +02:00
d1ce485572 Added 1B, 2 and added bootstrap again for site 2026-05-03 22:04:45 +02:00
65819900b1 Rewrite frontend, added rooms, voltage selection per project, startet with todos 2026-05-01 17:07:56 +02:00
81d47ce16f Added power sum per distributionboard 2026-04-30 22:04:08 +02:00
245a5b1485 Added distributionboards 2026-04-30 21:43:45 +02:00
ac48e03404 First frontend 2026-04-30 21:37:21 +02:00