Embed options and URL parameters

Pass options to AthanorEmbed.create: smiles or molfile to open with, tools for the toolbar, readOnly, theme, label, stereo, src, height and timeout. Each has a URL parameter on the editor address.

On a Mac, Ctrl is Cmd.

Option (create) URL parameter Meaning
smiles smiles Open with this structure
molfile molfile (base64url) Open with this molfile, V2000 or V3000. Wins over smiles
tools tools The toolbar tools, in order: any of select, bond, ring, charge, text, erase, arrow, shape, annotate, orbital. Default select,bond,ring,charge,text,erase. An empty list hides the tools
readOnly readonly=1 View only: no toolbar and no editing; the wheel still zooms and pans
theme theme dark or light. Default: the reader's own preference
label label What a screen reader calls the editor. Default "Structure editor"
stereo stereo=1 Show R/S and E/Z labels on stereocenters. Off by default
(set for you) origin The origins allowed to talk to the editor, comma-separated. The script sets it to your page's origin
src The Athanor app's address, if not the site the script came from
height The iframe's CSS height. Default 100% of the container
timeout How long create waits for the handshake, in ms. Default 20000

The editor's address

The editor is the app's #/embed route, for example:

https://athanor.arbastro.com/app/#/embed?smiles=CCO&origin=https%3A%2F%2Flms.example.edu

The keyboard works as in the full editor: tool letters, an element letter with the pointer on an atom, Delete, Ctrl+Z and Ctrl+Y.

Warning

The app is served under /app/. The script address without /app/ returns the app's HTML page, which a browser refuses to run as a script.

Is this helpful?

Last updated Nov 12, 2026