Repository navigation
Releases: spyshow/ProCal
Release list
v1.5.3 - Cable Schedule i18n, Tooltip & Telemetry Fixes
QA pass over the v1.5.2 cable-schedule rework found and fixed five issues. All browser-verified: 12/12 checks, 0 console errors, health score 92 → 100 on measured categories.
Fixes
i18n regression (high). The building-card subtitle called t('common.buildingLoads') — a key that does not exist. Because I18nProvider only falls back when i18n.exists() fails, a hardcoded English building loads fragment rendered in every locale:
de: 3 Etagen · 0 Techniketagen · 0 Wohnungen / Einheiten · 0 building loads
ar: 3 عدد الطوابق · 0 طوابق الخدمات · 0 شقق · 0 building loads
In Arabic this was worse than wrong text: the Latin fragment rendered LTR inside an RTL line, landing on the wrong side of the sentence. Repointed at cableSchedule.buildingLoads; now renders Gebäudelasten / أحمال المبنى / Carichi Edificio.
Column tooltip (medium). title={t('cableSchedule.load', 'Circuit & Tag identifier')} — the key exists and resolves to Load, so the fallback was silently discarded and the header advertised a different column. Now a literal, matching its 13 siblings.
10 orphaned i18n keys removed from all four locales, left behind when the Full Width and Phase Details toggles were deleted in 6bd935b. Verified unreferenced and unreachable by dynamic key construction.
Dev hygiene. Strict-Transport-Security (2-year preload) and CSP upgrade-insecure-requests were served in development, so Chrome attempted HTTPS navigations against the HTTP dev server — four ERR_CONNECTION_RESET console errors on every /login load. Both are now production-only.
Privacy. Clarity telemetry was running against local dev. layout.tsx carried a second, duplicated inline script with the project ID hardcoded, bypassing NEXT_PUBLIC_CLARITY_PROJECT_ID entirely — so no local configuration could disable it. layout.tsx now renders the existing ClarityAnalytics component, making the component the single source of truth and the env var authoritative. Local telemetry requests went 6 → 0.
Tests
Added src/i18n/locales.regression-1.test.ts (6 tests) pinning the i18n keys these fixes depend on and asserting the two touched pages reference only resolvable keys. Proven non-vacuous: reintroducing the bad key fails the suite with expected [ 'common.buildingLoads' ] to deeply equal [].
A repo-wide "every key resolves" check was deliberately not added — 73 keys are already missing across 960 t() call sites as pre-existing debt, so such a test would ship red. The new test scopes to the two affected pages with an explicit allowlist that should shrink.
Verification
tsc --noEmitcleaneslint0 errors (4 pre-existing unused-var warnings incable-schedule)vitest795 passed across 68 filesnext buildsucceeds
Also confirmed working
Sticky first column (pinned through horizontal scroll), no page overflow at 375/768/1280/1920, per-phase L1/L2/L3/Neutral columns correctly removed, MethodSelector unclipped at 375px, Load-library tab label localized in all four languages, RTL mirroring.
Not covered
No accessibility audit (axe/Lighthouse not run) and no performance measurement. The cable-schedule editing flows — inline size/method/insulation edits, Recalculate All, Apply-to-database, Default Settings — were not exercised; the diff touched the table shell, not the cell editors.
v1.5.2 - Screen-Adaptive Cable Schedule & UI Refinements
Highlights in v1.5.2
- Screen-Adaptive Cable Schedule: Fluid layout adapting smoothly across viewport sizes with responsive cell density and zero wasted horizontal space.
- Streamlined Cable Schedule Controls: Cleaned up toolbar by removing manual 'Full Width' toggle and 'Phase Details' columns.
- Sticky Circuit Tag Column: Pinned first column with theme-adaptive solid backgrounds and full RTL direction support for easy circuit tracking during horizontal scroll.
- Compact Selectors & Headers: Streamlined installation method selectors and concise localized table headers with informative tooltips.
- Room Density Synchronization: Automatically syncs apartment room load density with project engineering settings when switching room types.
- Service Load Library: Refined nomenclature across project details and load managers.
v1.5.1 - Theme Selector, Light & Parchment UI Polish, and Cable Shadow Refinements
Changes in v1.5.1
- Appearance & Theme Selector: Added quick theme selector dropdown in the footer with full support and persistence across Midnight CAD (Dark), CAD Blueprint (Light), and Drafting Warm (Parchment) themes.
- Homepage, Login & Signup Polish: Fixed card background colors, borders, typography contrast, and form controls across light and parchment themes.
- Enclosure & Switchgear Shadows: Refined top PG glands and RAL-7032 switchgear enclosures with theme-adaptive, light-toned shadows and luminous ambient back-glow in dark mode.
- Cable Drop Shadows: Implemented pure Gaussian blur diffusion filter with subtle physical offset and reduced cable shadow opacity by 50% across all themes for a delicate, refined look.
- Pricing Tier Cards: Fixed featured 'Professional' tier card contrast and ensured 100% solid, opaque 'Most Popular' badge.
v1.5.0 - Free Engineering Tools, Motor Inrush Sizing & Platform Enhancements
ProCal v1.5.0 Release Notes
- Free Engineering Tools Suite at /tools: Cable Sizer, Max Length, Motor Protection & HVAC, Short-Circuit, Protection Coordination, Max Demand, Transformer/Generator Sizer.
- Motor Starting Inrush Cable Sizing: Dual-constraint calculation for both continuous running and inrush voltage drop with interactive limit selection.
- ProCal Conversion Moat: Unified electrical design banner driving single-tool visitors into multi-building full project workflows.
- Landing Page Hero CTA: 'Try our Free Tools' linking directly to /tools\ with multilingual (EN/AR) support.
- UI Typography & Sidebar Enhancements: Increased navigation font sizes ( ext-sm), icon sizes, and expanded width (260px) for improved legibility across desktop and tablet screens.
- Production Deployment & Startup Self-Healing: Automated migration recovery script (scripts/pre-start.js), BOM removal from migrations, and automatic initial admin seeding.
Release v1.4.7
Features & Enhancements
- Project Settings Hub: Added dedicated project-level settings tab in /projects/[id]?tab=settings\ covering General Specifications, Engineering Defaults, and Company & Branding with a live report header preview.
- Sidebar Dynamic Routing: Updated the sidebar footer Settings button to link directly to active project settings when a project is selected, or global settings when none is active.
- Streamlined User Settings: Cleaned up /settings\ to strictly manage user-level preferences (Appearance & Theme, Language & RTL, and Account & Security).
- Live Theme Hover Preview: Hovering over any theme card dynamically renders the Live Engineering Preview table and headers in that theme palette in real-time.
v1.4.5 - User Role Profile Integration, Syrian Independence Flag & Active Menu Theme Contrast
What's Changed in ProCal v1.4.5
- TopHeader User Role Integration: Relocated user role badge (\PM, \QA, \Eng) from inside the project selector button to the User Profile identity button in the top navigation, expanding project selector max-width and eliminating title truncation.
- Syrian Independence Flag: Replaced the Arabic language selector flag icon with the green Syrian independence flag (green-white-black tricolor with three red 5-pointed stars) using high-fidelity vector SVGs.
- Active Menu High-Contrast Styling: Resolved text legibility issues across themes by defining explicit CSS tokens (--sidebar-active-fg, --sidebar-active-bg, --sidebar-active-border) across Midnight CAD (dark), CAD Blueprint (light), and Drafting Warm themes.
- Dynamic Riser Diagram Node Rendering: Enabled dynamic floor box heights to comfortably render all circuits per floor without truncation or node collision.
- QA Punchlist Drawer Improvements: Corrected backdrop coverage and active theme hover styling for the dismiss button.
v1.4.2 - Voltage Drop Upsizing Rationale in Cable Ampacity Trace
Changes in v1.4.2
- Voltage Drop Upsizing Detection: The Calculation Trace Engine now detects when a conductor is upsized above its base thermal requirement ( \ge I_n$) solely to satisfy allowable voltage drop limits (IEC 60364-5-52 §525 / NEC 210.19(A)).
- Voltage Drop Upsizing Gate Step: Adds a dedicated mathematical step showing the base thermal size, the excessive voltage drop at that size over the circuit length, and the upsized cable size that brings the voltage drop within compliance.
- Trace Parameters Provenance: Displays \Sizing Governing Factor: Voltage Drop, \Base Thermal Requirement, \Circuit Route Length, and \Calculated Voltage Drop (ΔU).
- Clarified Compliance Margin: Explains continuous margin above $ in the trace compliance banner as a consequence of voltage drop upsizing.
- Full Internationalization: Added English, Arabic, German, and Italian translations for all new trace labels, parameters, and margins.
- Build & Tests: All 720 tests pass across 60 test files; production build verified with Next.js Turbopack.
Release v1.4.1
Release v1.4.1 - MDB and SMDB Circuit Breaker Hierarchy & Apartment MCB Sizing
- Upstream Feeder from MDB / Subpanel Main Incomer: Always an MCCB (IEC 60947-2, minimum 160AF, 36kA+ or ACB >= 630A).
- Subpanel Outgoing Circuits: All circuits <= 63A default to domestic MCB (IEC 60898-1). Heavy equipment (> 63A or high-power 3-phase motors) uses an MCCB.
- Apartment Circuit Sizing: Sized to design demand current (e.g. Ib = 23.9A -> 32A MCB) instead of 100% undiversified connected load.
- Trace Modal Engine: Displays realistic modular DIN-rail frame, Icn rating, and IEC 60898-1 citation for MCBs.
v1.4 - Full-Width Application Layouts & Centered Riser Diagram
Changes in v1.4
- Full-Width Application Layouts: Standardized wide container dimensions (\w-full max-w-[1680px] mx-auto min-h-[80vh]) across Engineering Reports, Breaker Schedule, Load Calculator, Protection Coordination Studio, Panel Designer, Vertical Riser, Dashboard, and Administration modules, aligning with the Cable Schedule design standard.
- Centered Vertical Riser SVG: Wrapped the Vertical Riser diagram in a responsive centering container with dynamic zoom-aware bounding (\w-fit min-w-full flex justify-center), eliminating left-margin bias on wide viewports.
- Report Logo Protection: Enhanced logo rendering constraints with \max-w-[140px]\ alongside \h-6\ to guarantee submittal page layout integrity against panoramic aspect ratios.
v1.3.9.2 - Server-Side Headless Chromium PDF Generation & TrueType CMap Compliance
Changes in v1.3.9.2
-
Server-Side Headless Chromium PDF Generation (1-Click Download):
- Added authenticated endpoint
GET /api/projects/[id]/pdfgenerating executive submittal packages in memory using Puppeteer and headless Chromium (@sparticuz/chromiumon serverless Linux, local Chrome/Edge auto-detection on Windows/macOS). - Configured with landscape A4 dimensions, high-DPI scaling, and
maxDuration = 60. - Stitches all 8 schedules (
CoverPage,LoadSchedule,MDBSchedule,CableSchedule,BreakerSchedule,VDSchedule,ShortCircuitSchedule,BOMSchedule) withReportHeaderand standalone Base64-compiled CSS.
- Added authenticated endpoint
-
100% Compliant TrueType /ToUnicode CMaps & Clean Text Extraction:
- Embedded installable TrueType fonts (
Arial,Consolas) with complete/ToUnicodeCMaps, eliminating previous PDF parser extraction failures and(cid:XX)glyph errors in PyPDF2, pdfminer, and Adobe Acrobat. - Successfully verified on a 12-page submittal package with 11,393 extracted characters, 0 empty pages, and 0
(cid:XX)errors, with 100% fidelity for engineering symbols (3Φ,mm²,kA).
- Embedded installable TrueType fonts (
-
PDF Print Buffer Overflow & Hidden Calculation Cell Fixes:
- Eliminated font-outlining bezier explosion that caused printer spooler memory exhaustion on multi-page browser prints.
- Exempted interactive calculation elements inside table cells (
<TraceableCell>) from@media print { [role="button"] { display: none } }, ensuring full visibility across all printed tables.
-
Standardized Apparent Power (kVA) as Primary Engineering Metric:
- Updated Load Calculator summary cards, Executive Cover Page, SLD diagram headers, and Excel exports to prominently feature apparent power (kVA) for transformer and generator sizing, with active power (kW) and power factor clearly displayed in subtext.
-
Quality Assurance & Verification:
- Added unit and integration tests covering
renderReportHtmlandGET /api/projects/[id]/pdf. - Verified 100% passing test suite across all 60 test files (709 tests).
- Verified Next.js 16 production build (
next build) with 0 errors.
- Added unit and integration tests covering