diff --git a/examples/css/base.css b/examples/base.css similarity index 100% rename from examples/css/base.css rename to examples/base.css diff --git a/examples/generic_editor.html b/examples/generic_editor.html deleted file mode 100644 index 510b01bc..00000000 --- a/examples/generic_editor.html +++ /dev/null @@ -1,15 +0,0 @@ - - - - - Generic editor - OpenChemLib JS examples - - - - -

Generic editor

-
-
- - - diff --git a/examples/generic_editor.ts b/examples/generic_editor.ts deleted file mode 100644 index b758fa1c..00000000 --- a/examples/generic_editor.ts +++ /dev/null @@ -1,14 +0,0 @@ -import OCL from '../distesm/full.pretty'; - -const editorArea = document.getElementById('editor-area') as HTMLElement; -const eventsArea = document.getElementById('events-area') as HTMLElement; - -const editor = new OCL.CanvasEditor(editorArea); - -const molecule = OCL.Molecule.fromSmiles('COCO'); -editor.setMolecule(molecule); - -editor.setOnChangeListener((event) => { - console.log('change', event); - eventsArea.innerText = `Type: ${event.type}; User event: ${event.isUserEvent}`; -}); diff --git a/examples/generic_editor_poc.html b/examples/generic_editor/demo.html similarity index 85% rename from examples/generic_editor_poc.html rename to examples/generic_editor/demo.html index 40b1676b..6df46f1b 100644 --- a/examples/generic_editor_poc.html +++ b/examples/generic_editor/demo.html @@ -3,7 +3,9 @@ Generic editor - PoC - + + +
OpenChemLib JS examples - +

OpenChemLib JS examples

- +
+

Generic editor

+ +