gravity/tool.js
2025-12-28 15:19:58 -06:00

23 lines
453 B
JavaScript

// Idea here is, tool can declare its parameters;
// can call back to toolbar for whatever...
// through toolbar can access sim
import {
TOOL_CLASSNAME,
} from './config.js';
export class Tool {
toolbar = undefined;
sim = undefined;
constructor(toolbar) {
this.toolbar = toolbar;
this.sim = this.toolbar.sim;
const div = document.createElement('div');
this.div = div;
div.classList.add(TOOL_CLASSNAME)
}
frame() {}
}