function bruh_moment(){alert("this is a bruh moment")}const downloadToFile=(e,t,n)=>{const o=document.createElement("a");n=new Blob([e],{type:n});o.href=URL.createObjectURL(n),o.download=t,o.click(),URL.revokeObjectURL(o.href)};function get_smiles_from_element_text(e){e=`https://pubchem.ncbi.nlm.nih.gov/rest/pug/compound/name/${document.getElementById(e).value}/property/CanonicalSMILES/JSON`;console.log(e),fetch(e).then(e=>e.json()).then(e=>{console.log("Aye, got that dub from PubChem"),document.getElementById("inputSMILES").value=e.PropertyTable.Properties[0].CanonicalSMILES}).catch(e=>{throw bruh_moment(),e})}function draw_me_like_one_of_your_french_girls(e){e.condense_abbreviations();var t=document.getElementById("draw-output"),e=e.get_svg();t.outerHTML="
"+e+"
",document.getElementById("drawing-1").children[0].setAttribute("height","100%"),document.getElementById("drawing-1").children[0].setAttribute("width","100%")}function calculate_and_disperse(e){const t=["NumUnspecifiedAtomStereoCenters","NumAliphaticHeterocycles","NumSaturatedHeterocycles","NumAromaticHeterocycles","NumAmideBonds","NumAromaticRings","NumAliphaticRings","NumSaturatedRings","NumSpiroAtoms","NumBridgeheadAtoms","NumAtomStereoCenters"];try{var n=JSON.parse(e.get_descriptors())}catch(e){alert("oo wee, failed to calculate descriptors senpai")}let o=document.getElementById("analyse_table");var r=Object.keys(n);for(let e=0;e