Thank you for your interest in contributing to Ideon! We appreciate your help in making this project better.
Ideon uses a Docker-standardized development environment to ensure high-fidelity performance and consistency across all machines.
- Docker & Docker Compose v2
- Node.js (for running checks and tests locally)
- Fork the repository and clone it locally.
- Configure the environment:
cp env.example .env # Edit .env and ensure SECRET_KEY is set (e.g. using openssl rand -hex 32) - Install local dependencies (required for IDE support and linting):
npm install
The development server runs within Docker to guarantee production-like performance, especially for large spatial canvases.
npm run devThis command will:
- Build the Ideon container images.
- Start the stack including the application and a PostgreSQL database.
- The app will be available at
http://localhost:3000.
Note: Ideon runs in production mode within Docker for maximum performance. You must run npm run dev each time you want to apply your changes, as this will trigger a rebuild of the local container image.
-
Install Pre-commit Hooks (Mandatory): This project uses
pre-committo ensure code quality before every commit.# Install pre-commit (if not already installed) # macOS: brew install pre-commit # Linux: sudo apt install pre-commit # Arch: sudo pacman -S pre-commit # Install the git hooks pre-commit install
-
Create a new branch for your feature or fix.
-
Make your changes.
-
Run Pre-commit Manually (Mandatory): You can run all checks on all files to verify your changes:
pre-commit run --all-files
-
Run Tests & Quality Checks (Mandatory): Before submitting your PR, you must ensure that all tests pass and code quality standards are met. The CI pipeline will fail if these checks do not pass.
# Run unit and integration tests npm run test # Run type checking and linting npm run check
-
Submit a Pull Request (PR) describing your changes. All pre-commit checks and CI workflows must pass.
- We use Prettier for formatting.
- We use ESLint for linting.
- Follow the existing naming conventions (camelCase for logic, PascalCase for components).
- No inline styles allowed (use CSS files).
- No hardcoded strings in the UI (use i18n dictionaries).
Blocks are a core feature in Ideon. Adding a new block type touches a few layers (database, graph persistence, UI registration). If you miss one, you can end up with a block that renders locally but fails when saving a snapshot or importing a project.
-
Start with the database
- Add a migration in
src/app/db/migrations/that allows the newblockTypein theblockstable. - This is required for snapshots, exports, and imports to work.
- Add a migration in
-
Update TypeScript types and validation
- Add the new type to
src/app/lib/types/db.ts(theblocksTable.blockTypeunion). - Update graph validation in
src/app/lib/graph.tsso the newblockTypeis accepted when saving and loading the canvas.
- Add the new type to
-
Register it in the UI
- Add an entry (type, icon, label key, section) in
src/app/components/project/blockTypeMeta.tsxso it shows up in the Add Block modal. - Add the label key to all i18n dictionaries in
src/app/i18n/.
- Add an entry (type, icon, label key, section) in
-
Render it on the canvas
- Create the block component in
src/app/components/project/. - Register the block in the
blockTypesmap insrc/app/components/project/ProjectCanvas.tsx.
- Create the block component in
-
Set sensible defaults for new blocks
- Ensure the block can be created from the UI by updating defaults in
src/app/components/project/hooks/useProjectCanvasGraph.ts(size and initial metadata if needed).
- Ensure the block can be created from the UI by updating defaults in
-
Test the full flow
- Create the block, take a snapshot, refresh the page, and confirm it still loads.
- Export a project and import it back, and confirm the block round-trips.
- Run:
npm run checknpm run testnpm run validate:i18n
Ideon supports dynamic language loading. To add a new language:
- Create a new JSON file in
src/app/i18n/(e.g.,es.jsonfor Spanish). - Add the
__labelkey at the root of the JSON object. This is the name that will appear in the language selector. - Add all required translation keys (copy the structure from
en.json).
Example es.json:
{
"__label": "Español",
"title": "Ideon",
"subtitle": "...",
...
}The application will automatically detect the new file and add it to the language selection menu. No code changes are required.
By contributing, you agree that your contributions will be licensed under the project's AGPLv3 License.