A client-side chemistry workspace combining seven interactive calculation engines, IUPAC datasets, and real-time physical simulations in a unified neobrutalist interface.
ChemKit consolidates seven chemistry calculators and reference tools into a single, zero-dependency browser application. All calculations run client-side using validated algorithms and standard IUPAC atomic weights. The interface features neobrutalist typography, tactile micro-interactions, full keyboard navigation, and theme synchronization across light and dark modes.
| Tool | Route | Governing Formulas | Primary Function |
|---|---|---|---|
| Element Explorer | /elements |
Periodic Law | 18-column interactive periodic table with category filters, atomic radii, electron configurations, and one-click export to MoleMate. |
| MoleMate | /moles |
|
Computes molar mass breakdowns, mass-to-mole conversions across units (mg, g, kg), and particle counts with hydrate support (e.g. CuSO4·5H2O). |
| GasLab | /gas-laws |
|
Solves Boyle, Charles, Gay-Lussac, Avogadro, and Ideal Gas Law equations with automated multi-unit conversions (atm, kPa, bar, L, mL, K, °C). |
| Chemical Balancer | /balancer |
Conservation of Mass | Computes whole-number stoichiometric coefficients via null-space matrix reduction. Verifies atom counts with direct handoff to stoichiometry. |
| Stoichiometry Solver | /stoichiometry |
Mole ratios ( |
Mole-to-mole and gram-to-gram conversions with automatic equation balancing, limiting reactant verification, and step-by-step unit factor work. |
| pH Calculator | /ph |
|
Conversions between pH, pOH, |
| SolutionLab | /solutions |
|
Molarity, volumetric dilution, mass concentration ( |
Each calculator integrates visual feedback tied directly to the underlying calculation states:
-
Dynamic pH Beaker: An SVG volumetric beaker with universal indicator spectrum mapping (crimson acid
$\to$ emerald neutral$\to$ royal violet alkali), continuous meniscus wave motion, and rising solute micro-bubbles. - Kinetic Gas Chamber: A cylinder with a movable piston head that raises or lowers based on volume ratios, an analog pressure gauge with active needle deflection, and kinetic gas particles whose velocity scales with temperature in Kelvin.
- Catalyst Reaction Shimmer: Equation balancing and stoichiometry solutions trigger an emerald reaction wave across coefficients with animated atom conservation checks.
ChemKit is designed for keyboard-first operation:
| Shortcut | Action |
|---|---|
| Ctrl + K / Cmd + K | Open Command Palette (search tools or jump to any chemical formula) |
| 1 – 7 | Direct jump to tool tabs (1: Elements, 2: Moles, 3: Gas, 4: Balancer, etc.) |
| Tab / Shift + Tab | Cycle through interactive inputs and calculation triggers |
| Esc | Close dialogs, command palette, and clear focused overlays |
The codebase separates pure calculation math from UI components to guarantee deterministic results and straightforward unit testing:
ChemKit/
├── src/
│ ├── lib/ # Pure TypeScript/JavaScript chemistry engines
│ │ ├── elements.js # Complete 118-element IUPAC dataset
│ │ ├── molar-mass.js # Chemical formula tokenizer and molecular weight calculator
│ │ ├── balancer.js # Matrix-based linear equation balancer
│ │ ├── gas-laws.js # Gas law solver and unit transformation tables
│ │ ├── stoichiometry.js # Stoichiometric conversion solver
│ │ ├── ph.js # Acid-base equilibrium and dissociation solver
│ │ └── solutions.js # Solution concentration and dilution engines
│ ├── tools/ # Interactive tool views
│ │ ├── ElementExplorer.jsx
│ │ ├── MoleMate.jsx
│ │ ├── GasLab.jsx
│ │ ├── ChemBalancer.jsx
│ │ ├── StoichiometrySolver.jsx
│ │ ├── PhCalculator.jsx
│ │ └── SolutionLab.jsx
│ ├── components/ # Shared accessible UI primitives (Select, CommandPalette, Icons)
│ ├── hooks/ # Local storage and platform shortcuts
│ ├── App.jsx # Application shell, router, and tab switcher
│ └── index.css # Design tokens, neobrutalist utilities, and keyframe animations
├── test/ # Node.js built-in test runner test suites (46 tests)
└── logo/ # Brand marks, SVG assets, and design guidelines
- Node.js 20+
- npm 10+
# Clone the repository
git clone https://github.com/AK-Lmn/ChemKit.git
cd ChemKit
# Install dependencies
npm install
# Run test suite
npm test
# Start local development server
npm run dev
# Build for production
npm run buildAll engines are tested against textbook chemistry problems:
$ npm test
✔ balances combustion
✔ balances polyatomic group
✔ ideal gas law solves P, V, n, and T
✔ unit-aware gas law solver handles mixed units
✔ element dataset covers all 118 elements
✔ parses nested grouping with parentheses, brackets, and braces
✔ converts across all 6 standard pH, pOH, [H+], and [OH-] modes
✔ solves weak acid and weak base dissociation using exact quadratic
✔ solves M1V1 = M2V2 dilution for every variable
✔ solves mole-to-mole and gram-to-gram stoichiometry accurately
ℹ tests 46
ℹ pass 46
ℹ fail 0MIT © AK-Lmn